|
@@ -90,6 +90,7 @@
|
|
|
multiple
|
|
multiple
|
|
|
filterable
|
|
filterable
|
|
|
@change="executeIdListChange"
|
|
@change="executeIdListChange"
|
|
|
|
|
+ key="executeUsersIds"
|
|
|
>
|
|
>
|
|
|
<el-option
|
|
<el-option
|
|
|
v-for="item in executorList"
|
|
v-for="item in executorList"
|
|
@@ -101,29 +102,23 @@
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
</el-col>
|
|
</el-col>
|
|
|
<el-col :span="8" v-if="addForm.type">
|
|
<el-col :span="8" v-if="addForm.type">
|
|
|
- <el-form-item label="执行人" required prop="teamId">
|
|
|
|
|
- <el-select
|
|
|
|
|
- v-model="addForm.teamId"
|
|
|
|
|
- placeholder="请选择班组"
|
|
|
|
|
- filterable
|
|
|
|
|
- style="width: 120px"
|
|
|
|
|
|
|
+ <el-form-item label="班组" required prop="teamId">
|
|
|
|
|
+ <el-input
|
|
|
|
|
+ v-model="addForm.teamName"
|
|
|
|
|
+ placeholder=" "
|
|
|
disabled
|
|
disabled
|
|
|
- @change="checkTeamList(addForm.teamId)"
|
|
|
|
|
- >
|
|
|
|
|
- <el-option
|
|
|
|
|
- v-for="item in allTeamList"
|
|
|
|
|
- :label="item.name"
|
|
|
|
|
- :value="item.id"
|
|
|
|
|
- :key="item.id"
|
|
|
|
|
- >
|
|
|
|
|
- </el-option>
|
|
|
|
|
- </el-select>
|
|
|
|
|
|
|
+ ></el-input>
|
|
|
|
|
+ </el-form-item>
|
|
|
|
|
+ </el-col>
|
|
|
|
|
+ <el-col :span="8" v-if="addForm.type">
|
|
|
|
|
+ <el-form-item label="执行人" required prop="executeUsersIds">
|
|
|
<el-select
|
|
<el-select
|
|
|
v-model="addForm.executeUsersIds"
|
|
v-model="addForm.executeUsersIds"
|
|
|
placeholder="请选择执行人"
|
|
placeholder="请选择执行人"
|
|
|
filterable
|
|
filterable
|
|
|
multiple
|
|
multiple
|
|
|
@change="changeId"
|
|
@change="changeId"
|
|
|
|
|
+ style="width: 100%"
|
|
|
>
|
|
>
|
|
|
<div class="checkboxWrapper">
|
|
<div class="checkboxWrapper">
|
|
|
<el-checkbox v-model="checked" @change="checkChange">
|
|
<el-checkbox v-model="checked" @change="checkChange">
|
|
@@ -140,8 +135,8 @@
|
|
|
</el-select>
|
|
</el-select>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
</el-col>
|
|
</el-col>
|
|
|
- <el-col :span="8">
|
|
|
|
|
- <el-form-item label="场站" prop="postName">
|
|
|
|
|
|
|
+ <el-col :span="8" v-if="addForm.type">
|
|
|
|
|
+ <el-form-item label="场站" prop="productLineId">
|
|
|
<el-select
|
|
<el-select
|
|
|
v-model="addForm.productLineId"
|
|
v-model="addForm.productLineId"
|
|
|
placeholder="请选择场站"
|
|
placeholder="请选择场站"
|
|
@@ -180,31 +175,21 @@
|
|
|
/>
|
|
/>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
</el-col>
|
|
</el-col>
|
|
|
|
|
+ <el-col :span="8" v-if="pageName == 'qualityTestRecords'">
|
|
|
|
|
+ <el-form-item label="联合站检查人" required prop="contactName">
|
|
|
|
|
+ <el-input
|
|
|
|
|
+ clearable
|
|
|
|
|
+ v-model="addForm.contactName"
|
|
|
|
|
+ @click.native="handParent"
|
|
|
|
|
+ placeholder="请选择"
|
|
|
|
|
+ readonly
|
|
|
|
|
+ />
|
|
|
|
|
+ </el-form-item>
|
|
|
|
|
+ </el-col>
|
|
|
</el-row>
|
|
</el-row>
|
|
|
|
|
|
|
|
<header-title title="记录数据" :style="`margin-top: 20px`"></header-title>
|
|
<header-title title="记录数据" :style="`margin-top: 20px`"></header-title>
|
|
|
|
|
|
|
|
- <!-- <template v-if="addForm.recordTemplateStyle == '4'">
|
|
|
|
|
- <el-tabs v-model="statisticsType" type="card">
|
|
|
|
|
- <el-tab-pane
|
|
|
|
|
- v-for="i in statisticsTypeList"
|
|
|
|
|
- :label="i.label"
|
|
|
|
|
- :name="i.value"
|
|
|
|
|
- :key="i.value"
|
|
|
|
|
- >
|
|
|
|
|
- </el-tab-pane>
|
|
|
|
|
- </el-tabs>
|
|
|
|
|
- <statistics
|
|
|
|
|
- ref="statisticsRef"
|
|
|
|
|
- :details.sync="addForm.detailList"
|
|
|
|
|
- :statisticsType="statisticsType"
|
|
|
|
|
- :produceTaskId="addForm.produceTaskId"
|
|
|
|
|
- :workOrderId="addForm.workOrderId"
|
|
|
|
|
- :routingId="addForm.produceRoutingId"
|
|
|
|
|
- :ruleId="addForm.ruleId"
|
|
|
|
|
- ></statistics>
|
|
|
|
|
- </template> -->
|
|
|
|
|
-
|
|
|
|
|
<ele-pro-table
|
|
<ele-pro-table
|
|
|
v-loading="loading"
|
|
v-loading="loading"
|
|
|
ref="table"
|
|
ref="table"
|
|
@@ -493,20 +478,12 @@
|
|
|
// ]
|
|
// ]
|
|
|
},
|
|
},
|
|
|
loading: false,
|
|
loading: false,
|
|
|
- currentRow: null,
|
|
|
|
|
butLoading: false,
|
|
butLoading: false,
|
|
|
checked: false,
|
|
checked: false,
|
|
|
teamUserList: [],
|
|
teamUserList: [],
|
|
|
teamList: [],
|
|
teamList: [],
|
|
|
teamAllList: [],
|
|
teamAllList: [],
|
|
|
- workshopAreaList: [],
|
|
|
|
|
- // 1-成品统计,2-物料统计,3-工序统计"
|
|
|
|
|
- statisticsType: '1',
|
|
|
|
|
- statisticsTypeList: [
|
|
|
|
|
- { label: '成品统计', value: '1' },
|
|
|
|
|
- { label: '物料统计', value: '2' },
|
|
|
|
|
- { label: '工序统计', value: '3' }
|
|
|
|
|
- ],
|
|
|
|
|
|
|
+
|
|
|
executorList: [],
|
|
executorList: [],
|
|
|
allTeamList: [],
|
|
allTeamList: [],
|
|
|
productLineList: []
|
|
productLineList: []
|
|
@@ -662,21 +639,10 @@
|
|
|
// : '';
|
|
// : '';
|
|
|
|
|
|
|
|
if (this.addForm.executeUsers.length > 0 && !this.addForm.type) {
|
|
if (this.addForm.executeUsers.length > 0 && !this.addForm.type) {
|
|
|
- let groupIds = this.addForm.executeUsers
|
|
|
|
|
- .map((i) => i.groupId)
|
|
|
|
|
- .filter(
|
|
|
|
|
- (item, index, arr) => arr.indexOf(item) === index && item
|
|
|
|
|
- );
|
|
|
|
|
-
|
|
|
|
|
- if (groupIds.includes('1')) {
|
|
|
|
|
- this.addForm.groupId = '1';
|
|
|
|
|
- } else {
|
|
|
|
|
- this.addForm.groupId =
|
|
|
|
|
- this.addForm.executeUsers[0]?.groupId + '' || '1';
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
|
|
+ this.addForm.groupId = this.addForm.executeUsers[0]?.groupId + '';
|
|
|
|
|
+ this.addForm.groupName = this.addForm.executeUsers[0]?.groupName;
|
|
|
if (this.addForm.groupId) {
|
|
if (this.addForm.groupId) {
|
|
|
- this.searchDeptNodeClick(this.addForm.groupId);
|
|
|
|
|
|
|
+ this.searchDeptNodeClick(this.addForm.groupId, 'init');
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -755,6 +721,8 @@
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
const body = JSON.parse(JSON.stringify(this.addForm));
|
|
const body = JSON.parse(JSON.stringify(this.addForm));
|
|
|
|
|
+ console.log(body)
|
|
|
|
|
+ // return
|
|
|
|
|
|
|
|
this.butLoading = true;
|
|
this.butLoading = true;
|
|
|
|
|
|
|
@@ -856,6 +824,7 @@
|
|
|
} else {
|
|
} else {
|
|
|
this.addForm.executeUsersIds = [];
|
|
this.addForm.executeUsersIds = [];
|
|
|
}
|
|
}
|
|
|
|
|
+ this.changeId()
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
// 批量检查
|
|
// 批量检查
|
|
@@ -889,7 +858,7 @@
|
|
|
} catch (error) {}
|
|
} catch (error) {}
|
|
|
},
|
|
},
|
|
|
//选择部门(搜索)
|
|
//选择部门(搜索)
|
|
|
- async searchDeptNodeClick(groupId, data) {
|
|
|
|
|
|
|
+ async searchDeptNodeClick(groupId, type) {
|
|
|
if (groupId) {
|
|
if (groupId) {
|
|
|
// 根据部门获取人员
|
|
// 根据部门获取人员
|
|
|
const params = { groupId: groupId };
|
|
const params = { groupId: groupId };
|
|
@@ -897,6 +866,14 @@
|
|
|
} else {
|
|
} else {
|
|
|
this.addForm.groupId = null;
|
|
this.addForm.groupId = null;
|
|
|
}
|
|
}
|
|
|
|
|
+ if (type != 'init') {
|
|
|
|
|
+ this.addForm.detailList.forEach((detail) => {
|
|
|
|
|
+ detail.checkUsersIds = [];
|
|
|
|
|
+ detail.checkUsers = [];
|
|
|
|
|
+ });
|
|
|
|
|
+ this.addForm.executeUsers = [];
|
|
|
|
|
+ this.addForm.executeUsersIds = [];
|
|
|
|
|
+ }
|
|
|
},
|
|
},
|
|
|
// 负责人变更 同步执行人列表
|
|
// 负责人变更 同步执行人列表
|
|
|
executeIdListChange() {
|
|
executeIdListChange() {
|
|
@@ -913,7 +890,7 @@
|
|
|
})
|
|
})
|
|
|
.filter((i) => i);
|
|
.filter((i) => i);
|
|
|
// 同步详情执行人
|
|
// 同步详情执行人
|
|
|
- this.addForm.details.forEach((detail) => {
|
|
|
|
|
|
|
+ this.addForm.detailList.forEach((detail) => {
|
|
|
detail.checkUsersIds = this.addForm.executeUsersIds;
|
|
detail.checkUsersIds = this.addForm.executeUsersIds;
|
|
|
detail.checkUsers = this.addForm.executeUsers;
|
|
detail.checkUsers = this.addForm.executeUsers;
|
|
|
});
|
|
});
|