Procházet zdrojové kódy

产品管理详情提交

LAPTOP-16IUEB3P\Lenovo před 2 roky
rodič
revize
d35ba0d1bd

+ 4 - 4
src/views/material/product/components/link-msg.vue

@@ -26,10 +26,7 @@
 <script>
   export default {
     props: {
-      form: {
-        type: Object,
-        default: {}
-      }
+      id: [Number, String],
     },
     data () {
       return {
@@ -124,6 +121,9 @@
         ]
       };
     },
+    created(){
+      console.log('id2',this.id)
+    },
     methods: {
 
     }

+ 5 - 1
src/views/material/product/detail.vue

@@ -157,7 +157,7 @@
     <!-- 备注信息 -->
     <RemarkInfo ref="remarkRefs" :form="remarkform" />
     <!-- 关联信息 -->
-    <linkMsg ref="linkMsgRef" :form="form" />
+    <linkMsg ref="linkMsgRef" :id="id" />
   </div>
 </template>
 
@@ -180,6 +180,7 @@
   import { getDetails } from '@/api/classifyManage/itemInformation';
   import { addMaterial } from '@/api/material/manage.js';
   import { deepClone } from '@/utils/index';
+  import { finishPageTab , reloadPageTab } from '@/utils/page-tab-util';
   export default {
     name: 'ManageMaterial',
     components: {
@@ -231,6 +232,7 @@
           ]
         },
         PathInfo:{},
+        id:null
       };
     },
     created () {
@@ -238,6 +240,7 @@
     },
     methods: {
       async _getDetails () {
+        this.id = this.$route.query.id
         const data = await getDetails(this.$route.query.id);
         const info = deepClone(data)
         this.form = {
@@ -311,6 +314,7 @@
         this.$refs.categoryRefs.open(this.form.categoryLevelGroupId);
       },
       cancel () {
+        finishPageTab()
         this.$router.go(-1);
       },