Commit 43b738e252a4d0af7e7e65e5b4ea0a5280aca75d
Merge branch 'main' of http://git.xlyprint.cn/zhangz/xlyUmi into main
Showing
7 changed files
with
53 additions
and
18 deletions
src/components/Common/CommonListSelect/index.js
| ... | ... | @@ -349,6 +349,9 @@ class CommonList extends Component { |
| 349 | 349 | token, sModelsId, slaveFilterCondition, slaveConfig, slavePagination, slaveOrderBy, app, |
| 350 | 350 | } = this.props; |
| 351 | 351 | const { userinfo } = app; |
| 352 | + const BtnSure = commonFunc.showLocalMessage(this.props, 'BtnSure', '确定'); | |
| 353 | + const FriendlyReminder = commonFunc.showLocalMessage(this.props, 'FriendlyReminder', '温馨提示'); | |
| 354 | + | |
| 352 | 355 | const onSendSocketMessage = this.props.handleSendSocketMessage; |
| 353 | 356 | const returnData = await commonBusiness.saveData({ token, value: params, sModelsId }); |
| 354 | 357 | this.props.onSaveState({ |
| ... | ... | @@ -360,7 +363,7 @@ class CommonList extends Component { |
| 360 | 363 | // eslint-disable-next-line no-underscore-dangle |
| 361 | 364 | const _this = this; |
| 362 | 365 | confirm({ |
| 363 | - title: '单据校验', /* 防呆校验 */ | |
| 366 | + title: FriendlyReminder, /* 防呆校验 */ | |
| 364 | 367 | content: returnData.msg, |
| 365 | 368 | onOk() { |
| 366 | 369 | params.iFlag = 1; |
| ... | ... | @@ -368,8 +371,6 @@ class CommonList extends Component { |
| 368 | 371 | }, |
| 369 | 372 | onCancel() { |
| 370 | 373 | }, |
| 371 | - okText: '保存', | |
| 372 | - cancelText: '不保存', | |
| 373 | 374 | }); |
| 374 | 375 | this.props.onSaveState({ |
| 375 | 376 | loading: false, |
| ... | ... | @@ -377,13 +378,12 @@ class CommonList extends Component { |
| 377 | 378 | return true; |
| 378 | 379 | } else if (returnData.code === 2 || returnData.code === -8) { |
| 379 | 380 | Modal.info({ |
| 380 | - title: '温馨提示:', | |
| 381 | + title: FriendlyReminder, | |
| 381 | 382 | content: ( |
| 382 | 383 | <div> |
| 383 | 384 | {commonFunc.getReturnMsg(returnData.msg)} |
| 384 | 385 | </div> |
| 385 | 386 | ), |
| 386 | - okText: '确认', | |
| 387 | 387 | onOk() {}, |
| 388 | 388 | }); |
| 389 | 389 | } else { |
| ... | ... | @@ -855,8 +855,8 @@ const CommonListComponent = Form.create({ |
| 855 | 855 | }; |
| 856 | 856 | const upInvoiceName = commonUtils.isNotEmptyArr(btnUploadApi) ? btnUploadApi[0].showName : '发票上传(金税)'; |
| 857 | 857 | |
| 858 | - const BtnSure = commonFunc.showLocalMessage(this.props, 'BtnSure', '确定'); | |
| 859 | - const BtnCancel = commonFunc.showLocalMessage(this.props, 'BtnCancel', '取消'); | |
| 858 | + const BtnSure = commonFunc.showLocalMessage(props, 'BtnSure', '确定'); | |
| 859 | + const BtnCancel = commonFunc.showLocalMessage(props, 'BtnCancel', '取消'); | |
| 860 | 860 | |
| 861 | 861 | return ( |
| 862 | 862 | <Form > | ... | ... |
src/components/Common/CommonListSelectMulti/index.js
| ... | ... | @@ -832,6 +832,8 @@ const CommonListComponent = Form.create({ |
| 832 | 832 | const sProcessParams = commonFunc.showMessage(app.commonConst, 'sProcessParams');/* 选择工艺参数标题 */ |
| 833 | 833 | const displayLeft = (sModelsType !== 'search/sisColor' && sModelsType !== 'search/commonPopup'); |
| 834 | 834 | const realizeHeight = commonUtils.isNotEmptyNumber(props.realizeHeight) ? props.realizeHeight : 0; |
| 835 | + const BtnSure = commonFunc.showLocalMessage(this.props, 'BtnSure', '确定'); | |
| 836 | + const BtnCancel = commonFunc.showLocalMessage(this.props, 'BtnCancel', '取消'); | |
| 835 | 837 | const btnClick = (btn) => { |
| 836 | 838 | const { sControlName } = btn; |
| 837 | 839 | const picArr = slaveConfig.gdsconfigformslave.filter(item => (item.sName === 'picArr')); |
| ... | ... | @@ -915,8 +917,8 @@ const CommonListComponent = Form.create({ |
| 915 | 917 | width: '50%', textAlign: 'right', marginRight: '9px', marginBottom: '9px', |
| 916 | 918 | }} |
| 917 | 919 | > |
| 918 | - <Button key="back" style={{ marginRight: '8px' }} onClick={props.onCancel}>取消</Button> | |
| 919 | - <Button type="primary" onClick={props.onSelect}>确认</Button> | |
| 920 | + <Button key="back" style={{ marginRight: '8px' }} onClick={props.onCancel}>{BtnCancel}</Button> | |
| 921 | + <Button type="primary" onClick={props.onSelect}>{BtnSure}</Button> | |
| 920 | 922 | </div> |
| 921 | 923 | </div> |
| 922 | 924 | </Layout> | ... | ... |
src/components/Common/SlaveMemo.js
| ... | ... | @@ -11,6 +11,7 @@ import ShowType from './CommonComponent';/* 通用方法 */ |
| 11 | 11 | import AntdDraggableModal from '../Common/AntdDraggableModal'; |
| 12 | 12 | import moment from 'moment'; |
| 13 | 13 | import * as commonFunc from "@/components/Common/commonFunc"; |
| 14 | +import * as commonBusiness from '@/components/Common/commonBusiness'; /* 单据业务功能 */ | |
| 14 | 15 | |
| 15 | 16 | const { TextArea } = Input; |
| 16 | 17 | const FormItem = Form.Item; |
| ... | ... | @@ -64,6 +65,12 @@ export default class SlaveMemo extends Component { |
| 64 | 65 | |
| 65 | 66 | let valueKey = ''; |
| 66 | 67 | if (commonUtils.isNotEmptyArr(slaveMemoConfig) && commonUtils.isNotEmptyObject(masterData)) { |
| 68 | + const newConfig = { | |
| 69 | + gdsconfigformslave :slaveMemoConfig | |
| 70 | + } | |
| 71 | + if (!commonBusiness.validateTable(newConfig, [masterData], this.props)) { | |
| 72 | + return; | |
| 73 | + } | |
| 67 | 74 | // eslint-disable-next-line array-callback-return |
| 68 | 75 | slaveMemoConfig.map((item) => { |
| 69 | 76 | /** | ... | ... |
src/components/CommonSystemSettingEvent/CommonSystemSetting.js
| ... | ... | @@ -88,6 +88,11 @@ const CommonSystemSettingComponent = Form.create({ |
| 88 | 88 | onFilterData: props.onFilterData, |
| 89 | 89 | tableProps: { AutoTableHeight: 200 }, |
| 90 | 90 | }; |
| 91 | + const AccountingPeriod = commonFunc.showLocalMessage(props, 'AccountingPeriod', '会计期间'); | |
| 92 | + const SalesProductionParameters = commonFunc.showLocalMessage(props, 'SalesProductionParameters', '销售采购生产参数'); | |
| 93 | + const FinancialWarehouseParameters = commonFunc.showLocalMessage(props, 'FinancialWarehouseParameters', '财务仓库报价参数'); | |
| 94 | + const DocumentNumberSetup= commonFunc.showLocalMessage(props, 'DocumentNumberSetup', '单据编号设置'); | |
| 95 | + const SystemSetting = commonFunc.showLocalMessage(props, 'SystemSetting', '系统参数'); | |
| 91 | 96 | return ( |
| 92 | 97 | <Form> |
| 93 | 98 | <Layout> |
| ... | ... | @@ -98,16 +103,16 @@ const CommonSystemSettingComponent = Form.create({ |
| 98 | 103 | <Content className={selfStyles.container}> |
| 99 | 104 | <div> |
| 100 | 105 | <Tabs className={styles.slaveTabs}> |
| 101 | - <TabPane tab="会计期间" key={1}> | |
| 106 | + <TabPane tab={AccountingPeriod} key={1}> | |
| 102 | 107 | <TabFinancePeriod {...props} /> |
| 103 | 108 | </TabPane> |
| 104 | - <TabPane tab="销售采购生产参数" key={2}> | |
| 109 | + <TabPane tab={SalesProductionParameters} key={2}> | |
| 105 | 110 | <TabsSalesBuyer {...props} /> |
| 106 | 111 | </TabPane> |
| 107 | - <TabPane tab="财务仓库报价参数" key={3}> | |
| 112 | + <TabPane tab={FinancialWarehouseParameters} key={3}> | |
| 108 | 113 | <TabFinanceOffer {...props} /> |
| 109 | 114 | </TabPane> |
| 110 | - <TabPane tab="单据编号设置" key={4}> | |
| 115 | + <TabPane tab={DocumentNumberSetup} key={4}> | |
| 111 | 116 | <div className="xly-bill-list" > |
| 112 | 117 | <StaticEditTable {...tableProps} setOpterationColumn="Y" footer="hidden" /> |
| 113 | 118 | </div> |
| ... | ... | @@ -118,7 +123,7 @@ const CommonSystemSettingComponent = Form.create({ |
| 118 | 123 | </div> : '' |
| 119 | 124 | } |
| 120 | 125 | </TabPane> |
| 121 | - <TabPane tab="系统参数" key={5}> | |
| 126 | + <TabPane tab={SystemSetting} key={5}> | |
| 122 | 127 | <TabSysParam {...props} /> |
| 123 | 128 | </TabPane> |
| 124 | 129 | </Tabs> | ... | ... |
src/components/Manufacture/ProcessCardPack/ProcessCardPackTableTree.js
| ... | ... | @@ -1906,6 +1906,7 @@ class ProcessCardPackTableTree extends Component { |
| 1906 | 1906 | gdsformconst, slaveData, controlData, controlSelectedRowKeys, slaveSelectedRowKeys, [`${name}Data`]: tableData, |
| 1907 | 1907 | } = this.props; |
| 1908 | 1908 | let { packData }=this.props; |
| 1909 | + const selectProduct = commonFunc.showLocalMessage(this.props, 'selectProduct', '请先选择产品!'); | |
| 1909 | 1910 | if (name === 'control') { |
| 1910 | 1911 | /* 增加子部件 */ |
| 1911 | 1912 | const { |
| ... | ... | @@ -1979,7 +1980,7 @@ class ProcessCardPackTableTree extends Component { |
| 1979 | 1980 | if(iIndex ===-1){ |
| 1980 | 1981 | |
| 1981 | 1982 | if(commonUtils.isEmptyObject(slaveSelectedRow.sProductId)) { |
| 1982 | - message.error('请先选择产品!'); | |
| 1983 | + message.error(selectProduct); | |
| 1983 | 1984 | return; |
| 1984 | 1985 | } |
| 1985 | 1986 | if(slaveSelectedRow){ | ... | ... |
src/components/Manufacture/WorkOrderPackTableTreeNew/index.js
| ... | ... | @@ -3158,10 +3158,12 @@ const controlProps = props => { |
| 3158 | 3158 | if (commonUtils.isEmptyArr(packData)) { |
| 3159 | 3159 | packData = []; |
| 3160 | 3160 | } |
| 3161 | + const selectProduct = commonFunc.showLocalMessage(props, 'selectProduct', '请先选择产品'); | |
| 3162 | + | |
| 3161 | 3163 | const iIndex = packData.findIndex(item => item.sControlId === tableDataRow.sId); |
| 3162 | 3164 | if (iIndex === -1) { |
| 3163 | 3165 | if (commonUtils.isEmptyObject(slaveSelectedRow.sProductId)) { |
| 3164 | - message.error("请先选择产品!"); | |
| 3166 | + message.error(selectProduct); | |
| 3165 | 3167 | return; |
| 3166 | 3168 | } |
| 3167 | 3169 | if (slaveSelectedRow) { | ... | ... |
src/components/QuickQuote/index.jsx
| ... | ... | @@ -764,6 +764,19 @@ const QuickQuoteEvent = props => { |
| 764 | 764 | processAfterDataRow.sId = commonUtils.createSid(); |
| 765 | 765 | processAfterDataRow.sParentId = masterData.sId; |
| 766 | 766 | processAfterDataRow.sControlId = partsDataRow.sId; |
| 767 | + | |
| 768 | + const sBackendParams = process.sBackendParams || []; | |
| 769 | + if (sBackendParams.length) { | |
| 770 | + const sQuoParams = sBackendParams.map(item => ({ | |
| 771 | + sParamKey: item.sParamKey, | |
| 772 | + sParamKeyNew: item.sParamKeyNew, | |
| 773 | + sParamName: item.sParam, | |
| 774 | + sParamValue: item.value !== undefined ? item.value : "", | |
| 775 | + bSelfCbx: !(item.value === "" || item.value === undefined), | |
| 776 | + })); | |
| 777 | + processAfterDataRow.sQuoParams = JSON.stringify(sQuoParams); | |
| 778 | + } | |
| 779 | + | |
| 767 | 780 | // processAfterDataRow.sSlaveId = ' '; |
| 768 | 781 | processData.push(processAfterDataRow); |
| 769 | 782 | // 配套工序 |
| ... | ... | @@ -2484,7 +2497,8 @@ const BackendParamsExtraComponent = props => { |
| 2484 | 2497 | |
| 2485 | 2498 | const viewConfigs = backendParamsConfig.map((item, index) => ({ |
| 2486 | 2499 | ...item, |
| 2487 | - sName: item.sFieldName || `sParams${index}`, | |
| 2500 | + sName0: `sParams${index + 1}`, | |
| 2501 | + sName: item.sFieldName || `sParams${index + 1}`, | |
| 2488 | 2502 | showName: item.sParam, |
| 2489 | 2503 | sDropDownType: item.sParamDropDown ? "sql" : "", |
| 2490 | 2504 | iColValue: 4, |
| ... | ... | @@ -2504,7 +2518,7 @@ const BackendParamsExtraComponent = props => { |
| 2504 | 2518 | tableName: `sBackendParams${boxModel}`, |
| 2505 | 2519 | getSqlDropDownData: (...args) => { |
| 2506 | 2520 | const showConfig = args[2]; |
| 2507 | - const { sParamDropDown = "", sName } = showConfig; | |
| 2521 | + const { sParamDropDown = "", sName0, sName } = showConfig; | |
| 2508 | 2522 | const dropDownData = sParamDropDown.split(","); |
| 2509 | 2523 | if (dropDownData?.length) { |
| 2510 | 2524 | return { |
| ... | ... | @@ -2513,6 +2527,8 @@ const BackendParamsExtraComponent = props => { |
| 2513 | 2527 | value: item, |
| 2514 | 2528 | sParam: showConfig.sParam, |
| 2515 | 2529 | [sName]: item, |
| 2530 | + sParamKey: sName0, | |
| 2531 | + sParamKeyNew: sName, | |
| 2516 | 2532 | })), |
| 2517 | 2533 | totalPageCount: 1, |
| 2518 | 2534 | currentPageNo: 1, |
| ... | ... | @@ -2533,6 +2549,8 @@ const BackendParamsExtraComponent = props => { |
| 2533 | 2549 | value: changeValue[sFieldName], |
| 2534 | 2550 | sParam: showConfig.sParam, |
| 2535 | 2551 | [sFieldName]: changeValue[sFieldName], |
| 2552 | + sParamKey: showConfig.sName0, | |
| 2553 | + sParamKeyNew: sFieldName, | |
| 2536 | 2554 | }; |
| 2537 | 2555 | const { sParam } = dropDownDataSelected; |
| 2538 | 2556 | const { sBackendParams = [] } = slaveData[iIndex].sBackProcessData[iIndex1]; | ... | ... |