质量目标优化,人员线体优化

master
shaoyong 8 months ago
parent 02088b141c
commit 743aa13aa3

@ -84,17 +84,18 @@
</el-form>
<el-tabs type="border-card" v-if="form.userCodes != null">
<el-tab-pane label="关联物料">
<UserBind v-if="form.userCodes != null"
:optType="optType"
<UserBind ref="userBind"
v-if="form.userCodes != null"
:userCodes="form.userCodes"
:userNames="form.userNames"
:handleCode="handleCode"
>
</UserBind>
</el-tab-pane>
</el-tabs>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
<!-- <el-button @click="cancel"> </el-button> -->
</div>
</el-dialog>
</div>
@ -113,12 +114,14 @@ export default {
loading: true,
//
ids: [],
names: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
handleCode: '',
//
total: 0,
//
@ -210,32 +213,33 @@ export default {
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.userCode)
this.names = selection.map(item => item.userName)
this.handleCode = names.toString();
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加人员物料绑定";
this.title = "添加人员线体绑定";
},
/** 绑定按钮操作 */
handleUpdate(row) {
this.reset();
const userCodes = row.userCode || this.ids;
const userNames = row.userName;
const userNames = row.userName || this.names;
this.form.userCodes = userCodes;
this.form.userNames = userNames;
this.open = true;
this.title = "修改人员物料绑定";
this.optType = "edit";
// getMaterial(userCode).then(response => {
// });
this.title = "修改人员线体绑定";
},
/** 提交按钮 */
submitForm() {
this.open = false;
this.$refs.userBind.liftList = [];
this.$refs.userBind.rightList = [];
this.getList();
/* this.$refs["form"].validate(valid => {
if (valid) {
@ -258,7 +262,7 @@ export default {
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.userCode || this.ids;
this.$modal.confirm('是否确认删除人员物料绑定编号为"' + ids + '"的数据项?').then(function() {
this.$modal.confirm('是否确认删除人员线体绑定编号为"' + ids + '"的数据项?').then(function() {
return delMaterial(ids);
}).then(() => {
this.getList();

@ -1,5 +1,5 @@
<template>
<div>
<div v-loading.lock="loading">
<div class="query">
<el-input
style="width: 351px; margin-bottom: 10px"
@ -108,7 +108,7 @@
import { getListProduct,getRightList ,addProduct} from "@/api/quality/userbind";
export default {
name: "Routeprodproduct",
name: "userBind",
data() {
return {
@ -136,8 +136,8 @@ export default {
queryParams: {
pageNum: 1,
pageSize: 10,
userCode: this.userCodes,
userName: this.userNames,
userCodes: this.userCodes,
userNames: this.userNames,
itemId: null,
itemCode: null,
materialName: null,
@ -187,14 +187,31 @@ export default {
};
},
props: {
userCodes: undefined,
userNames: undefined,
optType: undefined,
userCodes: {
type: [Array],
required: true
},
userNames: {
type: [Array],
required: true
},
handleCode: {
type: [String],
required: true
}
},
created() {
this.getList();
this.getRightListFun();
},
watch: {
handleCode(newVal,oldVal) {
if(newVal !== oldVal) {
this.getList();
this.getRightListFun();
}
}
},
methods: {
// // 穿
// filterMethod(keyword, row) {
@ -293,7 +310,7 @@ export default {
/** 提交按钮 */
handleChange(value, direction, movedKeys) {
if (this.queryParams.userCode != null) {
if (this.queryParams.userCodes != null) {
this.queryParams.selectedValues = value;
addProduct(this.queryParams).then((response) => {
this.$modal.msgSuccess("关联成功");

@ -201,7 +201,6 @@ export default {
},
watch: {
belongGoalId(newVal,oldVal) {
console.log(newVal);
if(newVal !== oldVal) {
this.getList();
this.getRightListFun();

@ -321,7 +321,7 @@ export default {
showSearch: true,
//
total: 0,
//
//
qcGoalList: [],
checkTypeList: [],
checkTypes: [],
@ -446,7 +446,7 @@ export default {
handleAdd() {
this.reset();
this.open = true;
this.title = "添加检验方案维护";
this.title = "添加质量目标";
//
this.form.goalType="yyyy"
},
@ -457,7 +457,7 @@ export default {
getQcGoal(id).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改检验方案维护";
this.title = "修改质量目标";
this.handleCheckTypeList(this.form.typeCode);
});
},

Loading…
Cancel
Save