瀏覽代碼

修改销售订单配置数据

caojunjie 3 年之前
父節點
當前提交
f7155b6f1e

+ 13 - 0
src/api/basicData/configuration.js

@@ -84,6 +84,19 @@ export function getDeptLazyTree(parentId){
     })
 }
 
+export const getList = (current, size, params, goodsTypeId) => {
+    return request({
+        url: '/api//blade-client/goodsdesc/selectGoods',
+        method: 'get',
+        params: {
+            ...params,
+            current,
+            size,
+            goodsTypeId,
+        }
+    })
+}
+
 //查询客户类型下拉
 export function corpstypeTree() {
     return request({

+ 1 - 1
src/views/basicData/customerInformation/index.vue

@@ -4,7 +4,7 @@
       <div class="box">
         <el-scrollbar>
           <basic-container>
-            <avue-tree :option="treeOption" :data="treeData" @node-click="nodeClick"/>
+            <avue-tree :option="treeOption" :data="treeData" @node-click=""/>
           </basic-container>
         </el-scrollbar>
       </div>

+ 1 - 0
src/views/businessManagement/salesOrder/configuration/advantageProject.json

@@ -13,6 +13,7 @@
   "tree": true,
   "border": true,
   "index": true,
+  "refreshBtn": false,
   "selection": true,
   "menuWidth": 300,
   "dialogClickModal": false,

+ 1 - 0
src/views/businessManagement/salesOrder/configuration/bankOfDeposit.json

@@ -6,6 +6,7 @@
   "searchMenuSpan": 6,
   "dialogWidth": "60%",
   "tree": true,
+  "refreshBtn": false,
   "border": true,
   "index": true,
   "selection": true,

+ 0 - 1
src/views/businessManagement/salesOrder/configuration/commodity.json

@@ -6,7 +6,6 @@
   "addBtn": false,
   "searchShow": false,
   "searchShowBtn": false,
-  "refreshBtn": false,
   "menu": false,
   "searchMenuSpan": 6,
   "border": true,

+ 1 - 0
src/views/businessManagement/salesOrder/configuration/customerContact.json

@@ -8,6 +8,7 @@
   "addRowBtn":true,
   "cellBtn":false,
   "cancelBtn":false,
+  "refreshBtn": false,
   "searchMenuSpan": 6,
   "dialogWidth": "60%",
   "tree": true,

+ 17 - 9
src/views/businessManagement/salesOrder/detailsPageEdit.vue

@@ -127,6 +127,7 @@
                        :table-loading="loading"
                        :data="data"
                        ref="crud"
+                       @refresh-change="refreshChange"
                        @selection-change="selectionChange"
                        :page.sync="page"
                        @on-load="onLoad"></avue-crud>
@@ -147,18 +148,20 @@ import {customerList, typeSave, detail, deleteDetails,
   corpsattn,
   corpsbank,
   corpsfiles,
-  corpsitem} from "@/api/basicData/configuration"
+  corpsitem,
+  getList} from "@/api/basicData/configuration"
 import customerContact from "./configuration/customerContact.json"
 import advantageProject from "./configuration/advantageProject.json"
 import bankOfDeposit from "./configuration/bankOfDeposit.json"
 import commodity from "./configuration/commodity.json"
-import {getDeptLazyTree, getList} from "@/api/basicData/commodityType";
+import {getDeptLazyTree} from "@/api/basicData/commodityType";
 export default {
   name: "detailsPage",
   data() {
     return {
       form: {},
       data:[],
+      treeDeptId:'',
       page:{
         pageSize: 10,
         currentPage: 1,
@@ -627,13 +630,17 @@ export default {
     selectionChange(list){
       console.log(list);
       this.tableData = list
-      if (list.length > 1){
-        this.$message({
-          showClose: true,
-          message: '警告,只允许导入一条',
-          type: 'warning'
-        });
-      }
+    },
+    nodeClick(data) {
+      this.treeDeptId = data.id;
+      this.page.currentPage = 1;
+      this.onLoad(this.page);
+    },
+    //刷新触发
+    refreshChange() {
+      this.treeDeptId = '';
+      this.page.currentPage = 1;
+      this.onLoad(this.page);
     },
     //新增商品信息保存触发
     rowSave(row, done, loading){
@@ -684,6 +691,7 @@ export default {
     onLoad(page, params = {}) {
       this.loading = true;
       getList(page.currentPage, page.pageSize, Object.assign(params, this.query), this.treeDeptId).then(res => {
+        console.log(res)
         const data = res.data.data;
         this.page.total = data.total;
         this.data = data.records;