Ver código fonte

财务收款

chenrui 3 anos atrás
pai
commit
217ed65b9d

+ 32 - 32
src/views/financialManagement/financialCollection/list.vue

@@ -12,7 +12,7 @@
             </a-col>
             <a-col :md="6" :sm="24">
               <a-form-item label="经销商名称">
-                <a-input id="financialCollectionList-buyerName" v-model.trim="queryParam.buyerName" allowClear placeholder="请输入经销商名称"/>
+                <a-input id="financialCollectionList-settleClientName" v-model.trim="queryParam.settleClientName" allowClear placeholder="请输入经销商名称"/>
               </a-form-item>
             </a-col>
             <a-col :md="6" :sm="24">
@@ -30,9 +30,9 @@
               <a-col :md="6" :sm="24">
                 <a-form-item label="收款方式">
                   <v-select
-                    v-model="queryParam.settleStyleSn"
-                    ref="settleStyleSn"
-                    id="financialCollectionList-settleStyleSn"
+                    v-model="queryParam.settleStyle"
+                    ref="settleStyle"
+                    id="financialCollectionList-settleStyle"
                     code="SETTLE_STYLE"
                     placeholder="请选择收款方式"
                     allowClear></v-select>
@@ -57,9 +57,9 @@
               <a-col :md="6" :sm="24">
                 <a-form-item label="财务状态">
                   <v-select
-                    v-model="queryParam.financialStatus"
-                    ref="financialStatus"
-                    id="financialCollectionList-financialStatus"
+                    v-model="queryParam.settleState"
+                    ref="settleState"
+                    id="financialCollectionList-settleState"
                     code="FINANCIAL_RECEIVE_STATUS"
                     placeholder="请选择财务状态"
                     allowClear></v-select>
@@ -139,7 +139,7 @@
           <a-button
             size="small"
             type="link"
-            v-if="record.financialStatus=='WAIT' && $hasPermissions('B_financialCollection_receipt')"
+            v-if="record.settleState=='WAIT' && record.voidFlag==0 && $hasPermissions('B_financialCollection_receipt')"
             class="button-warning"
             @click="handleAudit(record)"
             id="financialCollectionList-audit-btn">收款</a-button>
@@ -165,16 +165,16 @@ export default {
       spinning: false,
       tableHeight: 0,
       queryParam: { //  查询条件
-        beginAuditDate: getDate.getThreeMonthDays().starttime,
-        endAuditDate: getDate.getCurrMonthDays().endtime,
-        beginSettleDate: '',
-        endSettleDate: '',
-        buyerName: '',
+        beginDate: getDate.getThreeMonthDays().starttime + ' 00:00:00',
+        endDate: getDate.getCurrMonthDays().endtime + ' 23:59:59',
+        beginDateSettle: '',
+        endDateSettle: '',
+        settleClientName: '',
         dealerLevel: undefined,
-        settleStyleSn: undefined,
+        settleStyle: undefined,
         subareaSn: undefined,
         billStatus: undefined,
-        financialStatus: undefined,
+        settleState: undefined,
         dealerProvinceSn: undefined,
         dealerCitySn: undefined,
         dealerCountySn: undefined
@@ -190,14 +190,14 @@ export default {
         { title: '销售单号', scopedSlots: { customRender: 'bizNo' }, width: '10%', align: 'center' },
         { title: '备货单号', scopedSlots: { customRender: 'dispatchBillNo' }, width: '10%', align: 'center' },
         { title: '经销商名称', dataIndex: 'settleClientName', align: 'left', width: '9%', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '商户级别', dataIndex: 'dealerEntity.dealerLevelDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '销售数量', dataIndex: 'totalQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '商户级别', dataIndex: 'dealerLevelDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '销售数量', dataIndex: 'qty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '销售金额', dataIndex: 'totalAmount', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '收款时间', dataIndex: 'settleTime', width: '9%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '收款方式', dataIndex: 'settleStyleSnDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '收款方式', dataIndex: 'settleStyleDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '备注', dataIndex: 'remark', width: '7%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '业务状态', dataIndex: 'billStatusDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '财务状态', dataIndex: 'financialStatusDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '财务状态', dataIndex: 'settleStateDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单据状态', dataIndex: 'voidFlag', scopedSlots: { customRender: 'voidFlag' }, width: '6%', align: 'center' },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '4%', align: 'center' }
       ],
@@ -226,13 +226,13 @@ export default {
   methods: {
     //  审核时间  change
     dateAuditChange (date) {
-      this.queryParam.beginAuditDate = date[0]
-      this.queryParam.endAuditDate = date[1]
+      this.queryParam.beginDate = date[0] ? date[0] + ' 00:00:00' : ''
+      this.queryParam.endDate = date[1] ? date[1] + ' 23:59:59' : ''
     },
     //  收款时间  change
     dateSettleChange (date) {
-      this.queryParam.beginSettleDate = date[0]
-      this.queryParam.endSettleDate = date[1]
+      this.queryParam.beginDateSettle = date[0] ? date[0] + ' 00:00:00' : ''
+      this.queryParam.endDateSettle = date[1] ? date[1] + ' 23:59:59' : ''
     },
     //  重置
     resetSearchForm () {
@@ -240,16 +240,16 @@ export default {
       if (this.advanced) { //  查询条件未展开时,该组件未渲染
         this.$refs.rangeSettleDate.resetDate()
       }
-      this.queryParam.beginAuditDate = getDate.getThreeMonthDays().starttime
-      this.queryParam.endAuditDate = getDate.getCurrMonthDays().endtime
-      this.queryParam.beginSettleDate = ''
-      this.queryParam.endSettleDate = ''
-      this.queryParam.buyerName = ''
+      this.queryParam.beginDate = getDate.getThreeMonthDays().starttime + ' 00:00:00'
+      this.queryParam.endDate = getDate.getCurrMonthDays().endtime + ' 23:59:59'
+      this.queryParam.beginDateSettle = ''
+      this.queryParam.endDateSettle = ''
+      this.queryParam.settleClientName = ''
       this.queryParam.dealerLevel = undefined
-      this.queryParam.settleStyleSn = undefined
+      this.queryParam.settleStyle = undefined
       this.queryParam.subareaSn = undefined
       this.queryParam.billStatus = undefined
-      this.queryParam.financialStatus = undefined
+      this.queryParam.settleState = undefined
       this.queryParam.dealerProvinceSn = undefined
       this.queryParam.dealerCitySn = undefined
       this.queryParam.dealerCountySn = undefined
@@ -257,7 +257,7 @@ export default {
     },
     // 详情
     handleDetail (row) {
-      this.$router.push({ name: 'salesDetail', params: { sn: row.salesBillSn } })
+      this.$router.push({ name: 'salesDetail', params: { sn: row.bizSn } })
     },
     handleBhDetail (row) {
       this.$router.push({ name: 'pushOrderDetail', params: { sn: row.dispatchBillSn, type: 'financialCollection' } })
@@ -271,7 +271,7 @@ export default {
         centered: true,
         onOk () {
           _this.spinning = true
-          settleReceipt({ sn: row.salesBillSn }).then(res => {
+          settleReceipt({ sn: row.accountReceiptSn }).then(res => {
             if (res.status == 200) {
               _this.$message.success(res.message)
               _this.$refs.table.refresh()