diff --git a/src/api/workCenter.js b/src/api/workCenter.js
index dfbf5f09..d2f54906 100644
--- a/src/api/workCenter.js
+++ b/src/api/workCenter.js
@@ -215,8 +215,6 @@ const getInspectPlanProjectId = (params) => getAction('/process/esInspectPlanFlo
const getInspectPlanDetail = (params) => getAction('/process/esInspectPlanFlow/queryDetailByProjectId', params)
// 发起
const startInspectPlan = (params) => postAction('/process/esInspectPlanFlow/flowStart', params)
-// 驳回
-const refusalInspectPlan = (params) => postAction('/process/esInspectPlanFlow/flowRefusal', params)
// 审批
const approvalInspectPlan = (params) => postAction('/process/esInspectPlanFlow/flowApproval', params)
// 转办
@@ -230,6 +228,39 @@ const editInspectPlanTable = (params) => postAction('/process/processEsInspectPl
// 稽查计划表-填写意见
const fillInOpinionInspectPlanTable = (params) => postAction('/process/processEsInspectPlanOpinion/fillInOpinion', params)
+/* 企标稽查流程 */
+// 生成项目id
+const getInspectProcessProjectId = (params) => getAction('/esinspect/esInspectFlowController/getProjectId', params)
+// 详情信息
+const getInspectProcessDetail = (params) => getAction('/esinspect/esInspectFlowController/queryDetailByProjectId', params)
+// 发起
+const startInspectProcess = (params) => postAction('/esinspect/esInspectFlowController/flowStart', params)
+// 审批
+const approvalInspectProcess = (params) => postAction('/esinspect/esInspectFlowController/flowApproval', params)
+// 转办
+const transferInspectProcess = (params) => getAction('/esinspect/esInspectFlowController/flowTransfer', params)
+// 保存
+const saveInspectProcess = (params) => postAction('/esinspect/esInspectFlowController/flowSave', params)
+// 稽查流程表-添加
+const addInspectProcessTable = (params) => postAction('/esinspect/processEsInspect/add', params)
+// 稽查流程表-编辑
+const editInspectProcessTable = (params) => postAction('/esinspect/processEsInspect/edit', params)
+// 稽查流程表-稽查内容-添加
+const addInspectionContentTable = (params) => postAction('/enterprise/InspectContent/add', params)
+// 稽查流程表-稽查内容-编辑
+const editInspectionContentTable = (params) => postAction('/enterprise/InspectContent/edit', params)
+// 稽查流程表-稽查内容-列表(下拉)
+const getInspectionContentTable = (params) => getAction('/enterprise/InspectContent/queryClauseByEsInspectId', params)
+// 稽查流程表-稽查报告-添加
+const addInspectionReportTable = (params) => postAction('/laws.enterprise/EnterpriseStandardInspectReport/add', params)
+// 稽查流程表-稽查报告-编辑
+const editInspectionReportTable = (params) => postAction('/laws.enterprise/EnterpriseStandardInspectReport/edit', params)
+// 稽查流程表-整改计划-添加
+const addInspectionRectificationPlanTable = (params) => postAction('/laws.enterprise/enterpriseStandardInspectRectifyPlan/add', params)
+// 稽查流程表-整改计划-编辑
+const editInspectionRectificationPlanTable = (params) => postAction('/laws.enterprise/enterpriseStandardInspectRectifyPlan/edit', params)
+// 稽查流程表-通过稽查内容id查寻稽查报告
+const queryByInspectContentId = (params) => getAction('/laws.enterprise/EnterpriseStandardInspectReport/queryByInspectContentId', params)
export {
getProcessNodeList,
@@ -339,11 +370,27 @@ export {
getInspectPlanProjectId,
getInspectPlanDetail,
startInspectPlan,
- refusalInspectPlan,
approvalInspectPlan,
transferInspectPlan,
saveInspectPlan,
addInspectPlanTable,
editInspectPlanTable,
- fillInOpinionInspectPlanTable
+ fillInOpinionInspectPlanTable,
+
+ getInspectProcessProjectId,
+ getInspectProcessDetail,
+ startInspectProcess,
+ approvalInspectProcess,
+ transferInspectProcess,
+ saveInspectProcess,
+ addInspectProcessTable,
+ editInspectProcessTable,
+ addInspectionContentTable,
+ editInspectionContentTable,
+ getInspectionContentTable,
+ addInspectionReportTable,
+ editInspectionReportTable,
+ addInspectionRectificationPlanTable,
+ editInspectionRectificationPlanTable,
+ queryByInspectContentId
}
diff --git a/src/enums/commonEnums.js b/src/enums/commonEnums.js
index 1e2ecf16..3fcd72d3 100644
--- a/src/enums/commonEnums.js
+++ b/src/enums/commonEnums.js
@@ -267,11 +267,11 @@ export const EsInspectionPlan = new EsEnums({
// 企标稽查流程
export const EsInspectionProcess = new EsEnums({
- initiate: { text: '稽查负责人发起', value: '1', btn: 6 },
- directorLeaderApprovalOne: { text: '负责人主管级领导审批', value: '2', btn: 27 },
- inputInspectionReport: { text: '稽查负责人上传稽查报告和整改计划', value: '3', btn: 7 },
- directorLeaderApprovalTwo: { text: '负责人主管级领导审批', value: '4', btn: 27 },
- relevantPersonnelCountersign: { text: '相关人员会签', value: '5', btn: 27 }
+ initiate: { text: '稽查负责人发起', value: 'responsible_start', btn: 6 },
+ directorLeaderApprovalOne: { text: '负责人主管级领导审批', value: 'leader_approval', btn: 27 },
+ inputInspectionReport: { text: '稽查负责人上传稽查报告和整改计划', value: 'responsible_upload', btn: 7 },
+ directorLeaderApprovalTwo: { text: '负责人主管级领导审批', value: 'leader_approval_again', btn: 27 },
+ relevantPersonnelCountersign: { text: '相关人员会签', value: 'involve_countersign', btn: 27 }
})
// 稽查延期申请流程
diff --git a/src/views/workCenter/enterpriseStandardInspectionPlan/modules/InspectionPlanTable.vue b/src/views/workCenter/enterpriseStandardInspectionPlan/modules/InspectionPlanTable.vue
index 3855760b..4095d654 100644
--- a/src/views/workCenter/enterpriseStandardInspectionPlan/modules/InspectionPlanTable.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionPlan/modules/InspectionPlanTable.vue
@@ -48,7 +48,7 @@
{{ $t('edit') }}
- {{ $t('delete') }}
+ {{ $t('delete') }}
diff --git a/src/views/workCenter/enterpriseStandardInspectionProcess/EnterpriseStandardInspectionProcess.vue b/src/views/workCenter/enterpriseStandardInspectionProcess/EnterpriseStandardInspectionProcess.vue
index c4aa82bc..e0ebd75b 100644
--- a/src/views/workCenter/enterpriseStandardInspectionProcess/EnterpriseStandardInspectionProcess.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionProcess/EnterpriseStandardInspectionProcess.vue
@@ -110,7 +110,11 @@ import InspectionProcessTable
import UserSelectModal from '@comp/selection/UserSelectModal'
import { EsInspectionProcess, ProcessKey } from '@/enums/commonEnums'
import { WorkCenterMixin } from '@/mixins/WorkCenterMixin'
-import { getInspectPlanDetail, getInspectPlanProjectId } from '@api/workCenter'
+import {
+ approvalInspectProcess,
+ getInspectProcessDetail,
+ getInspectProcessProjectId, saveInspectProcess, startInspectProcess, transferInspectProcess
+} from '@api/workCenter'
export default {
name: 'EnterpriseStandardInspectionProcess',
@@ -208,7 +212,7 @@ export default {
getProjectId () {
this.loading = true
// 否则就是创建一个新的流程
- getInspectPlanProjectId().then(res => {
+ getInspectProcessProjectId().then(res => {
if (res) {
this.projectId = res + ''
}
@@ -223,7 +227,7 @@ export default {
const { projectId, taskId } = this.$route.query
this.btn = EsInspectionProcess.propertyOfValue('btn', this.currentNode)
this.loading = true
- getInspectPlanDetail({
+ getInspectProcessDetail({
projectId,
taskId
}).then(res => {
@@ -268,15 +272,12 @@ export default {
personnelObj[key] = personnelObj[key].split(',')
}
}
- // 通过表格中的所属部门人员获取稽查征求意见对象
- const userList = this.$refs.inspectionPlanTable.dataSource.map(item => item.objectOfConsultation.split(',')).flat(Infinity)
- personnelObj.opinionFillList = Array.from(new Set(userList))
}
return personnelObj
},
// 获取页面参数
async getPageParams (isValidate = true) {
- if (this.$refs.inspectionPlanTable.dataSource.length === 0) {
+ if (this.$refs.inspectionProcessTable.dataSource.length === 0) {
this.$message.warning(this.$t('addAtLeastOneRowOfData'))
throw new Error('base')
}
@@ -329,7 +330,7 @@ export default {
taskId: this.$route.query.taskId,
userId
}
- Promise.resolve(params).then(res => {
+ transferInspectProcess(params).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
@@ -348,7 +349,7 @@ export default {
this.loading = true
this.getPageParams(false).then(res => {
console.log(res)
- return Promise.resolve(res)
+ return saveInspectProcess(res)
}).then(res => {
if (res.success) {
this.$message.success(res.message)
@@ -369,16 +370,22 @@ export default {
if (this.loading) return
this.loading = true
let fn
+ let pass
switch (this.currentNode) {
case EsInspectionProcess.initiate.value:
- fn = Promise.resolve
+ fn = startInspectProcess
break
default:
- fn = Promise.resolve
+ fn = approvalInspectProcess
+ pass = true
break
}
this.getPageParams().then(res => {
console.log(res)
+ // 如果是审批,就默认pass为true
+ if (pass && res.map) {
+ res.map.pass = pass
+ }
return fn && fn(res)
}).then(res => {
if (res.success) {
@@ -401,7 +408,7 @@ export default {
this.loading = true
this.getPageParams().then(res => {
res.map.pass = true
- return Promise.resolve(res)
+ return approvalInspectProcess(res)
}).then(res => {
if (res.success) {
this.$message.success(res.message)
@@ -423,7 +430,7 @@ export default {
this.loading = true
this.getPageParams().then(res => {
res.map.pass = false
- return Promise.resolve(res)
+ return approvalInspectProcess(res)
}).then(res => {
if (res.success) {
this.$message.success(res.message)
diff --git a/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessContent.vue b/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessContent.vue
index dd199c11..97f83065 100644
--- a/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessContent.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessContent.vue
@@ -20,7 +20,7 @@
:can-drag="true"
rowKey="id"
:row-selection="null"
- :pagination="ipagination"
+ :pagination="false"
:scroll="{x: '100%'}"
@change="tableOnChange">
@@ -38,7 +38,7 @@
{{ $t('edit') }}
- {{ $t('delete') }}
+ {{ $t('delete') }}
@@ -70,14 +70,14 @@ export default {
title: this.$t('workCenter.esInspectionProcess.accordingToTerms'),
align: 'center',
width: 140,
- dataIndex: 'planInspectionDate',
+ dataIndex: 'standardNo',
scopedSlots: { customRender: 'text' }
},
{ // 标准内容或要求
title: this.$t('workCenter.esInspectionProcess.standardContentOrDemand'),
align: 'center',
width: 200,
- dataIndex: 'inspectionDirector',
+ dataIndex: 'requirement',
scopedSlots: { customRender: 'text' }
},
{
@@ -98,22 +98,26 @@ export default {
model: {},
confirmLoading: false,
url: {
- list: ''
+ list: '/enterprise/InspectContent/queryClauseByEsInspectId',
+ delete: '/enterprise/InspectContent/delete'
},
- dataSource: [{}],
+ dataSource: [],
columns: columns.slice(0, this.disabled ? 2 : 3)
}
},
methods: {
show (record) {
- this.filters = {}
+ this.filters = {
+ processEsInspectId: record.id
+ }
this.loadData()
this.model = Object.assign({}, record)
this.visible = true
},
// 确定
handleOk () {
- console.log(this.selectedRowKeys)
+ // console.log(this.selectedRowKeys)
+ this.$emit('ok')
this.close()
},
// 关闭
@@ -141,13 +145,23 @@ export default {
},
handleAdd () {
this.$refs.inspectionProcessContentModal.title = this.$t('add') + this.$t('workCenter.esInspectionProcess.opinion')
- this.$refs.inspectionProcessContentModal.add()
+ this.$refs.inspectionProcessContentModal.add(this.model)
},
handleEdit (record, index) {
- const { file } = record
this.$refs.inspectionProcessContentModal.title = this.$t('edit') + this.$t('workCenter.esInspectionProcess.opinion')
- this.$refs.inspectionProcessContentModal.edit(file, record, index)
+ this.$refs.inspectionProcessContentModal.edit(this.model, record, index)
}
+ // 意见新增编辑完成
+ // modalFormOk (value, index) {
+ // console.log(value, index)
+ // if (index || index === 0) {
+ // // 有下标,说明是编辑
+ // this.dataSource.splice(index, 1, value)
+ // } else {
+ // // 没有下标, 是新增
+ // this.dataSource.push(value)
+ // }
+ // }
}
}
diff --git a/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessContentModal.vue b/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessContentModal.vue
index e61b7d8b..f41e3110 100644
--- a/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessContentModal.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessContentModal.vue
@@ -22,14 +22,14 @@
event.target.value = event.target.value.trim()"
- v-decorator.trim="[ 'sectionNumber', validatorRules.sectionNumber ]" />
+ v-decorator.trim="[ 'standardNo', validatorRules.sectionNumber ]" />
event.target.value = event.target.value.trim()"
- v-decorator.trim="[ 'standardContentOrDemand', validatorRules.standardContentOrDemand ]" />
+ v-decorator.trim="[ 'requirement', validatorRules.standardContentOrDemand ]" />
@@ -53,11 +53,11 @@