[update] 法规合规评估流程字段对应
This commit is contained in:
+1
-1
@@ -552,7 +552,7 @@ export default {
|
||||
param.common.taskId = this.$route.query.taskId
|
||||
param.data = data
|
||||
this.loading = true
|
||||
regulatoryComplianceCheckAgree(param).then(res => {
|
||||
regulatoryComplianceCheckSubmit(param).then(res => {
|
||||
if (res.success) {
|
||||
this.$message.success(res.message)
|
||||
this.goBack()
|
||||
|
||||
+41
-47
@@ -9,16 +9,16 @@
|
||||
rowKey="standardNumber"
|
||||
:columns="columns"
|
||||
:dataSource="dataSource"
|
||||
formIsDepend="evaluationResult"
|
||||
formIsDepend="result"
|
||||
:extraForm="extraForm"
|
||||
:loading="loading">
|
||||
|
||||
<template slot="evaluationResult" slot-scope="{text, record}">
|
||||
<template slot="result" slot-scope="{text, record}">
|
||||
<j-dict-select-tag
|
||||
style="width: 100%"
|
||||
:placeholder="$t('pleaseSelect')"
|
||||
dict-code="evaluation_result"
|
||||
v-model="record.evaluationResult">
|
||||
v-model="record.result">
|
||||
</j-dict-select-tag>
|
||||
</template>
|
||||
|
||||
@@ -48,43 +48,43 @@ export default {
|
||||
title: this.$t('clauseNo'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseNo',
|
||||
dataIndex: 'termNumber',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 条款标题
|
||||
title: this.$t('clauseTitle'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseTitle',
|
||||
dataIndex: 'termTitle',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 条款内容
|
||||
title: this.$t('clauseContent'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseContent',
|
||||
dataIndex: 'termContent',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型
|
||||
title: this.$t('vehicleType'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'vehicleType',
|
||||
dataIndex: 'model',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型状态
|
||||
title: this.$t('modelStatus'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'modelStatus',
|
||||
dataIndex: 'modelState',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 评价结果
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.evaluationResult'),
|
||||
align: 'center',
|
||||
width: 300,
|
||||
dataIndex: 'evaluationResult',
|
||||
scopedSlots: { customRender: 'evaluationResult' }
|
||||
dataIndex: 'result',
|
||||
scopedSlots: { customRender: 'result' }
|
||||
}
|
||||
],
|
||||
dataSource: [],
|
||||
@@ -94,7 +94,7 @@ export default {
|
||||
// 备注
|
||||
remark: { required: false, message: this.$t('pleaseEnter') + this.$t('remarks'), trigger: 'blur' },
|
||||
// 佐证材料
|
||||
file: { required: false, message: this.$t('pleaseUpload') + this.$t('supportingMaterial'), trigger: 'change' }
|
||||
material: { required: false, message: this.$t('pleaseUpload') + this.$t('supportingMaterial'), trigger: 'change' }
|
||||
},
|
||||
formArr: [
|
||||
{
|
||||
@@ -105,61 +105,61 @@ export default {
|
||||
{
|
||||
fieldShowType: 2,
|
||||
dbFieldTxt: this.$t('supportingMaterial'),
|
||||
dbFieldName: 'file'
|
||||
dbFieldName: 'material'
|
||||
}
|
||||
]
|
||||
},
|
||||
2: { // 不符合
|
||||
rules: {
|
||||
// 整改周期
|
||||
rectificationCycle: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' },
|
||||
correctionCycle: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' },
|
||||
// 整改费用
|
||||
rectificationCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'), trigger: 'blur' },
|
||||
correctionCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'), trigger: 'blur' },
|
||||
// 共用后本项目所需费用
|
||||
costOfThisItemAfterSharing: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'), trigger: 'blur' },
|
||||
commonalityCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'), trigger: 'blur' },
|
||||
// 不满足要求的现状
|
||||
theStatusNotMeetRequirements: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'), trigger: 'blur' },
|
||||
unsatisfiedRequire: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'), trigger: 'blur' },
|
||||
// 整改方案
|
||||
rectificationPlan: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'), trigger: 'blur' },
|
||||
correctionSolution: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'), trigger: 'blur' },
|
||||
// 与其他项目共用性
|
||||
sharedWithOtherProjects: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'), trigger: 'blur' }
|
||||
commonality: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'), trigger: 'blur' }
|
||||
},
|
||||
formArr: [
|
||||
{ // 整改周期
|
||||
fieldShowType: 4,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'rectificationCycle'
|
||||
dbFieldName: 'correctionCycle'
|
||||
},
|
||||
{ // 整改费用
|
||||
fieldShowType: 4,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'rectificationCost'
|
||||
dbFieldName: 'correctionCost'
|
||||
},
|
||||
{ // 共用后本项目所需费用
|
||||
fieldShowType: 4,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'costOfThisItemAfterSharing'
|
||||
dbFieldName: 'commonalityCost'
|
||||
},
|
||||
{ // 不满足要求的现状
|
||||
fieldShowType: 1,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'theStatusNotMeetRequirements'
|
||||
dbFieldName: 'unsatisfiedRequire'
|
||||
},
|
||||
{ // 整改方案
|
||||
fieldShowType: 1,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'rectificationPlan'
|
||||
dbFieldName: 'correctionSolution'
|
||||
},
|
||||
{ // 与其他项目共用性
|
||||
fieldShowType: 1,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'sharedWithOtherProjects'
|
||||
dbFieldName: 'commonality'
|
||||
}
|
||||
]
|
||||
},
|
||||
@@ -168,7 +168,7 @@ export default {
|
||||
// 备注
|
||||
remark: { required: false, message: this.$t('pleaseEnter') + this.$t('remarks'), trigger: 'blur' },
|
||||
// 佐证材料
|
||||
file: { required: false, message: this.$t('pleaseUpload') + this.$t('supportingMaterial'), trigger: 'change' }
|
||||
material: { required: false, message: this.$t('pleaseUpload') + this.$t('supportingMaterial'), trigger: 'change' }
|
||||
},
|
||||
formArr: [
|
||||
{
|
||||
@@ -179,61 +179,61 @@ export default {
|
||||
{
|
||||
fieldShowType: 2,
|
||||
dbFieldTxt: this.$t('supportingMaterial'),
|
||||
dbFieldName: 'file'
|
||||
dbFieldName: 'material'
|
||||
}
|
||||
]
|
||||
},
|
||||
4: { // 待验证
|
||||
rules: {
|
||||
// 整改周期
|
||||
rectificationCycle: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' },
|
||||
correctionCycle: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' },
|
||||
// 整改费用
|
||||
rectificationCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'), trigger: 'blur' },
|
||||
correctionCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'), trigger: 'blur' },
|
||||
// 共用后本项目所需费用
|
||||
costOfThisItemAfterSharing: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'), trigger: 'blur' },
|
||||
commonalityCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'), trigger: 'blur' },
|
||||
// 不满足要求的现状
|
||||
theStatusNotMeetRequirements: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'), trigger: 'blur' },
|
||||
unsatisfiedRequire: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'), trigger: 'blur' },
|
||||
// 整改方案
|
||||
rectificationPlan: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'), trigger: 'blur' },
|
||||
correctionSolution: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'), trigger: 'blur' },
|
||||
// 与其他项目共用性
|
||||
sharedWithOtherProjects: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'), trigger: 'blur' }
|
||||
commonality: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'), trigger: 'blur' }
|
||||
},
|
||||
formArr: [
|
||||
{ // 整改周期
|
||||
fieldShowType: 4,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'rectificationCycle'
|
||||
dbFieldName: 'correctionCycle'
|
||||
},
|
||||
{ // 整改费用
|
||||
fieldShowType: 4,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'rectificationCost'
|
||||
dbFieldName: 'correctionCost'
|
||||
},
|
||||
{ // 共用后本项目所需费用
|
||||
fieldShowType: 4,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'costOfThisItemAfterSharing'
|
||||
dbFieldName: 'commonalityCost'
|
||||
},
|
||||
{ // 不满足要求的现状
|
||||
fieldShowType: 1,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'theStatusNotMeetRequirements'
|
||||
dbFieldName: 'unsatisfiedRequire'
|
||||
},
|
||||
{ // 整改方案
|
||||
fieldShowType: 1,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'rectificationPlan'
|
||||
dbFieldName: 'correctionSolution'
|
||||
},
|
||||
{ // 与其他项目共用性
|
||||
fieldShowType: 1,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'sharedWithOtherProjects'
|
||||
dbFieldName: 'commonality'
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -244,26 +244,20 @@ export default {
|
||||
// 拿到外面传进来的数据初始化,因为套了几层就不在外层初始化数据了
|
||||
initData (data) {
|
||||
// 给表单赋值
|
||||
this.formInline = Object.assign({}, data)
|
||||
this.dataSource = JSON.parse(JSON.stringify(data.detailInfoList))
|
||||
this.isGetDataAfter = true
|
||||
},
|
||||
// 外层要获取数据
|
||||
getData () {
|
||||
// 把数据抛出,在线编辑不知道要不要抛
|
||||
const data = {}
|
||||
data.formInline = this.formInline
|
||||
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
|
||||
return data
|
||||
},
|
||||
// 外层获取数据要过校验,返回false表示没有通过校验
|
||||
async getDataValidate () {
|
||||
let data = {}
|
||||
await this.$refs.ruleForm.validate(valid => {
|
||||
if (valid) {
|
||||
data.formInline = this.formInline
|
||||
} else {
|
||||
data = false
|
||||
}
|
||||
})
|
||||
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
|
||||
return data
|
||||
}
|
||||
}
|
||||
|
||||
+14
-20
@@ -51,28 +51,28 @@ export default {
|
||||
title: this.$t('clauseNo'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseNo',
|
||||
dataIndex: 'termNumber',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 条款内容
|
||||
title: this.$t('clauseContent'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseContent',
|
||||
dataIndex: 'termContent',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型
|
||||
title: this.$t('vehicleType'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'vehicleType',
|
||||
dataIndex: 'model',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型状态
|
||||
title: this.$t('modelStatus'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'modelStatus',
|
||||
dataIndex: 'modelState',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 责任部门
|
||||
@@ -93,49 +93,49 @@ export default {
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.evaluationResult'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'evaluationResult',
|
||||
dataIndex: 'result',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 不满足要求的现状
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'theStatusNotMeetRequirements',
|
||||
dataIndex: 'unsatisfiedRequire',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 整改方案
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'rectificationPlan',
|
||||
dataIndex: 'correctionSolution',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 整改周期
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'rectificationCycle',
|
||||
dataIndex: 'correctionCycle',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 整改费用
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'rectificationCost',
|
||||
dataIndex: 'correctionCost',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 与其他项目共用性
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'sharedWithOtherProjects',
|
||||
dataIndex: 'commonality',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 共用后本项目所需费用
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'costOfThisItemAfterSharing',
|
||||
dataIndex: 'commonalityCost',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 备注
|
||||
@@ -160,26 +160,20 @@ export default {
|
||||
// 拿到外面传进来的数据初始化,因为套了几层就不在外层初始化数据了
|
||||
initData (data) {
|
||||
// 给表单赋值
|
||||
this.formInline = Object.assign({}, data)
|
||||
this.dataSource = JSON.parse(JSON.stringify(data.detailInfoList))
|
||||
this.isGetDataAfter = true
|
||||
},
|
||||
// 外层要获取数据
|
||||
getData () {
|
||||
// 把数据抛出,在线编辑不知道要不要抛
|
||||
const data = {}
|
||||
data.formInline = this.formInline
|
||||
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
|
||||
return data
|
||||
},
|
||||
// 外层获取数据要过校验,返回false表示没有通过校验
|
||||
async getDataValidate () {
|
||||
let data = {}
|
||||
await this.$refs.ruleForm.validate(valid => {
|
||||
if (valid) {
|
||||
data.formInline = this.formInline
|
||||
} else {
|
||||
data = false
|
||||
}
|
||||
})
|
||||
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
|
||||
return data
|
||||
}
|
||||
}
|
||||
|
||||
+16
-13
@@ -14,13 +14,13 @@
|
||||
{{ $t('workCenter.regulatoryComplianceCheckProcess.primaryInvestigator') }}
|
||||
</span>
|
||||
</div>
|
||||
<a-form-model-item class="item-model" prop="primaryInvestigator">
|
||||
<user-selection v-model="formInline.primaryInvestigator"
|
||||
<a-form-model-item class="item-model" prop="mainCheckUser">
|
||||
<user-selection v-model="formInline.mainCheckUser"
|
||||
:placeholder="$t('pleaseSelect')+$t('workCenter.regulatoryComplianceCheckProcess.primaryInvestigator')"
|
||||
:disabled="disabled"
|
||||
filedName="primaryInvestigator"
|
||||
filedName="mainCheckUser"
|
||||
@nameChange="userSelectNameChange"
|
||||
:nameStr="formInline.primaryInvestigator_dictText"
|
||||
:nameStr="formInline.mainCheckUser_dictText"
|
||||
type="checkbox"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
@@ -62,7 +62,7 @@ export default {
|
||||
formInline: {},
|
||||
rules: {
|
||||
// 主排查人
|
||||
primaryInvestigator: [
|
||||
mainCheckUser: [
|
||||
{
|
||||
required: true,
|
||||
message: this.$t('workCenter.regulatoryComplianceCheckProcess.primaryInvestigator') + this.$t('cannotEmpty'),
|
||||
@@ -85,35 +85,35 @@ export default {
|
||||
title: this.$t('standardNumber') + '/' + this.$t('clauseNo'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseNo',
|
||||
dataIndex: 'termNumber',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 标准名称/条款标题
|
||||
title: this.$t('standardName') + '/' + this.$t('clauseTitle'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseTitle',
|
||||
dataIndex: 'termTitle',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 条款内容
|
||||
title: this.$t('clauseContent'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseContent',
|
||||
dataIndex: 'termContent',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型
|
||||
title: this.$t('vehicleType'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'vehicleType',
|
||||
dataIndex: 'model',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型状态
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.modelStatus'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'modelStatus',
|
||||
dataIndex: 'modelState_dictText',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
}
|
||||
],
|
||||
@@ -125,14 +125,16 @@ export default {
|
||||
// 拿到外面传进来的数据初始化,因为套了几层就不在外层初始化数据了
|
||||
initData (data) {
|
||||
// 给表单赋值
|
||||
this.formInline = Object.assign({}, data)
|
||||
this.formInline = Object.assign({}, data.standardInfo)
|
||||
this.dataSource = JSON.parse(JSON.stringify(data.detailInfoList))
|
||||
this.isGetDataAfter = true
|
||||
},
|
||||
// 外层要获取数据
|
||||
getData () {
|
||||
// 把数据抛出,在线编辑不知道要不要抛
|
||||
const data = {}
|
||||
data.formInline = this.formInline
|
||||
data.standardInfo = Object.assign({}, this.formInline)
|
||||
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
|
||||
return data
|
||||
},
|
||||
// 外层获取数据要过校验,返回false表示没有通过校验
|
||||
@@ -140,7 +142,8 @@ export default {
|
||||
let data = {}
|
||||
await this.$refs.ruleForm.validate(valid => {
|
||||
if (valid) {
|
||||
data.formInline = this.formInline
|
||||
data.standardInfo = Object.assign({}, this.formInline)
|
||||
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
|
||||
} else {
|
||||
data = false
|
||||
}
|
||||
|
||||
+17
-14
@@ -132,28 +132,28 @@ export default {
|
||||
title: this.$t('clauseNo'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseNo',
|
||||
dataIndex: 'termNumber',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 条款内容
|
||||
title: this.$t('clauseContent'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseContent',
|
||||
dataIndex: 'termContent',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型
|
||||
title: this.$t('vehicleType'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'vehicleType',
|
||||
dataIndex: 'model',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型状态
|
||||
title: this.$t('modelStatus'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'modelStatus',
|
||||
dataIndex: 'modelState',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 责任部门
|
||||
@@ -174,49 +174,49 @@ export default {
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.evaluationResult'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'evaluationResult',
|
||||
dataIndex: 'result',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 不满足要求的现状
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'theStatusNotMeetRequirements',
|
||||
dataIndex: 'unsatisfiedRequire',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 整改方案
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'rectificationPlan',
|
||||
dataIndex: 'correctionSolution',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 整改周期
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'rectificationCycle',
|
||||
dataIndex: 'correctionCycle',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 整改费用
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'rectificationCost',
|
||||
dataIndex: 'correctionCost',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 与其他项目共用性
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'sharedWithOtherProjects',
|
||||
dataIndex: 'commonality',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 共用后本项目所需费用
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'costOfThisItemAfterSharing',
|
||||
dataIndex: 'commonalityCost',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 备注
|
||||
@@ -278,14 +278,16 @@ export default {
|
||||
// 拿到外面传进来的数据初始化,因为套了几层就不在外层初始化数据了
|
||||
initData (data) {
|
||||
// 给表单赋值
|
||||
this.formInline = Object.assign({}, data)
|
||||
this.formInline = Object.assign({}, data.standardInfo)
|
||||
this.dataSource = JSON.parse(JSON.stringify(data.detailInfoList))
|
||||
this.isGetDataAfter = true
|
||||
},
|
||||
// 外层要获取数据
|
||||
getData () {
|
||||
// 把数据抛出,在线编辑不知道要不要抛
|
||||
const data = {}
|
||||
data.formInline = this.formInline
|
||||
data.standardInfo = Object.assign({}, this.formInline)
|
||||
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
|
||||
return data
|
||||
},
|
||||
// 外层获取数据要过校验,返回false表示没有通过校验
|
||||
@@ -293,7 +295,8 @@ export default {
|
||||
let data = {}
|
||||
await this.$refs.ruleForm.validate(valid => {
|
||||
if (valid) {
|
||||
data.formInline = this.formInline
|
||||
data.standardInfo = Object.assign({}, this.formInline)
|
||||
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
|
||||
} else {
|
||||
data = false
|
||||
}
|
||||
|
||||
+15
-15
@@ -24,46 +24,46 @@
|
||||
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" :label="$t('workCenter.regulatoryComplianceCheckProcess.evaluationResult')">
|
||||
<j-dict-select-tag :placeholder="$t('pleaseSelect') + $t('workCenter.regulatoryComplianceCheckProcess.evaluationResult')"
|
||||
dict-code="evaluation_result"
|
||||
v-decorator="['evaluationResult', validatorRules.evaluationResult]" />
|
||||
v-decorator="['result', validatorRules.result]" />
|
||||
</a-form-item>
|
||||
<!-- 不满足要求的现状 -->
|
||||
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" :label="$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements')">
|
||||
<a-textarea :placeholder="$t('pleaseEnter') + $t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements')"
|
||||
:maxLength="500"
|
||||
:autoSize="{minRows: 4, maxRows: 6}"
|
||||
v-decorator="['theStatusNotMeetRequirements', validatorRules.theStatusNotMeetRequirements]" />
|
||||
v-decorator="['unsatisfiedRequire', validatorRules.unsatisfiedRequire]" />
|
||||
</a-form-item>
|
||||
<!-- 整改方案 -->
|
||||
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" :label="$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan')">
|
||||
<a-textarea :placeholder="$t('pleaseEnter') + $t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan')"
|
||||
:maxLength="500"
|
||||
:autoSize="{minRows: 4, maxRows: 6}"
|
||||
v-decorator="['rectificationPlan', validatorRules.rectificationPlan]" />
|
||||
v-decorator="['correctionSolution', validatorRules.correctionSolution]" />
|
||||
</a-form-item>
|
||||
<!-- 整改周期 -->
|
||||
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" :label="$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle')">
|
||||
<a-input :placeholder="$t('pleaseEnter') + $t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle')"
|
||||
:maxLength="50"
|
||||
v-decorator="['rectificationCycle', validatorRules.rectificationCycle]" />
|
||||
v-decorator="['correctionCycle', validatorRules.correctionCycle]" />
|
||||
</a-form-item>
|
||||
<!-- 整改费用 -->
|
||||
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" :label="$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost')">
|
||||
<a-input :placeholder="$t('pleaseEnter') + $t('workCenter.regulatoryComplianceCheckProcess.rectificationCost')"
|
||||
:maxLength="50"
|
||||
v-decorator="['rectificationCost', validatorRules.rectificationCost]" />
|
||||
v-decorator="['correctionCost', validatorRules.correctionCost]" />
|
||||
</a-form-item>
|
||||
<!-- 与其他项目共用性 -->
|
||||
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" :label="$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects')">
|
||||
<a-textarea :placeholder="$t('pleaseEnter') + $t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects')"
|
||||
:maxLength="500"
|
||||
:autoSize="{minRows: 4, maxRows: 6}"
|
||||
v-decorator="['sharedWithOtherProjects', validatorRules.sharedWithOtherProjects]" />
|
||||
v-decorator="['commonality', validatorRules.commonality]" />
|
||||
</a-form-item>
|
||||
<!-- 共用后本项目所需费用 -->
|
||||
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" :label="$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing')">
|
||||
<a-input :placeholder="$t('pleaseEnter') + $t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing')"
|
||||
:maxLength="50"
|
||||
v-decorator="['costOfThisItemAfterSharing', validatorRules.costOfThisItemAfterSharing]" />
|
||||
v-decorator="['commonalityCost', validatorRules.commonalityCost]" />
|
||||
</a-form-item>
|
||||
<!-- 备注 -->
|
||||
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" :label="$t('remarks')">
|
||||
@@ -75,7 +75,7 @@
|
||||
<!-- 佐证材料 -->
|
||||
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" :label="$t('supportingMaterial')">
|
||||
<j-upload return-id
|
||||
v-decorator="['supportingMaterial', validatorRules.supportingMaterial]" />
|
||||
v-decorator="['material', validatorRules.material]" />
|
||||
</a-form-item>
|
||||
</a-form>
|
||||
|
||||
@@ -110,37 +110,37 @@ export default {
|
||||
validateTrigger: 'change'
|
||||
},
|
||||
// 评估结果
|
||||
evaluationResult: {
|
||||
result: {
|
||||
rules: [{ required: true, message: this.$t('pleaseSelect') + this.$t('workCenter.regulatoryComplianceCheckProcess.evaluationResult') }],
|
||||
validateTrigger: 'change'
|
||||
},
|
||||
// 不满足要求的现状
|
||||
newProductImplDate: {
|
||||
unsatisfiedRequire: {
|
||||
rules: [{ required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements') }],
|
||||
validateTrigger: 'blur'
|
||||
},
|
||||
// 整改方案
|
||||
rectificationPlan: {
|
||||
correctionSolution: {
|
||||
rules: [{ required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan') }],
|
||||
validateTrigger: 'blur'
|
||||
},
|
||||
// 整改周期
|
||||
rectificationCycle: {
|
||||
correctionCycle: {
|
||||
rules: [{ required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle') }],
|
||||
validateTrigger: 'blur'
|
||||
},
|
||||
// 整改费用
|
||||
rectificationCost: {
|
||||
correctionCost: {
|
||||
rules: [{ required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost') }],
|
||||
validateTrigger: 'blur'
|
||||
},
|
||||
// 与其他项目共用性
|
||||
sharedWithOtherProjects: {
|
||||
commonality: {
|
||||
rules: [{ required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects') }],
|
||||
validateTrigger: 'blur'
|
||||
},
|
||||
// 共用后本项目所需费用
|
||||
costOfThisItemAfterSharing: {
|
||||
commonalityCost: {
|
||||
rules: [{ required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing') }],
|
||||
validateTrigger: 'blur'
|
||||
}
|
||||
|
||||
+54
-51
@@ -13,11 +13,11 @@
|
||||
{{ $t('workCenter.regulatoryComplianceCheckProcess.checkWhetherTheTaskIsDelivered') }}
|
||||
</span>
|
||||
</div>
|
||||
<a-form-model-item class="item-model" prop="checkWhetherTheTaskIsDelivered">
|
||||
<a-form-model-item class="item-model" prop="distributeFlag">
|
||||
<j-dict-select-tag
|
||||
:placeholder="$t('pleaseSelect') + this.$t('workCenter.regulatoryComplianceCheckProcess.checkWhetherTheTaskIsDelivered')"
|
||||
dict-code="yn"
|
||||
v-model="formInline.checkWhetherTheTaskIsDelivered">
|
||||
v-model="formInline.distributeFlag">
|
||||
</j-dict-select-tag>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
@@ -30,7 +30,7 @@
|
||||
</div>
|
||||
|
||||
<!-- 排查任务是否下发选择是的情况 -->
|
||||
<template v-if="clickNextAfter && formInline.checkWhetherTheTaskIsDelivered === YesOrNoEnum.YES.value">
|
||||
<template v-if="clickNextAfter && formInline.distributeFlag === YesOrNoEnum.YES.value">
|
||||
<!-- 操作区域 -->
|
||||
<div v-if="!disabled" class="table-operator">
|
||||
<!-- 批量选择人员 -->
|
||||
@@ -55,7 +55,7 @@
|
||||
</template>
|
||||
|
||||
<!-- 排查任务是否下发选择否的情况 -->
|
||||
<template v-else-if="clickNextAfter && formInline.checkWhetherTheTaskIsDelivered === YesOrNoEnum.NO.value">
|
||||
<template v-else-if="clickNextAfter && formInline.distributeFlag === YesOrNoEnum.NO.value">
|
||||
<!-- 操作区域 -->
|
||||
<div v-if="!disabled" class="table-operator">
|
||||
<!-- 导入 -->
|
||||
@@ -80,16 +80,16 @@
|
||||
rowKey="standardNumber"
|
||||
:columns="columnsEvaluate"
|
||||
:dataSource="dataSourceEvaluate"
|
||||
formIsDepend="evaluationResult"
|
||||
formIsDepend="result"
|
||||
:extraForm="extraForm"
|
||||
:loading="loading">
|
||||
|
||||
<template slot="evaluationResult" slot-scope="{text, record}">
|
||||
<template slot="result" slot-scope="{text, record}">
|
||||
<j-dict-select-tag
|
||||
style="width: 100%"
|
||||
:placeholder="$t('pleaseSelect')"
|
||||
dict-code="evaluation_result"
|
||||
v-model="record.evaluationResult">
|
||||
v-model="record.result">
|
||||
</j-dict-select-tag>
|
||||
</template>
|
||||
|
||||
@@ -206,7 +206,7 @@ export default {
|
||||
formInline: {},
|
||||
rules: {
|
||||
// 排查任务是否下发
|
||||
checkWhetherTheTaskIsDelivered: [
|
||||
distributeFlag: [
|
||||
{
|
||||
required: true,
|
||||
message: this.$t('workCenter.regulatoryComplianceCheckProcess.checkWhetherTheTaskIsDelivered') + this.$t('cannotEmpty'),
|
||||
@@ -254,35 +254,35 @@ export default {
|
||||
title: this.$t('clauseNo'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseNo',
|
||||
dataIndex: 'termNumber',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 条款标题
|
||||
title: this.$t('clauseTitle'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseTitle',
|
||||
dataIndex: 'termTitle',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 条款内容
|
||||
title: this.$t('clauseContent'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseContent',
|
||||
dataIndex: 'termContent',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型
|
||||
title: this.$t('vehicleType'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'vehicleType',
|
||||
dataIndex: 'model',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型状态
|
||||
title: this.$t('modelStatus'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'modelStatus',
|
||||
dataIndex: 'modelState',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 设计工程师
|
||||
@@ -308,43 +308,43 @@ export default {
|
||||
title: this.$t('clauseNo'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseNo',
|
||||
dataIndex: 'termNumber',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 条款标题
|
||||
title: this.$t('clauseTitle'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseTitle',
|
||||
dataIndex: 'termTitle',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 条款内容
|
||||
title: this.$t('clauseContent'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseContent',
|
||||
dataIndex: 'termContent',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型
|
||||
title: this.$t('vehicleType'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'vehicleType',
|
||||
dataIndex: 'model',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型状态
|
||||
title: this.$t('modelStatus'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'modelStatus',
|
||||
dataIndex: 'modelState',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 评价结果
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.evaluationResult'),
|
||||
align: 'center',
|
||||
width: 300,
|
||||
dataIndex: 'evaluationResult',
|
||||
scopedSlots: { customRender: 'evaluationResult' }
|
||||
dataIndex: 'result',
|
||||
scopedSlots: { customRender: 'result' }
|
||||
}
|
||||
],
|
||||
dataSourceEvaluate: [],
|
||||
@@ -354,7 +354,7 @@ export default {
|
||||
// 备注
|
||||
remark: { required: false, message: this.$t('pleaseEnter') + this.$t('remarks'), trigger: 'blur' },
|
||||
// 佐证材料
|
||||
file: { required: false, message: this.$t('pleaseUpload') + this.$t('supportingMaterial'), trigger: 'change' }
|
||||
material: { required: false, message: this.$t('pleaseUpload') + this.$t('supportingMaterial'), trigger: 'change' }
|
||||
},
|
||||
formArr: [
|
||||
{
|
||||
@@ -365,61 +365,61 @@ export default {
|
||||
{
|
||||
fieldShowType: 2,
|
||||
dbFieldTxt: this.$t('supportingMaterial'),
|
||||
dbFieldName: 'file'
|
||||
dbFieldName: 'material'
|
||||
}
|
||||
]
|
||||
},
|
||||
2: { // 不符合
|
||||
rules: {
|
||||
// 整改周期
|
||||
rectificationCycle: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' },
|
||||
correctionCycle: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' },
|
||||
// 整改费用
|
||||
rectificationCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'), trigger: 'blur' },
|
||||
correctionCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'), trigger: 'blur' },
|
||||
// 共用后本项目所需费用
|
||||
costOfThisItemAfterSharing: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'), trigger: 'blur' },
|
||||
commonalityCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'), trigger: 'blur' },
|
||||
// 不满足要求的现状
|
||||
theStatusNotMeetRequirements: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'), trigger: 'blur' },
|
||||
unsatisfiedRequire: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'), trigger: 'blur' },
|
||||
// 整改方案
|
||||
rectificationPlan: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'), trigger: 'blur' },
|
||||
correctionSolution: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'), trigger: 'blur' },
|
||||
// 与其他项目共用性
|
||||
sharedWithOtherProjects: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'), trigger: 'blur' }
|
||||
commonality: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'), trigger: 'blur' }
|
||||
},
|
||||
formArr: [
|
||||
{ // 整改周期
|
||||
fieldShowType: 4,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'rectificationCycle'
|
||||
dbFieldName: 'correctionCycle'
|
||||
},
|
||||
{ // 整改费用
|
||||
fieldShowType: 4,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'rectificationCost'
|
||||
dbFieldName: 'correctionCost'
|
||||
},
|
||||
{ // 共用后本项目所需费用
|
||||
fieldShowType: 4,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'costOfThisItemAfterSharing'
|
||||
dbFieldName: 'commonalityCost'
|
||||
},
|
||||
{ // 不满足要求的现状
|
||||
fieldShowType: 1,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'theStatusNotMeetRequirements'
|
||||
dbFieldName: 'unsatisfiedRequire'
|
||||
},
|
||||
{ // 整改方案
|
||||
fieldShowType: 1,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'rectificationPlan'
|
||||
dbFieldName: 'correctionSolution'
|
||||
},
|
||||
{ // 与其他项目共用性
|
||||
fieldShowType: 1,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'sharedWithOtherProjects'
|
||||
dbFieldName: 'commonality'
|
||||
}
|
||||
]
|
||||
},
|
||||
@@ -428,7 +428,7 @@ export default {
|
||||
// 备注
|
||||
remark: { required: false, message: this.$t('pleaseEnter') + this.$t('remarks'), trigger: 'blur' },
|
||||
// 佐证材料
|
||||
file: { required: false, message: this.$t('pleaseUpload') + this.$t('supportingMaterial'), trigger: 'change' }
|
||||
material: { required: false, message: this.$t('pleaseUpload') + this.$t('supportingMaterial'), trigger: 'change' }
|
||||
},
|
||||
formArr: [
|
||||
{
|
||||
@@ -439,61 +439,61 @@ export default {
|
||||
{
|
||||
fieldShowType: 2,
|
||||
dbFieldTxt: this.$t('supportingMaterial'),
|
||||
dbFieldName: 'file'
|
||||
dbFieldName: 'material'
|
||||
}
|
||||
]
|
||||
},
|
||||
4: { // 待验证
|
||||
rules: {
|
||||
// 整改周期
|
||||
rectificationCycle: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' },
|
||||
correctionCycle: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' },
|
||||
// 整改费用
|
||||
rectificationCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'), trigger: 'blur' },
|
||||
correctionCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'), trigger: 'blur' },
|
||||
// 共用后本项目所需费用
|
||||
costOfThisItemAfterSharing: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'), trigger: 'blur' },
|
||||
commonalityCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'), trigger: 'blur' },
|
||||
// 不满足要求的现状
|
||||
theStatusNotMeetRequirements: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'), trigger: 'blur' },
|
||||
unsatisfiedRequire: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'), trigger: 'blur' },
|
||||
// 整改方案
|
||||
rectificationPlan: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'), trigger: 'blur' },
|
||||
correctionSolution: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'), trigger: 'blur' },
|
||||
// 与其他项目共用性
|
||||
sharedWithOtherProjects: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'), trigger: 'blur' }
|
||||
commonality: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'), trigger: 'blur' }
|
||||
},
|
||||
formArr: [
|
||||
{ // 整改周期
|
||||
fieldShowType: 4,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'rectificationCycle'
|
||||
dbFieldName: 'correctionCycle'
|
||||
},
|
||||
{ // 整改费用
|
||||
fieldShowType: 4,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'rectificationCost'
|
||||
dbFieldName: 'correctionCost'
|
||||
},
|
||||
{ // 共用后本项目所需费用
|
||||
fieldShowType: 4,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'costOfThisItemAfterSharing'
|
||||
dbFieldName: 'commonalityCost'
|
||||
},
|
||||
{ // 不满足要求的现状
|
||||
fieldShowType: 1,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'theStatusNotMeetRequirements'
|
||||
dbFieldName: 'unsatisfiedRequire'
|
||||
},
|
||||
{ // 整改方案
|
||||
fieldShowType: 1,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'rectificationPlan'
|
||||
dbFieldName: 'correctionSolution'
|
||||
},
|
||||
{ // 与其他项目共用性
|
||||
fieldShowType: 1,
|
||||
dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'),
|
||||
fieldMustInput: true,
|
||||
dbFieldName: 'sharedWithOtherProjects'
|
||||
dbFieldName: 'commonality'
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -509,14 +509,16 @@ export default {
|
||||
// 拿到外面传进来的数据初始化,因为套了几层就不在外层初始化数据了
|
||||
initData (data) {
|
||||
// 给表单赋值
|
||||
this.formInline = Object.assign({}, data)
|
||||
this.formInline = Object.assign({}, data.standardInfo)
|
||||
this.dataSource = JSON.parse(JSON.stringify(data.detailInfoList))
|
||||
this.isGetDataAfter = true
|
||||
},
|
||||
// 外层要获取数据
|
||||
getData () {
|
||||
// 把数据抛出,在线编辑不知道要不要抛
|
||||
const data = {}
|
||||
data.formInline = this.formInline
|
||||
data.standardInfo = Object.assign({}, this.formInline)
|
||||
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
|
||||
return data
|
||||
},
|
||||
// 外层获取数据要过校验,返回false表示没有通过校验
|
||||
@@ -524,7 +526,8 @@ export default {
|
||||
let data = {}
|
||||
await this.$refs.ruleForm.validate(valid => {
|
||||
if (valid) {
|
||||
data.formInline = this.formInline
|
||||
data.standardInfo = Object.assign({}, this.formInline)
|
||||
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
|
||||
} else {
|
||||
data = false
|
||||
}
|
||||
|
||||
+14
-20
@@ -66,28 +66,28 @@ export default {
|
||||
title: this.$t('clauseNo'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseNo',
|
||||
dataIndex: 'termNumber',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 条款内容
|
||||
title: this.$t('clauseContent'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'clauseContent',
|
||||
dataIndex: 'termContent',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型
|
||||
title: this.$t('vehicleType'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'vehicleType',
|
||||
dataIndex: 'model',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 车型状态
|
||||
title: this.$t('modelStatus'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'modelStatus',
|
||||
dataIndex: 'modelState',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 责任部门
|
||||
@@ -108,49 +108,49 @@ export default {
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.evaluationResult'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'evaluationResult',
|
||||
dataIndex: 'result',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 不满足要求的现状
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.theStatusNotMeetRequirements'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'theStatusNotMeetRequirements',
|
||||
dataIndex: 'unsatisfiedRequire',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 整改方案
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationPlan'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'rectificationPlan',
|
||||
dataIndex: 'correctionSolution',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 整改周期
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'rectificationCycle',
|
||||
dataIndex: 'correctionCycle',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 整改费用
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'rectificationCost',
|
||||
dataIndex: 'correctionCost',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 与其他项目共用性
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.sharedWithOtherProjects'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'sharedWithOtherProjects',
|
||||
dataIndex: 'commonality',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 共用后本项目所需费用
|
||||
title: this.$t('workCenter.regulatoryComplianceCheckProcess.costOfThisItemAfterSharing'),
|
||||
align: 'center',
|
||||
width: 180,
|
||||
dataIndex: 'costOfThisItemAfterSharing',
|
||||
dataIndex: 'commonalityCost',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{ // 备注
|
||||
@@ -178,26 +178,20 @@ export default {
|
||||
// 拿到外面传进来的数据初始化,因为套了几层就不在外层初始化数据了
|
||||
initData (data) {
|
||||
// 给表单赋值
|
||||
this.formInline = Object.assign({}, data)
|
||||
this.dataSource = JSON.parse(JSON.stringify(data.detailInfoList))
|
||||
this.isGetDataAfter = true
|
||||
},
|
||||
// 外层要获取数据
|
||||
getData () {
|
||||
// 把数据抛出,在线编辑不知道要不要抛
|
||||
const data = {}
|
||||
data.formInline = this.formInline
|
||||
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
|
||||
return data
|
||||
},
|
||||
// 外层获取数据要过校验,返回false表示没有通过校验
|
||||
async getDataValidate () {
|
||||
let data = {}
|
||||
await this.$refs.ruleForm.validate(valid => {
|
||||
if (valid) {
|
||||
data.formInline = this.formInline
|
||||
} else {
|
||||
data = false
|
||||
}
|
||||
})
|
||||
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
|
||||
return data
|
||||
},
|
||||
handleExportXls (fileName, fileSuffix = '.xls') {
|
||||
|
||||
-353
@@ -1,353 +0,0 @@
|
||||
<template>
|
||||
<!-- 从拆分库选择标准, 看后端在选标准接口加查询条件还是换接口?? -->
|
||||
<a-drawer
|
||||
:title="$t('standardSelect.standardSelection')"
|
||||
:maskClosable="false"
|
||||
:width="1000"
|
||||
placement="right"
|
||||
:closable="true"
|
||||
@close="handleCancel"
|
||||
:visible="visible"
|
||||
class="custom-drawer-style">
|
||||
<div class="custom-drawer-style-scroll">
|
||||
<div class="table-page-search-wrapper">
|
||||
<a-form layout="inline" @keyup.enter.native="searchQuery">
|
||||
<a-row :gutter="24">
|
||||
<a-col :sm="8">
|
||||
<a-form-item :label="$t('standardSelect.source')" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<j-dict-select-tag style="width: 100%" v-model="queryParam.source"
|
||||
:disabled="disabledSourceSearch"
|
||||
:placeholder="$t('pleaseSelect')+$t('standardSelect.source')"
|
||||
:triggerChange="false"
|
||||
:options="sourceOptions"
|
||||
@change="handleTypeChange" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :sm="8">
|
||||
<a-form-item :label="$t('standardSelect.standardNumOrName')" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<a-input :placeholder="$t('pleaseEnter')+$t('standardSelect.standardNumOrName')"
|
||||
v-model="queryParam.standardNumberOrName"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<div style="float: right;overflow: hidden;margin-right: 41px;margin-bottom: 20px"
|
||||
class="table-page-search-submitButtons">
|
||||
<a-button style="margin-left: 8px" type="primary" icon="search" @click="searchQuery">{{ $t('query') }}</a-button>
|
||||
<a-button style="margin-left: 8px" type="primary" ghost icon="reload" @click="searchReset">{{ $t('reset') }}</a-button>
|
||||
</div>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<a-table
|
||||
:columns="columns"
|
||||
rowKey="standardNumber"
|
||||
:scroll="{x: 900}"
|
||||
:data-source="dataList"
|
||||
:pagination="ipagination"
|
||||
:row-selection="{ type: type, selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
|
||||
:loading="loading"
|
||||
@change="handleTableChange">
|
||||
<template slot="text" slot-scope="text">
|
||||
<a-tooltip overlay-class-name="tooltip-style">
|
||||
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
|
||||
<div class="table-text">{{ text || text === 0 ? text : global.emptyLine }}</div>
|
||||
</a-tooltip>
|
||||
</template>
|
||||
|
||||
<!-- 标准编号/标准名称 -->
|
||||
<template v-slot:toDetail="text, record">
|
||||
<a-tooltip overlay-class-name="tooltip-style">
|
||||
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
|
||||
<a v-if="text" class="link-a" @click="handleGoDetail(record)">{{ text }}</a>
|
||||
<div v-else class="table-text">{{ global.emptyLine }}</div>
|
||||
</a-tooltip>
|
||||
</template>
|
||||
|
||||
<!-- 标准状态 -->
|
||||
<template slot="standardState" slot-scope="text, record">
|
||||
<a-tooltip overlay-class-name="tooltip-style">
|
||||
<template slot="title">{{ record.source === '3' ? (record.esStandardState_dictText || global.emptyLine) : (record.standardState_dictText || global.emptyLine) }}</template>
|
||||
<div class="table-text">{{ record.source === '3' ? (record.esStandardState_dictText || global.emptyLine) : (record.standardState_dictText || global.emptyLine) }}</div>
|
||||
</a-tooltip>
|
||||
</template>
|
||||
|
||||
</a-table>
|
||||
</div>
|
||||
|
||||
<div class="custom-drawer-style-bottom-btn">
|
||||
<a-button @click="handleCancel">{{ $t('cancel') }}</a-button>
|
||||
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{ $t('submit') }}</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import JDictSelectTag from '@/components/dict/JDictSelectTag'
|
||||
import { StandardSource } from '../../../../enums/commonEnums'
|
||||
import { ajaxGetDictItems } from '../../../../api/api'
|
||||
import { selectStandardFromSplit } from '../../../../api/workCenter'
|
||||
export default {
|
||||
name: 'SelectStandardFromSplitModal',
|
||||
components: { JDictSelectTag },
|
||||
props: {
|
||||
source: {
|
||||
type: [String, Number],
|
||||
default: '1'
|
||||
},
|
||||
// 查询条件可以选择的类型
|
||||
canSelectedSource: {
|
||||
type: [String, Array],
|
||||
required: false,
|
||||
default: () => {
|
||||
return [StandardSource.FOREIGN.value, StandardSource.ENTERPRISE.value]
|
||||
}
|
||||
},
|
||||
value: {
|
||||
type: String,
|
||||
default: ''
|
||||
},
|
||||
// 搜索条件中的来源是否不可更改
|
||||
disabledSourceSearch: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
type: {
|
||||
type: String,
|
||||
required: false,
|
||||
default: 'checkbox'
|
||||
},
|
||||
// 列表数据不包含的标准
|
||||
excludeStandardNumbers: {
|
||||
type: String,
|
||||
required: false,
|
||||
default: null
|
||||
},
|
||||
// 过滤条件
|
||||
filters: {
|
||||
type: Object,
|
||||
required: false,
|
||||
default: () => {
|
||||
return {}
|
||||
}
|
||||
}
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
visible: false,
|
||||
confirmLoading: false,
|
||||
labelCol: {
|
||||
sm: 8
|
||||
},
|
||||
wrapperCol: {
|
||||
sm: 14
|
||||
},
|
||||
selectedRowKeys: [],
|
||||
selectedRowList: [],
|
||||
loading: false,
|
||||
queryParam: {},
|
||||
/* 分页参数 */
|
||||
ipagination: {
|
||||
current: 1,
|
||||
pageSize: 10,
|
||||
pageSizeOptions: ['10', '30', '50', '100', '150', '200'],
|
||||
showTotal: (total, range) => {
|
||||
return range[0] + '-' + range[1] + ' ' + this.$t('total') + ' ' + total + ' ' + this.$t('strip')
|
||||
},
|
||||
showQuickJumper: true,
|
||||
showSizeChanger: true,
|
||||
total: 0
|
||||
},
|
||||
columns: [
|
||||
{
|
||||
title: this.$t('standardNumber'),
|
||||
dataIndex: 'standardNumber',
|
||||
ellipsis: true,
|
||||
align: 'center',
|
||||
width: 150,
|
||||
scopedSlots: { customRender: 'toDetail' }
|
||||
},
|
||||
{
|
||||
title: this.$t('standardName'),
|
||||
dataIndex: 'standardName',
|
||||
ellipsis: true,
|
||||
align: 'center',
|
||||
width: 150,
|
||||
scopedSlots: { customRender: 'toDetail' }
|
||||
},
|
||||
// 实施日期
|
||||
{
|
||||
title: this.$t('standardSelect.materialDate'),
|
||||
dataIndex: 'implementationDate',
|
||||
align: 'center',
|
||||
width: 120,
|
||||
scopedSlots: { customRender: 'text' }
|
||||
},
|
||||
{
|
||||
title: this.$t('standardSelect.textState'),
|
||||
dataIndex: 'standardState_dictText',
|
||||
align: 'center',
|
||||
width: 150,
|
||||
scopedSlots: { customRender: 'standardState' }
|
||||
}
|
||||
],
|
||||
dataList: [],
|
||||
sourceOptions: []
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
open () {
|
||||
this.visible = true
|
||||
this.queryParam = {}
|
||||
this.initDict()
|
||||
this.$nextTick(() => {
|
||||
this.source ? this.queryParam.source = this.source : this.queryParam = {}
|
||||
this.replacePage()
|
||||
})
|
||||
},
|
||||
initDict () {
|
||||
ajaxGetDictItems('standard_source').then(res => {
|
||||
if (res.success) {
|
||||
const canSelectedArr = typeof this.canSelectedSource === 'string' ? this.canSelectedSource.split(',') : this.canSelectedSource
|
||||
this.sourceOptions = res.result.filter(tt => canSelectedArr.includes(tt.value))
|
||||
}
|
||||
})
|
||||
},
|
||||
// 获取表格数据
|
||||
replacePage (arg) {
|
||||
if (arg === 1) {
|
||||
this.ipagination.current = 1
|
||||
}
|
||||
const query = {
|
||||
...this.queryParam,
|
||||
...this.filters,
|
||||
pageNo: this.ipagination.current,
|
||||
pageSize: this.ipagination.pageSize,
|
||||
excludeStandardNumbers: this.excludeStandardNumbers
|
||||
}
|
||||
// 清空在可选范围内进行查询
|
||||
if (!query.source && this.canSelectedSource.length < 3) {
|
||||
query.source = this.canSelectedSource.join(',')
|
||||
}
|
||||
// this.selectedRowKeys = []
|
||||
this.loading = true
|
||||
selectStandardFromSplit(query).then((res) => {
|
||||
if (res.success) {
|
||||
this.dataList = res.result.records
|
||||
this.ipagination.total = res.result.total
|
||||
this.selectedRowKeys = this.value ? this.value.split(',') : (this.selectedRowKeys || [])
|
||||
} else {
|
||||
this.dataList = []
|
||||
}
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
searchQuery () {
|
||||
this.replacePage(1)
|
||||
},
|
||||
searchReset () {
|
||||
// 如果禁用来源,就不重置来源
|
||||
if (this.disabledSourceSearch) {
|
||||
this.queryParam = { source: this.source }
|
||||
} else {
|
||||
this.queryParam = {}
|
||||
}
|
||||
this.replacePage(1)
|
||||
},
|
||||
// 表格选择改变
|
||||
onSelectChange (selectedRowKeys, selectedRows) {
|
||||
this.selectedRowKeys = selectedRowKeys
|
||||
// this.selectedRowList = row
|
||||
if (this.type === 'checkbox') {
|
||||
if (selectedRowKeys.length > this.selectedRowList.length) {
|
||||
// 说明是增加了数据
|
||||
for (const rowIndex in selectedRows) {
|
||||
if (!this.selectedRowList.find(item => item.standardNumber === selectedRows[rowIndex].standardNumber)) {
|
||||
// 不存在,追加
|
||||
this.selectedRowList.push(selectedRows[rowIndex])
|
||||
}
|
||||
}
|
||||
} else {
|
||||
// 说明是删除了数据
|
||||
if (selectedRowKeys && selectedRowKeys.length > 0) {
|
||||
// 没有选中数据,说明这一页没有选中数据了
|
||||
for (let i = 0; i < this.selectedRowList.length; i++) {
|
||||
if (!selectedRowKeys.find(item => item === this.selectedRowList[i].standardNumber)) {
|
||||
// 表格选中中没有找到这一条数据,说明已经被删了
|
||||
this.selectedRowList.splice(i, 1)
|
||||
i--
|
||||
}
|
||||
}
|
||||
} else {
|
||||
this.selectedRowList = []
|
||||
}
|
||||
}
|
||||
console.log(this.selectedRowList)
|
||||
} else {
|
||||
this.selectedRowList = selectedRows
|
||||
}
|
||||
},
|
||||
handleTableChange (pagination) {
|
||||
// 分页、排序、筛选变化时触发
|
||||
this.ipagination = pagination
|
||||
this.replacePage()
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
},
|
||||
handleSubmit () {
|
||||
const serialNumber = []
|
||||
const serialNameArr = []
|
||||
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
|
||||
this.selectedRowList.forEach(res => {
|
||||
serialNumber.push(res.standardNumber)
|
||||
serialNameArr.push(res.standardName)
|
||||
})
|
||||
this.$emit('change', this.selectedRowKeys.join(','))
|
||||
this.$emit('nameChange', serialNameArr.join(','))
|
||||
this.$emit('listChange', this.selectedRowList)
|
||||
this.close()
|
||||
} else {
|
||||
this.$message.warning(this.$t('selectLeastOne'))
|
||||
}
|
||||
},
|
||||
close () {
|
||||
this.visible = false
|
||||
this.selectedRowKeys = []
|
||||
this.ipagination = {
|
||||
current: 1,
|
||||
pageSize: 10,
|
||||
pageSizeOptions: ['10', '30', '50', '100', '150', '200'],
|
||||
showTotal: (total, range) => {
|
||||
return range[0] + '-' + range[1] + ' ' + this.$t('total') + ' ' + total + ' ' + this.$t('strip')
|
||||
},
|
||||
showQuickJumper: true,
|
||||
showSizeChanger: true,
|
||||
total: 0
|
||||
}
|
||||
},
|
||||
handleTypeChange () {
|
||||
this.$forceUpdate()
|
||||
},
|
||||
// 点击跳转标准详情
|
||||
handleGoDetail (record) {
|
||||
let path = ''
|
||||
// 需要先判断是哪种标准
|
||||
if (record.source === '1') {
|
||||
path = '/standardRegulationLibrary/foreignStandardDetailPage'
|
||||
} else if (record.source === '3') {
|
||||
path = '/enterpriseStandardLibrary/enterpriseStandardDetail'
|
||||
}
|
||||
this.$openPageNewSheet({
|
||||
path: path,
|
||||
query: {
|
||||
id: record.id
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
@import '~@assets/less/common.less';
|
||||
</style>
|
||||
Reference in New Issue
Block a user