lilei 3 سال پیش
والد
کامیت
da6ee0ca2c
1فایلهای تغییر یافته به همراه45 افزوده شده و 39 حذف شده
  1. 45 39
      src/views/salesReturnManagement/pickUp/list.vue

+ 45 - 39
src/views/salesReturnManagement/pickUp/list.vue

@@ -12,7 +12,7 @@
             </a-col>
             <a-col :md="6" :sm="24">
               <a-form-item label="提货单号">
-                <a-input id="pickUp-billNo" v-model.trim="queryParam.purchaseReturnBillNo" allowClear placeholder="请输入客户采退申请单号"/>
+                <a-input id="pickUp-pickUpNo" v-model.trim="queryParam.pickUpNo" allowClear placeholder="请输入提货单号"/>
               </a-form-item>
             </a-col>
             <a-col :md="6" :sm="24">
@@ -28,12 +28,12 @@
               </a-col>
               <a-col :md="6" :sm="24">
                 <a-form-item label="物流点">
-                  <employee style="width: 100%;" id="pickUp-Employee2" v-model="queryParam.applyPersonSn"></employee>
+                  <logisticsPoint style="width: 100%;" id="pickUp-logisticsPoint" v-model="queryParam.logisticsPoint"></logisticsPoint>
                 </a-form-item>
               </a-col>
               <a-col :md="6" :sm="24">
                 <a-form-item label="发货方">
-                  <dealerSubareaScopeList ref="dealerSubareaScopeList" id="pickUp-buyerSn" @change="custChange" />
+                  <dealerSubareaScopeList ref="dealerSubareaScopeList" id="pickUp-senderSn" @change="custChange" />
                 </a-form-item>
               </a-col>
             </template>
@@ -63,11 +63,15 @@
         :defaultLoadData="false"
         bordered>
         <!-- 单号 -->
-        <template slot="salesReturnBillNo" slot-scope="text, record">
+        <template slot="pickUpNo" slot-scope="text, record">
           <div v-if="$hasPermissions('B_salesReturnDetail')">
-            <span class="link-bule" @click="handleDetail(record)">{{ record.salesReturnBillNo }}</span>
+            <span class="link-bule" @click="handleDetail(record)">{{ record.pickUpNo }}</span>
           </div>
-          <div v-else>{{ record.salesReturnBillNo }}</div>
+          <div v-else>{{ record.pickUpNo }}</div>
+        </template>
+        <!-- 关联单数 -->
+        <template slot="salesReturnNum" slot-scope="text, record">
+          <div>{{ record.salesReturnNum }}</div>
         </template>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
@@ -75,6 +79,7 @@
             size="small"
             type="link"
             class="button-info"
+            v-if="record.state == 'AUDIT_PASS'"
             @click="handleDetail(record)"
             id="pickUp-detail-btn">详情</a-button>
         </template>
@@ -88,17 +93,19 @@ import { commonMixin } from '@/utils/mixin'
 import { STable, VSelect } from '@/components'
 import dealerSubareaScopeList from '@/views/common/dealerSubareaScopeList.vue'
 import employee from '../../expenseManagement/expenseReimbursement/employee.js'
+import logisticsPoint from '../billOfLading/logisticsPoint'
 import rangeDate from '@/views/common/rangeDate.vue'
-import { salesReturnList } from '@/api/salesReturn'
+import { pickUpQueryPage } from '@/api/pickUp'
 export default {
-  name: 'BillOfLadingList',
+  name: 'PickUpList',
   mixins: [commonMixin],
   components: {
     STable,
     VSelect,
     dealerSubareaScopeList,
     employee,
-    rangeDate
+    rangeDate,
+    logisticsPoint
   },
   data () {
     return {
@@ -107,23 +114,22 @@ export default {
       advanced: false,
       tableHeight: 0,
       disabled: false, //  查询、重置按钮是否可操作
-      createDate: [], //  创建时间
       // 查询参数
       queryParam: {
-        beginAuditDate: '',
-        endAuditDate: '',
-        buyerSn: undefined, //  客户名称
+        auditBeginDate: '',
+        auditEndDate: '',
+        pickUpNo: '', // 提货单号
+        applyPersonSn: undefined, // 申请人
         salesReturnBillNo: undefined, //  总部销退单号
-        purchaseReturnBillNo: '',
-        billStatus: undefined, // 业务状态
-        shippingAddrProvinceSn: undefined,
-        salesReturnBillSource: undefined
+        logisticsPoint: undefined, // 物流点
+        senderSn: undefined, //  发货人
+        state: 'AUDIT_PASS' // 业务状态
       },
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
         this.spinning = true
-        return salesReturnList(Object.assign(parameter, this.queryParam)).then(res => {
+        return pickUpQueryPage(Object.assign(parameter, this.queryParam)).then(res => {
           let data
           if (res.status == 200) {
             data = res.data
@@ -146,16 +152,16 @@ export default {
     columns () {
       const arr = [
         { title: '编号', dataIndex: 'no', width: '4%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '审核时间', dataIndex: 'auditTime', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '提货单号', scopedSlots: { customRender: 'salesReturnBillNo' }, width: '10%', align: 'center' },
-        { title: '关联销退单', dataIndex: 'salesReturnBillSourceDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '申请人', dataIndex: 'purchaseReturnBillNo', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '主题', dataIndex: 'buyerName', width: '10%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '物流公司', dataIndex: 'buyerName2', width: '10%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '物流点', dataIndex: 'buyerName1', width: '10%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '发货方', dataIndex: 'purchaseReturnBillNo1', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '收货人', dataIndex: 'purchaseReturnBillNo2', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '状态', dataIndex: 'billStatusDictValue', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '审核时间', dataIndex: 'auditDate', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '提货单号', scopedSlots: { customRender: 'pickUpNo' }, width: '10%', align: 'center' },
+        { title: '关联销退单', dataIndex: 'salesReturnNum', scopedSlots: { customRender: 'salesReturnNum' }, width: '6%', align: 'center' },
+        { title: '申请人', dataIndex: 'applyPersonName', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '主题', dataIndex: 'theme', width: '10%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '物流公司', dataIndex: 'logisticsCompany', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '物流点', dataIndex: 'logisticsPoint', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '发货方', dataIndex: 'dealerEntity.dealerName', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '收货人', dataIndex: 'receiverName', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '状态', dataIndex: 'stateDictValue', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '6%', align: 'center' }
       ]
       return arr
@@ -164,29 +170,29 @@ export default {
   methods: {
     //  审核时间  change
     dateExamineChange (date) {
-      this.queryParam.beginAuditDate = date[0]
-      this.queryParam.endAuditDate = date[1]
+      this.queryParam.auditBeginDate = date[0]
+      this.queryParam.auditEndDate = date[1]
     },
     custChange (val) {
-      this.queryParam.buyerSn = val.key
+      this.queryParam.senderSn = val.key
     },
     // 详情
     handleDetail (row) {
       this.$router.push({ name: 'billOfLadingDetail', params: { sn: row.salesReturnBillSn } })
     },
     resetSearchForm () {
-      this.$refs.rangeExamineDate.resetDate()
       if (this.advanced) {
+        this.$refs.rangeExamineDate.resetDate()
         this.$refs.dealerSubareaScopeList.resetForm()
       }
-      this.queryParam.beginAuditDate = ''
-      this.queryParam.endAuditDate = ''
-      this.queryParam.buyerSn = undefined
+      this.queryParam.auditBeginDate = ''
+      this.queryParam.auditEndDate = ''
+      this.queryParam.pickUpNo = ''
+      this.queryParam.senderSn = undefined
+      this.queryParam.applyPersonSn = undefined
+      this.queryParam.logisticsPoint = undefined
       this.queryParam.salesReturnBillNo = ''
-      this.queryParam.purchaseReturnBillNo = ''
-      this.queryParam.billStatus = undefined
-      this.queryParam.salesReturnBillSource = undefined
-      this.queryParam.shippingAddrProvinceSn = undefined
+      this.queryParam.state = undefined
       this.$refs.table.refresh(true)
     },
     pageInit () {