diff --git a/src/views/modules/yieldReport/com_start_produce.vue b/src/views/modules/yieldReport/com_start_produce.vue index a9eb343..6987017 100644 --- a/src/views/modules/yieldReport/com_start_produce.vue +++ b/src/views/modules/yieldReport/com_start_produce.vue @@ -7,7 +7,7 @@ - + - 保存 - 关闭 + {{ buttons.saveButton }} + {{ buttons.closeButton }} + 对语言设置 @@ -51,11 +52,27 @@ import { from '@/api/yieldReport//com_start_produce.js'; /*引入组件*/ import comEndTuning from './com_end_tuning'; + +import { + searchSysLanguagePackList, + searchSysLanguageParam, + searchFunctionButtonList, + saveButtonList, + searchSysLanguage, + searchLanguageListByLanguageCode, + saveSysLanguageOne, + searchPageLanguageData, + removerLanguage, + saveSysLanguageList +} from "@/api/sysLanguage.js"; + +var functionId = 'C10000009'; /*开始生产时候报告调机的材料的使用数量*/ export default { data() { return { titleCon: '开始生产', + showDefault: false, endTuningFlag: false, sfdcTimeList: [], pageData: { @@ -79,6 +96,63 @@ export default { showFlag: false }, dataListLoading: false, + buttons: { + saveButton: '保存', + closeButton: '关闭', + }, + buttonList: [ + { + functionId: functionId, + languageValue: '保存', + objectId: 'saveButton', + objectType: 'button', + tableId: '*' + }, { + functionId: functionId, + languageValue: '关闭', + objectId: 'closeButton', + objectType: 'button', + tableId: '*' + }, + ], + queryButton: { + functionId: functionId, + table_id: '*', + languageCode: this.$i18n.locale, + objectType: 'button' + }, + labels: { + titleCon: '开始生产 ', + seqNoName: '派工单号:', + currentTime: '当前时间:', + }, + labelsList: [ + { + functionId: functionId, + languageValue: '开始生产 ', + objectId: 'titleCon', + objectType: 'label', + tableId: '*' + }, { + functionId: functionId, + languageValue: '派工单号:', + objectId: 'seqNoName', + objectType: 'label', + tableId: '*' + }, { + functionId: functionId, + languageValue: '当前时间:', + objectId: 'currentTime', + objectType: 'label', + tableId: '*' + }, + ], + queryLabel: { + functionId: functionId, + table_id: '*', + languageCode: this.$i18n.locale, + objectType: 'label' + }, } }, components: { @@ -100,8 +174,8 @@ export default { //初始化操作员对象 this.operatorData = JSON.parse(JSON.stringify(operatorData)); //初始化标题 - this.titleCon = '开始生产操作 \ - 派工单号:'+scheduleData.seqNo; + //初始化标题 + this.titleCon = this.labels.titleCon+this.labels.seqNoName+scheduleData.seqNo; // this.currentRollOps.seqNo = seqNo; // this.currentRollOps.rollNo = rollNo; //刷新当前派工单的信息 @@ -159,12 +233,42 @@ export default { }, + // 保存 默认配置 列 + async saveMultiLanguage() { + // 保存页面 button label title 属性 + let buttons = this.buttonList; + let labels = this.labelsList; + await saveButtonList(buttons) + await saveButtonList(labels) + this.getMultiLanguageList() + }, + getMultiLanguageList() { + //首先查询当前按钮的多语言 + searchFunctionButtonList(this.queryButton).then(({data}) => { + if (JSON.stringify(data.data) != '{}') { + this.buttons = data.data + } else { + // saveButtonList(this.buttonList).then(({data}) => { + // }) + } + }); + //其次查询当前标签的多语言 + searchFunctionButtonList(this.queryLabel).then(({data}) => { + if (JSON.stringify(data.data) != '{}') { + this.labels = data.data + } else { + // saveButtonList(this.buttonList).then(({data}) => { + // }) + } + }); + }, }, created() { // this.factoryList() // this.getLanguageList() + this.getMultiLanguageList()//刷新按钮 } } diff --git a/src/views/modules/yieldReport/com_start_tuning.vue b/src/views/modules/yieldReport/com_start_tuning.vue index dfad888..c4f490f 100644 --- a/src/views/modules/yieldReport/com_start_tuning.vue +++ b/src/views/modules/yieldReport/com_start_tuning.vue @@ -63,7 +63,7 @@ export default { data() { return { titleCon: '开始调机', - showDefault: true, + showDefault: false, scheduleData: { site: this.$store.state.user.site, username: this.$store.state.user.name,