diff --git a/src/components/selection/WorkGroupSelection.vue b/src/components/selection/WorkGroupSelection.vue
index 8fc67ed4..045682e6 100644
--- a/src/components/selection/WorkGroupSelection.vue
+++ b/src/components/selection/WorkGroupSelection.vue
@@ -2,7 +2,7 @@
+ :disabled="disabledInput" :placeholder="placeholder">
@@ -62,10 +62,10 @@ export default {
default: true,
required: false
},
- // 自定义返回字段,默认返回 id
+ // 自定义返回字段,默认返回 name
customReturnField: {
type: String,
- default: ''
+ default: 'name'
},
backDepart: {
type: Boolean,
@@ -156,9 +156,6 @@ export default {
this.$emit('change', this.storeVals)
this.backDepartInfo()
},
- getDepartNames () {
- return this.departNames
- },
handleEmpty () {
this.handleOK('')
},
diff --git a/src/components/selection/WorkGroupSelectionModal.vue b/src/components/selection/WorkGroupSelectionModal.vue
index 8c8650ab..01212ec7 100644
--- a/src/components/selection/WorkGroupSelectionModal.vue
+++ b/src/components/selection/WorkGroupSelectionModal.vue
@@ -280,7 +280,7 @@ export default {
if (item.id === key) {
return item
}
- if (item.children instanceof Array) {
+ if (Array.isArray(item.children)) {
const value = forChildren(item.children, key)
if (value != null) {
return value
diff --git a/src/views/workCenter/enterpriseStandardInspectionPlan/EnterpriseStandardInspectionPlanFlow.vue b/src/views/workCenter/enterpriseStandardInspectionPlan/EnterpriseStandardInspectionPlanFlow.vue
index b9c6790d..a282ffec 100644
--- a/src/views/workCenter/enterpriseStandardInspectionPlan/EnterpriseStandardInspectionPlanFlow.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionPlan/EnterpriseStandardInspectionPlanFlow.vue
@@ -231,16 +231,25 @@ export default {
this.loadPage({ projectId, taskId })
return
}
- // 否则就是创建一个新的流程
- getInspectPlanProjectId().then(res => {
- if (res) {
- this.projectId = res + ''
- this.currentNode = EsInspectionPlan.initiate.value
- this.btn = EsInspectionPlan.initiate.btn
- }
- })
+ this.getProjectId()
},
methods: {
+ /**
+ * 获取项目id
+ */
+ getProjectId () {
+ this.loading = true
+ // 否则就是创建一个新的流程
+ getInspectPlanProjectId().then(res => {
+ if (res) {
+ this.projectId = res + ''
+ this.currentNode = EsInspectionPlan.initiate.value
+ this.btn = EsInspectionPlan.initiate.btn
+ }
+ }).finally(() => {
+ this.loading = false
+ })
+ },
/**
* 获取页面详情
*/
@@ -295,7 +304,7 @@ export default {
personnelObj = this.$refs.personnelInfo.getDataObjVerify()
// List拆成数组
for (const key in personnelObj) {
- if (key.includes('List')) {
+ if (personnelObj[key] && key.includes('List')) {
personnelObj[key] = personnelObj[key].split(',')
}
}
@@ -332,7 +341,7 @@ export default {
personnelObj = this.$refs.personnelInfo.getDataObj()
// List拆成数组
for (const key in personnelObj) {
- if (key.includes('List')) {
+ if (personnelObj[key] && key.includes('List')) {
personnelObj[key] = personnelObj[key].split(',')
}
}
diff --git a/src/views/workCenter/enterpriseStandardInspectionPlan/modules/InspectionPlanDrawer.vue b/src/views/workCenter/enterpriseStandardInspectionPlan/modules/InspectionPlanDrawer.vue
index f15ded22..1d1803a4 100644
--- a/src/views/workCenter/enterpriseStandardInspectionPlan/modules/InspectionPlanDrawer.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionPlan/modules/InspectionPlanDrawer.vue
@@ -64,19 +64,19 @@
diff --git a/src/views/workCenter/enterpriseStandardInspectionPlan/modules/InspectionPlanTable.vue b/src/views/workCenter/enterpriseStandardInspectionPlan/modules/InspectionPlanTable.vue
index 4a7e321e..f242f632 100644
--- a/src/views/workCenter/enterpriseStandardInspectionPlan/modules/InspectionPlanTable.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionPlan/modules/InspectionPlanTable.vue
@@ -141,7 +141,7 @@ export default {
title: this.$t('workCenter.esInspectionPlan.mainDutyStandardizationGroup'),
align: 'center',
width: 150,
- dataIndex: 'standardizationWorkGroup_dictText',
+ dataIndex: 'standardizationWorkGroup',
scopedSlots: { customRender: 'text' }
},
{ // 所属部门
@@ -162,21 +162,21 @@ export default {
title: this.$t('workCenter.esInspectionPlan.inspectionDirector'),
align: 'center',
width: 120,
- dataIndex: 'inspectUser_dictText',
+ dataIndex: 'inspectUserDictText',
scopedSlots: { customRender: 'text' }
},
{ // 标准化组对接人
title: this.$t('workCenter.esInspectionPlan.standardizationGroupContactPerson'),
align: 'center',
width: 140,
- dataIndex: 'standardizationDockingUser_dictText',
+ dataIndex: 'standardizationDockingUserDictText',
scopedSlots: { customRender: 'text' }
},
{ // 所属部门人员
title: this.$t('workCenter.esInspectionPlan.departmentPersonnel'),
align: 'center',
width: 120,
- dataIndex: 'objectOfConsultation',
+ dataIndex: 'objectOfConsultationDictText',
showCodeList: [EsInspectionPlan.initiate.value],
scopedSlots: { customRender: 'text' }
},
@@ -184,7 +184,7 @@ export default {
title: this.$t('workCenter.esInspectionPlan.creator'),
align: 'center',
width: 120,
- dataIndex: 'createBy',
+ dataIndex: 'createByDictText',
showCodeList: [EsInspectionPlan.fillInComments.value],
scopedSlots: { customRender: 'text' }
},
@@ -229,7 +229,10 @@ export default {
// 列表查询带上项目id
projectId: {
immediate: true,
- handler () {
+ handler (val) {
+ if (!val) {
+ return
+ }
this.filters.projectId = this.projectId
if (this.currentNode === EsInspectionPlan.fillInComments.value) {
this.filters.nodeId = this.$route.query.nodeId
diff --git a/src/views/workCenter/enterpriseStandardInspectionPlan/modules/WriteOpinionModal.vue b/src/views/workCenter/enterpriseStandardInspectionPlan/modules/WriteOpinionModal.vue
index 8cfaea58..bc21d214 100644
--- a/src/views/workCenter/enterpriseStandardInspectionPlan/modules/WriteOpinionModal.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionPlan/modules/WriteOpinionModal.vue
@@ -125,6 +125,10 @@ export default {
},
// 确定
handleOk () {
+ if (this.disabled) {
+ this.close()
+ return
+ }
const that = this
// 触发表单验证
this.$refs.form.validate(valid => {
@@ -155,6 +159,7 @@ export default {
},
close () {
this.$emit('close')
+ this.dataSource = []
this.$refs.form.resetFields()
this.visible = false
},