update 项目合规流程

This commit is contained in:
赵霄
2023-12-13 10:24:22 +08:00
parent 052e0448c6
commit faf55988a8
5 changed files with 66 additions and 13 deletions
+6 -1
View File
@@ -358,6 +358,9 @@ const savePostMeetingManage = (params) => postAction('/process/meetingManageFlow
// 权限申请流程业务数据 // 权限申请流程业务数据
const getPostMeetingManageDataById = (params) => getAction('/meetingmanage/processMeetingManage/queryByProjectId', params) const getPostMeetingManageDataById = (params) => getAction('/meetingmanage/processMeetingManage/queryByProjectId', params)
/* 项目合规评估流程 */
const queryProjectRegulationList = (params) => getAction('/projectLibrary/lawsAssess/page', params)
export { export {
getProcessNodeList, getProcessNodeList,
@@ -537,5 +540,7 @@ export {
approvalPostMeetingManage, approvalPostMeetingManage,
transferPostMeetingManage, transferPostMeetingManage,
savePostMeetingManage, savePostMeetingManage,
getPostMeetingManageDataById getPostMeetingManageDataById,
queryProjectRegulationList
} }
+1 -1
View File
@@ -189,7 +189,7 @@ export const ProcessKey = {
// 征求意见流程 // 征求意见流程
CONSULTATION: { text: 'fb-standard-consultation', value: 'fb-standard-consultation' }, CONSULTATION: { text: 'fb-standard-consultation', value: 'fb-standard-consultation' },
// 项目合规评估流程 // 项目合规评估流程
PROJECT_COMPLIANCE_EVALUATION: { text: '', value: '' }, PROJECT_COMPLIANCE_EVALUATION: { text: 'project-assessment', value: 'project-assessment' },
// 未符合项跟踪流程 // 未符合项跟踪流程
NO_MATCH_TRACKING: { text: '', value: '' }, NO_MATCH_TRACKING: { text: '', value: '' },
// 法规合规评估流程 // 法规合规评估流程
@@ -92,7 +92,7 @@
<!--发起第二步选择项目、第三步添加标准,采用引入组件的方式--> <!--发起第二步选择项目、第三步添加标准,采用引入组件的方式-->
<keep-alive> <keep-alive>
<component :is="comp" v-if="comp" ref="projectStandardTable" /> <component :is="comp" v-if="comp" ref="projectStandardTable" :project-id="projectId"/>
</keep-alive> </keep-alive>
<!--业务分派信息--> <!--业务分派信息-->
@@ -387,6 +387,7 @@ export default {
} }
], ],
projectDataSource: [], // 选中的项目 projectDataSource: [], // 选中的项目
projectId: null, // 选中项目的id
standardDataSource: [], // 选中的标准 standardDataSource: [], // 选中的标准
basicColumns: [ basicColumns: [
// 序号 // 序号
@@ -748,6 +749,8 @@ export default {
this.processInfoForm.validateFields(this.processInfoShowField, (errors, values) => { this.processInfoForm.validateFields(this.processInfoShowField, (errors, values) => {
if (errors) { if (errors) {
flag = false flag = false
} else {
this.processInfo = Object.assign(this.processInfo, values)
} }
}) })
} }
@@ -757,6 +760,8 @@ export default {
if (!this.projectDataSource || this.projectDataSource.length === 0) { if (!this.projectDataSource || this.projectDataSource.length === 0) {
this.$message.warning(this.$t('addAtLeastOneRowOfData')) this.$message.warning(this.$t('addAtLeastOneRowOfData'))
flag = false flag = false
} else {
this.projectId = this.projectDataSource[0].id
} }
} }
// 第三步选择标准 // 第三步选择标准
@@ -891,7 +896,19 @@ export default {
record.evaluationFeedback = value record.evaluationFeedback = value
this.$set(this.dataSource, index, record) this.$set(this.dataSource, index, record)
}, },
dealFormData (isSave) {
let formData = {}, processProjectAssess = {}
// 流程信息
formData.basicProcessInfoDTO = { ...this.processInfo }
// 业务基本信息(项目信息)
if (this.projectDataSource && this.projectDataSource.length > 0) {
processProjectAssess.projectId = this.projectDataSource[0].id
}
return formData
},
handleSave () { handleSave () {
const formData = this.dealFormData(true)
console.log('保存表单数据===', formData)
}, },
handleSubmit () { handleSubmit () {
}, },
@@ -15,9 +15,10 @@
rowKey="id" rowKey="id"
:columns="columns" :columns="columns"
:dataSource="dataSource" :dataSource="dataSource"
:pagination="false" :pagination="ipagination"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }" :row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
v-bind="$attrs"> v-bind="$attrs"
@change="handleTableChange">
<!--分解单来源--> <!--分解单来源-->
<template v-slot:salvageListSource="{text, record, index}"> <template v-slot:salvageListSource="{text, record, index}">
@@ -42,8 +43,28 @@ import { ajaxGetDictItems } from '../../../../api/api'
export default { export default {
name: 'StandardList', name: 'StandardList',
components: { JTable, SelectStandardListDrawer }, components: { JTable, SelectStandardListDrawer },
props: {
// 第三步选中的项目id
projectId: {
type: String,
required: false,
default: null
}
},
data () { data () {
return { return {
/* 分页参数 */
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: [ columns: [
// 标准编号 // 标准编号
{ {
@@ -100,14 +121,14 @@ export default {
}, },
methods: { methods: {
initDict () { initDict () {
ajaxGetDictItems('process_manuscript').then(res => { ajaxGetDictItems('decomposition_order_source').then(res => {
if (res.success) { if (res.success) {
this.standardFileType = res.result this.standardFileType = res.result
} }
}) })
}, },
handleAdd () { handleAdd () {
this.$refs.selectStandardDrawer.open() this.$refs.selectStandardDrawer.open(this.projectId)
}, },
batchDel () { batchDel () {
if (!this.selectedRowKeys || this.selectedRowKeys.length === 0) { if (!this.selectedRowKeys || this.selectedRowKeys.length === 0) {
@@ -128,7 +149,12 @@ export default {
this.selectedRowKeys = selectedRowKeys this.selectedRowKeys = selectedRowKeys
}, },
handleOk (rows) { handleOk (rows) {
this.dataSource = rows this.dataSource = rows.map(item => {
if (!item.salvageSource) {
item.salvageSource = '0'
}
return item
})
}, },
getData () { getData () {
return this.dataSource return this.dataSource
@@ -136,6 +162,9 @@ export default {
handleSourceChange (value, record, index) { handleSourceChange (value, record, index) {
record.salvageSource = value record.salvageSource = value
this.$set(this.dataSource, index, record) this.$set(this.dataSource, index, record)
},
handleTableChange (pagination) {
this.ipagination = pagination
} }
} }
} }
@@ -62,8 +62,9 @@
</template> </template>
<script> <script>
import { ajaxGetDictItems, getStandardList } from '../../../../api/api' import { ajaxGetDictItems } from '../../../../api/api'
import { StandardSource } from '../../../../enums/commonEnums' import { StandardSource } from '../../../../enums/commonEnums'
import { queryProjectRegulationList } from '../../../../api/workCenter'
export default { export default {
name: 'SelectStandardListDrawer', name: 'SelectStandardListDrawer',
@@ -130,9 +131,11 @@ export default {
} }
}, },
methods: { methods: {
open () { open (projectId) {
this.visible = true this.visible = true
this.queryParam = {} this.queryParam = {
projectId
}
this.initDict() this.initDict()
this.$nextTick(() => { this.$nextTick(() => {
this.source ? this.queryParam.source = this.source : this.queryParam = {} this.source ? this.queryParam.source = this.source : this.queryParam = {}
@@ -153,7 +156,6 @@ export default {
...this.filters, ...this.filters,
pageNo: this.ipagination.current, pageNo: this.ipagination.current,
pageSize: this.ipagination.pageSize, pageSize: this.ipagination.pageSize,
excludeStandardNumbers: this.excludeStandardNumbers
} }
// 清空在可选范围内进行查询 // 清空在可选范围内进行查询
if (!query.source && this.canSelectedSource.length < 3) { if (!query.source && this.canSelectedSource.length < 3) {
@@ -161,7 +163,7 @@ export default {
} }
// this.selectedRowKeys = [] // this.selectedRowKeys = []
this.loading = true this.loading = true
getStandardList(query).then((res) => { queryProjectRegulationList(query).then((res) => {
if (res.success) { if (res.success) {
this.dataList = res.result.records this.dataList = res.result.records
this.ipagination.total = res.result.total this.ipagination.total = res.result.total