Procházet zdrojové kódy

产品新增判断产品编号是否存在

Danj0rr před 11 měsíci
rodič
revize
38d97ed2d4
2 změnil soubory, kde provedl 9 přidání a 3 odebrání
  1. 0 1
      src/api/index.js
  2. 9 2
      src/views/system/cooperatorProductApply.vue

+ 0 - 1
src/api/index.js

@@ -202,7 +202,6 @@ export function modelDefineList(){
     return request.get('/model_define/modelDefineList');
 }
 
-
 export function cooperatorProductApply(cooperator_num, cooperator_name,  product_num, product_name, model_id,fieldSelected) {
     return request.post('/cooperator_product/apply', {
         cooperator_num : cooperator_num,

+ 9 - 2
src/views/system/cooperatorProductApply.vue

@@ -158,7 +158,7 @@ import {
     findCooperatorProductFieldByNum,
     cooperatorProductApply,
     findCooperatorFieldsByName,
-    cooperatorList
+    cooperatorList,
 } from '@/api/index.js'
 import store from "@/store";
 import request from '@/utils/request.js'
@@ -410,7 +410,14 @@ export default {
             this.selected6 = true;
         },
         paneNext1() {
-            this.activeName2 = "second"
+            request.post('/cooperator_product/checkDupProdNum', {
+                product_num: this.cooperator_product_no
+            }).then(
+                res => {
+                    this.activeName2 = "second"
+                },
+            )
+
         },
         paneNext2() {
             this.activeName2 = "third"