From ff045a6a19e2e0bd5c2433aae71145401627c22d Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期四, 19 十二月 2019 19:08:32 +0800 Subject: [PATCH] 2019-12-19 --- src/templates/comtableconfig/editcard/index.jsx | 7 +++++-- 1 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/templates/comtableconfig/editcard/index.jsx b/src/templates/comtableconfig/editcard/index.jsx index 6107cb4..f005744 100644 --- a/src/templates/comtableconfig/editcard/index.jsx +++ b/src/templates/comtableconfig/editcard/index.jsx @@ -10,14 +10,14 @@ let _type = props.card.type if (props.type === 'columns') { - if (_type !== 'picture') { + if (_type === 'date' || _type === 'datetime') { _type = 'text' } } else if (props.type === 'search') { if (_type === 'number') { _type = 'text' } else if (_type === 'datetime') { - _type = 'date' + _type = 'daterange' } } @@ -40,6 +40,8 @@ const { card } = this.state this.setState({ card: {...card, type: e.target.value} + }, () => { + this.props.changeCard(this.state.card) }) } @@ -62,6 +64,7 @@ {type === 'columns' ? <Radio.Group onChange={this.changeType} value={card.type} disabled={!card.selected}> <Radio value="text">text</Radio> + <Radio value="number">number</Radio> <Radio value="picture">picture</Radio> </Radio.Group> : null } -- Gitblit v1.8.0