From 3df2d3624c6b768d29670b537f8d6a71d3ef122c Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期日, 12 四月 2020 22:04:53 +0800 Subject: [PATCH] 2020-04-12 --- src/tabviews/zshare/verifycard/tabcard/index.jsx | 48 ++++++++++++++++++++++++++++++++---------------- 1 files changed, 32 insertions(+), 16 deletions(-) diff --git a/src/tabviews/zshare/verifycard/tabcard/index.jsx b/src/tabviews/zshare/verifycard/tabcard/index.jsx index 0264edc..2e3c712 100644 --- a/src/tabviews/zshare/verifycard/tabcard/index.jsx +++ b/src/tabviews/zshare/verifycard/tabcard/index.jsx @@ -1,6 +1,6 @@ import React, {Component} from 'react' import PropTypes from 'prop-types' -import { Form, Tabs, Row, Col, Radio, Table, Icon, Select, notification } from 'antd' +import { Form, Tabs, Row, Col, Radio, Table, Icon, Select, notification, Input } from 'antd' import ActionForm from './actionform' import ColumnForm from './columnform' @@ -516,6 +516,17 @@ this.props.handleconfig(config.uuid, subconfig) } + changeEasyCode = ({ target: { value } }) => { + const { config } = this.props + let subconfig = JSON.parse(JSON.stringify(this.state.subconfig)) + + subconfig.easyCode = value + + this.setState({ + subconfig: subconfig + }) + this.props.handleconfig(config.uuid, subconfig) + } render() { const { config } = this.props @@ -536,23 +547,12 @@ <TabPane tab="鍩虹璁剧疆" key="1"> <Form {...formItemLayout}> <Row gutter={24}> - {config.type === 'main' ? <Col span={8}> - <Form.Item label="鍥哄畾鎸夐挳"> - <Radio.Group defaultValue={config.setting.actionfixed ? 'true' : 'false'} onChange={this.changebtnfix}> - <Radio value="true">鏄�</Radio> - <Radio value="false">鍚�</Radio> - </Radio.Group> + {config.type === 'main' ? <Col span={9}> + <Form.Item label="鍔╄鐮�"> + <Input defaultValue={config.easyCode} placeholder="" autoComplete="off" onChange={this.changeEasyCode}/> </Form.Item> </Col> : null} - {config.type === 'main' ? <Col span={8}> - <Form.Item label="鍥哄畾琛ㄥご"> - <Radio.Group defaultValue={config.setting.columnfixed ? 'true' : 'false'} onChange={this.changecolfix}> - <Radio value="true">鏄�</Radio> - <Radio value="false">鍚�</Radio> - </Radio.Group> - </Form.Item> - </Col> : null} - <Col span={8}> + <Col span={9}> <Form.Item label="琛ㄦ牸灞炴��"> <Select defaultValue={config.setting.tableType} onChange={this.changecheckbox}> <Select.Option value="">涓嶅彲閫�</Select.Option> @@ -561,6 +561,22 @@ </Select> </Form.Item> </Col> + {config.type === 'main' ? <Col span={9}> + <Form.Item label="鍥哄畾鎸夐挳"> + <Radio.Group defaultValue={config.setting.actionfixed ? 'true' : 'false'} onChange={this.changebtnfix}> + <Radio value="true">鏄�</Radio> + <Radio value="false">鍚�</Radio> + </Radio.Group> + </Form.Item> + </Col> : null} + {config.type === 'main' ? <Col span={9}> + <Form.Item label="鍥哄畾琛ㄥご"> + <Radio.Group defaultValue={config.setting.columnfixed ? 'true' : 'false'} onChange={this.changecolfix}> + <Radio value="true">鏄�</Radio> + <Radio value="false">鍚�</Radio> + </Radio.Group> + </Form.Item> + </Col> : null} </Row> </Form> </TabPane> -- Gitblit v1.8.0