Browse Source

Merge branch 'master' of http://121.41.102.225:8099/Nidong/jiufang

Ni Dong 3 years ago
parent
commit
038fee0f30

+ 5 - 4
src/views/BasicSettings/SuppliersManage/SippliersStockPriceList.vue

@@ -171,8 +171,8 @@ export default {
           break;
           break;
         case 2:
         case 2:
           this.$Modal.confirm({
           this.$Modal.confirm({
-            title: '确认审核?',
-            content: '此操作将审核订单,请确认!',
+            title: row.state == 0 ?'确认审核?':'确认弃审?',
+            content: row.state == 0 ?'此操作将审核订单,请确认!':'此操作将弃审订单,请确认!',
             onOk: () => {
             onOk: () => {
               this.axios({
               this.axios({
                 method: 'post',
                 method: 'post',
@@ -192,7 +192,7 @@ export default {
         case 3:
         case 3:
         case 4:
         case 4:
         case 5:
         case 5:
-          this.handleGoPage(type, row.supply_id)
+          this.handleGoPage(type, row.supply_id,row.state)
           break;
           break;
         case 6:
         case 6:
           break;
           break;
@@ -217,12 +217,13 @@ export default {
           break;
           break;
       }
       }
     },
     },
-    handleGoPage (type, supply_id) {
+    handleGoPage (type, supply_id,state) {
       this.$router.push({
       this.$router.push({
         path: '/cms/BasicSettings/SuppliersManage/SippliersStockPriceListEdit',
         path: '/cms/BasicSettings/SuppliersManage/SippliersStockPriceListEdit',
         query: {
         query: {
           type,
           type,
           supply_id,
           supply_id,
+          state,
         }
         }
       })
       })
     },
     },

+ 6 - 4
src/views/BasicSettings/SuppliersManage/SippliersStockPriceListEdit.vue

@@ -257,30 +257,32 @@ export default {
       }).catch((err) => { });
       }).catch((err) => { });
     },
     },
     initData () {
     initData () {
+
       this.axios({
       this.axios({
         method: 'get',
         method: 'get',
         url: '/api/supply_material_detail',
         url: '/api/supply_material_detail',
         params: {
         params: {
           supply_id: this.$route.query.supply_id
           supply_id: this.$route.query.supply_id
         }
         }
-      }).then((res) => {
+      }).then((res) => {  
         this.searchData.code = res.data.code
         this.searchData.code = res.data.code
         this.searchData.title = res.data.title
         this.searchData.title = res.data.title
         this.tableData = res.data.list
         this.tableData = res.data.list
         this.tableData.forEach(element => {
         this.tableData.forEach(element => {
           element.tax_price = (1 * element.price * (1 + element.fax * 1 / 100)).toFixed(2)
           element.tax_price = (1 * element.price * (1 + element.fax * 1 / 100)).toFixed(2)
         });
         });
-      }).catch((err) => { });
+      }).catch((err) => { }); 
     },
     },
     handleSet (type, row, index) {
     handleSet (type, row, index) {
       switch (type) {
       switch (type) {
         case 1:
         case 1:
           this.axios({
           this.axios({
             method: 'post',
             method: 'post',
-            url: '/api/supply_material_add',
+            url: '/api/supply_material_edit',
             data: {
             data: {
               supply_id: this.$route.query.supply_id ? this.$route.query.supply_id : this.searchData.id,
               supply_id: this.$route.query.supply_id ? this.$route.query.supply_id : this.searchData.id,
-              supply_material: this.tableData
+              supply_material: this.tableData,
+              state: this.$route.query.state
             }
             }
           }).then((res) => {
           }).then((res) => {
             this.$Message.success(res.msg);
             this.$Message.success(res.msg);