fix:成品检验详情列表
This commit is contained in:
parent
eba2759470
commit
4cbf1c4c9f
|
@ -317,7 +317,7 @@ export default {
|
|||
},
|
||||
apiObj: null,
|
||||
params: {},
|
||||
formTableData: null,
|
||||
formTableData: [],
|
||||
ftestWork: "",
|
||||
type: "",
|
||||
userList: [],
|
||||
|
@ -338,8 +338,7 @@ export default {
|
|||
that.$API.qm.ftestwork.item.req(that.ftestWork).then((res) => {
|
||||
that.workObj = res;
|
||||
that.addTemplate.test_date = res.test_date;
|
||||
that.addTemplate.test_numer = res.batch + "_1";
|
||||
that.getCheckList();
|
||||
that.getCheckList(that.ftestWork);
|
||||
});
|
||||
let tag = that.type == "bang" ? "prod_bang" : "prod_guan";
|
||||
that.getTestItem(tag, that.ftestWork);
|
||||
|
@ -407,15 +406,16 @@ export default {
|
|||
},
|
||||
//删除
|
||||
delCheck(id) {
|
||||
this.$confirm(`确定删除吗?`, "提示", {
|
||||
let that = this;
|
||||
that.$confirm(`确定删除吗?`, "提示", {
|
||||
type: "warning",
|
||||
})
|
||||
.then(() => {
|
||||
this.$API.qm.ftest.delete
|
||||
that.$API.qm.ftest.delete
|
||||
.req(id)
|
||||
.then((res) => {
|
||||
this.$message.success("删除成功");
|
||||
this.$refs.table.refresh();
|
||||
that.$message.success("删除成功");
|
||||
that.getCheckList(that.ftestWork);
|
||||
return res;
|
||||
})
|
||||
.catch((err) => {
|
||||
|
@ -425,29 +425,29 @@ export default {
|
|||
.catch(() => {});
|
||||
},
|
||||
saveCheck(row) {
|
||||
let that = this;
|
||||
console.log(row);
|
||||
let index = this.formTableData.findIndex(
|
||||
(item) => item.id == row.id
|
||||
);
|
||||
|
||||
if (row.id && row.id !== "") {
|
||||
this.$API.qm.ftest.update
|
||||
that.$API.qm.ftest.update
|
||||
.req(row.id, row)
|
||||
.then((res) => {
|
||||
this.formTableData[index].isEdit = false;
|
||||
this.$message.success("操作成功");
|
||||
this.$refs.formTable.refresh();
|
||||
that.formTableData[index].isEdit = false;
|
||||
that.$message.success("操作成功");
|
||||
})
|
||||
.catch((err) => {
|
||||
return err;
|
||||
});
|
||||
} else {
|
||||
this.$API.qm.ftest.create
|
||||
that.$API.qm.ftest.create
|
||||
.req(row)
|
||||
.then((res) => {
|
||||
this.formTableData[index].isEdit = false;
|
||||
this.$message.success("操作成功");
|
||||
this.$refs.formTable.refresh();
|
||||
that.formTableData[index].isEdit = false;
|
||||
that.$message.success("操作成功");
|
||||
that.getCheckList(that.ftestWork);
|
||||
})
|
||||
.catch((err) => {
|
||||
return err;
|
||||
|
|
Loading…
Reference in New Issue