[update] 法规符合性排查流程和流程中中心的翻译

This commit is contained in:
lideqin
2024-08-08 16:05:38 +08:00
parent 9cc2d3a9b8
commit bb5ecb6f27
17 changed files with 47 additions and 24 deletions
+7
View File
@@ -23,6 +23,13 @@
<div class="table-text">{{ text || text === 0 ? text : global.emptyLine }}</div> <div class="table-text">{{ text || text === 0 ? text : global.emptyLine }}</div>
</a-tooltip> </a-tooltip>
</template> </template>
<!--增加数据字典双语翻译的插槽-->
<template slot="dictText" slot-scope="text, record, index, column">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ (isChinese() ? text : record[column.key + 'En']) || (isChinese() ? text : record[column.key + 'En']) === 0 ? (isChinese() ? text : record[column.key + 'En']) : global.emptyLine }}</template>
<div class="table-text">{{ (isChinese() ? text : record[column.key + 'En']) || (isChinese() ? text : record[column.key + 'En']) === 0 ? (isChinese() ? text : record[column.key + 'En']) : global.emptyLine }}</div>
</a-tooltip>
</template>
<!-- 表格扩展插槽 --> <!-- 表格扩展插槽 -->
<div slot="expandedRowRender" slot-scope="record, index" style="margin: 0"> <div slot="expandedRowRender" slot-scope="record, index" style="margin: 0">
<!-- 如果表单会依赖某个字段变化就需要加判断循环判断extraForm中的表单 --> <!-- 如果表单会依赖某个字段变化就需要加判断循环判断extraForm中的表单 -->
@@ -82,8 +82,20 @@
<!-- 标准状态 --> <!-- 标准状态 -->
<template slot="standardState" slot-scope="text, record"> <template slot="standardState" slot-scope="text, record">
<a-tooltip overlay-class-name="tooltip-style"> <a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ record.source === '3' ? (record.esStandardState_dictText || global.emptyLine) : (record.standardState_dictText || global.emptyLine) }}</template> <template slot="title">
<div class="table-text">{{ record.source === '3' ? (record.esStandardState_dictText || global.emptyLine) : (record.standardState_dictText || global.emptyLine) }}</div> {{
record.source === '3' ?
(isChinese() ? (record.esStandardState_dictText || global.emptyLine) : (record.esStandardState_dictTextEn || global.emptyLine)) :
(isChinese() ? (record.standardState_dictText || global.emptyLine) : (record.standardState_dictTextEn || global.emptyLine))
}}
</template>
<div class="table-text">
{{
record.source === '3' ?
(isChinese() ? (record.esStandardState_dictText || global.emptyLine) : (record.esStandardState_dictTextEn || global.emptyLine)) :
(isChinese() ? (record.standardState_dictText || global.emptyLine) : (record.standardState_dictTextEn || global.emptyLine))
}}
</div>
</a-tooltip> </a-tooltip>
</template> </template>
@@ -371,7 +383,6 @@ export default {
} }
} }
} }
} else { } else {
this.selectedRowList = [] this.selectedRowList = []
} }
@@ -97,7 +97,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'prcType_dictText', dataIndex: 'prcType_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 流程名称 { // 流程名称
title: this.$t('processName'), title: this.$t('processName'),
@@ -140,7 +140,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'prcStatus_dictText', dataIndex: 'prcStatus_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ {
title: this.$t('operation'), title: this.$t('operation'),
@@ -75,7 +75,7 @@ export default {
align: 'center', align: 'center',
width: 300, width: 300,
dataIndex: 'prcType_dictText', dataIndex: 'prcType_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 流程名称 { // 流程名称
title: this.$t('processName'), title: this.$t('processName'),
@@ -113,7 +113,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'prcType_dictText', dataIndex: 'prcType_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 流程名称 { // 流程名称
title: this.$t('processName'), title: this.$t('processName'),
@@ -162,7 +162,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'prcStatus_dictText', dataIndex: 'prcStatus_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ {
title: this.$t('operation'), title: this.$t('operation'),
@@ -117,7 +117,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'prcType_dictText', dataIndex: 'prcType_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 流程名称 { // 流程名称
title: this.$t('processName'), title: this.$t('processName'),
@@ -160,7 +160,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'prcStatus_dictText', dataIndex: 'prcStatus_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ {
title: this.$t('operation'), title: this.$t('operation'),
@@ -112,7 +112,7 @@ export default {
align: 'center', align: 'center',
width: 260, width: 260,
dataIndex: 'prcType_dictText', dataIndex: 'prcType_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 流程名称 { // 流程名称
title: this.$t('processName'), title: this.$t('processName'),
@@ -106,7 +106,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'modelStatus_dictText', dataIndex: 'modelStatus_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 评价结果 { // 评价结果
title: this.$t('workCenter.regulatoryComplianceCheckProcess.evaluationResult'), title: this.$t('workCenter.regulatoryComplianceCheckProcess.evaluationResult'),
@@ -337,7 +337,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'standardState_dictText', dataIndex: 'standardState_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 分解单来源 { // 分解单来源
title: this.$t('workCenter.regulatoryComplianceCheckProcess.decompositionSingleSource'), title: this.$t('workCenter.regulatoryComplianceCheckProcess.decompositionSingleSource'),
@@ -445,7 +445,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'modelStatus_dictText', dataIndex: 'modelStatus_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 责任部门 { // 责任部门
title: this.$t('responsibleDepartment'), title: this.$t('responsibleDepartment'),
@@ -629,6 +629,7 @@ export default {
// 标准状态 // 标准状态
obj.standardState = result.standard_state obj.standardState = result.standard_state
obj.standardState_dictText = result.standard_state_dictText obj.standardState_dictText = result.standard_state_dictText
obj.standardState_dictTextEn = result.standard_state_dictTextEn
// 分解单来源初始化成不带入 // 分解单来源初始化成不带入
obj.splitFileSource = DecompositionSource.NO_INPUT.value obj.splitFileSource = DecompositionSource.NO_INPUT.value
// 新生产车实施日期 // 新生产车实施日期
@@ -99,7 +99,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'modelStatus_dictText', dataIndex: 'modelStatus_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 责任部门 { // 责任部门
title: this.$t('responsibleDepartment'), title: this.$t('responsibleDepartment'),
@@ -120,7 +120,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'result_dictText', dataIndex: 'result_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 不满足要求的现状 { // 不满足要求的现状
title: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'), title: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'),
@@ -138,7 +138,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'modelStatus_dictText', dataIndex: 'modelStatus_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
} }
], ],
dataSource: [], dataSource: [],
@@ -190,7 +190,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'modelStatus_dictText', dataIndex: 'modelStatus_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 责任部门 { // 责任部门
title: this.$t('responsibleDepartment'), title: this.$t('responsibleDepartment'),
@@ -211,7 +211,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'result_dictText', dataIndex: 'result_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 不满足要求的现状 { // 不满足要求的现状
title: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'), title: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'),
@@ -172,6 +172,7 @@ export default {
resultChange (value) { resultChange (value) {
this.model.result = value this.model.result = value
this.model.result_dictText = this.$refs.resultRef.dictOptions.find(item => item.value === value).text this.model.result_dictText = this.$refs.resultRef.dictOptions.find(item => item.value === value).text
this.model.result_dictTextEn = this.$refs.resultRef.dictOptions.find(item => item.value === value).enText
// 清空备注和佐证材料,不满足要求的现状,整改方案,整改周期,整改费用,与其他项目共用性,共用后本项目所需费用 // 清空备注和佐证材料,不满足要求的现状,整改方案,整改周期,整改费用,与其他项目共用性,共用后本项目所需费用
this.model.remark = '' this.model.remark = ''
this.model.material = '' this.model.material = ''
@@ -322,7 +322,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'modelStatus_dictText', dataIndex: 'modelStatus_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 设计工程师 { // 设计工程师
title: this.$t('designEngineer'), title: this.$t('designEngineer'),
@@ -376,7 +376,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'modelStatus_dictText', dataIndex: 'modelStatus_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 评价结果 { // 评价结果
title: this.$t('workCenter.regulatoryComplianceCheckProcess.evaluationResult'), title: this.$t('workCenter.regulatoryComplianceCheckProcess.evaluationResult'),
@@ -113,7 +113,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'modelStatus_dictText', dataIndex: 'modelStatus_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 责任部门 { // 责任部门
title: this.$t('responsibleDepartment'), title: this.$t('responsibleDepartment'),
@@ -134,7 +134,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'result_dictText', dataIndex: 'result_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 不满足要求的现状 { // 不满足要求的现状
title: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'), title: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'),
@@ -116,7 +116,7 @@ export default {
align: 'center', align: 'center',
width: 180, width: 180,
dataIndex: 'modelStatus_dictText', dataIndex: 'modelStatus_dictText',
scopedSlots: { customRender: 'text' } scopedSlots: { customRender: 'dictText' }
}, },
{ // 设计工程师 { // 设计工程师
title: this.$t('designEngineer'), title: this.$t('designEngineer'),
@@ -147,6 +147,7 @@ export default {
const valueArr = value.split(this.$refs.standardState.spliter) const valueArr = value.split(this.$refs.standardState.spliter)
const arr = this.$refs.standardState.dictOptions.filter(item => valueArr.includes(item.value)) const arr = this.$refs.standardState.dictOptions.filter(item => valueArr.includes(item.value))
this.model.standardState_dictText = arr.map(item => item.title).join(',') this.model.standardState_dictText = arr.map(item => item.title).join(',')
this.model.standardState_dictTextEn = arr.map(item => item.enText).join(',')
}, },
// 上传拆解单文件改变 // 上传拆解单文件改变
splitFileChange (value) { splitFileChange (value) {
@@ -166,6 +167,8 @@ export default {
const isEdit = this.model.standardNumber const isEdit = this.model.standardNumber
const formData = Object.assign(values) const formData = Object.assign(values)
formData.splitFile_dictText = this.model.splitFile_dictText formData.splitFile_dictText = this.model.splitFile_dictText
formData.standardState_dictText = this.model.standardState_dictText
formData.standardState_dictTextEn = this.model.standardState_dictTextEn
this.$emit('ok', formData, isEdit) this.$emit('ok', formData, isEdit)
this.confirmLoading = false this.confirmLoading = false
this.close() this.close()