From a24beb36feaa46f39cbb26ce5277e84f91241ce8 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期四, 26 三月 2020 01:30:05 +0800 Subject: [PATCH] 2020-03-26 --- src/tabviews/zshare/verifycard/tabcard/actionform/index.jsx | 53 +++++++++++++---------------------------------------- 1 files changed, 13 insertions(+), 40 deletions(-) diff --git a/src/tabviews/zshare/verifycard/actionform/index.jsx b/src/tabviews/zshare/verifycard/tabcard/actionform/index.jsx similarity index 67% rename from src/tabviews/zshare/verifycard/actionform/index.jsx rename to src/tabviews/zshare/verifycard/tabcard/actionform/index.jsx index 7f9581b..4599334 100644 --- a/src/tabviews/zshare/verifycard/actionform/index.jsx +++ b/src/tabviews/zshare/verifycard/tabcard/actionform/index.jsx @@ -1,6 +1,6 @@ import React, {Component} from 'react' import PropTypes from 'prop-types' -import { Form, Row, Col, Select, Button, Input, Cascader } from 'antd' +import { Form, Row, Col, Button, Input, Cascader } from 'antd' import './index.scss' const shortkeycode = { @@ -86,10 +86,6 @@ shortcut: _shortcut } - if (record.OpenType === 'funcbutton' && record.funcType === 'print') { - item.printer = record.printer || '' - } - this.props.form.setFieldsValue(item) }) } @@ -105,11 +101,6 @@ this.setState({ editItem: null - }, () => { - this.props.form.setFieldsValue({ - shortcut: [], - label: '' - }) }) } }) @@ -129,11 +120,9 @@ } } - let hasprint = editItem && editItem.OpenType === 'funcbutton' && editItem.funcType === 'print' - return ( - <Form {...formItemLayout} className="verify-form" id="verifycard1"> - <Row gutter={24}> + <Form {...formItemLayout} className="verify-form"> + {editItem ? <Row gutter={24}> <Col span={10}> <Form.Item label={'鍚嶇О'}> {getFieldDecorator('label', { @@ -154,34 +143,18 @@ </Form.Item> </Col> <Col span={4} className="add"> - <Form.Item label=" " colon={false} > - <Button onClick={this.handleConfirm} type="primary" className="add-row"> - 纭畾 - </Button> + <Button onClick={this.handleConfirm} type="primary" className="add-row"> + 纭畾 + </Button> + </Col> + </Row> : null} + {!editItem ? <Row gutter={24} style={{height: '64px', paddingTop: '5px'}}> + <Col span={24} className="print-tip"> + <Form.Item label={'鎻愮ず'}> + 鐐瑰嚮缂栬緫鍥炬爣鍙缃寜閽搴旂殑蹇嵎閿紝娉細蹇嵎閿缃噸澶嶆椂锛屼細浠ユ帓搴忓湪鍓嶇殑鎸夐挳涓哄噯銆� </Form.Item> </Col> - {hasprint ? - <Col span={10}> - <Form.Item label={'鎵撳嵃鏈�'}> - {getFieldDecorator('printer', { - initialValue: '', - rules: [ - { - required: true, - message: '璇烽�夋嫨鎵撳嵃鏈�!' - } - ] - })( - <Select> - {editItem.printers && editItem.printers.map(option => - <Select.Option id={option.value} title={option.text} key={option.value} value={option.value}>{option.text}</Select.Option> - )} - </Select> - )} - </Form.Item> - </Col> : null - } - </Row> + </Row> : null} </Form> ) } -- Gitblit v1.8.0