From 3bbf405ec1083b792d817bbd4c755bc3aa3abf14 Mon Sep 17 00:00:00 2001
From: yangfeng <wanwan926_4@163.com>
Date: 星期五, 01 十二月 2023 11:54:21 +0800
Subject: [PATCH] 左上统计组件
---
src/components/bomDialog.vue | 43 +++++++++++++++----------------------------
1 files changed, 15 insertions(+), 28 deletions(-)
diff --git a/src/components/bomDialog.vue b/src/components/bomDialog.vue
index 64afbd2..a7804d1 100644
--- a/src/components/bomDialog.vue
+++ b/src/components/bomDialog.vue
@@ -58,9 +58,16 @@
</template>
<script>
-import { addMaterial, updateMaterial } from "@/api/ProductiveTask/inventory";
-import { getCodeStandardList } from "@/api/basic/standard";
+import { getCodeStandardList } from "@/api/basic/standard";
+import {
+ NetworkCard,
+ getMiniDictList,
+ addMiniDict,
+ deleteMiniDict,
+ updateMiniDict,
+ sendProcessParams
+} from "@/api/home/index";
export default {
name: "",
props: {
@@ -131,11 +138,13 @@
watch: {
editDialogVisible(newVal){
if(newVal){
- this.BomTableData=this.workList;
+ this.BomTableData= JSON.parse(
+ JSON.stringify(this.workList))
}
},
workList(newVal){
- this.BomTableData=this.workList;
+ this.BomTableData=JSON.parse(
+ JSON.stringify(this.workList))
}
},
mounted() {
@@ -145,6 +154,7 @@
this.BomTableData.push({name:'',isDefault:false});
},
handleDelete(id) {
+
this.BomTableData=this.BomTableData.filter(i=>{
return i.id!=id
})
@@ -203,30 +213,7 @@
this.$emit('handleConfirmSave',this.BomTableData)
}
},
- async validate() {
- try {
- if (this.flag == "add")
- this.form.id = this.codenumberList.replace(/,/g, "");
- this.form.explain = this.explain;
- let fn = this.flag == "set" ? updateMaterial : addMaterial;
- const res = await fn(this.form);
- this.shutdown();
- this.$sucessSet('sucessSet')
- if(res.code==200){
- this.$message({
- message: this.flag == "set"?'淇敼鎴愬姛锛�':'娣诲姞鎴愬姛锛�',
- type: "success",
- });
- }
-
- } catch (err) {
- console.log(err);
- this.$message({
- message: err.message.data.data,
- type: "warning",
- });
- }
- },
+
shutdown() {
this.editDialogVisible = false;
--
Gitblit v1.8.0