ysy 1 年之前
父節點
當前提交
c324522e07
共有 2 個文件被更改,包括 15 次插入14 次删除
  1. 2 2
      src/views/material/BOMmanage/components/standardOutput.vue
  2. 13 12
      src/views/material/BOMmanage/details.vue

+ 2 - 2
src/views/material/BOMmanage/components/standardOutput.vue

@@ -54,7 +54,7 @@
   import ProductSearch from '@/components/select/bom/product-search.vue';
   import { getMaterialList } from '@/api/material/list.js';
 
-  import { getTreeByPid } from '@/api/classifyManage';
+  import { getTreeByGroup } from '@/api/classifyManage';
   export default {
     components: { ProductSearch },
     data() {
@@ -202,7 +202,7 @@
         try {
           this.treeLoading = true;
 
-          const res = await getTreeByPid(this.type);
+          const res = await  getTreeByGroup({ type: 1 });
           this.treeLoading = false;
           if (res?.code === '0') {
             this.treeList = res.data;

+ 13 - 12
src/views/material/BOMmanage/details.vue

@@ -21,24 +21,20 @@
               v-model="currentNodeData.bomType"
               @change="bomChange"
             >
-              <el-radio-button :label="1"
-                >PBOM </el-radio-button
-              >
+              <el-radio-button :label="1">PBOM </el-radio-button>
               <el-radio-button
-              v-if="[1, 9].includes(rootPathIdParent)"
+                v-if="[1, 9].includes(rootPathIdParent)"
                 :label="2"
                 >MBOM</el-radio-button
               >
               <el-radio-button
-              v-if="[1, 9].includes(rootPathIdParent)"
+                v-if="[1, 9].includes(rootPathIdParent)"
                 :label="3"
                 >ABOM</el-radio-button
               >
             </el-radio-group>
           </div>
 
-
-
           <el-input
             size="small"
             placeholder="在结构中查找"
@@ -156,7 +152,10 @@
               <el-tab-pane
                 label="工艺路线"
                 name="工艺路线"
-                v-if="[1, 9].includes(rootPathIdParent) && currentNodeData.bomType != 1"
+                v-if="
+                  [1, 9].includes(rootPathIdParent) &&
+                  currentNodeData.bomType != 1
+                "
               >
                 <routing
                   ref="routingRef"
@@ -166,7 +165,10 @@
               <el-tab-pane
                 label="工序配置"
                 name="工序配置"
-                 v-if="[1, 9].includes(rootPathIdParent) && currentNodeData.bomType != 1"
+                v-if="
+                  [1, 9].includes(rootPathIdParent) &&
+                  currentNodeData.bomType != 1
+                "
               >
                 <workmanship
                   ref="workmanshipRef"
@@ -251,7 +253,7 @@
       '$route.query': {
         immediate: true, // 启用立即执行
         handler(newQuery, oldQuery) {
-          this.rootPathIdParent = Number(newQuery.categoryLevelPathIdParent)
+          this.rootPathIdParent = Number(newQuery.categoryLevelPathIdParent);
         }
       }
     },
@@ -277,7 +279,6 @@
         this.categoryId = this.$route.query.categoryId;
         this.noBack = this.$route.query.noBack;
 
-
         (this.currentNodeData = {
           bomType: this.$route.query.bType || 1,
           children: []
@@ -393,7 +394,7 @@
       handBomDetails(id) {
         if (id) {
           getBomGetById(id).then((res) => {
-            this.versions = res.data.versions;
+            // this.versions = res.data.versions;
             this.currentNodeData = res.data;
 
             if (