diff --git a/src/views/modules/yieldReport/com_merge_roll.vue b/src/views/modules/yieldReport/com_merge_roll.vue index 6dd802a..8cae2ca 100644 --- a/src/views/modules/yieldReport/com_merge_roll.vue +++ b/src/views/modules/yieldReport/com_merge_roll.vue @@ -7,12 +7,12 @@ - + - + @@ -24,25 +24,26 @@ - + - + - + - 确 定 - 关闭 + {{ buttons.confirmButton }} + {{ buttons.closeButton }} + 对语言设置 @@ -61,10 +62,26 @@ printSfdcLabel, } from "@/views/modules/yieldReport/print_roll_label.js"; + import { + searchSysLanguagePackList, + searchSysLanguageParam, + searchFunctionButtonList, + saveButtonList, + searchSysLanguage, + searchLanguageListByLanguageCode, + saveSysLanguageOne, + searchPageLanguageData, + removerLanguage, + saveSysLanguageList + } from "@/api/sysLanguage.js"; + + var functionId = 'C10000006'; + export default { data() { return { titleCon: '合并卷', + showDefault: false, rollType: '', scheduleData: { site: this.$store.state.user.site, @@ -120,6 +137,84 @@ export default { seqNo: '', showFlag: false }, + buttons: { + confirmButton: '确定', + closeButton: '关闭', + }, + buttonList: [ + { + functionId: functionId, + languageValue: '确定', + objectId: 'confirmButton', + objectType: 'button', + tableId: '*' + },{ + functionId: functionId, + languageValue: '关闭', + objectId: 'closeButton', + objectType: 'button', + tableId: '*' + }, + ], + queryButton: { + functionId: functionId, + table_id: '*', + languageCode: this.$i18n.locale, + objectType: 'button' + }, + labels: { + titleCon: '合并卷', + currentRollNo: '当前卷号:', + currentRollQty: '当前卷数量:', + newRollNo: '新卷卷号:', + newRollQty: '新卷数量:', + totalQty: '总数量:', + }, + labelsList: [ + { + functionId: functionId, + languageValue: '合并卷', + objectId: 'titleCon', + objectType: 'label', + tableId: '*' + }, { + functionId: functionId, + languageValue: '当前卷号:', + objectId: 'currentRollNo', + objectType: 'label', + tableId: '*' + }, { + functionId: functionId, + languageValue: '当前卷数量:', + objectId: 'currentRollQty', + objectType: 'label', + tableId: '*' + }, { + functionId: functionId, + languageValue: '新卷卷号:', + objectId: 'newRollNo', + objectType: 'label', + tableId: '*' + }, { + functionId: functionId, + languageValue: '新卷数量:', + objectId: 'newRollQty', + objectType: 'label', + tableId: '*' + }, { + functionId: functionId, + languageValue: '总数量:', + objectId: 'totalQty', + objectType: 'label', + tableId: '*' + }, + ], + queryLabel: { + functionId: functionId, + table_id: '*', + languageCode: this.$i18n.locale, + objectType: 'label' + }, } }, methods: { @@ -146,6 +241,7 @@ export default { this.$nextTick(() => { this.$refs.newRollNo.focus(); }); + this.titleCon = this.labels.titleCon;//重置标题 }, /*刷新页面的参数*/ @@ -365,10 +461,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()//刷新按钮 } }