From c8dec113736cc78c47cd63377d756d364b42a94e Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期三, 23 四月 2025 16:39:15 +0800 Subject: [PATCH] Merge branch 'develop' --- src/templates/sharecomponent/actioncomponent/verifyexcelin/index.jsx | 27 +++++++++++++++++---------- 1 files changed, 17 insertions(+), 10 deletions(-) diff --git a/src/templates/sharecomponent/actioncomponent/verifyexcelin/index.jsx b/src/templates/sharecomponent/actioncomponent/verifyexcelin/index.jsx index be7041f..c1fca30 100644 --- a/src/templates/sharecomponent/actioncomponent/verifyexcelin/index.jsx +++ b/src/templates/sharecomponent/actioncomponent/verifyexcelin/index.jsx @@ -2,7 +2,7 @@ import PropTypes from 'prop-types' import { fromJS } from 'immutable' import { Form, Tabs, Row, Col, Input, Button, Popconfirm, Tooltip, notification, Modal, message, InputNumber, Radio, Typography } from 'antd' -import { EditOutlined, QuestionCircleOutlined, StopOutlined, CheckCircleOutlined, SwapOutlined, DeleteOutlined } from '@ant-design/icons' +import { EditOutlined, QuestionCircleOutlined, StopOutlined, CheckCircleOutlined, SwapOutlined, DeleteOutlined, ExclamationOutlined } from '@ant-design/icons' import moment from 'moment' import Api from '@/api' @@ -78,6 +78,8 @@ { value: 'Decimal(18,2)', text: 'Decimal(18,2)' }, { value: 'Decimal(18,4)', text: 'Decimal(18,4)' }, { value: 'Decimal(18,6)', text: 'Decimal(18,6)' }, + { value: 'Decimal(18,8)', text: 'Decimal(18,8)' }, + { value: 'Decimal(18,10)', text: 'Decimal(18,10)' }, { value: 'date', text: 'date' }, { value: 'datetime', text: 'datetime' } ] @@ -119,7 +121,7 @@ unlimit: true, editable: true, keyVals: ['Int', 'Decimal(18,0)', 'Decimal(18,2)', 'Decimal(18,4)', 'Decimal(18,6)'], - render: (text, record) => /^Decimal/ig.test(record.type) || /^int/ig.test(record.type) ? text : '' + render: (text, record) => record.required === 'true' && (/^Decimal/ig.test(record.type) || /^int/ig.test(record.type)) ? text : '' }, { @@ -131,7 +133,7 @@ unlimit: true, editable: true, keyVals: ['Int', 'Decimal(18,0)', 'Decimal(18,2)', 'Decimal(18,4)', 'Decimal(18,6)'], - render: (text, record) => /^Decimal/ig.test(record.type) || /^int/ig.test(record.type) ? text : '' + render: (text, record) => record.required === 'true' && (/^Decimal/ig.test(record.type) || /^int/ig.test(record.type)) ? text : '' } ], uniqueColumns: [ @@ -596,18 +598,18 @@ clearField = () => { const { verify } = this.state - const _this = this + const that = this confirm({ content: `纭畾娓呯┖Excel鍒楀悧锛焋, onOk() { - _this.setState({ + that.setState({ verify: { ...verify, columns: [] } }, () => { - _this.resetUniqueColumns() + that.resetUniqueColumns() }) }, onCancel() {} @@ -617,8 +619,8 @@ columnChange = (values, callback) => { let verify = JSON.parse(JSON.stringify(this.state.verify)) - let fields = verify.columns.map(item => item.Column) - if (fields.includes(values.Column)) { + let fields = verify.columns.map(item => item.Column.toLowerCase()) + if (fields.includes(values.Column.toLowerCase())) { notification.warning({ top: 92, message: values.Column + '瀛楁宸插瓨鍦紒', @@ -967,7 +969,12 @@ <div> {card.label ? <div className="mk-com-name">{card.label} - 楠岃瘉淇℃伅</div> : null} <Tabs activeKey={activeKey} className="excelin-verify-card-box" onChange={this.tabchange}> - <TabPane tab="鍩虹楠岃瘉" key="basemsg"> + <TabPane tab={ + <span> + 鍩虹楠岃瘉 + {verify.default === 'false' ? <span className="count-tip"><ExclamationOutlined style={{color: 'orange'}}/></span> : null} + </span> + } key="basemsg"> <Form {...formItemLayout}> <Row gutter={24}> {card.intertype === 'system' ? <Col span={8}> @@ -1074,7 +1081,7 @@ <Button className="excel-col-add mk-red" title="娓呯┖Excel鍒�" onClick={this.clearField}> 娓呯┖Excel鍒� </Button> - <Col style={{fontSize: '12px', color: '#757575', paddingLeft: '10px'}} span={24}>娉細鏁板�肩被鍨嬶紙int 鎴� decimal锛夛紝鍐呭涓哄繀濉紱鏈�澶у�煎拰鏈�灏忓�煎湪绫诲瀷涓烘暟鍊兼椂鏈夋晥銆傚鍏�-鍒濆鍖栵細鐢ㄤ簬excel涓笉瀛樺湪锛屽鍏ユ椂闇�瑕佸垵濮嬪寲鐨勫瓧娈�</Col> + <Col style={{fontSize: '12px', color: '#757575', paddingLeft: '10px'}} span={24}>娉細鏁板�肩被鍨嬶紙int 鎴� decimal锛夛紝鍐呭涓哄繀濉紱鏈�澶у�煎拰鏈�灏忓�煎湪绫诲瀷涓烘暟鍊兼椂锛堝繀濉級鏈夋晥銆傚鍏�-鍒濆鍖栵細鐢ㄤ簬excel涓笉瀛樺湪锛屽鍏ユ椂闇�瑕佸垵濮嬪寲鐨勫瓧娈�</Col> <EditTable actions={['edit', 'move', 'copy', 'del', 'extra:required:鏄惁蹇呭~']} searchKey={searchKey} type="excelcolumn" data={verify.columns} columns={excelColumns} onChange={this.changeColumns}/> </TabPane> {card.intertype === 'system' ? <TabPane tab={ -- Gitblit v1.8.0