update 企标稽查计划
This commit is contained in:
@@ -213,6 +213,10 @@ const approvalInspectPlan = (params) => postAction('/process/esInspectPlanFlow/f
|
|||||||
const transferInspectPlan = (params) => postAction('/process/esInspectPlanFlow/flowTransfer', params)
|
const transferInspectPlan = (params) => postAction('/process/esInspectPlanFlow/flowTransfer', params)
|
||||||
// 保存
|
// 保存
|
||||||
const saveInspectPlan = (params) => postAction('/process/esInspectPlanFlow/flowSave', params)
|
const saveInspectPlan = (params) => postAction('/process/esInspectPlanFlow/flowSave', params)
|
||||||
|
// 稽查计划表-添加
|
||||||
|
const addInspectPlanTable = (params) => postAction('/process/processEsInspectPlan/add', params)
|
||||||
|
// 稽查计划表-编辑
|
||||||
|
const editInspectPlanTable = (params) => postAction('/process/processEsInspectPlan/edit', params)
|
||||||
|
|
||||||
export {
|
export {
|
||||||
getProcessNodeList,
|
getProcessNodeList,
|
||||||
@@ -321,5 +325,7 @@ export {
|
|||||||
refusalInspectPlan,
|
refusalInspectPlan,
|
||||||
approvalInspectPlan,
|
approvalInspectPlan,
|
||||||
transferInspectPlan,
|
transferInspectPlan,
|
||||||
saveInspectPlan
|
saveInspectPlan,
|
||||||
|
addInspectPlanTable,
|
||||||
|
editInspectPlanTable
|
||||||
}
|
}
|
||||||
|
|||||||
+3
-5
@@ -55,7 +55,7 @@
|
|||||||
|
|
||||||
<!-- 业务基本信息 -->
|
<!-- 业务基本信息 -->
|
||||||
<div class="process-part-title">{{ $t('basicServiceInformation') }}</div>
|
<div class="process-part-title">{{ $t('basicServiceInformation') }}</div>
|
||||||
<inspection-plan-table ref="inspectionPlanTable" :current-node="currentNode" />
|
<inspection-plan-table ref="inspectionPlanTable" :current-node="currentNode" :project-id="projectId"/>
|
||||||
<!-- 会签表单 -->
|
<!-- 会签表单 -->
|
||||||
<a-form :form="countersignForm" v-if="currentNode === EsInspectionPlan.liaisonCollect.value">
|
<a-form :form="countersignForm" v-if="currentNode === EsInspectionPlan.liaisonCollect.value">
|
||||||
<a-row type="flex">
|
<a-row type="flex">
|
||||||
@@ -288,9 +288,7 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 获取表格数据
|
// 获取表格数据
|
||||||
const params = {
|
const params = {}
|
||||||
processEsInspectPlanList: this.$refs.inspectionPlanTable.getData()
|
|
||||||
}
|
|
||||||
if (isValidate) {
|
if (isValidate) {
|
||||||
this.validateFormList(
|
this.validateFormList(
|
||||||
this.processInfoForm,
|
this.processInfoForm,
|
||||||
@@ -298,7 +296,7 @@ export default {
|
|||||||
this.approvalInfoForm
|
this.approvalInfoForm
|
||||||
).then(res => {
|
).then(res => {
|
||||||
params.processAll = res[0]
|
params.processAll = res[0]
|
||||||
if (params.processAll.dueTime && params.processAll.dueTime.includes(' 00:00:00')) {
|
if (params.processAll.dueTime && !params.processAll.dueTime.includes(' 00:00:00')) {
|
||||||
params.processAll.dueTime = params.processAll.dueTime + ' 00:00:00'
|
params.processAll.dueTime = params.processAll.dueTime + ' 00:00:00'
|
||||||
}
|
}
|
||||||
params.processAll.projectId = this.projectId
|
params.processAll.projectId = this.projectId
|
||||||
|
|||||||
+23
-4
@@ -104,9 +104,17 @@ import StandardSelection from '@comp/selection/StandardSelection'
|
|||||||
import UserSelection from '@comp/selection/UserSelection'
|
import UserSelection from '@comp/selection/UserSelection'
|
||||||
import { getWorkGroupTreeList } from '@api/api'
|
import { getWorkGroupTreeList } from '@api/api'
|
||||||
import WorkGroupSelection from '@comp/selection/WorkGroupSelection'
|
import WorkGroupSelection from '@comp/selection/WorkGroupSelection'
|
||||||
|
import { addInspectPlanTable, editInspectPlanTable } from '@api/workCenter'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'InspectionPlanDrawer',
|
name: 'InspectionPlanDrawer',
|
||||||
|
props: {
|
||||||
|
// 项目id
|
||||||
|
projectId: {
|
||||||
|
type: String,
|
||||||
|
required: true
|
||||||
|
}
|
||||||
|
},
|
||||||
components: { WorkGroupSelection, UserSelection, StandardSelection },
|
components: { WorkGroupSelection, UserSelection, StandardSelection },
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
@@ -240,11 +248,22 @@ export default {
|
|||||||
if (this.confirmLoading) return
|
if (this.confirmLoading) return
|
||||||
this.form.validateFields((err, values) => {
|
this.form.validateFields((err, values) => {
|
||||||
if (!err) {
|
if (!err) {
|
||||||
const value = Object.assign({}, this.model, values)
|
const params = Object.assign({
|
||||||
|
projectId: this.projectId
|
||||||
|
}, this.model, values)
|
||||||
this.confirmLoading = true
|
this.confirmLoading = true
|
||||||
this.$emit('ok', value)
|
const fn = params.id ? editInspectPlanTable : addInspectPlanTable
|
||||||
this.confirmLoading = false
|
fn(params).then(res => {
|
||||||
this.close()
|
if (res.success) {
|
||||||
|
this.$emit('ok', params)
|
||||||
|
this.$message.success(res.message)
|
||||||
|
this.close()
|
||||||
|
} else {
|
||||||
|
this.$message.warn(res.message)
|
||||||
|
}
|
||||||
|
}).finally(() => {
|
||||||
|
this.confirmLoading = false
|
||||||
|
})
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|||||||
+17
-20
@@ -61,7 +61,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- 新增/编辑稽查计划 -->
|
<!-- 新增/编辑稽查计划 -->
|
||||||
<inspection-plan-drawer ref="modalForm" @ok="addOrEditOk"/>
|
<inspection-plan-drawer ref="modalForm" @ok="modalFormOk" :project-id="projectId"/>
|
||||||
<!-- 填写意见、意见回显 -->
|
<!-- 填写意见、意见回显 -->
|
||||||
<write-opinion-modal ref="writeOpinionModal" @ok="modalFormOk"/>
|
<write-opinion-modal ref="writeOpinionModal" @ok="modalFormOk"/>
|
||||||
<!-- 节点3:所属部门意见-查看 -->
|
<!-- 节点3:所属部门意见-查看 -->
|
||||||
@@ -86,6 +86,11 @@ export default {
|
|||||||
currentNode: {
|
currentNode: {
|
||||||
type: String,
|
type: String,
|
||||||
required: true
|
required: true
|
||||||
|
},
|
||||||
|
// 项目id
|
||||||
|
projectId: {
|
||||||
|
type: String,
|
||||||
|
required: true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data () {
|
data () {
|
||||||
@@ -93,7 +98,10 @@ export default {
|
|||||||
EsInspectionPlan,
|
EsInspectionPlan,
|
||||||
disableMixinCreated: true,
|
disableMixinCreated: true,
|
||||||
url: {
|
url: {
|
||||||
list: '/process/processEsInspectPlan/page'
|
list: '/process/processEsInspectPlan/page',
|
||||||
|
delete: '/process/processEsInspectPlan/delete',
|
||||||
|
importExcelUrl: '/process/processEsInspectPlan/importExcel',
|
||||||
|
deleteBatch: '/process/processEsInspectPlan/deleteBatch'
|
||||||
},
|
},
|
||||||
model: {},
|
model: {},
|
||||||
dataSource: [],
|
dataSource: [],
|
||||||
@@ -168,7 +176,7 @@ export default {
|
|||||||
title: this.$t('workCenter.esInspectionPlan.departmentPersonnel'),
|
title: this.$t('workCenter.esInspectionPlan.departmentPersonnel'),
|
||||||
align: 'center',
|
align: 'center',
|
||||||
width: 120,
|
width: 120,
|
||||||
dataIndex: 'departmentPersonnel',
|
dataIndex: 'objectOfConsultation',
|
||||||
showCodeList: [EsInspectionPlan.initiate.value],
|
showCodeList: [EsInspectionPlan.initiate.value],
|
||||||
scopedSlots: { customRender: 'text' }
|
scopedSlots: { customRender: 'text' }
|
||||||
},
|
},
|
||||||
@@ -217,6 +225,12 @@ export default {
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
watch: {
|
||||||
|
// 列表查询带上项目id
|
||||||
|
projectId () {
|
||||||
|
this.filters.projectId = this.projectId
|
||||||
|
}
|
||||||
|
},
|
||||||
computed: {
|
computed: {
|
||||||
// 是否发起节点和联络人汇总节点
|
// 是否发起节点和联络人汇总节点
|
||||||
isInitiateOrLiaisonCollect () {
|
isInitiateOrLiaisonCollect () {
|
||||||
@@ -242,23 +256,6 @@ export default {
|
|||||||
getData () {
|
getData () {
|
||||||
return this.dataSource
|
return this.dataSource
|
||||||
},
|
},
|
||||||
// 表单提交
|
|
||||||
addOrEditOk (formData) {
|
|
||||||
console.log(formData)
|
|
||||||
if (formData.id) {
|
|
||||||
// 编辑
|
|
||||||
for (let i = 0; i < this.dataSource.length; i++) {
|
|
||||||
if (this.dataSource[i].id === formData.id) {
|
|
||||||
this.dataSource.splice(i, 1, formData)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
// 添加
|
|
||||||
formData.id = this.dataSource.length
|
|
||||||
this.dataSource.push(formData)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 更新表格数据
|
// 更新表格数据
|
||||||
updateData (list) {
|
updateData (list) {
|
||||||
this.dataSource = list || []
|
this.dataSource = list || []
|
||||||
|
|||||||
Reference in New Issue
Block a user