From feffb4eacaa1f39c3e5c60771b7fdd800d5f964c Mon Sep 17 00:00:00 2001 From: shilixia <2309368887@qq.com> Date: Wed, 22 Dec 2021 09:46:15 +0800 Subject: [PATCH] baofei --- hb_client/src/api/wpm.js | 4 +- hb_client/src/views/wpm/need.vue | 58 +++ hb_client/src/views/wpm/operation.vue | 20 +- hb_client/src/views/wpm/worktask.vue | 581 ++++++++++++++------------ 4 files changed, 392 insertions(+), 271 deletions(-) diff --git a/hb_client/src/api/wpm.js b/hb_client/src/api/wpm.js index f3b876d..12858d8 100644 --- a/hb_client/src/api/wpm.js +++ b/hb_client/src/api/wpm.js @@ -298,11 +298,11 @@ export function testInit(data) { } //不合格半成品报废 -export function scrap(id) { +export function scrap(id,data) { return request({ url: `/wpm/wproduct/${id}/scrap/`, method: 'post', - + data }) } diff --git a/hb_client/src/views/wpm/need.vue b/hb_client/src/views/wpm/need.vue index 5d73c0f..c4af2cc 100644 --- a/hb_client/src/views/wpm/need.vue +++ b/hb_client/src/views/wpm/need.vue @@ -43,6 +43,11 @@ @click="checkRecord(scope,'1')" >检验记录 + 报废 + @@ -53,6 +58,32 @@ :limit.sync="listQuery.page_size" @pagination="getList" /> + + + + + + + + + + + + + + @@ -491,6 +522,7 @@ data() { return { testitem: defaultetestitem, + formbcp:{}, form: {remark: "", warehouse: ""}, wproductList: { count: 0, @@ -556,6 +588,12 @@ label: "不合格", }, ], + scrapreason: [ + { lable: "气泡", value: 10 }, + { lable: "破点", value: 20 }, + { lable: "划伤", value: 30 }, + { lable: "其他", value: 40 }, + ], recordList: [], options: [], listLoading: true, @@ -571,6 +609,7 @@ page: 0, }, recordVisible:false, + dialogFormVisiblebcp:false, innerIndex:null, origintest:null, mutipID: [], @@ -612,6 +651,25 @@ this.listLoading = false; }); }, + //待检半成品报废 + handleScrapbcp(scope){ + this.dialogFormVisiblebcp=true; + this.bcpbf=scope.row.id; + + }, + //确定报废半成品 + scrapesubmit(){ + + console.log(this.formbcp); + scrap(this.bcpbf,this.formbcp).then((response) => { + if (response.data) { + this.$message.success("该半成品已报废!"); + this.dialogFormVisiblebcp=false; + this.getList(); + } + + }); + }, //复检半成品列表 getList2() { this.listQuery2.act_state = 6; diff --git a/hb_client/src/views/wpm/operation.vue b/hb_client/src/views/wpm/operation.vue index b627aff..684e367 100644 --- a/hb_client/src/views/wpm/operation.vue +++ b/hb_client/src/views/wpm/operation.vue @@ -128,7 +128,7 @@ export default { watch: {}, created() { this.id = this.$route.params.id; - this. getProcessList() + this.getProcessList() }, methods: { @@ -147,19 +147,23 @@ handleoperation(scope) }); }, +getList(){ + getoperationList(this.listQuery).then((response) => { + if (response.data) { + this.operationList = response.data; + } + + }); +}, //选项卡切换 handleClick(tab) { this.process = tab.name; this.listQuery.step__process = tab.name; - this.steps = []; - getoperationList(this.listQuery).then((response) => { - if (response.data) { - this.operationList = response.data; - } - this.listLoading = false; - }); + this.getList(); + }, + //操作记录删除 handleDelete(scope) { this.$confirm("确认该操作删除?", "警告", { diff --git a/hb_client/src/views/wpm/worktask.vue b/hb_client/src/views/wpm/worktask.vue index 22ed361..d6438a9 100644 --- a/hb_client/src/views/wpm/worktask.vue +++ b/hb_client/src/views/wpm/worktask.vue @@ -18,20 +18,22 @@ @current-change="handleCurrentChange" > - - + + + + + - - - - - - - - - + @@ -90,13 +88,19 @@ @@ -111,12 +115,11 @@ /> -
半成品
- 显示全部 + + - - + + @@ -162,12 +175,11 @@ scope.row.step_.name }} - + - + + +
+
@@ -191,7 +207,7 @@ max-height="300" > - + @@ -218,48 +234,74 @@
- - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - > - - - - - - - - - + - + - + - - + - - - + + + - + - - - - - + + - - +
生产所需领料表