[update] 法规符合性评估流程

This commit is contained in:
lideqin
2024-07-17 13:59:19 +08:00
parent c884fa7462
commit 9593317341
3 changed files with 211 additions and 3 deletions
+2 -1
View File
@@ -192,7 +192,8 @@ export const RegulatoryComplianceCheckNodes = new EsEnums({
mainFinderCollect: { text: '主排查人汇总', value: 'sid-A478E1B2-84B6-4884-875B-E6C53392BC4F' },
countersign: { text: '会签', value: 'sid-D3B3377E-9392-44D6-81D5-9DDDA91FB083' },
designEngineerManagerReview: { text: '设计工程师科室经理审核', value: 'sid-B253F229-2E92-4882-A054-EAA068069F0F' },
seniorManagerApproved: { text: '高级经理/技术官批准', value: 'sid-31D9FF6F-D1BE-4B02-910C-5DB7A5D0A626' }
seniorManagerApproved: { text: '高级经理/技术官批准', value: 'sid-31D9FF6F-D1BE-4B02-910C-5DB7A5D0A626' },
mainFinderTwiceDistributes: { text: '主排查人分批下发(二次分发)', value: 'sid-3D1BFC0F-9074-4868-891F-2F76D00A21C7' }
})
// 市场清单发布流程节点
@@ -58,7 +58,7 @@
v-decorator="['processDescription']" />
</a-form-item>
</a-col>
<a-col v-if="[2, 3, 4, 5, 6, 7, 8, 9].includes(currentNode)" :span="24">
<a-col v-if="[2, 3, 4, 5, 6, 7, 8, 9, 10].includes(currentNode)" :span="24">
<!-- 标准编号/标准名称 -->
<a-form-item
:labelCol="$i18n.locale === EN ? longLabelColEn : longLabelCol"
@@ -70,7 +70,7 @@
v-decorator="['standardNumberName']" />
</a-form-item>
</a-col>
<a-col v-if="[2, 3, 4, 6, 7, 8, 9].includes(currentNode)" :span="24">
<a-col v-if="[2, 3, 4, 6, 7, 8, 9, 10].includes(currentNode)" :span="24">
<!-- 适用市场 -->
<a-form-item
:labelCol="$i18n.locale === EN ? longLabelColEn : longLabelCol"
@@ -102,6 +102,8 @@
<!-- 节点8设计工程师科室经理审核 -->
<!-- 节点9高级经理/技术官批准 -->
<finish-audit-base-info v-if="[7,8,9].includes(currentNode)" ref="baseInfoRef" :disabled="isLook"></finish-audit-base-info>
<!-- 节点10主排查人二次分发 -->
<main-finder-twice-distributes-base-info v-if="currentNode === 10" ref="baseInfoRef" :disabled="isLook"></main-finder-twice-distributes-base-info>
<!-- 流程审批信息 -->
<div class="process-part-title">{{ $t('processApprovalInformation') }}</div>
@@ -155,6 +157,15 @@
<!-- 提交 -->
<a-button type="primary" :loading="loading" @click="handleSubmit" icon="upload">{{ $t('submit') }}</a-button>
</template>
<!-- 主排查人二次分发 -->
<template v-else-if="[10].includes(currentNode)">
<!-- 转办 -->
<a-button type="primary" ghost :loading="loading" @click="handleTurnTo" icon="arrow-up">{{ $t('turnTo') }}</a-button>
<!-- 保存 -->
<a-button type="primary" ghost :loading="loading" @click="handleSave"><i class="iconfont icon-save"></i> {{ $t('preservation') }}</a-button>
<!-- 提交 -->
<a-button type="primary" :loading="loading" @click="handleSubmit" icon="upload">{{ $t('submit') }}</a-button>
</template>
<template v-else-if="[5].includes(currentNode)">
<!-- 转办 -->
<a-button type="primary" ghost :loading="loading" @click="handleTurnTo" icon="arrow-up">{{ $t('turnTo') }}</a-button>
@@ -210,10 +221,12 @@ import DesignEngineerEvaluation from './modules/DesignEngineerEvaluation'
import MainFinderSingleAuditBaseInfo from './modules/MainFinderSingleAuditBaseInfo'
import MainFinderCollectBaseInfo from './modules/MainFinderCollectBaseInfo'
import FinishAuditBaseInfo from './modules/FinishAuditBaseInfo'
import MainFinderTwiceDistributesBaseInfo from './modules/MainFinderTwiceDistributesBaseInfo'
export default {
name: 'RegulatoryComplianceCheckProcess',
components: {
MainFinderTwiceDistributesBaseInfo,
FinishAuditBaseInfo,
MainFinderCollectBaseInfo,
MainFinderSingleAuditBaseInfo,
@@ -264,6 +277,9 @@ export default {
} else if (nodeId === RegulatoryComplianceCheckNodes.seniorManagerApproved.value) {
// 高级经理/技术官批准
this.currentNode = 9
} else if (nodeId === RegulatoryComplianceCheckNodes.mainFinderTwiceDistributes.value) {
// 主排查人二次分发节点
this.currentNode = 10
} else {
// 预留加签节点
this.currentNode = 999
@@ -0,0 +1,191 @@
<template>
<div>
<!-- 业务分派信息部分 -->
<div class="process-part-title">{{ $t('dispatchInformation') }}</div>
<!-- 操作区域 -->
<div v-if="!disabled" class="table-operator">
<!-- 批量选择人员 -->
<a-button icon="setting" type="primary" ghost @click="batchCheckPerson">
{{ $t('workCenter.regulatoryComplianceCheckProcess.batchSelector') }}
</a-button>
</div>
<div>
<j-table
:can-drag="true"
:scroll="{x: '100%'}"
ref="table"
rowKey="id"
:columns="columns"
:dataSource="dataSource"
:pagination="ipagination"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
:loading="loading"
@change="handleTableChange">
</j-table>
</div>
<!-- 选用户弹框 -->
<user-select-modal ref="userSelectModal" type="checkbox" @change="userSelectModalChange" @nameChange="userSelectNameChange"/>
</div>
</template>
<script>
import JTable from '@/components/jero/JTable'
import UserSelectModal from '@/components/selection/UserSelectModal'
import UserSelection from '@/components/selection/UserSelection'
export default {
name: 'MainFinderTwiceDistributesBaseInfo',
components: { JTable, UserSelectModal, UserSelection },
props: {
disabled: {
type: Boolean,
required: false,
default: false
}
},
data () {
return {
loading: false,
/* 分页参数 */
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('serialNumber'),
dataIndex: '',
key: 'rowIndex',
align: 'center',
width: 80,
customRender: function (t, r, index) {
return parseInt(index) + 1
}
},
{ // 条款号
title: this.$t('clauseNo'),
align: 'center',
width: 180,
dataIndex: 'termNumber',
scopedSlots: { customRender: 'text' }
},
{ // 条款标题
title: this.$t('clauseTitle'),
align: 'center',
width: 180,
dataIndex: 'termTitle',
scopedSlots: { customRender: 'text' }
},
{ // 条款内容
title: this.$t('clauseContent'),
align: 'center',
width: 180,
dataIndex: 'termContent',
scopedSlots: { customRender: 'text' }
},
{ // 车型
title: this.$t('vehicleType'),
align: 'center',
width: 180,
dataIndex: 'model',
scopedSlots: { customRender: 'text' }
},
{ // 车型状态
title: this.$t('modelStatus'),
align: 'center',
width: 180,
dataIndex: 'modelState_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 设计工程师
title: this.$t('designEngineer'),
align: 'center',
width: 300,
dataIndex: 'designEngineer',
customRender: (value, row, index) => {
return <user-selection
v-model={row.designEngineer}
filedName={row.id} onNameChange={this.userNameChange}
nameStr={row.designEngineer_dictText} showBtn={false}
disabled={this.disabled} type={'checkbox'} placeholder={this.$t('pleaseSelect')} />
}
}
],
dataSource: [],
selectedRowKeys: [],
selectionRows: [],
selectNames: '' // 选完人的名字,批量设置人需要用
}
},
methods: {
// 拿到外面传进来的数据初始化,因为套了几层就不在外层初始化数据了
initData (data) {
// 给表单赋值
this.dataSource = JSON.parse(JSON.stringify(data.detailInfoList))
},
// 外层要获取数据
getData () {
// 把数据抛出,在线编辑不知道要不要抛
const data = {}
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
return data
},
// 外层获取数据要过校验,返回false表示没有通过校验
async getDataValidate () {
let data = {}
data.detailInfoList = JSON.parse(JSON.stringify(this.dataSource))
return data
},
// 表格选中
onSelectChange (selectedRowKeys, selectionRows) {
this.selectedRowKeys = selectedRowKeys
this.selectionRows = selectionRows
},
handleTableChange (pagination) {
this.ipagination = pagination
},
// 批量选择人员
batchCheckPerson () {
if (this.selectedRowKeys.length <= 0) {
// 请选择要分发的数据
this.$message.warning(this.$t('pleaseSelectDistributeData'))
return
}
this.$refs.userSelectModal.open()
},
// 批量设置审批人选择人后的回调
userSelectModalChange (value) {
for (const item of this.selectedRowKeys) {
const curr = this.dataSource.find(i => i.id === item)
curr.designEngineer = value
curr.designEngineer_dictText = this.selectNames
}
this.dataSource = JSON.parse(JSON.stringify(this.dataSource))
this.selectedRowKeys = []
},
// 选人的名字获取
userSelectNameChange (value) {
this.selectNames = value
},
userNameChange (value, fieldName) {
const dataIndex = this.dataSource.findIndex(item => item.id === fieldName)
this.dataSource[dataIndex].designEngineer_dictText = value
}
}
}
</script>
<style scoped>
</style>