Commit 46052874517275b33d8608a6dc455f6b4fd7ee89
1 parent
eee7a410
完善按钮的英文翻译
Showing
4 changed files
with
16 additions
and
11 deletions
src/components/Common/CommonListSelect/index.js
| @@ -349,6 +349,9 @@ class CommonList extends Component { | @@ -349,6 +349,9 @@ class CommonList extends Component { | ||
| 349 | token, sModelsId, slaveFilterCondition, slaveConfig, slavePagination, slaveOrderBy, app, | 349 | token, sModelsId, slaveFilterCondition, slaveConfig, slavePagination, slaveOrderBy, app, |
| 350 | } = this.props; | 350 | } = this.props; |
| 351 | const { userinfo } = app; | 351 | const { userinfo } = app; |
| 352 | + const BtnSure = commonFunc.showLocalMessage(this.props, 'BtnSure', '确定'); | ||
| 353 | + const FriendlyReminder = commonFunc.showLocalMessage(this.props, 'FriendlyReminder', '温馨提示'); | ||
| 354 | + | ||
| 352 | const onSendSocketMessage = this.props.handleSendSocketMessage; | 355 | const onSendSocketMessage = this.props.handleSendSocketMessage; |
| 353 | const returnData = await commonBusiness.saveData({ token, value: params, sModelsId }); | 356 | const returnData = await commonBusiness.saveData({ token, value: params, sModelsId }); |
| 354 | this.props.onSaveState({ | 357 | this.props.onSaveState({ |
| @@ -360,7 +363,7 @@ class CommonList extends Component { | @@ -360,7 +363,7 @@ class CommonList extends Component { | ||
| 360 | // eslint-disable-next-line no-underscore-dangle | 363 | // eslint-disable-next-line no-underscore-dangle |
| 361 | const _this = this; | 364 | const _this = this; |
| 362 | confirm({ | 365 | confirm({ |
| 363 | - title: '单据校验', /* 防呆校验 */ | 366 | + title: FriendlyReminder, /* 防呆校验 */ |
| 364 | content: returnData.msg, | 367 | content: returnData.msg, |
| 365 | onOk() { | 368 | onOk() { |
| 366 | params.iFlag = 1; | 369 | params.iFlag = 1; |
| @@ -368,8 +371,6 @@ class CommonList extends Component { | @@ -368,8 +371,6 @@ class CommonList extends Component { | ||
| 368 | }, | 371 | }, |
| 369 | onCancel() { | 372 | onCancel() { |
| 370 | }, | 373 | }, |
| 371 | - okText: '保存', | ||
| 372 | - cancelText: '不保存', | ||
| 373 | }); | 374 | }); |
| 374 | this.props.onSaveState({ | 375 | this.props.onSaveState({ |
| 375 | loading: false, | 376 | loading: false, |
| @@ -377,13 +378,12 @@ class CommonList extends Component { | @@ -377,13 +378,12 @@ class CommonList extends Component { | ||
| 377 | return true; | 378 | return true; |
| 378 | } else if (returnData.code === 2 || returnData.code === -8) { | 379 | } else if (returnData.code === 2 || returnData.code === -8) { |
| 379 | Modal.info({ | 380 | Modal.info({ |
| 380 | - title: '温馨提示:', | 381 | + title: FriendlyReminder, |
| 381 | content: ( | 382 | content: ( |
| 382 | <div> | 383 | <div> |
| 383 | {commonFunc.getReturnMsg(returnData.msg)} | 384 | {commonFunc.getReturnMsg(returnData.msg)} |
| 384 | </div> | 385 | </div> |
| 385 | ), | 386 | ), |
| 386 | - okText: '确认', | ||
| 387 | onOk() {}, | 387 | onOk() {}, |
| 388 | }); | 388 | }); |
| 389 | } else { | 389 | } else { |
| @@ -855,8 +855,8 @@ const CommonListComponent = Form.create({ | @@ -855,8 +855,8 @@ const CommonListComponent = Form.create({ | ||
| 855 | }; | 855 | }; |
| 856 | const upInvoiceName = commonUtils.isNotEmptyArr(btnUploadApi) ? btnUploadApi[0].showName : '发票上传(金税)'; | 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 | return ( | 861 | return ( |
| 862 | <Form > | 862 | <Form > |
src/components/Common/CommonListSelectMulti/index.js
| @@ -832,6 +832,8 @@ const CommonListComponent = Form.create({ | @@ -832,6 +832,8 @@ const CommonListComponent = Form.create({ | ||
| 832 | const sProcessParams = commonFunc.showMessage(app.commonConst, 'sProcessParams');/* 选择工艺参数标题 */ | 832 | const sProcessParams = commonFunc.showMessage(app.commonConst, 'sProcessParams');/* 选择工艺参数标题 */ |
| 833 | const displayLeft = (sModelsType !== 'search/sisColor' && sModelsType !== 'search/commonPopup'); | 833 | const displayLeft = (sModelsType !== 'search/sisColor' && sModelsType !== 'search/commonPopup'); |
| 834 | const realizeHeight = commonUtils.isNotEmptyNumber(props.realizeHeight) ? props.realizeHeight : 0; | 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 | const btnClick = (btn) => { | 837 | const btnClick = (btn) => { |
| 836 | const { sControlName } = btn; | 838 | const { sControlName } = btn; |
| 837 | const picArr = slaveConfig.gdsconfigformslave.filter(item => (item.sName === 'picArr')); | 839 | const picArr = slaveConfig.gdsconfigformslave.filter(item => (item.sName === 'picArr')); |
| @@ -915,8 +917,8 @@ const CommonListComponent = Form.create({ | @@ -915,8 +917,8 @@ const CommonListComponent = Form.create({ | ||
| 915 | width: '50%', textAlign: 'right', marginRight: '9px', marginBottom: '9px', | 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 | </div> | 922 | </div> |
| 921 | </div> | 923 | </div> |
| 922 | </Layout> | 924 | </Layout> |
src/components/Manufacture/ProcessCardPack/ProcessCardPackTableTree.js
| @@ -1906,6 +1906,7 @@ class ProcessCardPackTableTree extends Component { | @@ -1906,6 +1906,7 @@ class ProcessCardPackTableTree extends Component { | ||
| 1906 | gdsformconst, slaveData, controlData, controlSelectedRowKeys, slaveSelectedRowKeys, [`${name}Data`]: tableData, | 1906 | gdsformconst, slaveData, controlData, controlSelectedRowKeys, slaveSelectedRowKeys, [`${name}Data`]: tableData, |
| 1907 | } = this.props; | 1907 | } = this.props; |
| 1908 | let { packData }=this.props; | 1908 | let { packData }=this.props; |
| 1909 | + const selectProduct = commonFunc.showLocalMessage(this.props, 'selectProduct', '请先选择产品!'); | ||
| 1909 | if (name === 'control') { | 1910 | if (name === 'control') { |
| 1910 | /* 增加子部件 */ | 1911 | /* 增加子部件 */ |
| 1911 | const { | 1912 | const { |
| @@ -1979,7 +1980,7 @@ class ProcessCardPackTableTree extends Component { | @@ -1979,7 +1980,7 @@ class ProcessCardPackTableTree extends Component { | ||
| 1979 | if(iIndex ===-1){ | 1980 | if(iIndex ===-1){ |
| 1980 | 1981 | ||
| 1981 | if(commonUtils.isEmptyObject(slaveSelectedRow.sProductId)) { | 1982 | if(commonUtils.isEmptyObject(slaveSelectedRow.sProductId)) { |
| 1982 | - message.error('请先选择产品!'); | 1983 | + message.error(selectProduct); |
| 1983 | return; | 1984 | return; |
| 1984 | } | 1985 | } |
| 1985 | if(slaveSelectedRow){ | 1986 | if(slaveSelectedRow){ |
src/components/Manufacture/WorkOrderPackTableTreeNew/index.js
| @@ -3158,10 +3158,12 @@ const controlProps = props => { | @@ -3158,10 +3158,12 @@ const controlProps = props => { | ||
| 3158 | if (commonUtils.isEmptyArr(packData)) { | 3158 | if (commonUtils.isEmptyArr(packData)) { |
| 3159 | packData = []; | 3159 | packData = []; |
| 3160 | } | 3160 | } |
| 3161 | + const selectProduct = commonFunc.showLocalMessage(props, 'selectProduct', '请先选择产品'); | ||
| 3162 | + | ||
| 3161 | const iIndex = packData.findIndex(item => item.sControlId === tableDataRow.sId); | 3163 | const iIndex = packData.findIndex(item => item.sControlId === tableDataRow.sId); |
| 3162 | if (iIndex === -1) { | 3164 | if (iIndex === -1) { |
| 3163 | if (commonUtils.isEmptyObject(slaveSelectedRow.sProductId)) { | 3165 | if (commonUtils.isEmptyObject(slaveSelectedRow.sProductId)) { |
| 3164 | - message.error("请先选择产品!"); | 3166 | + message.error(selectProduct); |
| 3165 | return; | 3167 | return; |
| 3166 | } | 3168 | } |
| 3167 | if (slaveSelectedRow) { | 3169 | if (slaveSelectedRow) { |