Commit 46052874517275b33d8608a6dc455f6b4fd7ee89

Authored by Min
1 parent eee7a410

完善按钮的英文翻译

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/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 =&gt; {
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) {
... ...