Преглед на файлове

Merge branch 'dev' of http://git.echepei.com/caojunjie/Smart_platform_ui into dev

qukaidi преди 3 години
родител
ревизия
88e935523a

+ 4 - 1
src/api/landTransportation/index.js

@@ -256,7 +256,10 @@ export function getSalesman(data) {
     return request({
         url: '/api/blade-user/userList',
         method: 'get',
-        params:data
+        params:{
+            roleAlias:'业务员',
+            ...data
+        }
     })
 }
 //批量提交调度

+ 30 - 0
src/router/views/index.js

@@ -1140,6 +1140,36 @@ export default [{
       component: () => import( /* webpackChunkName: "views" */ '@/views/dealer/purchase/index')
     }]
   },
+  //司机
+  {
+    path: '/basicData/landTransportation/driverInformation/index',
+    component: Layout,
+    hidden: true,
+    children: [{
+      path: '/basicData/landTransportation/driverInformation/index',
+      name: '司机',
+      meta: {
+        i18n: '/basicData/landTransportation/driverInformation/index',
+        keepAlive: true,
+      },
+      component: () => import( /* webpackChunkName: "views" */ '@/views/basicData/landTransportation/driverInformation/index')
+    }]
+  },
+  //车辆
+  {
+    path: '/basicData/landTransportation/vehicleInformation/index',
+    component: Layout,
+    hidden: true,
+    children: [{
+      path: '/basicData/landTransportation/vehicleInformation/index',
+      name: '车辆',
+      meta: {
+        i18n: '/basicData/landTransportation/driverInformation/index',
+        keepAlive: true,
+      },
+      component: () => import( /* webpackChunkName: "views" */ '@/views/basicData/landTransportation/vehicleInformation/index')
+    }]
+  },
   //陆运委托
   {
     path: '/landTransportation/placeAnOrder/index',

+ 10 - 2
src/views/basicData/landTransportation/driverInformation/index.vue

@@ -47,7 +47,7 @@
         <crop-select corpType="CD" v-model="form.fleetId"/>
       </template>
       <template slot-scope="scope" slot="fleetIdSearch">
-        <crop-select corpType="CD" v-model="form.fleetId"/>
+        <crop-select corpType="CD" v-model="scope.row.fleetId"/>
       </template>
       <template slot-scope="scope" slot="fleetId">
         <span>{{scope.row.fleetName}}</span>
@@ -240,6 +240,13 @@ export default {
           cell: true,
           overHidden: true,
           search:true,
+          type: 'select',
+          filterable:true,
+          dicUrl: "/api/blade-client/land-driver/driver-list?vehicleId={{key}}",
+          props: {
+            label: "name",
+            value: "name"
+          },
         },{
           label: '身份证号',
           prop: 'idCard',
@@ -550,7 +557,7 @@ export default {
       let queryParams = {
         size: page.pageSize,
         current: page.currentPage,
-        ...params
+        ...this.query
       }
       this.loading = true;
       selectInvoiceList(queryParams).then(res => {
@@ -579,6 +586,7 @@ export default {
       delete data.driveExpire
       delete data.qualifiedExpire
       delete data.escortExpire
+      this.query = data
       this.onLoad(this.page,data)
       done();
     },

+ 4 - 1
src/views/basicData/landTransportation/vehicleInformation/index.vue

@@ -164,6 +164,7 @@ export default {
           span: 8,
           searchSpan: 8,
           type: 'select',
+          filterable:true,
           dicUrl: "/api/blade-client/land-driver/driver-list?vehicleId={{key}}",
           props: {
             label: "name",
@@ -501,6 +502,7 @@ export default {
         total: 0,
         pageSizes: [10, 50, 100, 200, 300]
       },
+      query:{},
       search: {},
       loading: false,
       action: "/api/blade-resource/oss/endpoint/put-file",
@@ -554,7 +556,7 @@ export default {
       this.$refs.crud.getTableHeight()
     },
     onLoad(page, params) {
-      const queryParams = Object.assign({}, params, {
+      const queryParams = Object.assign({}, this.query, {
         size: page.pageSize,
         current: page.currentPage,
       })
@@ -633,6 +635,7 @@ export default {
       delete data.scrapDate
       delete data.inspectExpired
       delete data.insuranceExpired
+      this.query = data
       this.onLoad(this.page, data);
       done()
     },

+ 39 - 25
src/views/businessManagement/purchaseOrder/configuration/mainList.json

@@ -198,34 +198,24 @@
       "pickerOptions": {}
     },
     {
-      "type": "select",
-      "dicData": [{
-          "name": "已收款",
-          "id": "0"
-        },
-        {
-          "name": "未收款",
-          "id": "1"
-        }
-      ],
-      "props": {
-        "label": "name",
-        "value": "id"
-      },
-      "label": "收款状态",
-      "prop": "gathering",
-      "search": true,
+      "label": "应付金额",
+      "prop": "debitAmount",
       "index": 17,
       "width": 100,
-      "showColumn": false,
-      "hide": true,
+      "overHidden": true
+    },
+    {
+      "label": "已付金额",
+      "prop": "settlmentAmount",
+      "index": 18,
+      "width": 100,
       "overHidden": true
     },
     {
       "label": "更改人",
       "prop": "updateUserName",
       "search": false,
-      "index": 18,
+      "index": 19,
       "width": 100,
       "overHidden": true
     },
@@ -233,7 +223,7 @@
       "label": "更改时间",
       "prop": "updateTime",
       "search": false,
-      "index": 19,
+      "index": 20,
       "width": 100,
       "overHidden": true
     },
@@ -241,7 +231,7 @@
       "label": "是否生成发货",
       "prop": "createFreight",
       "search": false,
-      "index": 20,
+      "index": 21,
       "width": 100,
       "overHidden": true
     },
@@ -249,7 +239,7 @@
       "label": "生成发货时间",
       "prop": "createFreightTime",
       "search": false,
-      "index": 21,
+      "index": 22,
       "width": 100,
       "overHidden": true
     },
@@ -257,7 +247,7 @@
       "label": "发货人",
       "prop": "createFreightUser",
       "search": false,
-      "index": 22,
+      "index": 23,
       "width": 100,
       "overHidden": true
     },
@@ -271,8 +261,32 @@
       "label": "单据状态",
       "prop": "orderStatus",
       "search": false,
-      "index": 23,
+      "index": 24,
+      "width": 100,
+      "overHidden": true
+    },
+    {
+      "type": "select",
+      "dicData": [{
+        "name": "已付款",
+        "id": "0"
+      },
+        {
+          "name": "未付款",
+          "id": "1"
+        }
+      ],
+      "props": {
+        "label": "name",
+        "value": "id"
+      },
+      "label": "付款状态",
+      "prop": "gathering",
+      "search": true,
+      "index": 999,
       "width": 100,
+      "showColumn": false,
+      "hide": true,
       "overHidden": true
     }
   ]

+ 11 - 3
src/views/businessManagement/purchaseOrder/index.vue

@@ -39,8 +39,12 @@
           {{ scope.row.createFreight == 1 ? '是' : '否' }}
         </template>
         <template slot-scope="scope" slot="menu">
-          <el-button type="text" icon="el-icon-delete" size="small" @click.stop="createPlant(scope.row, scope.index)"
-            :disabled="scope.row.status > 0 || scope.row.createFreight == 1">生成工厂发货
+          <el-button
+              type="text"
+              icon="el-icon-delete"
+              size="small"
+              @click.stop="createPlant(scope.row, scope.index)"
+              :disabled="scope.row.status > 0 || scope.row.createFreight == 1">生成工厂发货
           </el-button>
           <!--          <el-button-->
           <!--            type="text"-->
@@ -144,7 +148,7 @@ export default {
     this.option = await this.getColumnData(this.getColumnName(17), option);
     this.getWorkDicts("payment_term").then(res => {
       this.findObject(this.option.column, "paymentType").dicData =
-        res.data.data;
+          res.data.data;
     });
     gainUser().then(res => {
       this.findObject(this.option.column, "createUser").dicData = res.data.data;
@@ -192,6 +196,7 @@ export default {
         }
       }
     })
+    console.log(this.option.column.length)
   },
   activated() {
     if (this.$route.query.check) {
@@ -580,6 +585,9 @@ export default {
           delete res.data.data.orderItemsList
           delete res.data.data.corpName
           delete res.data.data.belongToCorpList
+          res.data.data.deliveryAmount = res.data.data.debitAmount
+          delete res.data.data.debitAmount
+          res.data.data.deliveryItemsList.forEach(item=>item.deliveryAmount = item.amount)
           genfactory(res.data.data).then(() => {
             this.$message.success('生成工厂发货成功')
             this.onLoad(this.page, this.search);

+ 11 - 0
src/views/businessManagement/receipt/detailsPageEdit.vue

@@ -676,6 +676,17 @@ export default {
                 trigger: 'blur'
               }
             ]
+          },{
+            label: '来源单号',
+            prop: 'srcOrderNo',
+            disabled: true,
+            rules: [
+              {
+                required: false,
+                message: ' ',
+                trigger: 'blur'
+              }
+            ]
           },
           {
             label: "入库单备注",

+ 0 - 13
src/views/businessManagement/salesOrder/configuration/BuyFree.json

@@ -73,19 +73,6 @@
         }
       ]
     },{
-      "label": "采购价(元)",
-      "prop": "purchasePrice",
-      "index": 4,
-      "width":100,
-      "cell": true,
-      "rules": [
-        {
-          "required": false,
-          "message": " ",
-          "trigger": "blur"
-        }
-      ]
-    },{
       "label": "销售价(元)",
       "prop": "salesPrice",
       "index": 5,

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

@@ -216,21 +216,6 @@
       ]
     },
     {
-      "label": "采购价格",
-      "prop": "purchaseAmount",
-      "index": 11,
-      "width":100,
-      "cell": false,
-      "slot": true,
-      "overHidden": true,
-      "rules": [
-        {
-          "required": false,
-          "message": "请输入采购价格",
-          "trigger": "blur"
-        }
-      ]
-    },{
       "label": "最新单价",
       "prop": "price",
       "index": 12,

+ 0 - 13
src/views/businessManagement/salesOrder/configuration/optionPolicy.json

@@ -94,19 +94,6 @@
         }
       ]
     },{
-      "label": "采购价(元)",
-      "prop": "purchasePrice",
-      "index": 5,
-      "width":100,
-      "cell": true,
-      "rules": [
-        {
-          "required": false,
-          "message": " ",
-          "trigger": "blur"
-        }
-      ]
-    },{
       "label": "销售价(元)",
       "prop": "salesPrice",
       "index": 6,

+ 59 - 0
src/views/businessManagement/salesOrder/detailsPageEdit.vue

@@ -1739,6 +1739,7 @@ export default {
         if (item.prop == 'grossProfitRate' || item.prop == 'grossProfit') item.display = false
       })
     }
+    this.judgeNew()
     if (this.roleName == 'salesman') {
       this.customerContact.column.forEach(item => {
         if (item.prop == 'purchaseAmount') {
@@ -1786,6 +1787,63 @@ export default {
     })
   },
   methods: {
+    judgeNew(){
+      if (!this.roleName.includes('salesman')){
+        for (let item of this.customerContact.column) {
+          if (item.prop === 'purchaseAmount') return false
+        }
+        this.customerContact.column.push({
+          "label": "采购价格",
+          "prop": "purchaseAmount",
+          "index": 11,
+          "width":100,
+          "cell": false,
+          "slot": true,
+          "overHidden": true,
+          "rules": [
+            {
+              "required": false,
+              "message": "请输入采购价格",
+              "trigger": "blur"
+            }
+          ]
+        })
+        for (let item of this.optionPolicy.column) {
+          if (item.prop === 'purchasePrice') return false
+        }
+        this.optionPolicy.column.push({
+          "label": "采购价(元)",
+          "prop": "purchasePrice",
+          "index": 5,
+          "width":100,
+          "cell": true,
+          "rules": [
+            {
+              "required": false,
+              "message": " ",
+              "trigger": "blur"
+            }
+          ]
+        })
+        for (let item of this.customerBuyFree.column) {
+          if (item.prop === 'purchasePrice') return false
+        }
+        this.customerBuyFree.column.push({
+              "label": "采购价(元)",
+              "prop": "purchasePrice",
+              "index": 4,
+              "width":100,
+              "cell": true,
+              "rules": [
+                {
+                  "required": false,
+                  "message": " ",
+                  "trigger": "blur"
+                }
+              ]
+            })
+      }
+    },
     getGoodsRow(event,row) {
       row.priceCategory = event.goodsTypeName
       row.code = event.code
@@ -3380,6 +3438,7 @@ export default {
           this.$refs.crudContact.doLayout()
         })
         this.$message.success("重置成功");
+        this.judgeNew()
         //关闭窗口
         this.$refs.crudContact.$refs.dialogColumn.columnBox = false;
       }

+ 7 - 0
src/views/financialManagement/paymentRequest/configuration/detailsPage.json

@@ -51,6 +51,13 @@
       "overHidden": true
     },
     {
+      "label": "销售单号",
+      "prop": "srcOrderno",
+      "index": 2,
+      "width":150,
+      "overHidden": true
+    },
+    {
       "label": "费用名称",
       "prop": "costType",
       "index": 3,

+ 14 - 0
src/views/financialManagement/paymentRequest/paymentRequestDetails.vue

@@ -441,6 +441,13 @@
     },
     async created() {
       this.itemOption = await this.getColumnData(this.getColumnName(62), itemOption);
+      if (JSON.parse(localStorage.getItem("saber-userInfo")).content.tenant_id === '681169'){
+        for (let item in this.itemOption.column){
+          if (this.itemOption.column[item].prop === 'billNo'){
+            this.itemOption.column.splice(item, 1)
+          }
+        }
+      }
       //是否需要根据 登录人所属公司  区分不用option
 
       //币别
@@ -746,6 +753,13 @@
         if (inSave) {
           this.$message.success("重置成功");
           this.itemOption = itemOption;
+          if (JSON.parse(localStorage.getItem("saber-userInfo")).content.tenant_id === '681169'){
+            for (let item in this.itemOption.column){
+              if (this.itemOption.column[item].prop === 'billNo'){
+                this.itemOption.column.splice(item, 1)
+              }
+            }
+          }
           //关闭窗口
           this.$refs.crud.$refs.dialogColumn.columnBox = false;
         }

+ 1 - 1
src/views/landTransportation/placeAnOrder/index.vue

@@ -232,7 +232,7 @@ export default {
             search: true,
             overHidden: true,
             type: "select",
-            dicUrl: "/api/blade-user/userList",
+            dicUrl: "/api/blade-user/userList?roleAlias=业务员",
             props: {
               label: "realName",
               value: "id"

+ 15 - 3
src/views/landTransportation/reportAnalysis/index.vue

@@ -12,6 +12,7 @@
           @saveColumn="saveColumn"
           @search-change="searchChange"
           @search-reset="query = {}"
+          :search.sync="query"
           @search-criteria-switch="searchCriteriaSwitch"
           @row-save="(row,done,loading)=>{rowSave(row,0,done,loading)}"
           @row-update="rowSave">
@@ -732,9 +733,20 @@ export default {
         cancelButtonText: '取消',
         type: 'warning'
       }).then(() => {
-        window.open(
-            `/api/blade-land/order/acct-export?${this.website.tokenHeader}=${getToken()}`
-        );
+        console.log(this.query);
+        let queryParams = this.query
+        if (queryParams.arrivalTime) {
+          queryParams.beginArrivalTime = queryParams.arrivalTime[0]
+          queryParams.endArrivalTime = queryParams.arrivalTime[1]
+          delete queryParams.arrivalTime
+        }
+        const routeData = this.$router.resolve({
+          path: '/api/blade-land/order/acct-export',      //跳转目标窗口的地址
+          query: {
+            ...queryParams    //括号内是要传递给新窗口的参数
+          }
+        })
+        window.open(routeData.href.slice(1,routeData.href.length-1)+'&'+`${this.website.tokenHeader}=${getToken()}`);
       }).catch(() => {
         this.$message({
           type: 'info',