Browse Source

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

caojunjie 3 years ago
parent
commit
df194ba7fa
32 changed files with 1312 additions and 188 deletions
  1. 15 0
      src/api/dealer/sales.js
  2. 8 0
      src/api/standAlone/handoverSheet.js
  3. 22 0
      src/api/statisticAnalysis/dataDetail.js
  4. 7 0
      src/api/wel.js
  5. 1 0
      src/components/crop-select/main.vue
  6. 2 2
      src/components/details-select/main.vue
  7. 37 21
      src/components/report-dialog/main.vue
  8. 4 0
      src/enums/column-name.js
  9. 1 5
      src/page/index/tags.vue
  10. 30 0
      src/router/views/index.js
  11. 8 6
      src/views/businessManagement/inventoryAccount/index.vue
  12. 6 1
      src/views/businessManagement/purchaseOrder/detailsPageEdit.vue
  13. 11 10
      src/views/businessManagement/salesOrder/detailsPageEdit.vue
  14. 2 0
      src/views/dealer/allocation/config/mainList.json
  15. 12 5
      src/views/dealer/allocation/detail.vue
  16. 98 2
      src/views/dealer/allocation/index.vue
  17. 39 24
      src/views/dealer/purchase/detail.vue
  18. 208 22
      src/views/dealer/sales/detail.vue
  19. 52 2
      src/views/dealer/sales/index.vue
  20. 30 23
      src/views/exportTrade/customerInquiry/config/mainList.json
  21. 5 3
      src/views/exportTrade/customerInquiry/detailsPage.vue
  22. 25 0
      src/views/financialManagement/receiptSettle/receiptSettleDetailsPage.vue
  23. 1 0
      src/views/reimbursement/detail.vue
  24. 345 0
      src/views/statisticAnalysis/dataDetail/index.vue
  25. 8 14
      src/views/statisticAnalysis/salesReconciliation/index.vue
  26. 147 17
      src/views/wel/home/tongjiSchool.vue
  27. 25 0
      src/views/workManagement/handoverSheet/config/mainList.json
  28. 111 10
      src/views/workManagement/handoverSheet/detail.vue
  29. 13 1
      src/views/workManagement/handoverSheet/index.vue
  30. 8 0
      src/views/workManagement/requisition/config/commodity.json
  31. 31 19
      src/views/workManagement/requisition/detail.vue
  32. 0 1
      src/views/workManagement/warehousing/detail.vue

+ 15 - 0
src/api/dealer/sales.js

@@ -79,3 +79,18 @@ export function itemDetail(current, size, params) {
     }
   })
 }
+// 请核
+export function pleaseCheck(data) {
+  return request({
+    url: '/api/blade-purchase-sales/order/checkOrder',
+    method: 'post',
+    data: data
+  })
+}
+export function repealCancel(data) {
+  return request({
+    url: '/api/blade-purchase-sales/order/repealCancel',
+    method: 'post',
+    data: data
+  })
+}

+ 8 - 0
src/api/standAlone/handoverSheet.js

@@ -68,3 +68,11 @@ export function getAttachment(data) {
     params:data
   })
 }
+// 确认提交
+export function submitConfirm(params) {
+  return request({
+    url: '/api/trade-project/handover/confirm',
+    method: 'get',
+    params
+  })
+}

+ 22 - 0
src/api/statisticAnalysis/dataDetail.js

@@ -0,0 +1,22 @@
+import request from '@/router/axios';
+
+// 列表查询
+export const getList = (current, size, params) => {
+  return request({
+    url: '/api/blade-purchase-sales/orderitems/dateset',
+    method: 'get',
+    params: {
+      ...params,
+      current,
+      size
+    }
+  })
+}
+// 导出
+export function exportExcel(params) {
+  return request({
+    url: '/api/blade-purchase-sales/orderitems/dateset-export',
+    method: 'get',
+    params
+  })
+}

+ 7 - 0
src/api/wel.js

@@ -90,3 +90,10 @@ export const bizCount = (query) => {
     params: query
   })
 }
+export const salaryAverage = (query) => {
+  return request({
+    url: '/api/blade-school/salary/salaryAverage',
+    method: 'get',
+    params: query
+  })
+}

+ 1 - 0
src/components/crop-select/main.vue

@@ -214,6 +214,7 @@ export default {
       this.$refs.crud.toggleSelection();
     },
     importCorp() {
+      if (this.multiple && this.selectionList.length == 0) return this.$message.error('请选择明细')
       this.$emit("balabala", this.selectionList[0].id);
       this.$emit("getCorpData", {
         ...this.selectionList[0],

+ 2 - 2
src/components/details-select/main.vue

@@ -50,12 +50,12 @@ export default {
           },
           {
             label: "联系人",
-            prop: "clientAddress",
+            prop: "clientAttn",
             span: 24
           },
           {
             label: "地址",
-            prop: "clientAttn",
+            prop: "clientAddress",
             type: "textarea",
             minRows: 2,
             span: 24

+ 37 - 21
src/components/report-dialog/main.vue

@@ -145,11 +145,16 @@ export default {
       &userId=${this.searchValue.userId}
       &goodsId=${this.searchValue.goodsId}`
         });
-      } else if (name == "客户资料-客户资料.ureport.xml") {
-        this.$router.push({
-          path: `/myiframe/urlPath?name=preview-${name}&src=${this.website.reportUrl}/preview?_u=blade-${name}&id=${this.reportId}&tenantId=${tenantId}`
-        });
-      } else if (name == "国内贸易-库存账.ureport.xml") {
+      }
+      // else if (name == "客户资料-客户资料.ureport.xml") {
+      //   this.$router.push({
+      //     path: `/myiframe/urlPath?name=preview-${name}&src=${this.website.reportUrl}/preview?_u=blade-${name}&id=${this.reportId}&tenantId=${tenantId}`,
+      //     query: {
+      //
+      //     }
+      //   });
+      // }
+      else if (name == "国内贸易-库存账.ureport.xml") {
         this.$router.push({
           path: `/myiframe/urlPath?name=preview-${name}&src=${this.website.reportUrl}/preview?_u=blade-${name}`,
           query: {
@@ -167,30 +172,41 @@ export default {
         });
       } else if (name == "国内贸易-客户确认.ureport.xml") {
         this.$router.push({
-          path: `/myiframe/urlPath?name=preview-${name}&src=${this.website.reportUrl}/preview?_u=blade-${name}
-          &orgOrderNo=${this.searchValue.orgOrderNo}
-          &corpId=${this.searchValue.corpId}
-          &salesCompany=${this.searchValue.salesCompany}
-          &businessStartDate=${this.searchValue.businessStartDate}
-          &businessEndDate=${this.searchValue.businessEndDate}
-          &storageId=${this.searchValue.storageId}
-          &arrivalAddress=${this.searchValue.arrivalAddress}
-          &arrivalContact=${this.searchValue.arrivalContact}
-          &arrivalTel=${this.searchValue.arrivalTel}
-          &createUser=${this.searchValue.createUser}
-          &createTimeStart=${this.searchValue.createTimeStart}
-          &createTimeEnd=${this.searchValue.createTimeEnd}
-          &tenantId=${tenantId}`
+          path: `/myiframe/urlPath?name=preview-${name}&src=${this.website.reportUrl}/preview?_u=blade-${name}`,
+          query: {
+            orgOrderNo: this.searchValue.orgOrderNo,
+            corpId: this.searchValue.corpId,
+            salesCompany: this.searchValue.salesCompany,
+            businessStartDate: this.searchValue.businessStartDate,
+            businessEndDate: this.searchValue.businessEndDate,
+            storageId: this.searchValue.storageId,
+            arrivalAddress:this.searchValue.arrivalAddress,
+            arrivalContact: this.searchValue.arrivalContact,
+            arrivalTel: this.searchValue.arrivalTel,
+            createUser: this.searchValue.createUser,
+            createTimeStart: this.searchValue.createTimeStart,
+            createTimeEnd: this.searchValue.createTimeEnd,
+            tenantId: tenantId,
+          }
         });
       } else if (name == "经销商-可用库存表.ureport.xml") {
         this.$router.push({
-          path: `/myiframe/urlPath?name=preview-${name}&src=${this.website.reportUrl}/preview?_u=blade-${name}&tradeType=JXS&tenantId=${tenantId}`
+          path: `/myiframe/urlPath?name=preview-${name}&src=${this.website.reportUrl}/preview?_u=blade-${name}`,
+          query: {
+            tradeType: 'JXS',
+            tenantId: tenantId,
+          },
         });
       } else {
         let userId = JSON.parse(localStorage.getItem("saber-userInfo")).content
           .user_id;
         this.$router.push({
-          path: `/myiframe/urlPath?name=preview-${name}&src=${this.website.reportUrl}/preview?_u=blade-${name}&id=${this.reportId}&userId=${userId}`
+          path: `/myiframe/urlPath?name=preview-${name}&src=${this.website.reportUrl}/preview?_u=blade-${name}`,
+          query: {
+            id: this.reportId,
+            userId: userId,
+            tenantId: tenantId,
+          },
         });
       }
       this.$emit("onClose", false);

+ 4 - 0
src/enums/column-name.js

@@ -475,6 +475,10 @@ const columnName = [{
   {
     code: 126,
     name: '统计分析销售对账'
+  },
+  {
+    code: 127,
+    name: '统计分析数据明细'
   }
 ]
 export const getColumnName = (key) => {

+ 1 - 5
src/page/index/tags.vue

@@ -407,13 +407,9 @@ export default {
       } else {
         tag = item;
       }
-      console.log(tag)
-      console.log(tag.query);
-      console.log(tag.meta);
-      console.log(this.$router.$avueRouter.getPath({name: tag.label,src: tag.value},tag.meta));
       this.$router.push({
         path: this.$router.$avueRouter.getPath({name: tag.label,src: tag.value},tag.meta),
-        // query: tag.query
+        query: tag.query
       });
 
 

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

@@ -1334,4 +1334,34 @@ export default [{
       component: () => import( /* webpackChunkName: "views" */ '@/views/dealer/allocation/index')
     }]
   },
+  //数据明细(N)
+  {
+    path: '/statisticAnalysis/dataDetail/index',
+    component: Layout,
+    hidden: true,
+    children: [{
+      path: '/statisticAnalysis/dataDetail/index',
+      name: '数据明细(N)',
+      meta: {
+        i18n: '/statisticAnalysis/dataDetail/index',
+        keepAlive: true,
+      },
+      component: () => import( /* webpackChunkName: "views" */ '@/views/statisticAnalysis/dataDetail/index')
+    }]
+  },
+  //销售对账
+  {
+    path: '/statisticAnalysis/salesReconciliation/index',
+    component: Layout,
+    hidden: true,
+    children: [{
+      path: '/statisticAnalysis/salesReconciliation/index',
+      name: '销售对账',
+      meta: {
+        i18n: '/statisticAnalysis/salesReconciliation/index',
+        keepAlive: true,
+      },
+      component: () => import( /* webpackChunkName: "views" */ '@/views/statisticAnalysis/salesReconciliation/index')
+    }]
+  },
 ]

+ 8 - 6
src/views/businessManagement/inventoryAccount/index.vue

@@ -56,7 +56,7 @@
           </el-button>
         </template>
       </avue-crud>
-      <el-dialog title="导入价格"
+      <el-dialog title="导入库存"
                  append-to-body
                  :visible.sync="excelBox"
                  :close-on-click-modal="false"
@@ -127,7 +127,7 @@ export default {
     }
   },
   created() {
-    this.search.createTime = defaultDate(1)
+    // this.search.createTime = defaultDate(1)
     let i = 0;
     this.option.column.forEach(item => {
       if (item.search) i++
@@ -253,10 +253,12 @@ export default {
       // this.show = false;
     },
     statement() {
-      this.statementData = {...this.search}
-      this.statementData.createStartTime = this.statementData.createTime[0]+ " " + "00:00:00"
-      this.statementData.createEndTime = this.statementData.createTime[1]+ " " + "23:59:59"
-      delete this.statementData.createTime
+      this.statementData = {...this.search};
+      if (this.statementData.createTime && this.statementData.createTime.length > 0) {
+        this.statementData.createStartTime = this.statementData.createTime[0]+ " " + "00:00:00"
+        this.statementData.createEndTime = this.statementData.createTime[1]+ " " + "23:59:59"
+        delete this.statementData.createTime;
+      }
       this.switchDialog = !this.switchDialog;
     },
     onClose(val) {

+ 6 - 1
src/views/businessManagement/purchaseOrder/detailsPageEdit.vue

@@ -608,7 +608,12 @@ export default {
       },
       billType:"申请",  //账单类型
       billData:{},     //账单需要数据
-      financeData: {}, // 账单请核需要的路由
+      financeData: {
+        url:"/financialManagement/paymentRequest/index",
+        pageStatus:"this.$store.getters.pqStatus",
+        pageLabel:"付费申请",
+        checkType: 'ffsq'
+      }, // 账单请核需要的路由
       applyPaymentDialog:false,//生成账单组件
       applicationDialog: false,// 申请记录
       dialogVisible: false,

+ 11 - 10
src/views/businessManagement/salesOrder/detailsPageEdit.vue

@@ -208,7 +208,8 @@
                                 :disabled="detailData.seeDisabled || browse"/>
                 <el-input
                   v-else-if="(item.prop === 'advancePayment') || (item.prop === 'orderAmount') ||
-                  (item.prop === 'settlmentAmount') || (item.prop === 'caseOverPayment') || (item.prop === 'thisUsedProfit')"
+                  (item.prop === 'settlmentAmount') || (item.prop === 'caseOverPayment') || (item.prop === 'thisUsedProfit') ||
+                  (item.prop === 'createProfit')"
                   v-model.trim="form[item.prop]" size="small" autocomplete="off"
                   @change="computedCost"
                   :disabled="detailData.seeDisabled || item.disabled || browse"
@@ -1052,7 +1053,7 @@ export default {
           }, {
             label: '产生返利',
             prop: 'createProfit',
-            disabled: true,
+            disabled: false,
             rules: [
               {
                 required: false,
@@ -2235,15 +2236,15 @@ export default {
       this.removeGoodsRepeat()
     },
     async getCorpRow(data) {
-      if (data.adminProfiles) {
-        data.adminProfiles = data.adminProfiles.split(",");
-        let arr=[]
-        data.adminProfiles.forEach(e => {
-          arr.push(this.userList.find(item => item.id == e).realName)
-        })
-        this.$set(this.form, 'chargeMember', arr[0])
-      }
       khDetail(data.id).then(res => {
+        if (res.data.data.adminProfiles) {
+          res.data.data.adminProfiles = res.data.data.adminProfiles.split(",");
+          let arr = [];
+          res.data.data.adminProfiles.forEach(e => {
+            arr.push(this.userList.find(item => item.id == e).realName)
+          })
+          this.$set(this.form, 'chargeMember', arr[0])
+        }
         if (res.data.data.corpsAttnList.length > 0) {
           this.khInfoList = res.data.data.corpsAttnList;
           this.$set(this.form, 'corpAttn', res.data.data.corpsAttnList[0].cname);

+ 2 - 0
src/views/dealer/allocation/config/mainList.json

@@ -18,6 +18,8 @@
   "showSummary": true,
   "summaryText": "合计",
   "sumColumnList": [],
+  "expand": true,
+  "expandWidth": 55,
   "column": [
     {
       "label": "系统编号",

+ 12 - 5
src/views/dealer/allocation/detail.vue

@@ -160,6 +160,7 @@
               icon="el-icon-printer"
               size="small"
               @click="openReport"
+              :disabled="!form.id || dataList.length === 0"
             >报表打印</el-button>
           </template>
           <template slot="menu" slot-scope="{ row, index }">
@@ -298,7 +299,7 @@
     <report-dialog
       :switchDialog="switchDialog"
       :reportId="form.id"
-      reportName=""
+      reportName="经销商-调拨单"
       @onClose="onClose()"
     />
     <!--    商品弹窗-->
@@ -692,7 +693,7 @@ export default {
     },
     //返回列表
     backToList() {
-      if (this.verification()) {
+      if (this.verification(true)) {
         this.$emit("goBack");
       }
     },
@@ -817,7 +818,7 @@ export default {
     },
     getKHData(row) {},
     // 验证新旧值对比
-    verification() {
+    verification(isBack = false) {
       if (contrastObj(this.form, this.oldForm) ||
         contrastList(this.dataList, this.oldDataList)) {
         this.$confirm("数据发生变化未有提交记录, 是否提交?", "提示", {
@@ -827,7 +828,11 @@ export default {
         }).then(() => {
           this.editCustomer();
         }).catch(() => {
-          return false;   //取消改动数据
+          if (isBack) {
+            this.$emit("goBack");
+          } else {
+            return false;   //取消改动数据
+          }
         })
       } else {
         return true;
@@ -850,7 +855,9 @@ export default {
     },
     // 报表
     openReport() {
-      this.switchDialog =! this.switchDialog;
+      if (this.verification()) {
+        this.switchDialog =! this.switchDialog;
+      }
     },
     // 报表关闭
     onClose(val) {

+ 98 - 2
src/views/dealer/allocation/index.vue

@@ -19,6 +19,7 @@
         @search-criteria-switch="searchCriteriaSwitch"
         @saveColumn="saveColumn"
         @resetColumn="resetColumn"
+        @expand-change="expandChange"
       >
         <template slot="menuLeft">
           <el-button
@@ -46,6 +47,16 @@
           >删除
           </el-button>
         </template>
+        <template slot-scope="{ row }" slot="expand">
+          <avue-crud
+            :data="row.itemList"
+            :option="itemOption"
+            :table-loading="row.itemLoading"
+            :cell-style="cellStyle"
+            class="itemTable"
+          >
+          </avue-crud>
+        </template>
         <template slot="storageNameSearch">
           <warehouse-select
             v-model="search.storageId"
@@ -74,7 +85,7 @@
 import option from "./config/mainList.json";
 import detailPage from "./detail";
 import { gainUser } from "@/api/basicData/customerInquiry";
-import {getList, deleteList} from "@/api/dealer/allocation";
+import {getList, deleteList, dataDetail} from "@/api/dealer/allocation";
 
 export default {
   name: "index",
@@ -106,6 +117,75 @@ export default {
         placeholder: "请点击右边按钮选择",
         dicData: [],
       },
+      // 展开明细列表配置
+      itemOption: {
+        align: "center",
+        border: true,
+        header: false,
+        menu: false,
+        column: [
+          {
+            label: "产品编码",
+            prop: "code",
+            width: 130,
+            overHidden: true
+          },
+          {
+            label: "商品名称",
+            prop: "cname",
+            width: 100,
+            overHidden: true
+          },
+          {
+            label: "规格",
+            prop: "typeno",
+            width: 100,
+            overHidden: true
+          },
+          {
+            label: "花纹",
+            prop: "brandItem",
+            width: 100,
+            overHidden: true
+          },
+          {
+            label: "负荷指数",
+            prop: "specsOne",
+            width: 100,
+            overHidden: true
+          },
+          {
+            label: "速度级别",
+            prop: "specsTwo",
+            width: 100,
+            overHidden: true
+          },
+          {
+            label: "单位",
+            prop: "unit",
+            width: 100,
+            overHidden: true
+          },
+          {
+            label: "结余库存",
+            prop: "inventoryNumber",
+            width: 100,
+            overHidden: true
+          },
+          {
+            label: "调拨件数",
+            prop: "actualQuantity",
+            width: 100,
+            overHidden: true
+          },
+          {
+            label: "备注",
+            prop: "remarks",
+            width: 100,
+            overHidden: true
+          }
+        ]
+      },
     }
   },
   async created() {
@@ -176,6 +256,10 @@ export default {
       this.loading = true;
       getList(queryParams).then(res => {
         this.dataList = res.data.data.records;
+        this.dataList.forEach(item => {
+          this.$set(item, 'itemLoading', true);
+          this.$set(item, 'itemList', []);
+        })
         this.page.total = res.data.data.total;
         this.option.height = window.innerHeight - 240;
         this.$nextTick(() => {
@@ -281,10 +365,22 @@ export default {
         this.onLoad(this.page)
       })
     },
+    //展开箭头触发
+    expandChange(row) {
+      if (row.itemLoading) {
+        dataDetail(row.id).then(res => {
+          row.itemList = res.data.data.deliveryItemsList? res.data.data.deliveryItemsList: [];
+        }).finally(() => {
+          row.itemLoading = false;
+        })
+      }
+    },
   },
 }
 </script>
 
 <style scoped>
-
+.itemTable ::v-deep .el-table {
+  width: 100%;
+}
 </style>

+ 39 - 24
src/views/dealer/purchase/detail.vue

@@ -403,7 +403,9 @@
         :billData="{}"
         :arrList="applyPaymentList"
         :belongCompany="form.belongToCorpId"
+        :checkData="checkData"
         @choceFun="choceFun"
+        @submit="feeSubmit"
       />
     </el-dialog>
 <!--    历史记录-->
@@ -657,6 +659,12 @@ export default {
       applyPaymentList: [],
       billType:"收费",  //账单类型
       billData:{},     //账单需要数据
+      checkData:{
+        url:"/financialManagement/paymentRequest/index",
+        pageStatus:"this.$store.getters.pqStatus",
+        pageLabel:"付费申请",
+        checkType: 'ffsq'
+      },
       applySettlementDialog:false,//生成账单组件
       financialAccountDialog:false,
       feesOption: [],
@@ -762,7 +770,7 @@ export default {
         delete this.form.orderItemsList;
         delete this.form.orderFilesList;
         this.oldForm = {...this.form};
-        this.oldDataList = [...this.dataList];
+        // this.oldDataList = [...this.dataList];
         this.oldUploadData = [...this.uploadData];
       }).finally(() => {
         this.pageLoading = false;
@@ -1218,36 +1226,41 @@ export default {
       this.billType = type;
       this.applyPaymentList = [];
       this.goodData.map(e => {
-        const form = {
-          srcOrderno:this.form.orderNo,
-          srcParentId: this.form.id,
-          itemType:"采购",
-          corpsName:this.form.corpsName,
-          corpId:this.form.corpId,
-          currency: 'CNY',
-          exchangeRate: '1',
-          taxRate: '0',
-          accDate: this.form.businesDate,
-          srcType: 1,
-          // chargeMember: this.form.chargeMember,
-          parentId: this.form.id,
-          tradeType: 'JXS',
-          optionType: 'JXS',
-          amount: e.amount,
-          costType: this.feesOption.find(item => item.cname == '货款')? this.feesOption.find(item => item.cname == '货款').id: null,
-          srcFeesId: e.id,
-          goodName: e.cname,
-          price: e.price,
-          quantity: e.orderQuantity,
-          unit:e.unit,
+        if (e.submitPay != 1) {
+          const form = {
+            srcOrderno:this.form.orderNo,
+            srcParentId: this.form.id,
+            itemType:"采购",
+            corpsName:this.form.corpsName,
+            corpId:this.form.corpId,
+            currency: 'CNY',
+            exchangeRate: '1',
+            taxRate: '0',
+            accDate: this.form.businesDate,
+            srcType: 1,
+            // chargeMember: this.form.chargeMember,
+            parentId: this.form.id,
+            tradeType: 'JXS',
+            optionType: 'JXS',
+            amount: e.amount,
+            costType: this.feesOption.find(item => item.cname == '货款')? this.feesOption.find(item => item.cname == '货款').id: null,
+            srcFeesId: e.id,
+            goodName: e.cname,
+            price: e.price,
+            quantity: e.orderQuantity,
+            unit:e.unit,
+          }
+          this.applyPaymentList.push(form);
         }
-        this.applyPaymentList.push(form);
       })
     },
     //关闭账单
     choceFun(){
       this.financialAccountDialog  = false
     },
+    feeSubmit() {
+      this.queryData(this.form.id);
+    },
     // 获得库存信息
     async getStockInfo(data) {
       //tradeType JXS
@@ -1380,12 +1393,14 @@ export default {
       itemDetail(this.goodPage.currentPage, this.goodPage.pageSize, data).then(res => {
         this.dataList = res.data.data.records;
         this.goodPage.total = res.data.data.total;
+        this.oldDataList = [...this.dataList];
       }).finally(() => {
         this.goodLoading = false;
       })
     },
     // 验证新旧值对比
     verification() {
+      console.log(contrastList(this.dataList, this.oldDataList))
       if (contrastObj(this.form, this.oldForm) ||
         contrastList(this.dataList, this.oldDataList) ||
         contrastList(this.uploadData, this.oldUploadData)) {

+ 208 - 22
src/views/dealer/sales/detail.vue

@@ -12,6 +12,21 @@
       </div>
       <div class="add-customer-btn">
         <el-button
+          v-if="checker && form.status != 3"
+          type="primary"
+          size="small"
+          class="el-button--small-yh"
+          @click.stop="openCheckDialog">
+          审批
+        </el-button>
+        <el-button
+          v-if="form.status > 0"
+          @click.native="checkScheduleDialog = true,checkId=form.id"
+          type="primary"
+          size="small"
+          class="el-button--small-yh"
+        >审核进度</el-button>
+        <el-button
           type="primary"
           size="small"
           class="el-button--small-yh"
@@ -20,22 +35,44 @@
         >编 辑</el-button>
         <el-button
           type="primary"
+          v-if="!checkDisabled && confirmDisabled"
+          :disabled="!form.id || disabled"
+          size="small"
+          @click="pleaseCheck"
+          :loading="btnLoading"
+          class="el-button--small-yh"
+        >请核</el-button>
+        <el-button
+          type="primary"
+          v-if="form.status == 1"
+          :disabled="disabled"
+          size="small"
+          @click="repealCancel"
+          :loading="btnLoading"
+        >撤销请核</el-button>
+        <el-button
+          type="primary"
           size="small"
           style="margin-right: 8px;"
           @click="dealerSubmit"
-          :disabled="disabled"
+          :disabled="disabled || checkDisabled"
           :loading="btnLoading"
           v-if="form.id"
         >
-          {{ form.status == 0? '确认订单': form.status == 3? '撤销订单': '' }}
+          {{ form.confirmStatus == 0? '确认订单': form.confirmStatus == 3? '撤销订单': '' }}
         </el-button>
         <el-dropdown style="margin-right: 8px;">
           <el-button type="warning" size="small">账单处理<i class="el-icon-arrow-down el-icon--right"></i></el-button>
           <el-dropdown-menu slot="dropdown">
+<!--            <el-dropdown-item-->
+<!--              @click.native="applySettlement('收费')"-->
+<!--              :disabled="disabled"-->
+<!--            >生成账单-->
+<!--            </el-dropdown-item>-->
             <el-dropdown-item
-              @click.native="applySettlement('收费')"
-              :disabled="disabled"
-            >生成账单
+              @click.native="openApplicationDialog"
+              :disabled="!form.id"
+            >查看账单
             </el-dropdown-item>
           </el-dropdown-menu>
         </el-dropdown>
@@ -72,7 +109,7 @@
               v-model="form.corpId"
               @getCorpData="getCorpData"
               corpType="KH"
-              :disabled="disabled || confirmDisabled"
+              :disabled="disabled || confirmDisabled || checkDisabled"
             />
           </template>
           <template slot="belongToCorpId">
@@ -80,7 +117,7 @@
               v-model="form.belongToCorpId"
               @getCorpData="getGSData"
               corpType="GS"
-              :disabled="disabled || confirmDisabled"
+              :disabled="disabled || confirmDisabled || checkDisabled"
             />
           </template>
           <template slot="storageId">
@@ -88,7 +125,7 @@
               v-model="form.storageId"
               @returnBack="storageChange"
               :configuration="configurationWarehouse"
-              :disabled="disabled || confirmDisabled"/>
+              :disabled="disabled || confirmDisabled || checkDisabled"/>
           </template>
           <template slot="chargeMember">
             <el-select
@@ -124,7 +161,7 @@
               icon="el-icon-circle-plus-outline"
               circle
               size="mini"
-              :disabled="disabled || !form.storageId || confirmDisabled"
+              :disabled="disabled || !form.storageId || confirmDisabled || checkDisabled"
               @click="$refs.crud.rowCellAdd()"></el-button>
           </template>
           <template slot="menuLeft">
@@ -133,7 +170,7 @@
               icon="el-icon-plus"
               size="small"
               @click.stop="newDetails"
-              :disabled="disabled || !form.storageId || confirmDisabled"
+              :disabled="disabled || !form.storageId || confirmDisabled || checkDisabled"
             >录入明细</el-button>
             <el-button
               type="info"
@@ -150,7 +187,7 @@
             <el-upload
               :action="baseURL"
               :headers="headers"
-              :disabled="disabled || confirmDisabled || !form.storageId"
+              :disabled="disabled || confirmDisabled || !form.storageId || checkDisabled"
               :on-progress="uploading"
               :show-file-list=false
               :data="uploadParam"
@@ -164,7 +201,7 @@
                 type="primary"
                 size="small"
                 icon="el-icon-upload"
-                :disabled="disabled || confirmDisabled || !form.storageId"
+                :disabled="disabled || confirmDisabled || !form.storageId || checkDisabled"
               >导 入</el-button>
             </el-upload>
           </template>
@@ -174,7 +211,7 @@
               icon="el-icon-edit"
               type="text"
               @click="rowCell(row, index)"
-              :disabled="disabled || confirmDisabled"
+              :disabled="disabled || confirmDisabled || checkDisabled"
             >{{ row.$cellEdit ? "保存" : "修改" }}</el-button
             >
             <el-button
@@ -182,7 +219,7 @@
               icon="el-icon-delete"
               type="text"
               @click="rowDel(row, index)"
-              :disabled="disabled || confirmDisabled"
+              :disabled="disabled || confirmDisabled || checkDisabled"
             >删除</el-button
             >
           </template>
@@ -340,7 +377,7 @@
         :data="uploadData"
         deleteUrl="/api/blade-client/corpsbank/update"
         :enumerationValue="84"
-        :disabled="disabled || confirmDisabled"
+        :disabled="disabled || confirmDisabled || checkDisabled"
       />
     </div>
 <!--    商品弹窗-->
@@ -462,6 +499,60 @@
       :params="historyParams"
       @closeDialog="closeDialog"
     />
+    <el-dialog
+      append-to-body
+      title="审批"
+      class="el-dialogDeep"
+      :visible.sync="checkDialog"
+      width="50%"
+      :close-on-click-modal="false"
+      :destroy-on-close="true"
+      :close-on-press-escape="false"
+      v-dialog-drag
+    >
+      <check
+        :checkData="checkData"
+        :checkDetail="false"
+        :idList="[]"
+        @choceCheckFun="choceCheckFun"
+      >
+      </check>
+    </el-dialog>
+    <el-dialog
+      append-to-body
+      title="审批进度"
+      class="el-dialogDeep"
+      :visible.sync="checkScheduleDialog"
+      width="40%"
+      :close-on-click-modal="false"
+      :destroy-on-close="true"
+      :close-on-press-escape="false"
+      v-dialog-drag
+    >
+      <check-schedule
+        :checkId="checkId"
+        :batchNo="batchNo"
+        @choceScheduleFun="choceScheduleFun"
+      >
+      </check-schedule>
+    </el-dialog>
+    <el-dialog
+      title="申请记录"
+      append-to-body
+      class="el-dialogDeep"
+      :visible.sync="applicationDialog"
+      width="60%"
+      :close-on-click-modal="false"
+      :destroy-on-close="true"
+      :close-on-press-escape="false"
+      v-dialog-drag
+    >
+      <bill-application
+        :billId="form.id"
+        @choceApplication="choceApplication"
+      >
+      </bill-application>
+    </el-dialog>
   </div>
 </template>
 
@@ -474,7 +565,11 @@ import {getUserInfo} from "@/api/system/user";
 import { gainUser } from "@/api/basicData/customerInquiry";
 import {selectGoodsNum} from "@/api/basicData/inventoryAccount"; // 库存查询
 import {detail as KHDetail} from "@/api/basicData/customerInformation";
-import {dataDetail, removeGoods, typeSave, getLotNo, dealerSubmit, historyPrice, itemDetail} from "@/api/dealer/sales";
+import {dataDetail, removeGoods,
+  typeSave, getLotNo,
+  dealerSubmit, historyPrice,
+  itemDetail, pleaseCheck,
+  repealCancel,} from "@/api/dealer/sales";
 import reportDialog from "@/components/report-dialog/main";
 import {
   isDiscount,
@@ -483,6 +578,7 @@ import {
   IntegerFormat
 } from "@/util/validate";
 import financialAccount from "../../../components/finance/financialAccount";
+import check from "@/components/check/check";
 import checkSchedule from "@/components/check/checkSchedule";
 import  billApplication from "@/components/bill/billApplication";
 import { customerList as feeList } from "@/api/basicData/basicFeesDesc";
@@ -504,6 +600,7 @@ export default {
     reportDialog,
     billApplication,
     financialAccount,
+    check,
     checkSchedule,
     viewHistory,
   },
@@ -604,6 +701,18 @@ export default {
             span: 8,
           },
           {
+            label: "系统编号",
+            prop: "sysNo",
+            span: 8,
+            disabled: true,
+          },
+          {
+            label: "订单号",
+            prop: "orderNo",
+            span: 8,
+            disabled: true,
+          },
+          {
             label: "备注",
             prop: "orderRemark",
             type: "textarea",
@@ -745,6 +854,14 @@ export default {
       oldForm: {},
       oldDataList: [],
       oldUploadData: [],
+      checkDisabled: false, // 审核状态
+      checker: false,
+      checkId: '',
+      batchNo:'',
+      checkDialog: false,
+      checkScheduleDialog: false,
+      checkData: {},
+      applicationDialog: false, // 历史账单查看弹窗
     }
   },
   async created() {
@@ -783,12 +900,17 @@ export default {
     });
     this.$set(this.form, 'businesDate', getCurrentDate());
     this.$set(this.form, 'status', 0);
+    this.$set(this.form , 'confirmStatus', 0);
     if (this.detailData.query) {
       this.disabled = true;
       this.option.column.map(e => {
         this.$set(e, 'disabled', true)
       })
       this.queryData(this.detailData.id);
+    }  else if (this.detailData.auditId) {
+      this.checker = true;
+      this.batchNo = this.detailData.check.batchNo
+      this.queryData(this.detailData.id);
     } else {
       this.dataList = [
         {
@@ -829,7 +951,8 @@ export default {
             storageId: this.form.storageId
           }
         }
-        this.confirmDisabled = this.form.status == 3? true: false;
+        this.confirmDisabled = this.form.confirmStatus == 3? true: false;
+        this.checkDisabled = this.form.status > 0? true: false;
         if (this.confirmDisabled) {
           // this.option.column.map(e => {
           //   this.$set(e, 'disabled', true)
@@ -861,8 +984,8 @@ export default {
     openEdit() {
       this.disabled = false;
       this.option.column.map(e => {
-        if (this.confirmDisabled) {
-          if (e.prop == 'businesDate') {
+        if (this.confirmDisabled || this.checkDisabled) {
+          if (e.prop == 'businesDate' || e.prop == 'sysNo' || e.prop == 'orderNo') {
             this.$set(e, 'disabled', true)
           } else {
             this.$set(e, 'disabled', false)
@@ -976,7 +1099,7 @@ export default {
           balanceAmount: 0,
           balanceQuantity: 0,
         };
-        this.$set(form, 'purchaseAmount', a.balanceQuantity == 0? 0: (Number(a.balanceAmount) / Number(a.balanceQuantity)).toFixed(2));
+        this.$set(form, 'purchaseAmount', a.inQuantity == 0? 0: (Number(a.inAmount) / Number(a.inQuantity)).toFixed(2));
         this.$set(form, 'stock', a.balanceQuantity);
       })
       return form;
@@ -1498,9 +1621,9 @@ export default {
     dealerSubmit() {
       if (this.verification()) {
         let dealer;
-        if (this.form.status == 0) {
+        if (this.form.confirmStatus == 0) {
           dealer = 1;
-        } else if (this.form.status == 3) {
+        } else if (this.form.confirmStatus == 3) {
           dealer = 2;
         }
         this.btnLoading = true;
@@ -1622,6 +1745,69 @@ export default {
         return true;
       }
     },
+    // 请核
+    pleaseCheck() {
+      if (this.verification()) {
+        const data = {
+          id : this.form.id,
+          checkType: 'xsqh',
+          url: '/dealer/sales/index',
+          pageStatus:"this.$store.getters.dealerSaleStatus",
+          pageLabel:"销售订单(D)",
+          checkFlag: 2,
+        }
+        this.btnLoading = true;
+        pleaseCheck(data).then(res => {
+          this.$message.success('请核成功')
+          this.queryData(this.form.id)
+        }).catch(() => {
+          this.$message.error('请核失败')
+        }).finally(() => {
+          this.btnLoading = false;
+        })
+      }
+    },
+    repealCancel(){
+      this.$confirm("您确定撤回此次申请吗?", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(() => {
+        const data = {
+          id : this.form.id,
+          checkType: 'xsqh',
+          pageLabel:"销售订单(D)",
+          checkFlag: 2,
+        }
+        this.pageLoading = true
+        repealCancel(data).then(res => {
+          this.$message.success('撤回成功')
+          this.queryData(this.form.id)
+        }).finally(() => {
+          this.pageLoading = false
+        })
+      })
+    },
+    //打开审核
+    openCheckDialog(){
+      this.checkData  = this.detailData.check
+      this.checkDialog = true;
+    },
+    //关闭审核
+    choceCheckFun(){
+      this.checkDialog = false;
+    },
+    choceScheduleFun(){
+      this.checkScheduleDialog = false
+    },
+    // 查看申请记录
+    openApplicationDialog(){
+      this.applicationDialog = true
+    },
+    //关闭记录
+    choceApplication(){
+      this.applicationDialog = false
+    },
   },
 }
 </script>

+ 52 - 2
src/views/dealer/sales/index.vue

@@ -70,6 +70,13 @@
             @click.stop="copyDoc()"
             :disabled="selection.length != 1"
           >复制单据</el-button>
+          <el-button
+            v-if="false"
+            type="info"
+            size="small"
+            icon="el-icon-printer"
+            @click.stop="statement"
+          >报表打印</el-button>
         </template>
         <template slot-scope="scope" slot="menu">
           <el-button
@@ -77,7 +84,7 @@
             icon="el-icon-delete"
             size="small"
             @click.stop="rowDel(scope.row, scope.index)"
-            :disabled="scope.row.status == 3"
+            :disabled="scope.row.confirmStatus == 3 || scope.row.status > 0"
           >删除
           </el-button>
         </template>
@@ -89,6 +96,12 @@
       :detailData="detailData"
       v-if="!show"
     />
+    <report-dialog
+      :switchDialog="switchDialog"
+      :searchValue="statementData"
+      :reportName="'经销商-账务对账'"
+      @onClose="onClose()"
+    />
   </div>
 </template>
 
@@ -97,10 +110,14 @@ import option from './config/mainList.json';
 import detailPage from "./detail";
 import { gainUser } from "@/api/basicData/customerInquiry";
 import {getSalesList, dataDetail, deleteDetails} from "@/api/dealer/sales";
+import reportDialog from "@/components/report-dialog/main";
 
 export default {
   name: "index",
-  components: { detailPage },
+  components: {
+    detailPage,
+    reportDialog,
+  },
   data() {
     return {
       option: {},
@@ -199,6 +216,8 @@ export default {
           },
         ]
       },
+      switchDialog: false, //报表弹窗
+      statementData: {},
     }
   },
   async created() {
@@ -220,6 +239,27 @@ export default {
       this.option.searchMenuPosition = "right";
     }
   },
+  activated() {
+    if (this.$route.query.check) {
+      this.show = true;
+      this.detailData = {
+        id: this.$route.query.check.billId,
+        check: this.$route.query.check,
+        auditId: this.$route.query.check.id,
+      };
+      this.show = false;
+      this.$store.commit("JXSSALE_IN_DETAIL");
+    }
+    if (this.$route.query.params) {
+      this.show = true;
+      this.detailData = {
+        id: this.$route.query.params,
+        query: true,
+      };
+      this.show = false;
+      this.$store.commit("JXSSALE_IN_DETAIL");
+    }
+  },
   filters: {
     decimalFormat(num) {
       return num ? Number(num).toFixed(2) : "0.00";
@@ -236,6 +276,7 @@ export default {
     },
     newAdd() {
       this.show = false;
+      this.$store.commit("JXSSALE_IN_DETAIL");
     },
     copyDoc() {},
     selectionChange(list) {
@@ -354,6 +395,7 @@ export default {
       };
       this.$nextTick(() => {
         this.show = false;
+        this.$store.commit("JXSSALE_IN_DETAIL");
       });
     },
     beforeOpenPage(row, index) {
@@ -362,6 +404,7 @@ export default {
         id: row.id,
         query: true, // 表示只是查询
       };
+      this.$store.commit("JXSSALE_IN_DETAIL");
     },
     expandChange(row) {
       if (this.dataList[row.$index].itemLoading == false) {
@@ -375,6 +418,13 @@ export default {
           });
       }
     },
+    statement() {
+      this.statementData = {...this.search};
+      this.switchDialog = !this.switchDialog;
+    },
+    onClose(val) {
+      this.switchDialog = val;
+    },
   },
 }
 </script>

+ 30 - 23
src/views/exportTrade/customerInquiry/config/mainList.json

@@ -26,10 +26,17 @@
       "searchSpan": 8
     },
     {
+      "label": "详情信息",
+      "prop": "clientMessage",
+      "index": 2,
+      "minWidth": 80,
+      "overHidden": true
+    },
+    {
       "label": "报价日期",
       "prop": "businesDate",
       "search": true,
-      "index": 2,
+      "index": 3,
       "minWidth": 80,
       "overHidden": true,
       "searchSpan": 8,
@@ -40,7 +47,7 @@
       "label": "订单号",
       "prop": "orderNo",
       "search": true,
-      "index": 3,
+      "index": 4,
       "minWidth": 80,
       "overHidden": true,
       "searchSpan": 8
@@ -49,7 +56,7 @@
       "label": "有效日期",
       "prop": "dateValidity",
       "search": true,
-      "index": 4,
+      "index": 5,
       "minWidth": 80,
       "overHidden": true,
       "searchSpan": 8,
@@ -59,35 +66,35 @@
     {
       "label": "价格条款",
       "prop": "priceTerms",
-      "index": 5,
+      "index": 6,
       "minWidth": 80,
       "overHidden": true
     },
     {
       "label": "收款方式",
       "prop": "paymentType",
-      "index": 6,
+      "index": 7,
       "minWidth": 80,
       "overHidden": true
     },
     {
       "label": "运输方式",
       "prop": "transport",
-      "index": 7,
+      "index": 8,
       "minWidth": 80,
       "overHidden": true
     },
     {
       "label": "箱型",
       "prop": "boxPile",
-      "index": 8,
+      "index": 9,
       "minWidth": 80,
       "overHidden": true
     },
     {
       "label": "箱量",
       "prop": "boxNumber",
-      "index": 9,
+      "index": 10,
       "minWidth": 80,
       "overHidden": true
     },
@@ -95,7 +102,7 @@
       "label": "订单状态",
       "prop": "orderStatus",
       "search": true,
-      "index": 10,
+      "index": 11,
       "minWidth": 80,
       "overHidden": true,
       "type": "select",
@@ -109,7 +116,7 @@
       "label": "起运港",
       "prop": "portOfLoad",
       "search": true,
-      "index": 11,
+      "index": 12,
       "minWidth": 80,
       "overHidden": true,
       "searchSpan": 8
@@ -118,7 +125,7 @@
       "label": "目的港",
       "prop": "portOfDestination",
       "search": true,
-      "index": 12,
+      "index": 13,
       "minWidth": 80,
       "overHidden": true,
       "type": "select",
@@ -133,35 +140,35 @@
     {
       "label": "数量合计",
       "prop": "orderQuantity",
-      "index": 13,
+      "index": 14,
       "minWidth": 80,
       "overHidden": true
     },
     {
       "label": "产品毛利",
       "prop": "grossProfit",
-      "index": 14,
+      "index": 15,
       "minWidth": 80,
       "overHidden": true
     },
     {
       "label": "产品利率",
       "prop": "grossProfitRate",
-      "index": 15,
+      "index": 16,
       "minWidth": 80,
       "overHidden": true
     },
     {
       "label": "销售金额",
       "prop": "amount",
-      "index": 16,
+      "index": 17,
       "minWidth": 80,
       "overHidden": true
     },
     {
       "label": "采购金额",
       "prop": "purchaseAmount",
-      "index": 17,
+      "index": 18,
       "minWidth": 80,
       "overHidden": true
     },
@@ -169,7 +176,7 @@
       "label": "商品名称",
       "prop": "",
       "search": true,
-      "index": 18,
+      "index": 19,
       "minWidth": 80,
       "overHidden": true,
       "hide": true,
@@ -180,7 +187,7 @@
       "label": "系统号",
       "prop": "sysNo",
       "search": true,
-      "index": 19,
+      "index": 20,
       "minWidth": 80,
       "overHidden": true,
       "searchSpan": 8
@@ -188,7 +195,7 @@
     {
       "label": "制单人",
       "prop": "createUser",
-      "index": 20,
+      "index": 21,
       "minWidth": 80,
       "search": true,
       "overHidden": true,
@@ -204,7 +211,7 @@
     {
       "label": "制单日期",
       "prop": "createTime",
-      "index": 21,
+      "index": 22,
       "minWidth": 80,
       "search": true,
       "overHidden": true,
@@ -215,7 +222,7 @@
     {
       "label": "备注",
       "prop": "orderRemark",
-      "index": 22,
+      "index": 23,
       "minWidth": 80,
       "search": true,
       "overHidden": true,
@@ -224,14 +231,14 @@
     {
       "label": "采购备注",
       "prop": "purchaseRemark",
-      "index": 23,
+      "index": 24,
       "minWidth": 80,
       "overHidden": true
     },
     {
       "label": "销售备注",
       "prop": "shippingRemark",
-      "index": 24,
+      "index": 25,
       "minWidth": 80,
       "overHidden": true
     }

+ 5 - 3
src/views/exportTrade/customerInquiry/detailsPage.vue

@@ -1023,6 +1023,8 @@ export default {
         this.tableOption.column,
         "purchaseCost"
       ).showColumn = false;
+      this.findObject(this.tableOption.column, "partsCost").hide = true;
+      this.findObject(this.tableOption.column, "partsCost").showColumn = false;
     }
     this.getWorkDicts("product_properties").then(res => {
       this.findObject(this.tableOption.column, "itemProp").dicData =
@@ -1967,9 +1969,9 @@ export default {
     detailsDate(obj) {
       this.form = obj;
       this.form.clientMessage =
-        (this.form.client ? this.form.client + ";" :"") +
-        (this.form.clientAttn ? this.form.clientAttn + ";" :"") +
-        (this.form.clientAddress ? this.form.clientAddress + ";" :"");
+        (this.form.client ? this.form.client + ";" : "") +
+        (this.form.clientAttn ? this.form.clientAttn + ";" : "") +
+        (this.form.clientAddress ? this.form.clientAddress + ";" : "");
     },
     //返回列表
     backToList() {

+ 25 - 0
src/views/financialManagement/receiptSettle/receiptSettleDetailsPage.vue

@@ -117,6 +117,13 @@
                        @click="selectRecipt"
             >选择销售合同
             </el-button>
+            <el-button
+              v-if="false && form.id"
+              type="info"
+              size="small"
+              icon="el-icon-printer"
+              @click.stop="openReport"
+            >报表打印</el-button>
           </template>
           <template slot-scope="{ row }" slot="currency">
             <el-select  v-if="row.$cellEdit" v-model="row.currency" size="small" placeholder="请选择 币别" clearable filterable>
@@ -183,6 +190,13 @@
       ref="messagePost"
       @closeDialog="closeDialog"
     ></messagePost>
+    <report-dialog
+      :reportId="form.id"
+      :switchDialog="switchDialog"
+      :searchValue="statementData"
+      :reportName="'对账单'"
+      @onClose="onClose()"
+    />
   </div>
 </template>
 
@@ -197,6 +211,7 @@
   import {getUserInfo} from "@/api/system/user";
   import {getCorpDetail} from "@/api/maintenance/overpayment";
   import { getlistBankBy as GYSGetBank } from "@/api/basicData/configuration"
+  import reportDialog from "@/components/report-dialog/main";
 
   export default {
     name: "receiptDetailsPage",
@@ -207,6 +222,7 @@
     },
     components:{
       billDetail,
+      reportDialog,
     },
     data() {
       return {
@@ -440,6 +456,8 @@
             label: '停用'
           }],
         editDisable: false, //编辑状态禁用
+        switchDialog: false,
+        statementData: {},
       }
     },
     created() {
@@ -823,6 +841,13 @@
       cellStyle() {
         return "padding:0;height:40px;";
       },
+      openReport() {
+        this.statementData = {...this.search};
+        this.switchDialog = !this.switchDialog;
+      },
+      onClose(val) {
+        this.switchDialog = val;
+      },
     }
   }
 </script>

+ 1 - 0
src/views/reimbursement/detail.vue

@@ -689,6 +689,7 @@ export default {
       if (this.verification()) {
         const data = {
           id : this.form.id,
+          serialNo: this.form.serialNo,
           checkType: 'fybx',
           url: '/reimbursement/index',
           pageStatus:"this.$store.getters.reimbursementStatus",

+ 345 - 0
src/views/statisticAnalysis/dataDetail/index.vue

@@ -0,0 +1,345 @@
+<template>
+  <div>
+    <basic-container class="page-crad">
+      <avue-crud
+        ref="crud"
+        :option="option"
+        :data="dataList"
+        :page.sync="page"
+        :search.sync="search"
+        :cell-style="cellStyle"
+        @search-change="searchChange"
+        @current-change="currentChange"
+        @size-change="sizeChange"
+        @refresh-change="refreshChange"
+        @on-load="onLoad"
+        :table-loading="loading"
+        @saveColumn="saveColumn"
+        @resetColumn="resetColumn"
+        @search-criteria-switch="searchCriteriaSwitch"
+      >
+        <template slot="menuLeft">
+          <el-button type="info" size="small" @click="outExport" icon="el-icon-download">导出</el-button>
+        </template>
+      </avue-crud>
+    </basic-container>
+  </div>
+</template>
+
+<script>
+import { getToken } from "@/util/auth";
+import { getList, exportExcel } from "@/api/statisticAnalysis/dataDetail";
+import { micrometerFormat } from "@/util/validate";
+import _ from "lodash";
+export default {
+  name: "index",
+  data() {
+    return {
+      form: {},
+      search: {},
+      dataList: [],
+      loading: false,
+      detailData: {},
+      page: {
+        pageSize: 20,
+        currentPage: 1,
+        total: 0,
+        pageSizes: [10, 20, 30, 40, 50, 100, 200, 300, 400, 500]
+      },
+      option: {},
+      defaultOption: {
+        searchShow: true,
+        align: "center",
+        searchSpan: 8,
+        border: true,
+        index: true,
+        addBtn: false,
+        viewBtn: false,
+        editBtn: false,
+        delBtn: false,
+        showSummary: true,
+        summaryText: '合计',
+        sumColumnList: [
+          {
+            name: "orderQuantity",
+            type: "sum",
+            decimals: 0
+          },
+          {
+            name: "amount",
+            type: "sum",
+          },
+          {
+            name: "purchaseAmount",
+            type: "sum",
+          },
+        ],
+        searchIcon: true,
+        searchIndex: 2,
+        menu: false,
+        column: [
+          {
+            label: "销售订单号",
+            prop: "orderNo",
+            search: true,
+            overHidden: true,
+          },
+          {
+            label: "客户名称",
+            prop: "corpName",
+            search: true,
+            overHidden: true,
+          },
+          {
+            label: "供应商",
+            prop: "gysName",
+            search: false,
+            overHidden: true,
+          },
+          {
+            label: "所属公司",
+            prop: "belongCompany",
+            search: true,
+            overHidden: true,
+          },
+          {
+            label: "制单日期",
+            prop: "createTime",
+            search: true,
+            type: 'date',
+            format: "yyyy-MM-dd",
+            valueFormat: "yyyy-MM-dd",
+            unlinkPanels: true,
+            searchRange: true,
+            overHidden: true,
+          },
+          {
+            label: "商品名称",
+            prop: "goodsName",
+            search: false,
+            overHidden: true,
+          },
+          {
+            label: "规格",
+            prop: "typeNo",
+            search: false,
+            overHidden: true,
+          },
+          {
+            label: "花纹",
+            prop: "brandItem",
+            search: false,
+            overHidden: true,
+          },
+          {
+            label: "数量",
+            prop: "orderQuantity",
+            search: false,
+            overHidden: true,
+          },
+          {
+            label: "金额",
+            prop: "amount",
+            search: false,
+            overHidden: true,
+          },
+          {
+            label: "采购价",
+            prop: "purchaseAmount",
+            search: false,
+            overHidden: true,
+          },
+          {
+            label: "包装要求",
+            prop: "packageRemarks",
+            search: true,
+            overHidden: true,
+          },
+        ],
+      },
+    };
+  },
+  filters: {
+    decimalFormat(num) {
+      return num ? Number(num).toFixed(2) : "0.00";
+    }
+  },
+  async created() {
+    this.option = await this.getColumnData(this.getColumnName(127), this.defaultOption);
+    let i = 0;
+    this.option.column.forEach(item => {
+      if (item.search) i++
+    })
+    if (i % 3 !== 0){
+      const num = 3 - Number(i % 3)
+      this.option.searchMenuSpan = num * 8;
+      this.option.searchMenuPosition = "right";
+    }
+  },
+  methods: {
+    cellStyle() {
+      return "padding:0;height:40px;";
+    },
+    searchCriteriaSwitch(type) {
+      if (type) {
+        this.option.height = this.option.height - 46;
+      } else {
+        this.option.height = this.option.height + 46;
+      }
+      this.$refs.crud.getTableHeight();
+    },
+    //点击搜索按钮触发
+    searchChange(params, done) {
+      this.page.currentPage = 1;
+      this.onLoad(this.page, params);
+      done();
+    },
+    refreshChange() {
+      delete this.search.corpName;
+      delete this.search.storageName
+      this.onLoad(this.page, this.search);
+    },
+    currentChange(val) {
+      this.page.currentPage = val;
+    },
+    sizeChange(val) {
+      this.page.currentPage = 1;
+      this.page.pageSize = val;
+    },
+    onLoad(page, params) {
+      this.loading = true;
+      this.dataList.forEach(item => {
+        this.$refs.crud.toggleRowExpansion(item, false);
+      });
+      let queryParams = Object.assign({}, params);
+      if (queryParams.createTime && queryParams.createTime.length > 0) {
+        queryParams = {
+          ...queryParams,
+          beginCreateTime: queryParams.createTime[0] + ' 00:00:00',
+          endCreateTime: queryParams.createTime[1] + ' 23:59:59',
+        }
+        delete queryParams.createTime;
+      }
+      getList(
+        page.currentPage,
+        page.pageSize,
+        queryParams
+      )
+        .then(res => {
+          if (res.data.data.records) {
+            res.data.data.records.forEach(e => {
+              e.itemLoading = true;
+            });
+          }
+          this.dataList = res.data.data.records ? res.data.data.records : [];
+          this.page.total = res.data.data.total;
+          if (this.page.total) {
+            this.option.height = window.innerHeight - 210;
+          }
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    editOpen(row) {
+      if (row.billType == "BJ") {
+        this.$router.push({
+          path: "/exportTrade/customerInquiry/index",
+          query: {
+            id: row.id
+          }
+        });
+      } else {
+        this.$router.push({
+          path: "/exportTrade/salesContract/index",
+          query: {
+            id: row.id
+          }
+        });
+      }
+    },
+    outExport() {
+      let params = {...this.search}
+      if (!params.corpName) this.$set(params, 'corpName', '');
+      if (!params.orderNo) this.$set(params, 'orderNo', '');
+      if (!params.gysName) this.$set(params, 'gysName', '');
+      if (!params.belongCompany) this.$set(params, 'belongCompany', '');
+      if (params.createTime && params.createTime.length > 0) {
+        params = {
+          ...params,
+          beginCreateTime: params.createTime[0] + ' 00:00:00',
+          endCreateTime: params.createTime[1] + ' 23:59:59',
+        }
+      } else {
+        params = {
+          ...params,
+          beginCreateTime: '',
+          endCreateTime: '',
+        }
+      }
+      // return console.log(this.search)
+      this.$confirm('是否导出数据明细?', '提示', {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning'
+      }).then(() => {
+        window.open(
+          `/api/blade-purchase-sales/orderitems/dateset-export?${
+            this.website.tokenHeader
+          }=${getToken()}&corpName=${params.corpName}&beginCreateTime=${params.beginCreateTime}&endCreateTime=${params.endCreateTime}&orderNo=${params.orderNo}&gysName=${params.gysName}&belongCompany=${params.belongCompany}`
+        );
+      }).catch(() => {
+        this.$message({
+          type: 'info',
+          message: '已取消' //
+        });
+      })
+    },
+    //列保存触发
+    async saveColumn() {
+      /**
+       * 已定义全局方法,直接使用,saveColumnData保存列数据方法,参数传值(表格名称,当前表格的option数据)
+       * 已定义全局方法,直接使用,getColumnName方法用来获取枚举值,参数根据自己定义的code值获取中文名
+       * 一定要执行异步操作,要等接口成功返回,才能执行下一行代码
+       */
+      const inSave = await this.saveColumnData(
+        this.getColumnName(127),
+        this.option
+      );
+      if (inSave) {
+        this.$message.success("保存成功");
+        //关闭窗口
+        this.$refs.crud.$refs.dialogColumn.columnBox = false;
+        this.$nextTick(() => {
+          this.$refs.crud.doLayout()
+        })
+
+      }
+    },
+    async resetColumn() {
+      this.option = this.defaultOption;
+      const inSave = await this.delColumnData(this.getColumnName(127), this.defaultOption);
+      if (inSave) {
+        this.$nextTick(() => {
+          this.$refs.crud.doLayout()
+        })
+        this.$message.success("重置成功");
+        //关闭窗口
+        this.$refs.crud.$refs.dialogColumn.columnBox = false;
+      }
+    },
+  }
+};
+</script>
+
+<style scoped>
+.page-crad ::v-deep .basic-container__card {
+  height: 94.2vh;
+}
+::v-deep .el-table__expanded-cell[class*="cell"] {
+  padding: 0px;
+}
+.itemTable ::v-deep .el-table {
+  width: 100%;
+}
+</style>

+ 8 - 14
src/views/statisticAnalysis/salesReconciliation/index.vue

@@ -39,7 +39,6 @@ import { getToken } from "@/util/auth";
 import { getList, exportExcel } from "@/api/statisticAnalysis/salesReconciliation";
 import { micrometerFormat } from "@/util/validate";
 import _ from "lodash";
-import option from "../../businessManagement/salesOrder/configuration/mainList.json";
 export default {
   name: "index",
   data() {
@@ -55,7 +54,8 @@ export default {
         total: 0,
         pageSizes: [10, 20, 30, 40, 50, 100, 200, 300, 400, 500]
       },
-      option: {
+      option: {},
+      defaultOption: {
         searchShow: true,
         align: "center",
         searchSpan: 8,
@@ -165,7 +165,7 @@ export default {
     }
   },
   async created() {
-    // this.option = await this.getColumnData(this.getColumnName(126), option);
+    this.option = await this.getColumnData(this.getColumnName(126), this.defaultOption);
     let i = 0;
     this.option.column.forEach(item => {
       if (item.search) i++
@@ -294,28 +294,22 @@ export default {
     },
     //列保存触发
     async saveColumn() {
-      /**
-       * 已定义全局方法,直接使用,saveColumnData保存列数据方法,参数传值(表格名称,当前表格的option数据)
-       * 已定义全局方法,直接使用,getColumnName方法用来获取枚举值,参数根据自己定义的code值获取中文名
-       * 一定要执行异步操作,要等接口成功返回,才能执行下一行代码
-       */
       const inSave = await this.saveColumnData(
         this.getColumnName(126),
         this.option
       );
       if (inSave) {
+        this.$nextTick(() => {
+          this.$refs.crud.doLayout();
+        });
         this.$message.success("保存成功");
         //关闭窗口
         this.$refs.crud.$refs.dialogColumn.columnBox = false;
-        this.$nextTick(() => {
-          this.$refs.crud.doLayout()
-        })
-
       }
     },
     async resetColumn() {
-      this.option = option;
-      const inSave = await this.delColumnData(this.getColumnName(126),option);
+      this.option = this.defaultOption;
+      const inSave = await this.delColumnData(this.getColumnName(126), this.defaultOption);
       if (inSave) {
         this.$nextTick(() => {
           this.$refs.crud.doLayout()

+ 147 - 17
src/views/wel/home/tongjiSchool.vue

@@ -178,12 +178,39 @@
       </index-card>
       <br />
     </basic-container>
+    <basic-container>
+      <index-card
+        title="人均月工资对比走势图"
+        iconName="el-icon-s-fold"
+        style="height:500px;margin-bottom: 30px"
+      >
+        <div slot="select">
+          <el-date-picker
+            v-model="annual4"
+            type="year"
+            size="mini"
+            placeholder="选择年"
+            value-format="yyyy"
+            style="margin-right:10px"
+            @change="getsalaryAverage"
+          >
+          </el-date-picker>
+        </div>
+        <div slot="content" style="height:450px" id="commoDity3"></div>
+      </index-card>
+      <br />
+    </basic-container>
   </div>
 </template>
 
 <script>
 import { getYearDate } from "@/util/date";
-import { salaryStatistics, salaryData, salaryDataChain } from "@/api/wel";
+import {
+  salaryStatistics,
+  salaryData,
+  salaryDataChain,
+  salaryAverage
+} from "@/api/wel";
 import { mapGetters } from "vuex";
 import indexCard from "../components/card.vue";
 import butCard from "../components/butCard.vue";
@@ -208,9 +235,14 @@ export default {
       annual: "",
       annual2: "",
       annual3: "",
+      annual4: "",
       salaryType: "",
       salaryType2: "",
       salaryType3: "",
+      salaryType4: "",
+      xxList: [],
+      czList: [],
+      gzList: [],
       isHeight: {},
       options: [
         {
@@ -251,7 +283,7 @@ export default {
             // click: function(item) {
             //   // alert(JSON.stringify(item));
             // },
-            title: "工资总额",
+            title: "工资总额",
             count: 0,
             decimals: 2,
             icon: "el-icon-tickets"
@@ -273,7 +305,7 @@ export default {
             // click: function(item) {
             //   // alert(JSON.stringify(item));
             // },
-            title: "人均工资",
+            title: "人均工资",
             count: 0,
             decimals: 2,
             icon: "el-icon-s-finance"
@@ -295,7 +327,7 @@ export default {
             // click: function(item) {
             //   // alert(JSON.stringify(item));
             // },
-            title: "保险总额",
+            title: "保险总额",
             count: 0,
             decimals: 2,
             icon: "el-icon-s-cooperation"
@@ -306,7 +338,7 @@ export default {
             // click: function(item) {
             //   // alert(JSON.stringify(item));
             // },
-            title: "保险总额同比(%)",
+            title: "保险总额同比(%)",
             count: 0,
             decimals: 2,
             icon: "el-icon-notebook-1"
@@ -317,7 +349,7 @@ export default {
             // click: function(item) {
             //   // alert(JSON.stringify(item));
             // },
-            title: "人均保险",
+            title: "人均保险",
             count: 0,
             decimals: 2,
             icon: "el-icon-s-custom"
@@ -328,7 +360,7 @@ export default {
             // click: function(item) {
             //   // alert(JSON.stringify(item));
             // },
-            title: "人均保险同比(%)",
+            title: "人均保险同比(%)",
             count: 0,
             icon: "el-icon-notebook-2"
             // href:'https://avuejs.com',
@@ -342,6 +374,7 @@ export default {
     this.annual = getYearDate().toString();
     this.annual2 = getYearDate().toString();
     this.annual3 = getYearDate().toString();
+    this.annual4 = getYearDate().toString();
     this.isHeight.height = window.innerHeight - 165 + "px";
     this.getWorkDicts("month").then(res => {
       this.moonList = res.data.data;
@@ -351,6 +384,7 @@ export default {
     this.getsalaryStatistics();
     this.getsalaryData();
     this.getsalaryDataChain();
+    this.getsalaryAverage();
   },
   components: {
     indexCard,
@@ -413,6 +447,28 @@ export default {
       this.moon = null;
       this.getsalaryDataChain();
     },
+    getsalaryAverage() {
+      this.xxList = [];
+      this.czList = [];
+      this.gzList = [];
+      salaryAverage({ annual: this.annual4 })
+        .then(res => {
+          res.data.data.forEach(e => {
+            if (e.salaryType == "小学部") {
+              this.xxList.push(Number(e.fsalary));
+            }
+            if (e.salaryType == "初中部") {
+              this.czList.push(Number(e.fsalary));
+            }
+            if (e.salaryType == "高中部") {
+              this.gzList.push(Number(e.fsalary));
+            }
+          });
+        })
+        .finally(() => {
+          this.commoDity3();
+        });
+    },
     getsalaryDataChain() {
       this.yearList = [];
       this.fsalaryList2 = [];
@@ -536,7 +592,7 @@ export default {
           }
         },
         legend: {
-          data: ["工资", "人数", "工资比", "人数比"]
+          data: ["工资", "人数", "工资增加率", "人数增长率"]
         },
         xAxis: {
           type: "category",
@@ -597,7 +653,7 @@ export default {
           },
           {
             type: "value",
-            name: "工资",
+            name: "工资增加率",
             position: "left",
             alignTicks: true,
             axisLine: {
@@ -613,7 +669,7 @@ export default {
           },
           {
             type: "value",
-            name: "工资",
+            name: "工资增加率",
             position: "right",
             alignTicks: true,
             offset: 80,
@@ -643,13 +699,13 @@ export default {
           },
           {
             data: this.fsalaryContrastList,
-            name: "工资",
+            name: "工资增加率",
             yAxisIndex: 2,
             type: "line"
           },
           {
             data: this.studentNumberContrastList,
-            name: "人数",
+            name: "人数增长率",
             yAxisIndex: 3,
             type: "line"
           }
@@ -669,7 +725,7 @@ export default {
           }
         },
         legend: {
-          data: ["工资", "人数", "工资比", "人数比"]
+          data: ["工资", "人数", "工资增加率", "人数增长率"]
         },
         xAxis: {
           type: "category",
@@ -717,7 +773,7 @@ export default {
           },
           {
             type: "value",
-            name: "工资",
+            name: "工资增加率",
             position: "left",
             alignTicks: true,
             axisLine: {
@@ -733,7 +789,7 @@ export default {
           },
           {
             type: "value",
-            name: "工资",
+            name: "工资增加率",
             position: "right",
             alignTicks: true,
             offset: 80,
@@ -763,18 +819,92 @@ export default {
           },
           {
             data: this.fsalaryContrastList2,
-            name: "工资",
+            name: "工资增加率",
             yAxisIndex: 2,
             type: "line"
           },
           {
             data: this.studentNumberContrastList2,
-            name: "人数",
+            name: "人数增长率",
             yAxisIndex: 3,
             type: "line"
           }
         ]
       });
+    },
+    commoDity3() {
+      // 基于准备好的dom,初始化echarts实例,所以只能在mounted中调用
+      let myChart = this.$echarts.init(document.getElementById("commoDity3"));
+      const colors = ["#5470C6", "#91CC75", "#EE6666", "#00008b"];
+      // 绘制图表
+      myChart.setOption({
+        tooltip: {
+          trigger: "axis",
+          axisPointer: {
+            type: "shadow"
+          }
+        },
+        legend: {
+          data: ["小学部", "初中部", "高中部"]
+        },
+        xAxis: {
+          type: "category",
+          data: [
+            "一月",
+            "二月",
+            "三月",
+            "四月",
+            "五月",
+            "六月",
+            "七月",
+            "八月",
+            "九月",
+            "十月",
+            "十一月",
+            "十二月"
+          ]
+        },
+        grid: {
+          left: "3%",
+          right: "4%",
+          bottom: "3%",
+          containLabel: true
+        },
+        yAxis: [
+          {
+            type: "value",
+            name: "人民币",
+            alignTicks: true,
+            axisLine: {
+              show: true,
+              lineStyle: {
+                color: colors[0]
+              },
+              onZero: false
+            },
+            axisLabel: {
+              formatter: "{value} 元"
+            }
+          }
+        ],
+        series: [
+          {
+            data: this.xxList,
+            name: "小学部",
+            type: "bar"
+          },
+          {
+            data: this.czList,
+            name: "初中部",
+            type: "bar"
+          },
+          {
+            data: this.gzList,
+            name: "高中部",
+            type: "bar"
+          }
+        ]
+      });
     }
   }
 };

+ 25 - 0
src/views/workManagement/handoverSheet/config/mainList.json

@@ -46,6 +46,31 @@
       "unlinkPanels": true,
       "searchRange": true,
       "search": true
+    },
+    {
+      "label": "接手人",
+      "prop": "handingUserName",
+      "overHidden": true
+    },
+    {
+      "label": "是否收费",
+      "prop": "chargeStatus",
+      "overHidden": true
+    },
+    {
+      "label": "是否确认",
+      "prop": "confirmStatus",
+      "overHidden": true
+    },
+    {
+      "label": "确认时间",
+      "prop": "confirmTime",
+      "overHidden": true
+    },
+    {
+      "label": "是否外部交接单",
+      "prop": "external",
+      "overHidden": true
     }
   ]
 }

+ 111 - 10
src/views/workManagement/handoverSheet/detail.vue

@@ -19,6 +19,15 @@
           v-if="disabled"
         >编 辑</el-button>
         <el-button
+          v-if="form.id && loginUser === form.handingUser && form.confirmStatus !== 1"
+          type="primary"
+          size="small"
+          class="el-button--small-yh"
+          :loading="btnLoading"
+          @click="submitConfirm"
+          :disabled="!form.id || disabled"
+        >提交确认</el-button>
+        <el-button
           v-if="checker && form.status != 3"
           type="primary"
           size="small"
@@ -35,7 +44,7 @@
         <el-button
           type="primary"
           v-if="!checkDisabled"
-          :disabled="!form.id || disabled"
+          :disabled="!form.id || disabled || form.confirmStatus !== 1"
           size="small"
           @click="pleaseCheck"
           :loading="btnLoading"
@@ -70,9 +79,48 @@
               v-model="form.corpId"
               @getCorpData="getKHData"
               corpType="KH"
-              :disabled="disabled || checkDisabled"
+              :disabled="disabled || checkDisabled || confirmDisabled"
             />
           </template>
+          <template slot="chargeStatus">
+            <el-switch
+              v-model="form.chargeStatus"
+              active-text="是"
+              inactive-text="否"
+              :active-value="1"
+              :inactive-value="0"
+              :disabled="disabled || checkDisabled || confirmDisabled"
+              @change="chargeStatusChange"
+            ></el-switch>
+          </template>
+          <template slot="handingUser">
+            <el-select
+              v-model="form.handingUser"
+              filterable
+              clearable
+              size="small"
+              placeholder="请选择"
+              :disabled="disabled || checkDisabled || form.chargeStatus == 0 || confirmDisabled"
+              @change="handingUserChange"
+            >
+              <el-option
+                v-for="(item,index) in userList"
+                :key="index"
+                :label="item.realName"
+                :value="item.id"
+              ></el-option>
+            </el-select>
+          </template>
+          <template slot="external">
+            <el-switch
+              v-model="form.external"
+              active-text="是"
+              inactive-text="否"
+              :active-value="1"
+              :inactive-value="0"
+              :disabled="disabled || checkDisabled || confirmDisabled"
+            ></el-switch>
+          </template>
         </avue-form>
       </basic-container>
       <containerTitle title="详情内容"/>
@@ -91,7 +139,7 @@
               icon="el-icon-plus"
               size="small"
               @click.stop="newDetails"
-              :disabled="disabled || checkDisabled"
+              :disabled="disabled || checkDisabled || confirmDisabled"
             >录入明细</el-button>
             <el-button
               type="info"
@@ -106,13 +154,13 @@
               icon="el-icon-edit"
               type="text"
               @click="rowCell(row, index)"
-              :disabled="disabled || checkDisabled"
+              :disabled="disabled || checkDisabled || confirmDisabled"
             >{{ row.$cellEdit ? "保存" : "修改" }}</el-button>
             <el-button
               size="small"
               icon="el-icon-upload"
               type="text"
-              :disabled="disabled || checkDisabled"
+              :disabled="disabled || checkDisabled || confirmDisabled"
               @click="annexOpen(row, index)"
             >附件</el-button>
             <el-button
@@ -120,7 +168,7 @@
               icon="el-icon-delete"
               type="text"
               @click="rowDel(row, index)"
-              :disabled="disabled || checkDisabled"
+              :disabled="disabled || checkDisabled || confirmDisabled"
             >删除</el-button>
           </template>
           <template slot="quantity" slot-scope="{ row, index }">
@@ -261,7 +309,8 @@ import {
   removeGoods,
   pleaseCheck,
   saveAttached,
-  getAttachment} from "@/api/standAlone/handoverSheet";
+  getAttachment,
+  submitConfirm} from "@/api/standAlone/handoverSheet";
 import reportDialog from "@/components/report-dialog/main";
 
 export default {
@@ -277,6 +326,13 @@ export default {
     reportDialog
   },
   data() {
+    const validateHandingUser = (rule, value, callback) => {
+      if (this.form.chargeStatus == 1 && !this.form.handingUser) {
+        callback(new Error('接手人不能为空'))
+      } else {
+        callback()
+      }
+    }
     return {
       disabled: false,
       pageLoading: false,
@@ -331,6 +387,24 @@ export default {
             span: 8,
           },
           {
+            label: "是否收费",
+            prop: "chargeStatus",
+            span: 8,
+          },
+          {
+            label: "接手人",
+            prop: "handingUser",
+            span: 8,
+            rules: [
+              {validator: validateHandingUser, trigger: 'change'}
+            ]
+          },
+          {
+            label: "是否外部交接单",
+            prop: "external",
+            span: 8,
+          },
+          {
             label: "交接备注",
             prop: "remarks",
             type: "textarea",
@@ -374,6 +448,7 @@ export default {
       oldForm: {},
       oldDataList: [],
       checkDisabled: false, // 审核状态
+      confirmDisabled: false, // 提交状态
       checker: false,
       checkId: '',
       batchNo:'',
@@ -396,7 +471,7 @@ export default {
       this.userList = res.data.data;
     });
     getUserInfo().then(res => {
-      this.loginUser = res.data.data.realName;
+      this.loginUser = res.data.data.id;
     })
     getDeptTree().then(res => {
       this.dic = res.data.data
@@ -435,7 +510,8 @@ export default {
         this.oldForm = {...this.form};
         this.oldDataList = [...this.dataList];
         this.checkDisabled = this.form.status > 0? true: false;
-        if (this.form.status > 0) {
+        this.confirmDisabled = this.form.confirmStatus === 1? true: false;
+        if (this.form.status > 0 || this.form.confirmStatus === 1) {
           this.option.column.map(e => {
             this.$set(e, 'disabled', true)
           })
@@ -452,7 +528,7 @@ export default {
     openEdit() {
       this.disabled = false;
       this.option.column.map(e => {
-        if (this.checkDisabled) {
+        if (this.checkDisabled || this.confirmDisabled) {
           this.$set(e, 'disabled', true)
         } else {
           if (e.prop != 'serialNo') {
@@ -598,6 +674,7 @@ export default {
       if (this.verification()) {
         const data = {
           id : this.form.id,
+          serialNo: this.form.serialNo,
           checkType: 'jjd',
           url: '/workManagement/handoverSheet/index',
           pageStatus:"this.$store.getters.handOverStatus",
@@ -657,6 +734,30 @@ export default {
         })
       }
     },
+    // 是否收费选择触发
+    chargeStatusChange(data) {
+      if (data === 0) this.form.handingUser = null;
+    },
+    // 接手人选择触发
+    handingUserChange(data) {
+      this.$set(this.form, 'handingUserName', this.userList.find(item => data == item.id).realName);
+    },
+    // 提交确认
+    submitConfirm() {
+      this.$confirm("提交确认?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(() => {
+        this.btnLoading = true
+        submitConfirm({id: this.form.id}).then(res => {
+          this.$message.success('提交成功');
+          this.queryData(this.form.id);
+        }).finally(() => {
+          this.btnLoading = false;
+        })
+      })
+    },
   },
 }
 </script>

+ 13 - 1
src/views/workManagement/handoverSheet/index.vue

@@ -42,7 +42,7 @@
             icon="el-icon-delete"
             size="small"
             @click.stop="rowDel(scope.row, scope.index)"
-            :disabled="scope.row.status == 3"
+            :disabled="scope.row.status == 3 || scope.row.confirmStatus === 1"
           >删除
           </el-button>
         </template>
@@ -55,6 +55,18 @@
         <template slot="serialNo" slot-scope="scope">
           <span style="color: #409EFF;cursor: pointer" @click.stop="beforeOpenPage(scope.row,scope.index)">{{ scope.row.serialNo }}</span>
         </template>
+        <template slot="chargeStatus" slot-scope="scope">
+          <span v-if="scope.row.chargeStatus === 0">否</span>
+          <span v-else>是</span>
+        </template>
+        <template slot="confirmStatus" slot-scope="scope">
+          <span v-if="scope.row.confirmStatus === 0">否</span>
+          <span v-else>是</span>
+        </template>
+        <template slot="external" slot-scope="scope">
+          <span v-if="scope.row.external === 0">否</span>
+          <span v-else>是</span>
+        </template>
       </avue-crud>
     </basic-container>
     <detail-page

+ 8 - 0
src/views/workManagement/requisition/config/commodity.json

@@ -92,6 +92,14 @@
       "index": 9,
       "minWidth": 80,
       "overHidden": true
+    },
+    {
+      "label": "库区",
+      "prop": "storageId",
+      "search": false,
+      "index": 10,
+      "minWidth": 80,
+      "overHidden": true
     }
   ]
 }

+ 31 - 19
src/views/workManagement/requisition/detail.vue

@@ -146,6 +146,7 @@
                 size="small"
                 style="width:60%"
                 @change="codeChange(row, index)"
+                disabled
               >
                 <el-option
                   v-for="item in goodsoptions"
@@ -172,6 +173,7 @@
                 filterable
                 style="width:60%"
                 @change="cnameChange(row, index)"
+                disabled
               >
                 <el-option
                   v-for="item in goodsoptions"
@@ -238,21 +240,20 @@
             <span>{{ row.storageQuantity | IntegerFormat }}</span>
           </template>
           <template slot="storageId" slot-scope="{ row, index }">
-            <el-select
-              v-if="row.$cellEdit"
-              v-model="row.storageId"
-              filterable
-              clearable
-              @change="storageChange(row)"
-            >
-              <el-option
-                v-for="(item, index) in storageOptions"
-                :key="index"
-                :value="item.id"
-                :label="item.cname"
-              ></el-option>
-            </el-select>
-            <span v-else>{{ row.storageName }}</span>
+            <span>{{ row.storageId | storageFormat(storageOptions) }}</span>
+<!--            <el-select-->
+<!--              v-model="row.storageId"-->
+<!--              filterable-->
+<!--              @change="storageChange(row)"-->
+<!--              disabled-->
+<!--            >-->
+<!--              <el-option-->
+<!--                v-for="(item, index) in storageOptions"-->
+<!--                :key="index"-->
+<!--                :value="item.id"-->
+<!--                :label="item.cname"-->
+<!--              ></el-option>-->
+<!--            </el-select>-->
           </template>
           <template slot="remarks" slot-scope="{ row, index }">
             <el-input
@@ -321,6 +322,9 @@
                 >移除
                 </el-button>
               </template>
+              <template slot="storageId" slot-scope="scope">
+                <span>{{scope.row.storageId | storageFormat(storageOptions)}}</span>
+              </template>
             </avue-crud>
       </span>
 
@@ -611,6 +615,9 @@ export default {
     },
     decimalFormat(num) {
       return num ? Number(num).toFixed(2) : "0.00";
+    },
+    storageFormat(row, storageOptions) {
+      return row = storageOptions.find(item => item.id == row).cname
     }
   },
   methods: {
@@ -757,6 +764,7 @@ export default {
           row.unit = e.unit;
           row.priceCategory = e.goodsTypeName;
           row.price = e.unitPrice;
+          row.storageId = e.storageId;
         }
       });
     },
@@ -771,6 +779,7 @@ export default {
           row.unit = e.unit;
           row.priceCategory = e.goodsTypeName;
           row.price = e.unitPrice;
+          row.storageId = e.storageId;
         }
       });
     },
@@ -908,6 +917,7 @@ export default {
                 item.unit = e.unit;
                 item.priceCategory = e.goodsTypeName;
                 item.price = e.unitPrice;
+                item.storageId = e.storageId;
                 item.$cellEdit = true;
               }
             });
@@ -926,8 +936,9 @@ export default {
               price: e.unitPrice,
               amount: 0,
               orderQuantity: 0,
-              storageId: this.storageOptions.length > 0? this.storageOptions[0].id: null,
-              storageName: this.storageOptions.length > 0? this.storageOptions[0].cname: null,
+              storageId: e.storageId,
+              // storageId: this.storageOptions.length > 0? this.storageOptions[0].id: null,
+              // storageName: this.storageOptions.length > 0? this.storageOptions[0].cname: null,
               $cellEdit: true
             });
           });
@@ -943,8 +954,9 @@ export default {
               amount: 0,
               orderQuantity: 0,
               price: e.unitPrice,
-              storageId: this.storageOptions.length > 0? this.storageOptions[0].id: null,
-              storageName: this.storageOptions.length > 0? this.storageOptions[0].cname: null,
+              // storageId: this.storageOptions.length > 0? this.storageOptions[0].id: null,
+              // storageName: this.storageOptions.length > 0? this.storageOptions[0].cname: null,
+              storageId: e.storageId,
               $cellEdit: true
             });
           });

+ 0 - 1
src/views/workManagement/warehousing/detail.vue

@@ -239,7 +239,6 @@
               v-if="row.$cellEdit"
               v-model="row.storageId"
               filterable
-              clearable
               @change="storageChange(row)"
             >
               <el-option