update 项目合规评估流程\征求意见流程

This commit is contained in:
赵霄
2023-12-22 14:33:25 +08:00
parent be10e66144
commit bb6df0220c
4 changed files with 71 additions and 15 deletions
+1
View File
@@ -1,6 +1,7 @@
module.exports = {
basicInformation: '基础信息',
personalInformation: '人员信息',
checkTableRequired: '请检查表格必填项是否已填写',
// 新建流程页
newProcess: {
externalStandardsManagementProcess: '外部标准管理流程',
+1
View File
@@ -2,6 +2,7 @@ module.exports = {
basicInformation: '基础信息',
personalInformation: '人员信息',
dispatchInformation: '业务分派信息',
checkTableRequired: '请检查表格必填项是否已填写',
// 新建流程页
newProcess: {
externalStandardsManagementProcess: '外部标准管理流程',
@@ -193,7 +193,8 @@
</j-table>
</div>
<div v-if="showExpandTable">
<j-expand-table :columns="columns"
<j-expand-table ref="expandTable"
:columns="columns"
:data-source="dataSource"
:pagination="ipagination"
:all-disabled="expandTableDisabled"
@@ -321,7 +322,7 @@ import PersonnelInfo from '../../../components/PersonnelInfo'
import InternalDetailPage from '../../../components/InternalDetailPage'
import ProcessDetailList from '../../../components/ProcessDetailList'
import { WorkCenterMixin } from '../../../mixins/WorkCenterMixin'
import { ProcessKey, ProjectComplianceEvaluationProcessNode, StandardSource } from '../../../enums/commonEnums'
import { EvaluationResultType, ProcessKey, ProjectComplianceEvaluationProcessNode, StandardSource } from '../../../enums/commonEnums'
import JTable from '../../../components/jero/JTable'
import ProjectTable from './components/ProjectTable'
import UserSelection from '../../../components/selection/UserSelection'
@@ -508,10 +509,16 @@ export default {
// 不符合
'2': {
rules: {
// 依据描述
description: {
// 不符合项
nonConformance: {
required: true,
message: this.$t('pleaseEnter') + this.$t('projectLibrary.specialProjectLibrary.basisDescription'),
message: this.$t('pleaseEnter') + this.$t('projectLibrary.vehicleItemLibrary.nonConformanceTerm'),
trigger: 'blur'
},
// 应对措施
countermeasures: {
required: true,
message: this.$t('pleaseEnter') + this.$t('projectLibrary.vehicleItemLibrary.solutions'),
trigger: 'blur'
},
// 预计整改完成日期
@@ -524,8 +531,13 @@ export default {
formArr: [
{
fieldShowType: 1,
dbFieldTxt: this.$t('projectLibrary.specialProjectLibrary.basisDescription'),
dbFieldName: 'description'
dbFieldTxt: this.$t('projectLibrary.vehicleItemLibrary.nonConformanceTerm'),
dbFieldName: 'nonConformance'
},
{
fieldShowType: 1,
dbFieldTxt: this.$t('projectLibrary.vehicleItemLibrary.solutions'),
dbFieldName: 'countermeasures'
},
{
fieldShowType: 3,
@@ -537,10 +549,16 @@ export default {
// 待验证
'3': {
rules: {
// 依据描述
description: {
// 风险点
riskPoints: {
required: true,
message: this.$t('pleaseEnter') + this.$t('projectLibrary.specialProjectLibrary.basisDescription'),
message: this.$t('pleaseEnter') + this.$t('projectLibrary.vehicleItemLibrary.riskPoint'),
trigger: 'blur'
},
// 验证方案
validateSolution: {
required: true,
message: this.$t('pleaseEnter') + this.$t('projectLibrary.vehicleItemLibrary.verificationScheme'),
trigger: 'blur'
},
// 预计整改完成日期
@@ -553,8 +571,13 @@ export default {
formArr: [
{
fieldShowType: 1,
dbFieldTxt: this.$t('projectLibrary.specialProjectLibrary.basisDescription'),
dbFieldName: 'description'
dbFieldTxt: this.$t('projectLibrary.vehicleItemLibrary.riskPoint'),
dbFieldName: 'riskPoints'
},
{
fieldShowType: 1,
dbFieldTxt: this.$t('projectLibrary.vehicleItemLibrary.verificationScheme'),
dbFieldName: 'validateSolution'
},
{
fieldShowType: 3,
@@ -1104,6 +1127,18 @@ export default {
*/
handleEvaluationFeedBackChange (value, record, index) {
record.evaluationFeedback = value
// 处理变化之后清空之前的数据
const extraFormKeys = Object.keys(this.extraForm)
let deleteField = []
for (const key of extraFormKeys) {
if (key !== value) {
const fields = this.extraForm[key].formArr.map(tt => tt.dbFieldName)
deleteField = [...deleteField, ...fields]
}
}
for (const fieldName of deleteField) {
delete record[fieldName]
}
this.$set(this.dataSource, index, record)
},
dealFormData () {
@@ -1130,6 +1165,11 @@ export default {
processProjectAssess, processProjectAssessLinkList, processProjectAssessTermList
}
} else {
// 设计工程师评估节点,expand-table校验
if ((this.currentNode === ProjectComplianceEvaluationProcessNode.designEngineerEvaluation.value || this.currentNode === ProjectComplianceEvaluationProcessNode.moduleOwnerModification.value) && !this.$refs.expandTable.submit()) {
this.$message.warning(this.$t('workCenter.checkTableRequired'))
flag = false
}
const data = JSON.parse(JSON.stringify(this.dataSource))
formData.businessInfoDTO = {
processProjectAssessTermList: data
@@ -226,7 +226,7 @@
class="opinion-select"
dict-code="consultation_opinion"
:placeholder="$t('pleaseSelect') + $t('workCenter.esInspectionPlan.opinion')"
@change="value => {handleOpinionChange(value, index)}" />
@change="value => {handleOpinionChange(value, index, record)}" />
</template>
</j-expand-table>
</template>
@@ -1191,9 +1191,23 @@ export default {
* 修改意见
* @param value
* @param index
* @param record
*/
handleOpinionChange (value, index) {
this.$set(this.dataSource[index], 'isAdopt', value)
handleOpinionChange (value, index, record) {
record.isAdopt = value
// 处理变化之后清空之前的数据
const extraFormKeys = Object.keys(this.extraForm)
let deleteField = []
for (const key of extraFormKeys) {
if (key !== value) {
const fields = this.extraForm[key].formArr.map(tt => tt.dbFieldName)
deleteField = [...deleteField, ...fields]
}
}
for (const fieldName of deleteField) {
delete record[fieldName]
}
this.$set(this.dataSource, index, record)
},
showContent (text) {
this.$refs.textContentModal.open(text)