Browse Source

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

QuKatie 3 years ago
parent
commit
6365617654

+ 7 - 2
src/components/fee-info/main.vue

@@ -323,7 +323,10 @@ export default {
     srcType: {
       type: Number,
       default: 2,
-    }
+    },
+    corpId: {
+      type: String
+    },
   },
   filters: {
     isPercentage(val) {
@@ -514,8 +517,10 @@ export default {
     },
     //新增
     rowAdd() {
+      if (!this.corpId) return this.$message.error('请选择往来单位')
       const params = {
-        feesType:this.selectTab
+        feesType:this.selectTab,
+        corpId: this.corpId
       }
       this.$refs.feeCrud.rowCellAdd(params);
     },

+ 8 - 0
src/components/finance/config/option.json

@@ -17,6 +17,14 @@
   "delBtn": true,
   "menuWidth": 80,
   "searchLabelWidth": 130,
+  "showSummary": true,
+  "summaryText": "合计",
+  "sumColumnList": [
+    {
+      "name": "amount",
+      "type": "sum"
+    }
+  ],
   "column": [
     {
       "label": "合同号",

+ 32 - 17
src/components/finance/financialAccount.vue

@@ -110,6 +110,7 @@
   import {applyLoan, paymentApply} from "@/api/financialManagement/paymentRequest";
   import option from "./config/option.json"
   import {getUserInfo} from "@/api/system/user";
+
   export default {
     name: "financialAccount",
     props: {
@@ -126,6 +127,15 @@
         type: Array,
         default: []
       },
+      checkData: {
+        type: Object,
+        default: {
+          url: null,
+          pageStatus: null,
+          pageLabel: null,
+          checkType: null
+        },
+      },
     },
     data(){
       return {
@@ -255,11 +265,15 @@
         this.submitButton = true
         const itemsList = this.data.map(item => {
           item.corpId = this.corpId;
-          item.tradeType = this.billData.optionType
-          item.srcType = 1
+          item.tradeType = this.billData.optionType?this.billData.optionType: item.tradeType
+          // item.srcType = 1
           return item
         })
         const params = {
+          url: this.checkData.url,
+          pageStatus: this.checkData.pageStatus,
+          pageLabel: this.checkData.pageLabel,
+          checkType: this.checkData.checkType,
           billType : this.billType,
           DC : this.billData.itemType === "采购"?"C":"D",     //账单明细会根据D C区分采购 销售搜索
           itemsList: itemsList
@@ -271,21 +285,22 @@
               this.$message.success("操作成功!")
               this.$emit("choceFun");
               //跳转付款申请页面
-              if(this.$store.getters.pqStatus){
-                this.$alert("无法自动跳,因为付费申请页面已存在!", "温馨提示", {
-                  confirmButtonText: "确定",
-                  type: 'warning',
-                  callback: action => {
-                  }
-                });
-              }else{
-                //关闭一下存在的列表页  跳转
-                this.$router.$avueRouter.closeTag('/financialManagement/paymentRequest/index');
-                this.$router.push({
-                  path: "/financialManagement/paymentRequest/index",
-                  query: {params: res.data.data.id},
-                });
-              }
+
+              // if(this.$store.getters.pqStatus){
+              //   this.$alert("无法自动跳,因为付费申请页面已存在!", "温馨提示", {
+              //     confirmButtonText: "确定",
+              //     type: 'warning',
+              //     callback: action => {
+              //     }
+              //   });
+              // }else{
+              //   //关闭一下存在的列表页  跳转
+              //   this.$router.$avueRouter.closeTag('/financialManagement/paymentRequest/index');
+              //   this.$router.push({
+              //     path: "/financialManagement/paymentRequest/index",
+              //     query: {params: res.data.data.id},
+              //   });
+              // }
             }
           }).finally(()=>{
             this.submitButton = false

+ 33 - 10
src/views/businessManagement/deliveryNotice/detailsPageEdit.vue

@@ -99,6 +99,14 @@
                 </el-select>
                 <warehouse-select v-else-if="item.prop === 'storageId'" v-model="form[item.prop]"
                                  :configuration="configurationWarehouse" style="width: 100%" :disabled="detailData.seeDisabled || arrivalDisabled || deliverDisabled"/>
+                <el-select v-else-if="item.prop === 'chargeMember'"
+                           v-model="form[item.prop]" placeholder="请选择"
+                           filterable
+                           size="small"
+                           style="width: 100%;"
+                           :disabled="detailData.seeDisabled">
+                  <el-option v-for="(item,index) in userList" :key="index" :label="item.realName" :value="item.realName"></el-option>
+                </el-select>
                 <el-input
                   v-else-if="item.type == 'number'"
                   placeholder="请输入"
@@ -474,6 +482,7 @@ import {
   IntegerFormat
 } from "@/util/validate";
 import reportDialog from "@/components/report-dialog/main";
+import { gainUser } from "@/api/basicData/customerInquiry";
 
 export default {
   name: "detailsPage",
@@ -806,6 +815,16 @@ export default {
               }
             ]
           },{
+            label: '业务员',
+            prop: 'chargeMember',
+            rules: [
+              {
+                required: false,
+                message: ' ',
+                trigger: 'change'
+              }
+            ]
+          },{
             label: "备注",
             span: 24,
             type: 'textarea',
@@ -850,6 +869,7 @@ export default {
       // 确认到货禁用
       arrivalDisabled: false,
       switchDialog: false,
+      userList: [],
     }
   },
   mounted() {
@@ -910,6 +930,9 @@ export default {
     selectWareHouse().then(res => {
       this.warehouseName = res.data.data.records
     })
+    gainUser().then(res => {
+      this.userList = res.data.data;
+    });
     if (this.detailData.id) {
       let id = this.detailData.id
       this.queryData(id)
@@ -1147,7 +1170,7 @@ export default {
             })
           })
         } else if (type == '到货') {
-          if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+          if (this.goodsActives == 'gift') {
             this.form.deliveryItemsList = this.goodsShowData.concat(this.contactsData)
           } else {
             this.form.deliveryItemsList = this.goodsShowData.concat(this.giftData)
@@ -1587,7 +1610,7 @@ export default {
           this.contactsData.forEach(item => {
             this.$set(item, 'contractAmount', item.deliveryAmount)
           })
-          if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+          if (this.goodsActives == 'gift') {
             this.form.deliveryItemsList = this.goodsShowData.concat(this.contactsData)
           } else {
             this.form.deliveryItemsList = this.goodsShowData.concat(this.giftData)
@@ -1635,7 +1658,7 @@ export default {
       let getGoodsList = []
       let getGiftList = []
       let getFeeList = this.$refs.feeInfo.submitData()
-      if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+      if (this.goodsActives == 'gift') {
         getGiftList = this.goodsShowData
         getGoodsList = this.contactsData
       } else {
@@ -1671,7 +1694,7 @@ export default {
           let getGoodsList = []
           let getGiftList = []
           let getFeeList = this.$refs.feeInfo.submitData()
-          if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+          if (this.goodsActives == 'gift') {
             getGiftList = this.goodsShowData
             getGoodsList = this.contactsData
           } else {
@@ -1695,7 +1718,7 @@ export default {
             })
           } else {
             //商品信息
-            if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+            if (this.goodsActives == 'gift') {
               this.form.deliveryItemsList = this.goodsShowData.concat(this.contactsData)
             } else {
               this.form.deliveryItemsList = this.goodsShowData.concat(this.giftData)
@@ -1724,7 +1747,7 @@ export default {
       this.$refs["form"].validate((valid) => {
         if (valid) {
           //商品信息
-          if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+          if (this.goodsActives == 'gift') {
             this.form.deliveryItemsList = this.goodsShowData.concat(this.contactsData)
           } else {
             this.form.deliveryItemsList = this.goodsShowData.concat(this.giftData)
@@ -1752,7 +1775,7 @@ export default {
       let getGoodsList = []
       let getGiftList = []
       let getFeeList = this.$refs.feeInfo.submitData()
-      if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+      if (this.goodsActives == 'gift') {
         getGiftList = this.goodsShowData
         getGoodsList = this.contactsData
       } else {
@@ -1775,7 +1798,7 @@ export default {
           this.$message.info('已取消')
         })
       } else {
-        if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+        if (this.goodsActives == 'gift') {
           this.form.deliveryItemsList = this.goodsShowData.concat(this.contactsData)
         } else {
           this.form.deliveryItemsList = this.goodsShowData.concat(this.giftData)
@@ -1792,7 +1815,7 @@ export default {
     },
     // 撤销到货
     cancelArrival() {
-      if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+      if (this.goodsActives == 'gift') {
         this.form.deliveryItemsList = this.goodsShowData.concat(this.contactsData)
       } else {
         this.form.deliveryItemsList = this.goodsShowData.concat(this.giftData)
@@ -1874,7 +1897,7 @@ export default {
       if (inSave) {
         this.$message.success("重置成功");
         //关闭窗口
-        this.$refs.crud.$refs.dialogColumn.columnBox = false;
+        this.$refs.crudContact.$refs.dialogColumn.columnBox = false;
       }
     },
     // 商品表格加色

+ 18 - 10
src/views/businessManagement/purchaseOrder/configuration/mainList.json

@@ -84,6 +84,14 @@
       "overHidden": true
     },
     {
+      "label": "采购金额",
+      "prop": "orderAmount",
+      "search": false,
+      "index": 6,
+      "width": 100,
+      "overHidden": true
+    },
+    {
       "type": "select",
       "dicUrl": "/api/blade-system/dict-biz/dictionary?code=payment_term",
       "props": {
@@ -93,7 +101,7 @@
       "label": "付款方式",
       "prop": "paymentType",
       "search": true,
-      "index": 6,
+      "index": 7,
       "width": 100,
       "overHidden": true
     },
@@ -101,7 +109,7 @@
       "label": "预估运费",
       "prop": "oceanFreight",
       "search": false,
-      "index": 7,
+      "index": 8,
       "width": 100,
       "overHidden": true
     },
@@ -109,7 +117,7 @@
       "label": "包装要求",
       "prop": "packageRemarks",
       "search": true,
-      "index": 8,
+      "index": 9,
       "width": 100,
       "overHidden": true
     },
@@ -117,7 +125,7 @@
       "label": "公司户头",
       "prop": "banksAccountName",
       "search": true,
-      "index": 9,
+      "index": 10,
       "width": 100,
       "overHidden": true
     },
@@ -128,7 +136,7 @@
       "searchRange": true,
       "prop": "businesDate",
       "search": false,
-      "index": 10,
+      "index": 11,
       "width": 100,
       "format": "yyyy-MM-dd",
       "valueFormat": "yyyy-MM-dd",
@@ -139,7 +147,7 @@
       "label": "银行账号",
       "prop": "banks",
       "search": false,
-      "index": 11,
+      "index": 12,
       "width": 100,
       "overHidden": true
     },
@@ -147,7 +155,7 @@
       "label": "系统编号",
       "prop": "sysNo",
       "search": false,
-      "index": 12,
+      "index": 13,
       "width": 100,
       "overHidden": true
     },
@@ -155,7 +163,7 @@
       "label": "来源单号",
       "prop": "orgOrderNo",
       "search": false,
-      "index": 13,
+      "index": 14,
       "width": 100,
       "overHidden": true
     },
@@ -169,7 +177,7 @@
       "label": "制单人",
       "prop": "createUser",
       "search": true,
-      "index": 14,
+      "index": 15,
       "width": 100,
       "overHidden": true
     },
@@ -180,7 +188,7 @@
       "searchRange": true,
       "prop": "createTime",
       "search": true,
-      "index": 15,
+      "index": 16,
       "width": 100,
       "format": "yyyy-MM-dd",
       "valueFormat": "yyyy-MM-dd",

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

@@ -67,7 +67,7 @@
           size="small"
           class="el-button--small-yh"
           type="primary"
-          :disabled="disabled || detailData.seeDisabled || browse"
+          :disabled="disabled || detailData.seeDisabled"
           @click="editCustomer(false)"
           :loading="saveLoading"
         >保 存
@@ -241,6 +241,7 @@
           optionType="GN"
           itemType="采购"
           @beforeFinance="beforeFinance"
+          :corpId="form.corpId"
         />
 <!--        <containerTitle title="费用明细"></containerTitle>-->
 <!--        <basic-container style="margin-bottom: 10px">-->
@@ -492,7 +493,9 @@
     >
       <financial-account
         :billType="billType"
-        :billData="billData"
+        :billData="{}"
+        :arrList="applyPaymentList"
+        :checkData="financeData"
         @choceFun="choceFun"
       >
       </financial-account>
@@ -597,6 +600,7 @@ import financialAccount from "../../../components/finance/financialAccount";
 import reportDialog from "@/components/report-dialog/main";
 import check from "@/components/check/check";
 import checkSchedule from "@/components/check/checkSchedule";
+import { customerList as feeList } from "@/api/basicData/basicFeesDesc";
 
 export default {
   name: "detailsPage",
@@ -711,6 +715,7 @@ export default {
       },
       billType:"申请",  //账单类型
       billData:{},     //账单需要数据
+      financeData: {}, // 账单请核需要的路由
       applyPaymentDialog:false,//生成账单组件
       applicationDialog: false,// 申请记录
       dialogVisible: false,
@@ -775,7 +780,7 @@ export default {
             prop: 'packageRemarks',
             rules: [
               {
-                required: true,
+                required: false,
                 message: ' ',
                 trigger: 'blur'
               }
@@ -889,6 +894,8 @@ export default {
       checkScheduleDialog: false,
       checkId: '',
       batchNo:'',
+      feesOption: [],
+      applyPaymentList: [],
     }
   },
   mounted() {
@@ -917,6 +924,9 @@ export default {
     this.getWorkDicts("packageRemarks").then(res => {
       this.packageOptions = res.data.data;
     });
+    feeList().then(res => {
+      this.feesOption = res.data.data.records
+    })
     if (this.detailData.check) {
       this.checkDisabled = true
       this.batchNo = this.detailData.check.batchNo
@@ -1016,6 +1026,8 @@ export default {
         if (isCopy) {
           delete this.form.sysNo;
           delete this.form.id
+          this.form.status = 0
+          this.browse = false
           this.contactsData.forEach(item => {
             delete item.id
             delete item.pid
@@ -1547,7 +1559,15 @@ export default {
       });
     },
     beforeBillData(bool,type){
+      this.applyPaymentList = [];
+      let arr = [];
       this.billType = type
+      this.financeData = {
+        url:"/financialManagement/paymentRequest/index",
+        pageStatus:"this.$store.getters.pqStatus",
+        pageLabel:"付费申请",
+        checkType: 'ffsq'
+      }
       //采购明细提单号 list
       this.billData = {
         srcOrderno:this.form.orderNo,
@@ -1562,10 +1582,36 @@ export default {
         srcType: 1,
         tradeType: 'GN',
         optionType: 'GN',
-        amount: this.form.orderAmount
+        amount: this.form.orderAmount,
+        costType: this.feesOption.find(e => e.cname == '货款').id
       }
+      arr.push(this.billData)
+      let getFeeList = this.$refs.feeInfo.submitData().filter(item => item.feesType == 2)
+      getFeeList.forEach(item => {
+        let form = {
+          srcOrderno:this.form.orgOrderNo,
+          itemType:"采购",
+          corpsName:item.corpName,
+          corpId: item.corpId,
+          srcParentId: this.form.id,
+          currency: 'CNY',
+          exchangeRate: '1',
+          taxRate: '0',
+          accDate: this.form.businesDate,
+          srcType: 2,
+          tradeType: 'GN',
+          optionType: 'GN',
+          chargeMember: this.form.chargeMember,
+          parentId: this.form.id,
+          amount: item.amount,
+          costType: item.itemId,
+          srcFeesId: item.id,
+        }
+        arr.push(form)
+      })
+      this.applyPaymentList = [...arr]
       if(bool){ //申请货款
-        this.billData.srcId = -1
+        // this.billData.srcId = -1
       }
     },
     // 查看申请记录
@@ -1652,7 +1698,7 @@ export default {
       if (inSave) {
         this.$message.success("重置成功");
         //关闭窗口
-        this.$refs.crud.$refs.dialogColumn.columnBox = false;
+        this.$refs.crudContact.$refs.dialogColumn.columnBox = false;
       }
     },
     returnBack(row) {

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

@@ -113,6 +113,7 @@
         v-if="financialAccountDialog"
         :billType="billType"
         :billData="billData"
+        :checkData="financeData"
         :arrList="applyPaymentList"
         @choceFun="choceFun"
       >
@@ -172,6 +173,12 @@ export default {
       detailData: {},
       billType:"申请",  //账单类型
       billData:{},     //账单需要数据
+      financeData: {
+        url:"/financialManagement/paymentRequest/index",
+        pageStatus:"this.$store.getters.pqStatus",
+        pageLabel:"付费申请",
+        checkType: 'ffsq'
+      }, // 账单请核需要的路由
       applyPaymentDialog:false,//生成账单组件
       financialAccountDialog:false,
       applyPaymentList: [],
@@ -179,8 +186,8 @@ export default {
   },
   async created() {
     this.search.requiredArrivalDate = defaultDate(1)
-    this.option = option
-    // this.option = await this.getColumnData(this.getColumnName(17), option);
+    // this.option = option
+    this.option = await this.getColumnData(this.getColumnName(17), option);
     let i = 0;
     this.option.column.forEach(item => {
       if (item.search) i++
@@ -258,7 +265,6 @@ export default {
     //查询全部
     initData() {
       customerList().then(res => {
-        console.log(this.form);
         const column = this.findObject(this.option.column, "parentId");
         column.dicData = res.data.data.records;
       });

+ 23 - 19
src/views/businessManagement/receipt/detailsPageEdit.vue

@@ -58,44 +58,44 @@
                 <!--                <avue-input-tree v-if="item.prop === 'corpsTypeId'"  leaf-only multiple :props="{label:'title'}" v-model="form[item.prop]" placeholder="请选择内容" type="tree" :dic="dic"-->
                 <!--                ></avue-input-tree>-->
                 <el-date-picker v-if="item.type === 'datetime'" style="width: 100%;" v-model="form[item.prop]"
-                                size="small" type="datetime" placeholder="选择日期" value-format="yyyy-MM-dd HH:mm:ss" :disabled="detailData.seeDisabled"/>
+                                size="small" type="datetime" placeholder="选择日期" value-format="yyyy-MM-dd HH:mm:ss" :disabled="detailData.seeDisabled || receiveDisabled"/>
                 <el-date-picker v-else-if="item.type === 'date'" style="width: 100%;" v-model="form[item.prop]"
                                 size="small" type="date" placeholder="选择日期"
-                                :disabled="detailData.seeDisabled"/>
+                                :disabled="detailData.seeDisabled || receiveDisabled"/>
                 <crop-select
                   v-else-if="item.prop === 'corpId'"
                   v-model="form[item.prop]"
                   corpType="GYS"
-                  :disabled="detailData.seeDisabled"
+                  :disabled="detailData.seeDisabled || receiveDisabled"
                 ></crop-select>
                 <crop-select
                   v-else-if="item.prop === 'salesCompany'"
                   v-model="form[item.prop]"
                   corpType="GS"
-                  :disabled="detailData.seeDisabled"
+                  :disabled="detailData.seeDisabled || receiveDisabled"
                 ></crop-select>
 <!--                <selectComponent v-else-if="item.prop === 'corpId'" v-model="form[item.prop]"-->
 <!--                                 :configuration="configuration" style="width: 100%" :disabled="detailData.seeDisabled"/>-->
 <!--                <selectComponent v-else-if="item.prop === 'salesCompany'" v-model="form[item.prop]"-->
 <!--                                 :configuration="companyConfiguration" style="width: 100%" :disabled="detailData.seeDisabled"/>-->
-                <el-select v-else-if="item.prop === 'purchaseMode'" v-model="form[item.prop]" placeholder="请选择" clearable filterable style="width: 100%" size="small" :disabled="detailData.seeDisabled">
+                <el-select v-else-if="item.prop === 'purchaseMode'" v-model="form[item.prop]" placeholder="请选择" clearable filterable style="width: 100%" size="small" :disabled="detailData.seeDisabled || receiveDisabled">
                   <el-option v-for="(item,index) in procurementMethodOption" :key="index" :label="item.dictValue" :value="item.dictValue"></el-option>
                 </el-select>
-                <el-select v-else-if="item.prop === 'warehouseType'" v-model="form[item.prop]" placeholder="请选择" clearable filterable style="width: 100%" size="small" :disabled="detailData.seeDisabled">
+                <el-select v-else-if="item.prop === 'warehouseType'" v-model="form[item.prop]" placeholder="请选择" clearable filterable style="width: 100%" size="small" :disabled="detailData.seeDisabled || receiveDisabled">
                   <el-option v-for="(item,index) in warehouseTypeOption" :key="index" :label="item.dictValue" :value="item.dictValue"></el-option>
                 </el-select>
                 <warehouse-select v-else-if="item.prop === 'storageId'" v-model="form[item.prop]"
-                                  :configuration="configurationWarehouse" style="width: 100%" :disabled="detailData.seeDisabled"/>
+                                  :configuration="configurationWarehouse" style="width: 100%" :disabled="detailData.seeDisabled || receiveDisabled"/>
                 <el-input
                   v-else-if="item.type == 'number'"
                   placeholder="请输入"
                   v-input-limit="2"
                   size="small"
-                  :disabled="item.disabled || detailData.seeDisabled"
+                  :disabled="item.disabled || detailData.seeDisabled || receiveDisabled"
                   v-model.trim="form[item.prop]"
                 />
-                <el-input type="textarea" v-else-if="item.type === 'textarea'" v-model.trim="form[item.prop]" size="small" autocomplete="off" :disabled="item.disabled || detailData.seeDisabled"></el-input>
-                <el-input type="age" v-else v-model.trim="form[item.prop]" size="small" autocomplete="off" :disabled="item.disabled || detailData.seeDisabled"></el-input>
+                <el-input type="textarea" v-else-if="item.type === 'textarea'" v-model.trim="form[item.prop]" size="small" autocomplete="off" :disabled="item.disabled || detailData.seeDisabled || receiveDisabled"></el-input>
+                <el-input type="age" v-else v-model.trim="form[item.prop]" size="small" autocomplete="off" :disabled="item.disabled || detailData.seeDisabled || receiveDisabled"></el-input>
               </el-form-item>
             </el-col>
           </el-row>
@@ -123,7 +123,7 @@
                   type="text"
                   size="small"
                   @click="rowCell(row,index)"
-                  :disabled="detailData.seeDisabled"
+                  :disabled="detailData.seeDisabled || receiveDisabled"
               >{{ row.$cellEdit ? '保存' : '修改' }}
               </el-button>
               <el-button
@@ -131,7 +131,7 @@
                 icon="el-icon-delete"
                 type="text"
                 @click="rowDel(row, index)"
-                :disabled="detailData.seeDisabled"
+                :disabled="detailData.seeDisabled || receiveDisabled"
                 v-if="!row.$cellEdit"
               >删 除</el-button>
             </template>
@@ -149,7 +149,7 @@
                          icon="el-icon-plus"
                          size="small"
                          @click="commoditySelection"
-                         :disabled="detailData.seeDisabled"
+                         :disabled="detailData.seeDisabled || receiveDisabled"
               >录入明细
               </el-button>
               <el-button type="info" :size="size" icon="el-icon-printer">报 表</el-button>
@@ -159,7 +159,7 @@
         <fee-info
           ref="feeInfo"
           :orderFeesList="advantageProjectData"
-          :disabled="detailData.seeDisabled"
+          :disabled="detailData.seeDisabled || receiveDisabled"
           @beforeFinance="beforeFinance"
           :srcType="3"
           optionType="GN"
@@ -247,7 +247,7 @@
                 icon="el-icon-plus"
                 size="small"
                 @click.stop="$refs.uploadCrud.rowAdd()"
-                :disabled="detailData.seeDisabled"
+                :disabled="detailData.seeDisabled || receiveDisabled"
               >上传</el-button
               >
             </template>
@@ -257,7 +257,7 @@
                 icon="el-icon-edit"
                 type="text"
                 @click="$refs.uploadCrud.rowEdit(row, index)"
-                :disabled="detailData.seeDisabled"
+                :disabled="detailData.seeDisabled || receiveDisabled"
               >编 辑</el-button
               >
               <el-button
@@ -265,7 +265,7 @@
                 icon="el-icon-delete"
                 type="text"
                 @click="rowDelBankOfDeposit(row, index)"
-                :disabled="detailData.seeDisabled"
+                :disabled="detailData.seeDisabled || receiveDisabled"
               >删 除</el-button
               >
             </template>
@@ -705,6 +705,8 @@ export default {
       rowHeight: '',
       // 查询时loading页面
       pageLoading: false,
+      // 收货禁用
+      receiveDisabled: false,
     }
   },
   mounted() {
@@ -816,6 +818,7 @@ export default {
       this.pageLoading = true
       detail(id).then(res => {
         this.form = res.data.data;
+        this.receiveDisabled = this.form.deliveryStatus == '录入'? false: true
         this.contactsData = this.form.deliveryItemsList
         this.advantageProjectData = this.form.deliveryFeesList
         this.bankOfDepositData = this.form.deliveryFilesList
@@ -890,7 +893,8 @@ export default {
             delete item.id
             delete item.pid
           })
-          this.form.deliveryStatus == '录入'
+          this.form.deliveryStatus = '录入'
+          this.receiveDisabled = false;
         }
       }).finally(() => {
         this.saveLoading = false
@@ -1418,7 +1422,7 @@ export default {
       if (inSave) {
         this.$message.success("重置成功");
         //关闭窗口
-        this.$refs.crud.$refs.dialogColumn.columnBox = false;
+        this.$refs.crudContact.$refs.dialogColumn.columnBox = false;
       }
     },
     //费用明细回调

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

@@ -130,6 +130,21 @@
         }
       ]
     },{
+      "label": "质量胎",
+      "prop": "shopQuality",
+      "index": 4,
+      "width":140,
+      "cell": false,
+      "slot": true,
+      "overHidden": true,
+      "rules": [
+        {
+          "required": false,
+          "message": "请选择",
+          "trigger": "blur"
+        }
+      ]
+    },{
       "label": "订货数量",
       "prop": "orderQuantity",
       "index": 5,

+ 76 - 14
src/views/businessManagement/salesOrder/detailsPageEdit.vue

@@ -72,7 +72,7 @@
         <el-button
           class="el-button--small-yh"
           type="primary"
-          :disabled="disabled || detailData.seeDisabled || browse"
+          :disabled="disabled || detailData.seeDisabled"
           :loading="saveLoading"
           size="small"
           @click="editCustomer(false)"
@@ -316,6 +316,15 @@
                 {{row.cname}}
               </span>
             </template>
+            <template slot="shopQuality" slot-scope="{ row, index }">
+              <el-switch
+                v-model="row.shopQuality"
+                :disabled="!row.$cellEdit"
+                :active-value="1"
+                :inactive-value="0"
+                @change="(val) => shopQualityChange(val, row)"
+              ></el-switch>
+            </template>
             <template slot-scope="{row,index}" slot="menu">
               <el-button
                   type="text"
@@ -412,6 +421,7 @@
           optionType="GN"
           itemType="销售"
           @beforeFinance="beforeFinance"
+          :corpId="form.corpId"
         />
 <!--        <containerTitle title="费用明细"></containerTitle>-->
 <!--        <basic-container style="margin-bottom: 10px">-->
@@ -693,8 +703,9 @@
     >
       <apply-payment
         :billType="billType"
-        :billData="billData"
+        :billData="{}"
         itemType="销售"
+        :arrList="applyPaymentList"
         @choceFun="choceFun"
       >
       </apply-payment>
@@ -720,7 +731,8 @@
     >
       <financial-account
         :billType="billType"
-        :billData="billData"
+        :billData="{}"
+        :arrList="applyPaymentList"
         @choceFun="choceFun"
       >
       </financial-account>
@@ -840,6 +852,7 @@ import financialAccount from "../../../components/finance/financialAccount";
 import { gainUser } from "@/api/basicData/customerInquiry";
 import check from "@/components/check/check";
 import checkSchedule from "@/components/check/checkSchedule";
+import { customerList as feeList } from "@/api/basicData/basicFeesDesc";
 
 export default {
   name: "detailsPage",
@@ -1429,7 +1442,7 @@ export default {
             prop: 'packageRemarks',
             rules: [
               {
-                required: false,
+                required: true,
                 message: ' ',
                 trigger: 'change'
               }
@@ -1571,12 +1584,14 @@ export default {
       browse: false,
       roleName: '',
       userList: [],
+      feesOption: [],
       checkDisabled: false,
       checkData: {},
       checkDialog: false,
       checkScheduleDialog: false,
       checkId: '',
       batchNo:'',
+      applyPaymentList: [],
     }
   },
   mounted() {
@@ -1625,6 +1640,9 @@ export default {
     gainUser().then(res => {
       this.userList = res.data.data;
     });
+    feeList().then(res => {
+      this.feesOption = res.data.data.records
+    })
     if (this.detailData.seeDisabled) {
       // this.bankOfDeposit.column.forEach(item => {
       //   item.editDisabled = true
@@ -1737,6 +1755,8 @@ export default {
         this.oldUploadList = this.deepClone(this.bankOfDepositData)
         if (isCopy) {
           this.$set(this.form, 'orderStatus', '录入')
+          this.form.status = 0
+          this.browse = false
           delete this.form.id
           delete this.form.orgOrderNo
           delete this.form.orderNo
@@ -1814,7 +1834,7 @@ export default {
       let getGoodsList = []
       let getGiftList = []
       let getFeeList = this.$refs.feeInfo.submitData()
-      if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+      if (this.goodsActives == 'gift') {
         getGiftList = this.goodsShowData
         getGoodsList = this.contactsData
       } else {
@@ -2004,7 +2024,7 @@ export default {
       let getGoodsList = []
       let getGiftList = []
       let getFeeList = this.$refs.feeInfo.submitData()
-      if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+      if (this.goodsActives == 'gift') {
         getGiftList = this.goodsShowData
         getGoodsList = this.contactsData
       } else {
@@ -2056,7 +2076,7 @@ export default {
       let getGoodsList = []
       let getGiftList = []
       let getFeeList = this.$refs.feeInfo.submitData()
-      if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+      if (this.goodsActives == 'gift') {
         getGiftList = this.goodsShowData
         getGoodsList = this.contactsData
       } else {
@@ -2084,6 +2104,8 @@ export default {
     },
     //生成账单 拿到主表信息
     beforeBillData(bool,type){
+      this.applyPaymentList = [];
+      let arr = [];
       this.billType = type
       this.billData = {
         srcOrderno:this.form.orgOrderNo,
@@ -2099,10 +2121,36 @@ export default {
         tradeType: 'GN',
         optionType: 'GN',
         chargeMember: this.form.chargeMember,
-        amount: this.form.balanceAmount
+        amount: this.form.balanceAmount,
+        costType: this.feesOption.find(e => e.cname == '货款').id
       }
+      arr.push(this.billData)
+      let getFeeList = this.$refs.feeInfo.submitData().filter(item => item.feesType == 1)
+      getFeeList.forEach(item => {
+        let form = {
+          srcOrderno:this.form.orgOrderNo,
+          itemType:"销售",
+          corpsName:this.form.corpName,
+          corpId:this.form.corpId,
+          srcParentId: this.form.id,
+          currency: 'CNY',
+          exchangeRate: '1',
+          taxRate: '0',
+          accDate: this.form.businesDate,
+          srcType: 2,
+          tradeType: 'GN',
+          optionType: 'GN',
+          chargeMember: this.form.chargeMember,
+          parentId: this.form.id,
+          amount: item.amount,
+          costType: item.itemId,
+          srcFeesId: item.id,
+        }
+        arr.push(form)
+      })
+      this.applyPaymentList = [...arr]
       if(bool){ //申请货款
-        this.billData.srcId = -1
+        // this.billData.srcId = -1
       }
     },
     //关闭账单
@@ -2304,6 +2352,7 @@ export default {
           this.$set(this.goodsListSave[item], 'orderQuantity', 1)
           this.$set(this.goodsListSave[item], 'actualQuantity', 0)
           this.$set(this.goodsListSave[item], 'invoiceWeight', this.goodsListSave[item].cartonWeight)
+          this.$set(this.goodsListSave[item], 'shopQuality', 0)
           this.goodsListSave[item].amount = 0
           if (this.goodsActives == "goods") {
             this.$set(this.goodsListSave[item], 'goodType', 0)
@@ -2366,6 +2415,7 @@ export default {
           this.$set(this.tableData[item], 'itemType', this.tableData[item].typeno)
           this.$set(this.tableData[item], 'orderQuantity', 1)
           this.$set(this.tableData[item], 'actualQuantity', 0)
+          this.$set(this.tableData[item], 'shopQuality', 0)
           this.$set(this.tableData[item], 'invoiceWeight', this.tableData[item].cartonWeight)
           this.tableData[item].amount = 0
           if (this.goodsActives == "goods") {
@@ -2535,6 +2585,7 @@ export default {
           // 积分
           this.$set(list[item], 'integralMultiples', 0)
           this.$set(list[item], 'integral', 0)
+          this.$set(list[item], 'shopQuality', 0)
 
           if (listLength != 0) {
             this.$set(buyFree[item], 'actualQuantity', 0)
@@ -2548,6 +2599,7 @@ export default {
             // 积分
             this.$set(buyFree[item], 'integralMultiples', 0)
             this.$set(buyFree[item], 'integral', 0)
+            this.$set(buyFree[item], 'shopQuality', 0)
             this.maxGoodsNum++
             delete buyFree[item].id
             delete buyFree[item].pid
@@ -2786,7 +2838,7 @@ export default {
       this.$refs["form"].validate((valid) => {
         if (valid) {
           //商品信息
-          if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+          if (this.goodsActives == 'gift') {
             this.form.orderItemsList = this.goodsShowData.concat(this.contactsData)
           } else {
             this.form.orderItemsList = this.goodsShowData.concat(this.giftData)
@@ -2945,6 +2997,7 @@ export default {
     priceChange(row) {
       if (!row.price) {
         row.price = 0;
+        row.amount = '0.00'
       } else {
         row.amount = (row.price * row.orderQuantity).toFixed(2)
       }
@@ -2962,7 +3015,7 @@ export default {
       let getGoodsList = []
       let getGiftList = []
       let getFeeList = this.$refs.feeInfo.submitData()
-      if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+      if (this.goodsActives == 'gift') {
         getGiftList = this.goodsShowData
         getGoodsList = this.contactsData
       } else {
@@ -3020,7 +3073,7 @@ export default {
       if (inSave) {
         this.$message.success("重置成功");
         //关闭窗口
-        this.$refs.crud.$refs.dialogColumn.columnBox = false;
+        this.$refs.crudContact.$refs.dialogColumn.columnBox = false;
       }
     },
     returnBack(row) {
@@ -3185,8 +3238,9 @@ export default {
     },
     // 请核
     pleaseCheck() {
+      const giftList = this.goodsActives == 'gift'? this.goodsShowData: this.giftData
       if (this.verification()) {
-        this.$confirm("您确定提交此次申请吗?", {
+        this.$confirm(giftList.length == 0?"此单没有赠品,确定提交此次审批吗?": "您确定提交此次申请吗?", {
           confirmButtonText: "确定",
           cancelButtonText: "取消",
           type: "warning"
@@ -3217,13 +3271,17 @@ export default {
       let getGoodsList = []
       let getGiftList = []
       let getFeeList = this.$refs.feeInfo.submitData()
-      if (this.goodsShowData.findIndex(item => item.goodType == 0) == -1) {
+      // this.goodsShowData.findIndex(item => item.goodType == 0) == -1
+      if (this.goodsActives == 'gift') {
         getGiftList = this.goodsShowData
         getGoodsList = this.contactsData
       } else {
+        console.log(this.giftData)
         getGoodsList = this.goodsShowData
         getGiftList = this.giftData
       }
+      console.log(getGiftList)
+      console.log(this.oldGiftList)
       if (contrastObj(this.form, this.oldForm) ||
         contrastList(getGoodsList, this.oldGoodsList) ||
         contrastList(getGiftList, this.oldGiftList) ||
@@ -3255,6 +3313,10 @@ export default {
     choceScheduleFun(){
       this.checkScheduleDialog = false
     },
+    shopQualityChange(val, row) {
+      (val == 1) && (row.price = 0)
+      this.priceChange(row)
+    },
   },
 }
 </script>

+ 24 - 2
src/views/salesManagement/salesContract/detailsPage.vue

@@ -353,6 +353,25 @@
       </apply-payment>
     </el-dialog>
     <el-dialog
+      append-to-body
+      title="账单"
+      class="el-dialogDeep"
+      :visible.sync="financialAccountDialog"
+      width="70%"
+      :close-on-click-modal="false"
+      :destroy-on-close="true"
+      :close-on-press-escape="false"
+      v-dialog-drag
+    >
+      <financial-account
+        :billType="billType"
+        :billData="billData"
+        @choceFun="choceFun"
+      >
+      </financial-account>
+    </el-dialog>
+
+    <el-dialog
       title="收款记录"
       append-to-body
       class="el-dialogDeep"
@@ -385,6 +404,7 @@ import { contrastObj,contrastList } from "@/util/contrastData";
 import _ from "lodash";
 import { isPercentage,roundNumbers } from "@/util/validate";
 //账单组件
+import financialAccount from "../../../components/finance/financialAccount";
 import ApplyPayment from "../../../components/finance/applyPayment";
 import  billApplication from "@/components/bill/billApplication";
 
@@ -406,6 +426,7 @@ export default {
   components: {
     ApplyPayment,
     feeInfo,
+    financialAccount,
     uploadFile,
     billApplication
   },
@@ -415,6 +436,7 @@ export default {
       buttonLoading:false,
       dialogCommodity: false,
       applySettlementDialog:false,
+      financialAccountDialog:false,
       applicationDialog:false,
       viewDisabled:false,
       takeDisabled:false,
@@ -838,11 +860,11 @@ export default {
     applySettlement(type){
       if(this.verificationData()){
         this.beforeBillData(true,type)
-        this.applySettlementDialog = true;
+        this.financialAccountDialog = true;
       }
     },
     choceFun(){
-      this.applySettlementDialog  = false
+      this.financialAccountDialog  = false
     },
     //刷新
     payeeRefreshChange(){

+ 3 - 0
src/views/wel/components/audit-data.vue

@@ -51,6 +51,9 @@ export default {
   },
   methods: {
     init(){
+      if(this.sysType === 3){
+
+      }
       if(this.sysType === 5){
         this.list = [
           { icon: "el-icon-s-order", qty: "0", text: "主营业务/待审核" },

+ 82 - 22
src/views/wel/components/quick-launch.vue

@@ -6,60 +6,92 @@
           快速发起
         </span>
       </div>
-      <div class="content">
-        <div class="content-icon" v-if="sysType !== 5" @click="inPage('xs')">
-          <i class="tradingIcon icon-sales" style="color:#409EFF"></i>
-          <span>销售</span>
-        </div>
-        <div class="content-icon" v-if="sysType !== 5" @click="inPage('cg')">
+      <div class="content" v-if="sysType == 3">
+        <div class="content-icon"  @click="inPage('cg')">
           <i class="tradingIcon icon-purchase" style="color:#75CD28"></i>
           <span>采购</span>
         </div>
-        <div class="content-icon" v-if="sysType !== 5" @click="inPage('fh')">
-          <i class="tradingIcon icon-ship" style="color:#143056"></i>
-          <span>发货</span>
+        <div class="content-icon"  @click="inPage('xs')">
+          <i class="tradingIcon icon-sales" style="color:#409EFF"></i>
+          <span>销售</span>
         </div>
-        <div class="content-icon" v-if="sysType !== 5" @click="inPage('sh')">
+        <div class="content-icon"  @click="inPage('sh')">
           <i class="tradingIcon icon-receipt" style="color:#921939"></i>
           <span>收货</span>
         </div>
-        <div class="content-icon" v-if="sysType !== 5" @click="inPage('sqfk')">
+        <div class="content-icon"  @click="inPage('fh')">
+          <i class="tradingIcon icon-ship" style="color:#143056"></i>
+          <span>发货</span>
+        </div>
+        <div class="content-icon"  @click="inPage('sqfk')">
           <i class="tradingIcon icon-apply" style="color:#BE3216"></i>
           <span>申请付款</span>
         </div>
-        <div class="content-icon" v-if="sysType !== 5" @click="inPage('sf')">
-          <i class="tradingIcon icon-charge" style="color:#4D6016"></i>
-          <span>收费</span>
-        </div>
-        <div class="content-icon" v-if="sysType !== 5" @click="inPage('ff')">
+        <div class="content-icon"  @click="inPage('ff')">
           <i class="tradingIcon icon-pay" style="color:#7E8270"></i>
           <span>付费</span>
         </div>
-        <div class="content-icon" v-if="sysType === 5" @click="inPage('zy')">
+        <div class="content-icon"  @click="inPage('sf')">
+          <i class="tradingIcon icon-charge" style="color:#4D6016"></i>
+          <span>收费</span>
+        </div>
+      </div>
+      <div class="content" v-if="sysType == 5">
+        <div class="content-icon"  @click="inPage('zy')">
           <i class="tradingIcon icon-pay" style="color:#57927a"></i>
           <span>主营业务</span>
         </div>
-        <div class="content-icon" v-if="sysType === 5" @click="inPage('yf')">
+        <div class="content-icon"  @click="inPage('yf')">
           <i class="tradingIcon icon-pay" style="color:#576892"></i>
           <span>业绩分析</span>
         </div>
-        <div class="content-icon" v-if="sysType === 5" @click="inPage('tj')">
+        <div class="content-icon"  @click="inPage('tj')">
           <i class="tradingIcon icon-pay" style="color:#57927a"></i>
           <span>统计列表</span>
         </div>
-        <div class="content-icon" v-if="sysType === 5" @click="inPage('fw')">
+        <div class="content-icon"  @click="inPage('fw')">
           <i class="tradingIcon icon-pay" style="color:#576892"></i>
           <span>服务项目</span>
         </div>
-        <div class="content-icon" v-if="sysType === 5" @click="inPage('sp')">
+        <div class="content-icon"  @click="inPage('sp')">
           <i class="tradingIcon icon-pay" style="color:#57927a"></i>
           <span>商品信息</span>
         </div>
-        <div class="content-icon" v-if="sysType === 5" @click="inPage('fy')">
+        <div class="content-icon"  @click="inPage('fy')">
           <i class="tradingIcon icon-pay" style="color:#576892"></i>
           <span>费用详情</span>
         </div>
       </div>
+      <div class="content" v-if="sysType == 4 || sysType == 2 ">
+        <div class="content-icon"  @click="inPage('xs')">
+          <i class="tradingIcon icon-sales" style="color:#409EFF"></i>
+          <span>销售</span>
+        </div>
+        <div class="content-icon"  @click="inPage('cg')">
+          <i class="tradingIcon icon-purchase" style="color:#75CD28"></i>
+          <span>采购</span>
+        </div>
+        <div class="content-icon"  @click="inPage('fh')">
+          <i class="tradingIcon icon-ship" style="color:#143056"></i>
+          <span>发货</span>
+        </div>
+        <div class="content-icon"  @click="inPage('sh')">
+          <i class="tradingIcon icon-receipt" style="color:#921939"></i>
+          <span>收货</span>
+        </div>
+        <div class="content-icon"  @click="inPage('sqfk')">
+          <i class="tradingIcon icon-apply" style="color:#BE3216"></i>
+          <span>付费申请</span>
+        </div>
+        <div class="content-icon"  @click="inPage('sf')">
+          <i class="tradingIcon icon-charge" style="color:#4D6016"></i>
+          <span>收费</span>
+        </div>
+        <div class="content-icon"  @click="inPage('ff')">
+          <i class="tradingIcon icon-pay" style="color:#7E8270"></i>
+          <span>付费</span>
+        </div>
+      </div>
     </el-card>
   </div>
 </template>
@@ -132,6 +164,34 @@ export default {
             );
             break;
         }
+      }else if (this.sysType == 3) {
+        switch (type) {
+          case "xs":
+            this.$router.push("/salesManagement/salesContract/index");
+            break;
+          case "cg":
+            this.$router.push("/purchase/contract/index");
+            break;
+          case "fh":
+            this.$router.push("/importTrade/invoice/index");
+            break;
+          case "sh":
+            this.$router.push("/importTrade/receipt/index");
+            break;
+          case "sqfk":
+            this.$router.push("/financialManagement/paymentRequest/index");
+            break;
+          case "sf":
+            this.$router.push(
+              "/financialManagement/receiptSettle/receiptSettle"
+            );
+            break;
+          case "ff":
+            this.$router.push(
+              "/financialManagement/paymentSettle/paymentSettle"
+            );
+            break;
+        }
       }else if (this.sysType == 5) {
         switch (type) {
           case "zy":