Browse Source

Merge branch 'deploy_0804' of jianguan-web/qpls-md-html into master

陈瑞 4 years ago
parent
commit
88df0f127f
69 changed files with 578 additions and 567 deletions
  1. 6 2
      src/views/allocationManagement/chainTransferIn/detail.vue
  2. 6 2
      src/views/allocationManagement/chainTransferIn/edit.vue
  3. 2 2
      src/views/allocationManagement/chainTransferIn/list.vue
  4. 5 1
      src/views/allocationManagement/chainTransferOut/detail.vue
  5. 9 5
      src/views/allocationManagement/chainTransferOut/edit.vue
  6. 1 1
      src/views/allocationManagement/chainTransferOut/list.vue
  7. 8 33
      src/views/allocationManagement/storeTransferOut/basicInfoModal.vue
  8. 8 4
      src/views/allocationManagement/storeTransferOut/detail.vue
  9. 9 5
      src/views/allocationManagement/storeTransferOut/edit.vue
  10. 2 2
      src/views/allocationManagement/storeTransferOut/list.vue
  11. 15 17
      src/views/allocationManagement/warehouseAllocation/detail.vue
  12. 9 5
      src/views/allocationManagement/warehouseAllocation/edit.vue
  13. 1 1
      src/views/allocationManagement/warehouseAllocation/list.vue
  14. 2 2
      src/views/basicData/bulkPartsTypeManagement/list.vue
  15. 2 2
      src/views/basicData/customerTypeManagement/list.vue
  16. 2 2
      src/views/basicData/expenseType/list.vue
  17. 2 2
      src/views/basicData/storeTransferOutTypeManagement/list.vue
  18. 12 5
      src/views/bulkManagement/bulkWarehousingOrder/detail.vue
  19. 8 4
      src/views/bulkManagement/bulkWarehousingOrder/edit.vue
  20. 11 14
      src/views/bulkManagement/bulkWarehousingOrder/list.vue
  21. 75 0
      src/views/common/custList.vue
  22. 14 14
      src/views/customerManagement/customerInfo/detailModal.vue
  23. 1 1
      src/views/customerManagement/customerInfo/list.vue
  24. 8 4
      src/views/financialManagement/companyCollectionPayment/detail.vue
  25. 7 1
      src/views/financialManagement/companyCollectionPayment/list.vue
  26. 6 1
      src/views/financialManagement/companyReceivablePayable/collectionPayment.vue
  27. 6 2
      src/views/financialManagement/companyReceivablePayable/detail.vue
  28. 5 1
      src/views/financialManagement/companyReceivablePayable/list.vue
  29. 19 10
      src/views/financialManagement/expenseManagement/detailModal.vue
  30. 5 2
      src/views/financialManagement/expenseManagement/list.vue
  31. 10 17
      src/views/financialManagement/financialCollection/detailModal.vue
  32. 14 14
      src/views/financialManagement/financialCollection/list.vue
  33. 8 8
      src/views/financialManagement/financialPayment/detailModal.vue
  34. 4 4
      src/views/financialManagement/financialPayment/list.vue
  35. 6 3
      src/views/financialManagement/ledgerRecord/list.vue
  36. 13 13
      src/views/financialManagement/warehousingAudit/detail.vue
  37. 4 1
      src/views/financialManagement/warehousingAudit/list.vue
  38. 1 1
      src/views/financialManagement/withdrawalManagement/list.vue
  39. 6 9
      src/views/inventoryManagement/inventoryQuery/detailModal.vue
  40. 4 1
      src/views/inventoryManagement/inventoryQuery/list.vue
  41. 4 1
      src/views/inventoryManagement/inventoryQuery/warehouseDetail.vue
  42. 2 2
      src/views/inventoryManagement/warehouse/storingLocation/list.vue
  43. 20 11
      src/views/notice/detailModal.vue
  44. 1 1
      src/views/productManagement/priceChangeRecord/list.vue
  45. 1 1
      src/views/productManagement/productBrand/list.vue
  46. 2 2
      src/views/productManagement/productCategory/list.vue
  47. 9 9
      src/views/productManagement/productInfo/detailModal.vue
  48. 2 2
      src/views/productManagement/productInfo/list.vue
  49. 0 4
      src/views/productManagement/productInfoJg/list.vue
  50. 22 19
      src/views/purchasingManagement/purchaseOrder/detail.vue
  51. 13 10
      src/views/purchasingManagement/purchaseOrder/edit.vue
  52. 5 1
      src/views/purchasingManagement/purchaseOrder/list.vue
  53. 8 8
      src/views/purchasingManagement/purchaseReturn/detail.vue
  54. 1 1
      src/views/purchasingManagement/purchaseReturn/edit.vue
  55. 3 3
      src/views/reportData/chainSalesDetailReport/list.vue
  56. 3 3
      src/views/reportData/chainSalesReport/list.vue
  57. 12 33
      src/views/salesManagement/giftRecord/list.vue
  58. 9 44
      src/views/salesManagement/salesQuery/chooseCustomModal.vue
  59. 29 21
      src/views/salesManagement/salesQuery/detail.vue
  60. 7 7
      src/views/salesManagement/salesQuery/edit.vue
  61. 13 35
      src/views/salesManagement/salesQuery/list.vue
  62. 9 40
      src/views/salesManagement/salesReturn/chooseCustomModal.vue
  63. 22 9
      src/views/salesManagement/salesReturn/detail.vue
  64. 13 35
      src/views/salesManagement/salesReturn/list.vue
  65. 6 6
      src/views/salesManagement/salesReturn/salesReturnEdit.vue
  66. 6 6
      src/views/salesManagement/salesReturn/salesReturnGrabEdit.vue
  67. 10 2
      src/views/salesManagement/urgentItemsOffset/detail.vue
  68. 8 31
      src/views/salesManagement/urgentItemsOffset/list.vue
  69. 2 2
      vue.config.js

+ 6 - 2
src/views/allocationManagement/chainTransferIn/detail.vue

@@ -39,7 +39,11 @@
       <a-card size="small" :bordered="false" class="chainTransferInDetail-cont">
         <!-- 总计 -->
         <a-alert type="info" showIcon style="margin-bottom:15px">
-          <div slot="message">总款数 <strong>{{ (productTotal&&productTotal.productTotalCategory) || 0 }}</strong> ,总数量 <strong>{{ (productTotal&&productTotal.productTotalQty) || 0 }}</strong> ,总成本¥<strong>{{ (productTotal&&productTotal.productTotalCost) || 0 }}</strong></div>
+          <div slot="message">
+            总款数 <strong>{{ (productTotal&&(productTotal.productTotalCategory || productTotal.productTotalCategory==0)) ? productTotal.productTotalCategory : '--' }}</strong> ,
+            总数量 <strong>{{ (productTotal&&(productTotal.productTotalQty || productTotal.productTotalQty==0)) ? productTotal.productTotalQty : '--' }}</strong> ,
+            总成本 <strong>{{ (productTotal&&(productTotal.productTotalCost || productTotal.productTotalCost==0)) ? '¥'+productTotal.productTotalCost : '--' }}</strong>
+          </div>
         </a-alert>
         <!-- 列表 -->
         <s-table
@@ -77,7 +81,7 @@ export default {
         { title: '成本价(¥)', dataIndex: 'putCost', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '调入数量', dataIndex: 'putQty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '单位', dataIndex: 'dealerProductEntity.unit', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '成本小计(¥)', dataIndex: 'costSubtotal', width: 115, align: 'center' },
+        { title: '成本小计(¥)', dataIndex: 'costSubtotal', width: 115, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '仓库', dataIndex: 'warehouseName', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '仓位', dataIndex: 'warehouseLocationName', width: 140, align: 'center', customRender: function (text) { return text || '--' } }
       ],

+ 6 - 2
src/views/allocationManagement/chainTransferIn/edit.vue

@@ -31,7 +31,11 @@
       </a-card>
       <!-- 总计 -->
       <a-alert type="info" showIcon style="margin-bottom:15px">
-        <div slot="message">总款数 <strong>{{ (basicInfoData&&basicInfoData.productTotalCategory) || 0 }}</strong> ,总数量 <strong>{{ (basicInfoData&&basicInfoData.productTotalQty) || 0 }}</strong> ,总成本¥<strong>{{ (basicInfoData&&basicInfoData.productTotalCost) || 0 }}</strong></div>
+        <div slot="message">
+          总款数 <strong>{{ (basicInfoData&&(basicInfoData.productTotalCategory || basicInfoData.productTotalCategory==0)) ? basicInfoData.productTotalCategory : '--' }}</strong> ,
+          总数量 <strong>{{ (basicInfoData&&(basicInfoData.productTotalQty || basicInfoData.productTotalQty==0)) ? basicInfoData.productTotalQty : '--' }}</strong> ,
+          总成本 <strong>{{ (basicInfoData&&(basicInfoData.productTotalCost || basicInfoData.productTotalCost==0)) ? '¥'+basicInfoData.productTotalCost : '--' }}</strong>
+        </div>
       </a-alert>
       <a-card size="small" :bordered="false" class="chainTransferInEdit-cont">
         <!-- 筛选条件 -->
@@ -142,7 +146,7 @@ export default {
         { title: '成本价(¥)', dataIndex: 'putCost', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '调入数量', dataIndex: 'putQty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '单位', dataIndex: 'dealerProductEntity.unit', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '成本小计(¥)', dataIndex: 'costSubtotal', width: 115, align: 'center' },
+        { title: '成本小计(¥)', dataIndex: 'costSubtotal', width: 115, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '仓库仓位', scopedSlots: { customRender: 'warehouse' }, width: 280, align: 'center' }
       ],
       loadData: [],

+ 2 - 2
src/views/allocationManagement/chainTransferIn/list.vue

@@ -142,7 +142,7 @@ export default {
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '连锁调入单号', scopedSlots: { customRender: 'allocationLinkagePutNo' }, width: 220, align: 'center' },
         { title: '调出对象', dataIndex: 'outTenantName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '总款数', dataIndex: 'productTotalCategory', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
@@ -150,7 +150,7 @@ export default {
         { title: '总成本', dataIndex: 'productTotalCost', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '入库时间', dataIndex: 'putWarehouseTime', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '调拨产品类型', dataIndex: 'allocationTypeDictValue', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '业务状态', dataIndex: 'stateDictValue', width: 100, align: 'center' },
+        { title: '业务状态', dataIndex: 'stateDictValue', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '财务状态', scopedSlots: { customRender: 'settleState' }, width: 100, align: 'center' },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 170, align: 'center', fixed: 'right' }
       ],

+ 5 - 1
src/views/allocationManagement/chainTransferOut/detail.vue

@@ -43,7 +43,11 @@
           <a-collapse-panel key="1" header="产品详情">
             <!-- 总计 -->
             <a-alert type="info" showIcon style="margin-bottom:15px">
-              <div slot="message">总款数 <strong>{{ (productTotal&&productTotal.productTotalCategory) || 0 }}</strong> ,总数量 <strong>{{ (productTotal&&productTotal.productTotalQty) || 0 }}</strong> ,总成本¥<strong>{{ (productTotal&&productTotal.productTotalCost) || 0 }}</strong></div>
+              <div slot="message">
+                总款数 <strong>{{ (productTotal&&(productTotal.productTotalCategory || productTotal.productTotalCategory==0)) ? productTotal.productTotalCategory : '--' }}</strong> ,
+                总数量 <strong>{{ (productTotal&&(productTotal.productTotalQty || productTotal.productTotalQty==0)) ? productTotal.productTotalQty : '--' }}</strong> ,
+                总成本 <strong>{{ (productTotal&&(productTotal.productTotalCost || productTotal.productTotalCost==0)) ? '¥'+productTotal.productTotalCost : '--' }}</strong>
+              </div>
             </a-alert>
             <!-- 列表 -->
             <s-table

+ 9 - 5
src/views/allocationManagement/chainTransferOut/edit.vue

@@ -124,7 +124,11 @@
           <a-collapse-panel key="1" header="已选产品">
             <!-- 总计 -->
             <a-alert type="info" showIcon style="margin-bottom:15px">
-              <div slot="message">总款数 <strong>{{ (productTotal&&productTotal.productTotalCategory) || 0 }}</strong> ,总数量 <strong>{{ (productTotal&&productTotal.productTotalQty) || 0 }}</strong> ,总成本¥<strong>{{ (productTotal&&productTotal.productTotalCost) || 0 }}</strong></div>
+              <div slot="message">
+                总款数 <strong>{{ (productTotal&&(productTotal.productTotalCategory || productTotal.productTotalCategory==0)) ? productTotal.productTotalCategory : '--' }}</strong> ,
+                总数量 <strong>{{ (productTotal&&(productTotal.productTotalQty || productTotal.productTotalQty==0)) ? productTotal.productTotalQty : '--' }}</strong> ,
+                总成本 <strong>{{ (productTotal&&(productTotal.productTotalCost || productTotal.productTotalCost==0)) ? '¥'+productTotal.productTotalCost : '--' }}</strong>
+              </div>
             </a-alert>
             <!-- 筛选条件 -->
             <a-row :gutter="15" justify="space-between">
@@ -223,8 +227,8 @@ export default {
       // 表头
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '产品编码', dataIndex: 'productCode', width: 220, align: 'center' },
-        { title: '产品名称', dataIndex: 'productName', align: 'center', ellipsis: true },
+        { title: '产品编码', dataIndex: 'productCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品名称', dataIndex: 'productName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '原厂编码', dataIndex: 'productOrigCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '品牌', dataIndex: 'brandName', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '仓库', dataIndex: 'warehouseName', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
@@ -253,14 +257,14 @@ export default {
       chooseColumns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
         { title: '产品编码', dataIndex: 'dealerProductEntity.code', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '产品名称', dataIndex: 'dealerProductEntity.name', align: 'center', ellipsis: true },
+        { title: '产品名称', dataIndex: 'dealerProductEntity.name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '品牌', dataIndex: 'dealerProductEntity.productBrandName', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '仓库', dataIndex: 'warehouseName', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '仓位', dataIndex: 'warehouseLocationName', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '单位', dataIndex: 'dealerProductEntity.unit', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '成本价', dataIndex: 'outCost', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '调出数量', dataIndex: 'outQty', width: 140, align: 'center' },
+        { title: '调出数量', dataIndex: 'outQty', width: 140, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '成本小计', dataIndex: 'costSubtotal', width: 115, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 100, align: 'center', fixed: 'right' }
       ],

+ 1 - 1
src/views/allocationManagement/chainTransferOut/list.vue

@@ -161,7 +161,7 @@ export default {
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '连锁调出单号', scopedSlots: { customRender: 'allocationLinkageOutNo' }, align: 'center' },
         { title: '调往对象', dataIndex: 'putTenantName', width: 180, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '总款数', dataIndex: 'productTotalCategory', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },

+ 8 - 33
src/views/allocationManagement/storeTransferOut/basicInfoModal.vue

@@ -23,17 +23,7 @@
           </a-radio-group>
         </a-form-model-item>
         <a-form-model-item label="调往对象名称" :prop="isCustomer ? 'putPersonSn' : 'putPersonName'">
-          <a-select
-            v-if="isCustomer"
-            v-model="form.putPersonSn"
-            placeholder="请选择"
-            allowClear
-            :showSearch="true"
-            option-filter-prop="children"
-            :filter-option="filterOption"
-            @change="putPersonChange">
-            <a-select-option v-for="item in custData" :key="item.customerSn" :value="item.customerSn">{{ item.customerName }}</a-select-option>
-          </a-select>
+          <custList ref="custList" v-if="isCustomer" @change="custChange" v-model="form.putPersonSn"></custList>
           <a-input v-if="!isCustomer" v-model="form.putPersonName" placeholder="请输入调往对象名称(最多30个字符)" allowClear :maxLength="30" />
         </a-form-model-item>
         <a-form-model-item label="调拨类型" prop="callOutType">
@@ -56,12 +46,12 @@
 <script>
 import { VSelect } from '@/components'
 import { storeCallOutSave } from '@/api/storeCallOut'
-import { custAllList } from '@/api/customer'
 import { getLookUpData } from '@/api/data'
+import custList from '@/views/common/custList.vue'
 import { storeCallOutTypeAllList } from '@/api/storeCallOutType'
 export default {
   name: 'StoreTransferOutBasicInfoModal',
-  components: { VSelect },
+  components: { VSelect, custList },
   props: {
     openModal: {
       //  弹框显示状态
@@ -90,7 +80,6 @@ export default {
         putPersonName: [{ required: true, message: '请输入调往对象名称', trigger: 'blur' }],
         callOutType: [{ required: true, message: '请选择调拨类型', trigger: 'change' }]
       },
-      custData: [], //  调往对象  下拉数据
       putPersonTypeList: [], //  调往对象类型
       storeCallOutTypeList: [] //  调拨类型
     }
@@ -127,6 +116,11 @@ export default {
         }
       })
     },
+    // 调往对象名称 change
+    custChange (obj) {
+      this.form.putPersonSn = obj.key || undefined
+      this.form.putPersonName = obj.row.customerName
+    },
     // 调往对象  change
     putPersonTypeChange (e) {
       this.$refs.ruleForm.resetFields()
@@ -134,21 +128,6 @@ export default {
       this.form.putPersonName = ''
       this.form.putPersonType = e.target.value
     },
-    // 调往对象名称  change
-    putPersonChange (val) {
-      const ind = this.custData.findIndex(item => item.customerSn == val)
-      this.form.putPersonName = this.custData[ind].customerName
-    },
-    // 调往对象列表
-    getCustAllList () {
-      custAllList().then(res => {
-        if (res.status == 200) {
-          this.custData = res.data
-        } else {
-          this.custData = []
-        }
-      })
-    },
     // 调往对象类型
     getPutPersonTypeList () {
       const _this = this
@@ -173,9 +152,6 @@ export default {
           this.storeCallOutTypeList = []
         }
       })
-    },
-    filterOption (input, option) {
-      return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
     }
   },
   watch: {
@@ -189,7 +165,6 @@ export default {
         this.$emit('close')
         this.$refs.ruleForm.resetFields()
       } else {
-        this.getCustAllList()
         this.getPutPersonTypeList()
         this.getStoreCallOutTypeAllList()
       }

+ 8 - 4
src/views/allocationManagement/storeTransferOut/detail.vue

@@ -41,7 +41,11 @@
       <a-card size="small" :bordered="false" class="storeTransferOutDetail-cont">
         <!-- 总计 -->
         <a-alert type="info" showIcon style="margin-bottom:15px">
-          <div slot="message">总款数 <strong>{{ (productTotal&&productTotal.productTotalCategory) || 0 }}</strong> ,总数量 <strong>{{ (productTotal&&productTotal.productTotalQty) || 0 }}</strong> ,总成本¥<strong>{{ (productTotal&&productTotal.productTotalCost) || 0 }}</strong></div>
+          <div slot="message">
+            总款数 <strong>{{ (productTotal&&(productTotal.productTotalCategory || productTotal.productTotalCategory==0)) ? productTotal.productTotalCategory : '--' }}</strong> ,
+            总数量 <strong>{{ (productTotal&&(productTotal.productTotalQty || productTotal.productTotalQty==0)) ? productTotal.productTotalQty : '--' }}</strong> ,
+            总成本 <strong>{{ (productTotal&&(productTotal.productTotalCost || productTotal.productTotalCost==0)) ? '¥'+productTotal.productTotalCost : '--' }}</strong>
+          </div>
         </a-alert>
         <!-- 列表 -->
         <s-table
@@ -74,12 +78,12 @@ export default {
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center', fixed: 'left' },
         { title: '产品编码', dataIndex: 'productCode', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '产品名称', dataIndex: 'productName', align: 'center', ellipsis: true },
+        { title: '产品名称', dataIndex: 'productName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '单位', dataIndex: 'productUnit', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '成本价(¥)', dataIndex: 'outCost', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '调出仓库', dataIndex: 'warehouseName', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '调出数量', dataIndex: 'outQty', width: 100, align: 'center' },
-        { title: '成本小计(¥)', dataIndex: 'costSubtotal', width: 115, align: 'center' }
+        { title: '调出数量', dataIndex: 'outQty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '成本小计(¥)', dataIndex: 'costSubtotal', width: 115, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } }
       ],
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {

+ 9 - 5
src/views/allocationManagement/storeTransferOut/edit.vue

@@ -109,7 +109,11 @@
           <a-collapse-panel key="1" header="已选产品">
             <!-- 总计 -->
             <a-alert type="info" showIcon style="margin-bottom:15px">
-              <div slot="message">总款数 <strong>{{ (productTotal&&productTotal.productTotalCategory) || 0 }}</strong> ,总数量 <strong>{{ (productTotal&&productTotal.productTotalQty) || 0 }}</strong> ,总成本¥<strong>{{ (productTotal&&productTotal.productTotalCost) || 0 }}</strong></div>
+              <div slot="message">
+                总款数 <strong>{{ (productTotal&&(productTotal.productTotalCategory || productTotal.productTotalCategory==0)) ? productTotal.productTotalCategory : '--' }}</strong> ,
+                总数量 <strong>{{ (productTotal&&(productTotal.productTotalQty || productTotal.productTotalQty==0)) ? productTotal.productTotalQty : '--' }}</strong> ,
+                总成本 <strong>{{ (productTotal&&(productTotal.productTotalCost || productTotal.productTotalCost==0)) ? '¥'+productTotal.productTotalCost : '--' }}</strong>
+              </div>
             </a-alert>
             <!-- 筛选条件 -->
             <a-row :gutter="15">
@@ -223,8 +227,8 @@ export default {
       // 表头
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '产品编码', dataIndex: 'productCode', width: 220, align: 'center' },
-        { title: '产品名称', dataIndex: 'productName', align: 'center', ellipsis: true },
+        { title: '产品编码', dataIndex: 'productCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品名称', dataIndex: 'productName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '单位', dataIndex: 'unit', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '仓库', dataIndex: 'warehouseName', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '仓位', dataIndex: 'warehouseLocationName', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
@@ -249,13 +253,13 @@ export default {
       chooseColumns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
         { title: '产品编码', dataIndex: 'productCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '产品名称', dataIndex: 'productName', align: 'center', ellipsis: true },
+        { title: '产品名称', dataIndex: 'productName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '单位', dataIndex: 'productUnit', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '成本价(¥)', dataIndex: 'outCost', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '仓库', dataIndex: 'warehouseName', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '仓位', dataIndex: 'warehouseLocationName', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '调出数量', scopedSlots: { customRender: 'outQty' }, width: 140, align: 'center' },
-        { title: '成本小计(¥)', dataIndex: 'costSubtotal', width: 115, align: 'center' },
+        { title: '成本小计(¥)', dataIndex: 'costSubtotal', width: 115, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 100, align: 'center', fixed: 'right' }
       ],
       chooseLoadData: [],

+ 2 - 2
src/views/allocationManagement/storeTransferOut/list.vue

@@ -145,7 +145,7 @@ export default {
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '店内调出单号', scopedSlots: { customRender: 'storeCallOutNo' }, width: 220, align: 'center' },
         { title: '调往对象名称', dataIndex: 'putPersonName', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '调拨类型', dataIndex: 'callOutTypeName', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
@@ -153,7 +153,7 @@ export default {
         { title: '总数量', dataIndex: 'productTotalQty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '总成本', dataIndex: 'productTotalCost', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '审核时间', dataIndex: 'auditTime', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '业务状态', dataIndex: 'stateDictValue', width: 110, align: 'center' },
+        { title: '业务状态', dataIndex: 'stateDictValue', width: 110, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '财务状态', dataIndex: 'settleState', scopedSlots: { customRender: 'settleState' }, width: 110, align: 'center' },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 250, align: 'center', fixed: 'right' }
       ],

+ 15 - 17
src/views/allocationManagement/warehouseAllocation/detail.vue

@@ -26,12 +26,12 @@
       <a-collapse :activeKey="['1']">
         <a-collapse-panel key="1" header="基础信息">
           <a-descriptions :column="3">
-            <a-descriptions-item label="调出仓库">{{ warehouse?warehouse.outWarehouseName:'--' }}</a-descriptions-item>
-            <a-descriptions-item label="调入仓库">{{ warehouse?warehouse.putWarehouseName:'--' }}</a-descriptions-item>
-            <a-descriptions-item label="调拨单号">{{ warehouse?warehouse.allocationWarehouseNo:'--' }}</a-descriptions-item>
-            <a-descriptions-item label="关联单号">{{ warehouse?warehouse.relevanceNo ||'--':'--' }}</a-descriptions-item>
-            <a-descriptions-item label="单据状态">{{ warehouse?warehouse.stateDictValue ||'--':'--' }}</a-descriptions-item>
-            <a-descriptions-item label="备注">{{ warehouse?warehouse.remark ||'--':'--' }}</a-descriptions-item>
+            <a-descriptions-item label="调出仓库">{{ (warehouse&&warehouse.outWarehouseName) || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="调入仓库">{{ (warehouse&&warehouse.putWarehouseName) || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="调拨单号">{{ (warehouse&&warehouse.allocationWarehouseNo) || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="关联单号">{{ (warehouse&&warehouse.relevanceNo) || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="单据状态">{{ (warehouse&&warehouse.stateDictValue) || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="备注">{{ (warehouse&&warehouse.remark) || '--' }}</a-descriptions-item>
           </a-descriptions>
         </a-collapse-panel>
       </a-collapse>
@@ -39,7 +39,11 @@
     <a-card size="small" :bordered="false" class="warehouseAllocationDetail-cont">
       <!-- 总计 -->
       <a-alert type="info" showIcon style="margin-bottom:15px">
-        <div slot="message">总款数: <strong>{{ productTotalCategory }}</strong> ,总数量: <strong>{{ productTotalQty }}</strong> ,总成本:¥<strong>{{ productTotalCost }}</strong></div>
+        <div slot="message">
+          总款数: <strong>{{ productTotal&&(productTotal.productTotalCategory || productTotal.productTotalCategory==0) ? productTotal.productTotalCategory : '--' }}</strong> ,
+          总数量: <strong>{{ productTotal&&(productTotal.productTotalQty || productTotal.productTotalQty==0) ? productTotal.productTotalQty : '--' }}</strong> ,
+          总成本: <strong>{{ productTotal&&(productTotal.productTotalCost || productTotal.productTotalCost==0) ? '¥'+productTotal.productTotalCost : '--' }}</strong>
+        </div>
       </a-alert>
       <!-- 列表 -->
       <s-table
@@ -82,10 +86,8 @@ export default {
         allocationWarehouseSn: this.$route.params.sn
       },
       id: this.$route.params.id, // 单据id
-      productTotalCost: 0, // 总成本
-      productTotalQty: 0, // 总数量
-      productTotalCategory: 0, // 总款项
       warehouse: null, // 基础信息
+      productTotal: null,
       // 表头
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center', fixed: 'left' },
@@ -93,7 +95,7 @@ export default {
         { title: '产品名称', dataIndex: 'productName', width: 200, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '原厂编码', dataIndex: 'productOrigCode', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '类别', scopedSlots: { customRender: 'productType' }, width: 160, align: 'center' },
-        { title: '数量', dataIndex: 'allocationQty', width: 100, align: 'center' },
+        { title: '数量', dataIndex: 'allocationQty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '单位', dataIndex: 'productUnit', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '成本小计(¥)', scopedSlots: { customRender: 'totalCost' }, width: 135, align: 'center' },
         { title: '调出仓位', dataIndex: 'outWarehouseLocationName', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
@@ -139,13 +141,9 @@ export default {
     getProduceTotal () {
       allocWarehouseDetailCount(this.queryParam).then(res => {
         if (res.status == 200) {
-          this.productTotalCost = res.data.productTotalCost || 0
-          this.productTotalQty = res.data.productTotalQty || 0
-          this.productTotalCategory = res.data.productTotalCategory || 0
+          this.productTotal = res.data
         } else {
-          this.productTotalCost = 0
-          this.productTotalQty = 0
-          this.productTotalCategory = 0
+          this.productTotal = null
         }
       })
     },

+ 9 - 5
src/views/allocationManagement/warehouseAllocation/edit.vue

@@ -134,7 +134,11 @@
           <a-collapse-panel key="1" header="已选产品">
             <!-- 总计 -->
             <a-alert type="info" showIcon style="margin-bottom:15px">
-              <div slot="message">总款数 <strong>{{ (productTotal&&productTotal.productTotalCategory) || 0 }}</strong> ,总数量 <strong>{{ (productTotal&&productTotal.productTotalQty) || 0 }}</strong> ,总成本¥<strong>{{ (productTotal&&productTotal.productTotalCost) || 0 }}</strong></div>
+              <div slot="message">
+                总款数 <strong>{{ (productTotal&&(productTotal.productTotalCategory || productTotal.productTotalCategory==0)) ? productTotal.productTotalCategory : '--' }}</strong> ,
+                总数量 <strong>{{ (productTotal&&(productTotal.productTotalQty || productTotal.productTotalQty==0)) ? productTotal.productTotalQty : '--' }}</strong> ,
+                总成本 <strong>{{ (productTotal&&(productTotal.productTotalCost || productTotal.productTotalCost==0)) ? '¥'+productTotal.productTotalCost : '--' }}</strong>
+              </div>
             </a-alert>
             <!-- 筛选条件 -->
             <a-row :gutter="15" justify="space-between">
@@ -264,8 +268,8 @@ export default {
       // 表头
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '产品编码', dataIndex: 'productCode', width: 220, align: 'center' },
-        { title: '产品名称', dataIndex: 'productName', align: 'center', ellipsis: true },
+        { title: '产品编码', dataIndex: 'productCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品名称', dataIndex: 'productName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '原厂编码', dataIndex: 'productOrigCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '品牌', dataIndex: 'brandName', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '分类', scopedSlots: { customRender: 'productType' }, width: 200, align: 'center', ellipsis: true },
@@ -290,8 +294,8 @@ export default {
       // 表头
       chooseColumns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '产品编码', dataIndex: 'productCode', width: 220, align: 'center' },
-        { title: '产品名称', dataIndex: 'productName', align: 'center', ellipsis: true },
+        { title: '产品编码', dataIndex: 'productCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品名称', dataIndex: 'productName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '原厂编码', dataIndex: 'productOrigCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '品牌', dataIndex: 'brandName', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '分类', scopedSlots: { customRender: 'productType' }, width: 200, align: 'center', ellipsis: true },

+ 1 - 1
src/views/allocationManagement/warehouseAllocation/list.vue

@@ -129,7 +129,7 @@ export default {
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单号', scopedSlots: { customRender: 'allocationWarehouseNo' }, align: 'center' },
         { title: '调出仓库', dataIndex: 'outWarehouseName', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '调入仓库', dataIndex: 'putWarehouseName', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },

+ 2 - 2
src/views/basicData/bulkPartsTypeManagement/list.vue

@@ -56,8 +56,8 @@ export default {
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '散件类型名称', dataIndex: 'name', align: 'center', ellipsis: true },
-        { title: '创建时间', dataIndex: 'createDate', align: 'center' },
+        { title: '散件类型名称', dataIndex: 'name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '创建时间', dataIndex: 'createDate', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 200, align: 'center' }
       ],
       // 加载数据方法 必须为 Promise 对象

+ 2 - 2
src/views/basicData/customerTypeManagement/list.vue

@@ -71,8 +71,8 @@ export default {
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '客户类型名称', dataIndex: 'name', align: 'center', ellipsis: true },
-        { title: '创建时间', dataIndex: 'createDate', align: 'center' },
+        { title: '客户类型名称', dataIndex: 'name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '创建时间', dataIndex: 'createDate', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 200, align: 'center' }
       ],
       // 加载数据方法 必须为 Promise 对象

+ 2 - 2
src/views/basicData/expenseType/list.vue

@@ -66,8 +66,8 @@ export default {
         wrapperCol: { span: 16 }
       },
       columns: [
-        { title: '费用类型名称', dataIndex: 'name', align: 'left' },
-        { title: '创建时间', dataIndex: 'createDate', align: 'center' },
+        { title: '费用类型名称', dataIndex: 'name', align: 'left', customRender: function (text) { return text || '--' } },
+        { title: '创建时间', dataIndex: 'createDate', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, align: 'center' }
       ],
       // 加载数据方法 必须为 Promise 对象

+ 2 - 2
src/views/basicData/storeTransferOutTypeManagement/list.vue

@@ -60,8 +60,8 @@ export default {
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '店内调出类型名称', dataIndex: 'name', align: 'center', ellipsis: true },
-        { title: '创建时间', dataIndex: 'createDate', align: 'center' },
+        { title: '店内调出类型名称', dataIndex: 'name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '创建时间', dataIndex: 'createDate', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 200, align: 'center' }
       ],
       // 加载数据方法 必须为 Promise 对象

+ 12 - 5
src/views/bulkManagement/bulkWarehousingOrder/detail.vue

@@ -41,10 +41,13 @@
                 <span v-if="basicInfoData&&basicInfoData.supplierContactTel">({{ basicInfoData.supplierContactTel }})</span>
               </a-descriptions-item>
               <a-descriptions-item label="联系地址">
-                {{ (basicInfoData&&basicInfoData.supplierProvinceName) || '' }}
-                {{ (basicInfoData&&basicInfoData.supplierCityName) || '' }}
-                {{ (basicInfoData&&basicInfoData.supplierCountyName) || '' }}
-                {{ (basicInfoData&&basicInfoData.supplierAddress) || '' }}
+                <div v-if="basicInfoData&&(basicInfoData.supplierProvinceName || basicInfoData.supplierCityName || basicInfoData.supplierCountyName || basicInfoData.supplierAddress)">
+                  {{ (basicInfoData&&basicInfoData.supplierProvinceName) || '' }}
+                  {{ (basicInfoData&&basicInfoData.supplierCityName) || '' }}
+                  {{ (basicInfoData&&basicInfoData.supplierCountyName) || '' }}
+                  {{ (basicInfoData&&basicInfoData.supplierAddress) || '' }}
+                </div>
+                <span v-else>--</span>
               </a-descriptions-item>
             </a-descriptions>
           </a-collapse-panel>
@@ -56,7 +59,11 @@
           <a-collapse-panel key="1" header="产品详情">
             <!-- 总计 -->
             <a-alert type="info" showIcon style="margin-bottom:15px">
-              <div slot="message">总款数 <strong>{{ (productTotal&&productTotal.productTotalCategory) || 0 }}</strong> ,总数量 <strong>{{ (productTotal&&productTotal.productTotalQty) || 0 }}</strong> ,总成本¥<strong>{{ (productTotal&&productTotal.productTotalCost) || 0 }}</strong></div>
+              <div slot="message">
+                总款数 <strong>{{ (productTotal&&(productTotal.productTotalCategory || productTotal.productTotalCategory==0)) ? productTotal.productTotalCategory : '--' }}</strong> ,
+                总数量 <strong>{{ (productTotal&&(productTotal.productTotalQty || productTotal.productTotalQty==0)) ? productTotal.productTotalQty : '--' }}</strong> ,
+                总成本 <strong>{{ (productTotal&&(productTotal.productTotalCost || productTotal.productTotalCost==0)) ? '¥'+productTotal.productTotalCost : '--' }}</strong>
+              </div>
             </a-alert>
             <!-- 列表 -->
             <s-table

+ 8 - 4
src/views/bulkManagement/bulkWarehousingOrder/edit.vue

@@ -156,7 +156,11 @@
             <div>
               <!-- 总计 -->
               <a-alert type="info" showIcon style="margin-bottom:15px">
-                <div slot="message">总款数 <strong>{{ (productTotal&&productTotal.productTotalCategory) || 0 }}</strong> ,总数量 <strong>{{ (productTotal&&productTotal.productTotalQty) || 0 }}</strong> ,总成本¥<strong>{{ (productTotal&&productTotal.productTotalCost) || 0 }}</strong></div>
+                <div slot="message">
+                  总款数 <strong>{{ (productTotal&&(productTotal.productTotalCategory || productTotal.productTotalCategory==0)) ? productTotal.productTotalCategory : '--' }}</strong> ,
+                  总数量 <strong>{{ (productTotal&&(productTotal.productTotalQty || productTotal.productTotalQty==0)) ? productTotal.productTotalQty : '--' }}</strong> ,
+                  总成本 <strong>{{ (productTotal&&(productTotal.productTotalCost || productTotal.productTotalCost==0)) ? '¥'+productTotal.productTotalCost : '--' }}</strong>
+                </div>
               </a-alert>
               <!-- 列表 -->
               <a-table
@@ -287,14 +291,14 @@ export default {
       // 表头
       chooseColumns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '产品编码', dataIndex: 'productCode', width: 220, align: 'center', sorter: true },
+        { title: '产品编码', dataIndex: 'productCode', width: 220, align: 'center', customRender: function (text) { return text || '--' }, sorter: true },
         { title: '产品名称', dataIndex: 'productName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '原厂编码', dataIndex: 'productOrigCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '产品品牌', dataIndex: 'brandName', width: 200, align: 'center', sorter: true, customRender: function (text) { return text || '--' } },
         { title: '单位', dataIndex: 'productUnit', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '成本价', scopedSlots: { customRender: 'putCost' }, width: 140, align: 'center' },
         { title: '数量', scopedSlots: { customRender: 'putQty' }, width: 140, align: 'center' },
-        { title: '成本小计', dataIndex: 'costSubtotal', width: 100, align: 'center' },
+        { title: '成本小计', dataIndex: 'costSubtotal', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '仓库仓位', scopedSlots: { customRender: 'warehouse' }, width: 200, align: 'center' },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 100, align: 'center', fixed: 'right' }
       ],
@@ -495,7 +499,7 @@ export default {
               _this.$message.success(res.message)
               _this.getChooseDealerProductList()
               _this.spinning = false
-            }else{
+            } else {
               _this.spinning = false
             }
           })

+ 11 - 14
src/views/bulkManagement/bulkWarehousingOrder/list.vue

@@ -83,7 +83,11 @@
       </div>
       <!-- alert -->
       <a-alert type="info" showIcon style="margin-bottom:15px">
-        <div slot="message">共 <strong>{{ dataTotalCount }}</strong> 条记录,总数量合计 <strong>{{ productTotal.productTotalQty }}</strong> ,总金额合计¥<strong>{{ productTotal.productTotalCost }}</strong> </div>
+        <div slot="message">
+          共 <strong>{{ dataTotalCount }}</strong> 条记录,
+          总数量合计 <strong>{{ productTotal&&(productTotal.productTotalQty || productTotal.productTotalQty==0) ? productTotal.productTotalQty : '--' }}</strong> ,
+          总金额合计 <strong>{{ productTotal&&(productTotal.productTotalCost || productTotal.productTotalCost==0) ? '¥'+productTotal.productTotalCost : '--' }}</strong>
+        </div>
       </a-alert>
       <!-- 列表 -->
       <s-table
@@ -168,12 +172,12 @@ export default {
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
         { title: '散件单号', scopedSlots: { customRender: 'sparePartsPurchaseNo' }, width: 220, align: 'center' },
-        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '供应商', dataIndex: 'supplierName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '产品款数', dataIndex: 'productTotalCategory', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '总数量', dataIndex: 'productTotalQty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '总金额', dataIndex: 'productTotalCost', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '业务状态', dataIndex: 'stateDictValue', width: 100, align: 'center' },
+        { title: '业务状态', dataIndex: 'stateDictValue', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '财务状态', dataIndex: 'settleState', scopedSlots: { customRender: 'settleState' }, width: 100, align: 'center' },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 200, align: 'center', fixed: 'right' }
       ],
@@ -190,16 +194,13 @@ export default {
             data.list[i].no = no + i + 1
           }
           this.disabled = false
-          this.dataTotalCount = data.count
+          this.dataTotalCount = data.count || 0
           this.getTotal(Object.assign(parameter, this.queryParam))
           return data
         })
       },
-      productTotal: { // 合计信息
-        productTotalCost: '',
-        productTotalQty: ''
-      },
-      dataTotalCount: '' //  列表数据总条数
+      productTotal: null,
+      dataTotalCount: 0 //  列表数据总条数
     }
   },
   methods: {
@@ -214,11 +215,7 @@ export default {
         if (res.status == 200 && res.data) {
           this.productTotal = res.data
         } else {
-          this.productTotal = {
-            // 合计信息
-            productTotalCost: '',
-            productTotalQty: ''
-          }
+          this.productTotal = null
         }
       })
     },

+ 75 - 0
src/views/common/custList.vue

@@ -0,0 +1,75 @@
+<template>
+  <a-select
+    show-search
+    label-in-value
+    :value="dealerName"
+    placeholder="请输入名称搜索"
+    style="width: 100%"
+    :filter-option="false"
+    :not-found-content="fetching ? undefined : null"
+    @search="fetchUser"
+    @change="handleChange"
+    allowClear
+  >
+    <a-spin v-if="fetching" slot="notFoundContent" size="small" />
+    <a-select-option v-for="item in data" :key="item.customerSn" :value="item.customerSn">
+      {{ item.customerName }}
+    </a-select-option>
+  </a-select>
+</template>
+<script>
+import debounce from 'lodash/debounce'
+import { custList } from '@/api/customer'
+export default {
+  props: {
+  },
+  data () {
+    this.lastFetchId = 0
+    this.fetchUser = debounce(this.fetchUser, 800)
+    return {
+      data: [],
+      dealerName: undefined,
+      fetching: false
+    }
+  },
+  methods: {
+    fetchUser (dealerName) {
+      console.log('fetching user', dealerName)
+      if (dealerName == '') return
+      this.lastFetchId += 1
+      const fetchId = this.lastFetchId
+      this.data = []
+      this.fetching = true
+      custList({ 'customerName': dealerName, pageNo: 1, pageSize: 20 }).then(res => {
+        if (fetchId !== this.lastFetchId) {
+          return
+        }
+        this.data = res.data && res.data.list ? res.data.list : []
+        this.fetching = false
+      })
+    },
+    handleChange (value) {
+      if (value && value.key) {
+        const ind = this.data.findIndex(item => item.customerSn == value.key)
+        value.row = ind != -1 ? this.data[ind] : undefined
+      }
+      Object.assign(this, {
+        dealerName: value,
+        data: [],
+        fetching: false
+      })
+      this.$emit('change', value || { key: undefined })
+    },
+    resetForm () {
+      this.dealerName = undefined
+    },
+    setData (value) {
+      Object.assign(this, {
+        dealerName: value,
+        data: [],
+        fetching: false
+      })
+    }
+  }
+}
+</script>

+ 14 - 14
src/views/customerManagement/customerInfo/detailModal.vue

@@ -11,17 +11,17 @@
     <!-- 客户详情 -->
     <div>
       <a-spin :spinning="!detailData" tip="Loading...">
-        <a-descriptions :column="3" bordered size="small" v-if="detailData">
-          <a-descriptions-item label="客户名称:">{{ detailData.customerName || '--' }}</a-descriptions-item>
-          <a-descriptions-item label="联系人:">{{ detailData.contactName || '--' }}</a-descriptions-item>
-          <a-descriptions-item label="联系电话:">{{ detailData.contactTel || '--' }}</a-descriptions-item>
+        <a-descriptions :column="3" bordered size="small">
+          <a-descriptions-item label="客户名称:">{{ detailData&&detailData.customerName || '--' }}</a-descriptions-item>
+          <a-descriptions-item label="联系人:">{{ detailData&&detailData.contactName || '--' }}</a-descriptions-item>
+          <a-descriptions-item label="联系电话:">{{ detailData&&detailData.contactTel || '--' }}</a-descriptions-item>
           <a-descriptions-item label="客户地址:" :span="3">{{ addressStr }}</a-descriptions-item>
-          <a-descriptions-item label="客户传真:">{{ detailData.fax || '--' }}</a-descriptions-item>
-          <a-descriptions-item label="配送方式:">{{ detailData.dispatchTypeDictValue || '--' }}</a-descriptions-item>
-          <a-descriptions-item label="是否卫星仓客户:">{{ detailData.satelliteFlagDictValue || '--' }}</a-descriptions-item>
-          <a-descriptions-item label="价格类型:">{{ detailData.priceTypeDictValue || '--' }}</a-descriptions-item>
-          <a-descriptions-item label="收款方式:">{{ detailData.settleStyleName || '--' }}</a-descriptions-item>
-          <a-descriptions-item label="客户类型:">{{ detailData.customerTypeName || '--' }}</a-descriptions-item>
+          <a-descriptions-item label="客户传真:">{{ detailData&&detailData.fax || '--' }}</a-descriptions-item>
+          <a-descriptions-item label="配送方式:">{{ detailData&&detailData.dispatchTypeDictValue || '--' }}</a-descriptions-item>
+          <a-descriptions-item label="是否卫星仓客户:">{{ detailData&&detailData.satelliteFlagDictValue || '--' }}</a-descriptions-item>
+          <a-descriptions-item label="价格类型:">{{ detailData&&detailData.priceTypeDictValue || '--' }}</a-descriptions-item>
+          <a-descriptions-item label="收款方式:">{{ detailData&&detailData.settleStyleName || '--' }}</a-descriptions-item>
+          <a-descriptions-item label="客户类型:">{{ detailData&&detailData.customerTypeName || '--' }}</a-descriptions-item>
         </a-descriptions>
       </a-spin>
       <div class="btn-cont"><a-button id="customer-management-detail-modal-back" @click="isShow = false">返回列表</a-button></div>
@@ -48,10 +48,10 @@ export default {
   computed: {
     // 地址处理
     addressStr () {
-      const provinceName = this.detailData.provinceName ? this.detailData.provinceName : ''
-      const cityName = this.detailData.cityName ? this.detailData.cityName : ''
-      const countyName = this.detailData.countyName ? this.detailData.countyName : ''
-      const customerAddr = this.detailData.customerAddr ? this.detailData.customerAddr : ''
+      const provinceName = this.detailData && this.detailData.provinceName ? this.detailData.provinceName : ''
+      const cityName = this.detailData && this.detailData.cityName ? this.detailData.cityName : ''
+      const countyName = this.detailData && this.detailData.countyName ? this.detailData.countyName : ''
+      const customerAddr = this.detailData && this.detailData.customerAddr ? this.detailData.customerAddr : ''
       const str = (provinceName || cityName || countyName || customerAddr) ? (provinceName + cityName + countyName + customerAddr) : '--'
       return str
     }

+ 1 - 1
src/views/customerManagement/customerInfo/list.vue

@@ -152,7 +152,7 @@ export default {
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '客户名称', dataIndex: 'customerName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '联系人', dataIndex: 'contactName', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '联系电话', dataIndex: 'contactTel', width: 140, align: 'center', customRender: function (text) { return text || '--' } },

+ 8 - 4
src/views/financialManagement/companyCollectionPayment/detail.vue

@@ -20,9 +20,9 @@
             <a-descriptions-item label="单位名称">{{ (basicInfoData&&basicInfoData.settleClientName) || '--' }}</a-descriptions-item>
             <a-descriptions-item label="单位类型">{{ (basicInfoData&&basicInfoData.settleClientTypeDictValue) || '--' }}</a-descriptions-item>
             <a-descriptions-item label="结算类型">{{ (basicInfoData&&basicInfoData.settleTypeDictValue) || '--' }}</a-descriptions-item>
-            <a-descriptions-item label="应结算金额">{{ (basicInfoData&&basicInfoData.settleAmount) || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="应结算金额">{{ (basicInfoData&&(basicInfoData.settleAmount || basicInfoData.settleAmount==0)) ? basicInfoData.settleAmount : '--' }}</a-descriptions-item>
             <a-descriptions-item label="折让金额">{{ discountAmount || '--' }}</a-descriptions-item>
-            <a-descriptions-item label="实结算金额">{{ (basicInfoData&&basicInfoData.realSettleAmount) || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="实结算金额">{{ (basicInfoData&&(basicInfoData.realSettleAmount || basicInfoData.realSettleAmount==0)) ? basicInfoData.realSettleAmount : '--' }}</a-descriptions-item>
             <a-descriptions-item label="结算时间">{{ (basicInfoData&&basicInfoData.createDate) || '--' }}</a-descriptions-item>
             <a-descriptions-item label="操作人">{{ (basicInfoData&&basicInfoData.operateName) || '--' }}</a-descriptions-item>
             <a-descriptions-item label="结算方式">{{ (basicInfoData&&basicInfoData.settleStyleName) || '--' }}</a-descriptions-item>
@@ -36,7 +36,11 @@
         <a-collapse-panel key="1" header="收款明细">
           <!-- alert -->
           <a-alert type="info" showIcon style="margin-bottom:15px">
-            <div slot="message">共 <strong>{{ total }}</strong> 条明细,金额合计 <strong>¥{{ (basicInfoData&&basicInfoData.totalSettleAmount) || 0 }}</strong> ,结算金额合计 <strong>¥{{ (basicInfoData&&basicInfoData.realSettleAmount) || 0 }}</strong> </div>
+            <div slot="message">
+              共 <strong>{{ total }}</strong> 条明细,
+              金额合计 <strong>{{ (basicInfoData&&(basicInfoData.totalSettleAmount || basicInfoData.totalSettleAmount==0)) ? '¥'+basicInfoData.totalSettleAmount : '--' }}</strong> ,
+              结算金额合计 <strong>{{ (basicInfoData&&(basicInfoData.realSettleAmount || basicInfoData.realSettleAmount==0)) ? '¥'+basicInfoData.realSettleAmount : '--' }}</strong>
+            </div>
           </a-alert>
           <!-- 列表 -->
           <s-table
@@ -80,7 +84,7 @@ export default {
             data.list[i].no = no + i + 1
           }
           this.disabled = false
-          this.total = data.list.length
+          this.total = data.list.length || 0
           return data
         })
       },

+ 7 - 1
src/views/financialManagement/companyCollectionPayment/list.vue

@@ -65,7 +65,13 @@
     </div>
     <!-- alert -->
     <a-alert type="info" showIcon style="margin-bottom:15px">
-      <div slot="message">共 <strong>{{ total }}</strong> 条记录,其中收款单 <strong>{{ (productTotal&&productTotal.receiptCount) || 0 }}</strong> 条,收款金额合计 <strong>¥{{ (productTotal&&productTotal.receiptAmount) || 0 }}</strong> ,付款单 <strong>{{ (productTotal&&productTotal.payCount) || 0 }}</strong> 条,付款金额合计 <strong>¥{{ (productTotal&&productTotal.payAmount) || 0 }}</strong> </div>
+      <div slot="message">
+        共 <strong>{{ total }}</strong> 条记录,
+        其中收款单 <strong>{{ (productTotal&&(productTotal.receiptCount || productTotal.receiptCount==0)) ? productTotal.receiptCount : '--' }}</strong> 条,
+        收款金额合计 <strong>{{ (productTotal&&(productTotal.receiptAmount || productTotal.receiptAmount==0)) ? '¥'+productTotal.receiptAmount : '--' }}</strong> ,
+        付款单 <strong>{{ (productTotal&&(productTotal.payCount || productTotal.payCount==0)) ? productTotal.payCount : '--' }}</strong> 条,
+        付款金额合计 <strong>{{ (productTotal&&(productTotal.payAmount || productTotal.payAmount==0)) ? '¥'+productTotal.payAmount : '--' }}</strong>
+      </div>
     </a-alert>
     <!-- 列表 -->
     <s-table

+ 6 - 1
src/views/financialManagement/companyReceivablePayable/collectionPayment.vue

@@ -18,7 +18,12 @@
             </template>
             <!-- 总计 -->
             <a-alert type="info" showIcon style="margin-bottom:15px">
-              <div slot="message">共 <strong>{{ chooseLoadData.length }}</strong>条明细 ,金额合计¥<strong>{{ totalAmount }}</strong> ,余额合计¥<strong>{{ totalBalance }}</strong> ,本次结算金额合计¥<strong>{{ currentTotalBalance }}</strong></div>
+              <div slot="message">
+                共 <strong>{{ chooseLoadData.length }}</strong>条明细 ,
+                金额合计¥<strong>{{ totalAmount }}</strong> ,
+                余额合计¥<strong>{{ totalBalance }}</strong> ,
+                本次结算金额合计¥<strong>{{ currentTotalBalance }}</strong>
+              </div>
             </a-alert>
             <!-- 列表 -->
             <a-table

+ 6 - 2
src/views/financialManagement/companyReceivablePayable/detail.vue

@@ -45,7 +45,11 @@
       </div>
       <!-- alert -->
       <a-alert type="info" showIcon style="margin-bottom:15px">
-        <div slot="message">共 <strong>{{ total }}</strong> 条明细,金额合计 <strong>¥{{ (productTotal&&productTotal.totalAmount) || 0 }}</strong> ,余额合计 <strong>¥{{ (productTotal&&productTotal.unsettleAmount) || 0 }}</strong> </div>
+        <div slot="message">
+          共 <strong>{{ total }}</strong> 条明细,
+          金额合计 <strong>{{ (productTotal&&(productTotal.totalAmount || productTotal.totalAmount==0)) ? '¥'+productTotal.totalAmount : '--' }}</strong> ,
+          余额合计 <strong>{{ (productTotal&&(productTotal.unsettleAmount || productTotal.unsettleAmount==0)) ? '¥'+productTotal.unsettleAmount : '--' }}</strong>
+        </div>
       </a-alert>
       <!-- 列表 -->
       <s-table
@@ -107,7 +111,7 @@ export default {
             data.list[i].no = no + i + 1
           }
           this.disabled = false
-          this.total = data.list.length
+          this.total = data.list.length || 0
           this.getTotal(params)
           return data
         })

+ 5 - 1
src/views/financialManagement/companyReceivablePayable/list.vue

@@ -31,7 +31,11 @@
     </div>
     <!-- alert -->
     <a-alert type="info" showIcon style="margin-bottom:15px">
-      <div slot="message">共 <strong>{{ total }}</strong> 条记录,应收金额合计 <strong>¥{{ (productTotal&&productTotal.receipt) || 0 }}</strong> ,应付金额合计 <strong>¥{{ (productTotal&&productTotal.pay) ? Math.abs(productTotal.pay) : 0 }}</strong> </div>
+      <div slot="message">
+        共 <strong>{{ total }}</strong> 条记录,
+        应收金额合计 <strong>{{ (productTotal&&(productTotal.receipt || productTotal.receipt==0)) ? '¥'+productTotal.receipt : '--' }}</strong> ,
+        应付金额合计 <strong>¥{{ (productTotal&&productTotal.pay) ? Math.abs(productTotal.pay) : 0 }}</strong>
+      </div>
     </a-alert>
     <!-- 列表 -->
     <s-table

+ 19 - 10
src/views/financialManagement/expenseManagement/detailModal.vue

@@ -9,13 +9,22 @@
     @cancle="isShow=false"
     :width="600">
     <!-- 详情 -->
-    <div v-if="detailsData">
-      <a-descriptions :column="1" size="default" v-if="detailsData">
-        <a-descriptions-item label="费用单号">{{ detailsData.accountExpensesSn || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="费用类型">{{ [detailsData.expensesTypeName1, detailsData.expensesTypeName2, detailsData.expensesTypeName3].join(' > ') }}</a-descriptions-item>
-        <a-descriptions-item label="费用金额">¥{{ detailsData.settleAmount || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="单据状态">{{ detailsData.stateDictValue || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="备注">{{ detailsData.remark || '--' }}</a-descriptions-item>
+    <div>
+      <a-descriptions :column="1" size="default">
+        <a-descriptions-item label="费用单号">{{ detailsData&&detailsData.accountExpensesSn || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="费用类型">
+          <div v-if="detailsData&&(detailsData.expensesTypeName1 || detailsData.expensesTypeName2 || detailsData.expensesTypeName3)">
+            {{ detailsData&&detailsData.expensesTypeName1 ? detailsData.expensesTypeName1 : '' }}
+            <span v-if="(detailsData&&detailsData.expensesTypeName1) && (detailsData&&detailsData.expensesTypeName2)"> > </span>
+            {{ detailsData&&detailsData.expensesTypeName2 ? detailsData.expensesTypeName2 : '' }}
+            <span v-if="(detailsData&&detailsData.expensesTypeName2) && (detailsData&&detailsData.expensesTypeName3)"> > </span>
+            {{ detailsData&&detailsData.expensesTypeName3 ? detailsData.expensesTypeName3 : '' }}
+          </div>
+          <span v-else>--</span>
+        </a-descriptions-item>
+        <a-descriptions-item label="费用金额">¥{{ detailsData&&detailsData.settleAmount || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="单据状态">{{ detailsData&&detailsData.stateDictValue || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="备注">{{ detailsData&&detailsData.remark || '--' }}</a-descriptions-item>
       </a-descriptions>
       <div class="btn-cont"><a-button id="expenseManagementDetail-modal-back" @click="isShow = false">返回列表</a-button></div>
     </div>
@@ -78,11 +87,11 @@ export default {
 <style lang="less">
   .expenseManagementDetail-modal{
     .ant-modal-body {
-    	padding: 40px 40px 24px;
+      padding: 40px 40px 24px;
     }
     .btn-cont {
-    	text-align: center;
-    	margin: 35px 0 10px;
+      text-align: center;
+      margin: 35px 0 10px;
     }
   }
 </style>

+ 5 - 2
src/views/financialManagement/expenseManagement/list.vue

@@ -61,7 +61,10 @@
       </div>
       <!-- alert -->
       <a-alert type="info" showIcon style="margin-bottom:15px">
-        <div slot="message">共 <strong>{{ totalData.count }}</strong> 条记录,金额共计 <strong>¥{{ totalData.totalAmount }}</strong></div>
+        <div slot="message">
+          共 <strong>{{ totalData&&(totalData.count || totalData.count==0) ? totalData.count : '--' }}</strong> 条记录,
+          金额共计 <strong>¥{{ totalData&&(totalData.totalAmount || totalData.totalAmount==0) ? '¥'+totalData.totalAmount : '--' }}</strong>
+        </div>
       </a-alert>
       <!-- 列表 -->
       <s-table
@@ -152,7 +155,7 @@ export default {
         { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '费用类型', align: 'center', scopedSlots: { customRender: 'expensesType' } },
         { title: '金额', dataIndex: 'settleAmount', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? ('¥' + text) : '--') } },
-        { title: '单据状态', dataIndex: 'stateDictValue', width: 110, align: 'center' },
+        { title: '单据状态', dataIndex: 'stateDictValue', width: 110, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 200, align: 'center', fixed: 'right' }
       ],
       // 加载数据方法 必须为 Promise 对象

+ 10 - 17
src/views/financialManagement/financialCollection/detailModal.vue

@@ -9,16 +9,16 @@
     @cancle="isShow=false"
     :width="600">
     <!-- 详情 -->
-    <div v-if="detailsData">
+    <div>
       <a-descriptions :column="1" size="default">
-        <a-descriptions-item label="收款单号">{{ detailsData.settleNo || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="关联单号">{{ detailsData.bizNo || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="商户名称">{{ detailsData.settleClientName || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="收款金额">{{ ('¥'+detailsData.settledAmount) || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="收款类型">{{ detailsData.bizTypeDictValue || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="收款方式">{{ detailsData.settleStyleName || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="收款时间">{{ detailsData.settleTime || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="审核时间">{{ detailsData.auditTime || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="收款单号">{{ detailsData&&detailsData.settleNo || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="关联单号">{{ detailsData&&detailsData.bizNo || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="商户名称">{{ detailsData&&detailsData.settleClientName || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="收款金额">{{ '¥'+ (detailsData&&(detailsData.settledAmount || detailsData.settledAmount==0) ? detailsData.settledAmount : '--') }}</a-descriptions-item>
+        <a-descriptions-item label="收款类型">{{ detailsData&&detailsData.bizTypeDictValue || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="收款方式">{{ detailsData&&detailsData.settleStyleName || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="收款时间">{{ detailsData&&detailsData.settleTime || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="审核时间">{{ detailsData&&detailsData.auditTime || '--' }}</a-descriptions-item>
       </a-descriptions>
       <div class="btn-cont"><a-button id="financialPaymentDetail-modal-back" @click="isShow = false">关闭</a-button></div>
     </div>
@@ -42,14 +42,7 @@ export default {
   data () {
     return {
       isShow: this.openModal, //  是否打开弹框
-      // detailsData: null, //  详情数据
-      detailsData: {
-        productName: '',
-        productCode: '',
-        origCode: '',
-        unit: '',
-        productBrandName: ''
-      }
+      detailsData: null
     }
   },
   methods: {

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

@@ -58,13 +58,13 @@
       <a-alert type="info" showIcon style="margin-bottom:15px">
         <div slot="message">
-          <strong>{{ totalData.count }}</strong>
+          <strong>{{ totalData&&(totalData.count || totalData.count==0) ? totalData.count : '--' }}</strong>
           条记录,应收金额合计
-          <strong>{{ totalData.totalAmount }}</strong>
+          <strong>{{ totalData&&(totalData.totalAmount || totalData.totalAmount==0) ? '¥'+totalData.totalAmount : '--' }}</strong>
           ,其中已收金额
-          <strong>{{ totalData.settledAmount }}</strong>
+          <strong>{{ totalData&&(totalData.settledAmount || totalData.settledAmount==0) ? '¥'+totalData.settledAmount : '--' }}</strong>
           ,待收金额
-          <strong>{{ totalData.unsettleAmount }}</strong>
+          <strong>{{ totalData&&(totalData.unsettleAmount || totalData.unsettleAmount==0) ? '¥'+totalData.unsettleAmount : '--' }}</strong>
         </div>
       </a-alert>
       <div v-if="$hasPermissions('B_financialCollectionPl')" style="margin-bottom: 15px">
@@ -175,7 +175,7 @@ export default {
             data.list[i].no = no + i + 1
           }
           this.disabled = false
-          this.totalData.count = data.count
+          this.totalData.count = data.count || 0
           // 查询总计
           this.settleReceiptQuerySum(Object.assign(parameter, this.queryParam))
           return data
@@ -191,15 +191,15 @@ export default {
     rowSelection () {
       if (this.$hasPermissions('B_financialCollectionPl')) {
         return {
-			  selectedRowKeys: this.selectedRowKeys,
-			  onChange: (selectedRowKeys, selectedRows) => {
-			    this.selectedRowKeys = selectedRowKeys
-			  },
-			  getCheckboxProps: record => ({
-			    props: {
-			      disabled: record.settleState == 'SETTLED'
-			    }
-			  })
+          selectedRowKeys: this.selectedRowKeys,
+          onChange: (selectedRowKeys, selectedRows) => {
+            this.selectedRowKeys = selectedRowKeys
+          },
+          getCheckboxProps: record => ({
+            props: {
+              disabled: record.settleState == 'SETTLED'
+            }
+          })
         }
       } else {
         return null

+ 8 - 8
src/views/financialManagement/financialPayment/detailModal.vue

@@ -11,14 +11,14 @@
     <!-- 详情 -->
     <div v-if="detailsData">
       <a-descriptions :column="1" size="default">
-        <a-descriptions-item label="付款单号">{{ detailsData.settleNo || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="关联单号">{{ detailsData.bizNo || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="商户名称">{{ detailsData.settleClientName || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="付款金额">{{ ('¥'+detailsData.settledAmount) || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="付款类型">{{ detailsData.bizTypeDictValue || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="付款方式">{{ detailsData.settleStyleName || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="付款时间">{{ detailsData.settleTime || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="审核时间">{{ detailsData.auditTime || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="付款单号">{{ detailsData&&detailsData.settleNo || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="关联单号">{{ detailsData&&detailsData.bizNo || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="商户名称">{{ detailsData&&detailsData.settleClientName || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="付款金额">{{ detailsData&&(detailsData.settledAmount || detailsData.settledAmount==0) ? '¥'+detailsData.settledAmount : '--' }}</a-descriptions-item>
+        <a-descriptions-item label="付款类型">{{ detailsData&&detailsData.bizTypeDictValue || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="付款方式">{{ detailsData&&detailsData.settleStyleName || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="付款时间">{{ detailsData&&detailsData.settleTime || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="审核时间">{{ detailsData&&detailsData.auditTime || '--' }}</a-descriptions-item>
       </a-descriptions>
       <div class="btn-cont"><a-button id="financialPaymentDetail-modal-back" @click="isShow = false">关闭</a-button></div>
     </div>

+ 4 - 4
src/views/financialManagement/financialPayment/list.vue

@@ -57,13 +57,13 @@
       <a-alert type="info" showIcon style="margin-bottom:15px">
         <div slot="message">
-          <strong>{{ totalData.count }}</strong>
+          <strong>{{ totalData&&(totalData.count || totalData.count==0) ? totalData.count : '--' }}</strong>
           条记录,应付金额合计
-          <strong>{{ totalData.totalAmount }}</strong>
+          <strong>{{ totalData&&(totalData.totalAmount || totalData.totalAmount==0) ? '¥'+totalData.totalAmount : '--' }}</strong>
           ,其中已付金额
-          <strong>{{ totalData.settledAmount }}</strong>
+          <strong>{{ totalData&&(totalData.settledAmount || totalData.settledAmount==0) ? '¥'+totalData.settledAmount : '--' }}</strong>
           ,待付金额
-          <strong>{{ totalData.unsettleAmount }}</strong>
+          <strong>{{ totalData&&(totalData.unsettleAmount || totalData.unsettleAmount==0) ? '¥'+totalData.unsettleAmount : '--' }}</strong>
         </div>
       </a-alert>
       <div v-if="$hasPermissions('B_financialPaymentPl')" style="margin-bottom: 15px">

+ 6 - 3
src/views/financialManagement/ledgerRecord/list.vue

@@ -41,7 +41,10 @@
     </div>
     <!-- alert -->
     <a-alert type="info" showIcon style="margin-bottom:15px">
-      <div slot="message">总计:<strong>{{ total }}</strong>条 ,分账金额:<strong>{{ (totalAmount || totalAmount == 0) ? totalAmount : '--' }}</strong> 元</div>
+      <div slot="message">
+        总计:<strong>{{ total }}</strong>条 ,
+        分账金额:<strong>{{ (totalAmount || totalAmount == 0) ? totalAmount+'元' : '--' }}</strong>
+      </div>
     </a-alert>
     <!-- 列表 -->
     <s-table
@@ -109,7 +112,7 @@ export default {
             data.list[i].no = no + i + 1
           }
           this.disabled = false
-          this.total = data.list.length
+          this.total = data.list.length || 0
           this.getTotal(Object.assign(parameter, this.queryParam))
           return data
         })
@@ -128,7 +131,7 @@ export default {
     getTotal (params) {
       satelliteWHSeparateTotal(params).then(res => {
         if (res.status == 200) {
-          this.totalAmount = res.data || 0
+          this.totalAmount = res.data
         } else {
           this.totalAmount = ''
         }

+ 13 - 13
src/views/financialManagement/warehousingAudit/detail.vue

@@ -21,18 +21,18 @@
       <a-card size="small" :bordered="false" class="warehousingAuditDetail-cont">
         <a-collapse :activeKey="['1']">
           <a-collapse-panel key="1" header="基础信息">
-            <a-descriptions :column="3" v-if="basicInfoData">
+            <a-descriptions :column="3">
               <a-descriptions-item label="供应商">{{ basicInfoData&&basicInfoData.purchaseTargetName ? basicInfoData.purchaseTargetName : '--' }}</a-descriptions-item>
               <a-descriptions-item label="入库时间">{{ basicInfoData&&basicInfoData.stockPutTime ? basicInfoData.stockPutTime : '--' }}</a-descriptions-item>
               <a-descriptions-item label="采购单号">{{ basicInfoData&&basicInfoData.purchaseBillNo ? basicInfoData.purchaseBillNo : '--' }}</a-descriptions-item>
             </a-descriptions>
-            <a-descriptions :column="3" bordered v-if="basicInfoData">
-              <a-descriptions-item label="采购总款数">{{ (basicInfoData.totalCategory&&basicInfoData.totalCategory!=0) ? basicInfoData.totalCategory : 0 }}</a-descriptions-item>
-              <a-descriptions-item label="采购总数量">{{ (basicInfoData.totalQty&&basicInfoData.totalQty!=0) ? basicInfoData.totalQty : 0 }}</a-descriptions-item>
-              <a-descriptions-item label="采购总成本">¥{{ (basicInfoData.totalAmount&&basicInfoData.totalAmount!=0) ? basicInfoData.totalAmount : 0 }}</a-descriptions-item>
-              <a-descriptions-item label="入库总款数">{{ (basicInfoData.totalPutCategory&&basicInfoData.totalPutCategory!=0) ? basicInfoData.totalPutCategory : 0 }}</a-descriptions-item>
-              <a-descriptions-item label="入库总数量">{{ (basicInfoData.totalPutQty&&basicInfoData.totalPutQty!=0) ? basicInfoData.totalPutQty : 0 }}</a-descriptions-item>
-              <a-descriptions-item label="入库总成本">¥{{ (basicInfoData.totalPutAmount&&basicInfoData.totalPutAmount!=0) ? basicInfoData.totalPutAmount : 0 }}</a-descriptions-item>
+            <a-descriptions :column="3" bordered>
+              <a-descriptions-item label="采购总款数">{{ basicInfoData&&(basicInfoData.totalCategory || basicInfoData.totalCategory==0) ? basicInfoData.totalCategory : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="采购总数量">{{ basicInfoData&&(basicInfoData.totalQty || basicInfoData.totalQty==0) ? basicInfoData.totalQty : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="采购总成本">{{ basicInfoData&&(basicInfoData.totalAmount || basicInfoData.totalAmount==0) ? '¥'+basicInfoData.totalAmount : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="入库总款数">{{ basicInfoData&&(basicInfoData.totalPutCategory || basicInfoData.totalPutCategory==0) ? basicInfoData.totalPutCategory : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="入库总数量">{{ basicInfoData&&(basicInfoData.totalPutQty || basicInfoData.totalPutQty==0) ? basicInfoData.totalPutQty : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="入库总成本">{{ basicInfoData&&(basicInfoData.totalPutAmount || basicInfoData.totalPutAmount==0) ? '¥'+basicInfoData.totalPutAmount : '--' }}</a-descriptions-item>
             </a-descriptions>
           </a-collapse-panel>
         </a-collapse>
@@ -72,14 +72,14 @@ export default {
       // 表头
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center', fixed: 'left' },
-        { title: '产品编码', dataIndex: 'dealerProductEntity.code', width: 220, align: 'center' },
-        { title: '产品名称', dataIndex: 'dealerProductEntity.name', align: 'center', ellipsis: true },
-        { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: 220, align: 'center' },
+        { title: '产品编码', dataIndex: 'dealerProductEntity.code', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品名称', dataIndex: 'dealerProductEntity.name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '采购数量', dataIndex: 'qty', width: 110, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '入库数量', dataIndex: 'putQty', width: 110, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '成本价', dataIndex: 'price', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '单位', dataIndex: 'dealerProductEntity.unit', width: 100, align: 'center' },
-        { title: '入库小计', dataIndex: 'totalAmount', width: 100, align: 'center' },
+        { title: '单位', dataIndex: 'dealerProductEntity.unit', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '入库小计', dataIndex: 'totalAmount', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '仓库', dataIndex: 'warehouseEntity.name', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '仓位', dataIndex: 'warehouseLocationEntity.name', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true }
       ],

+ 4 - 1
src/views/financialManagement/warehousingAudit/list.vue

@@ -48,7 +48,10 @@
       </div>
       <!-- alert -->
       <a-alert type="info" showIcon style="margin-bottom:15px">
-        <div slot="message">共 <strong>{{ (productTotal&&productTotal.totalRecord) || 0 }}</strong> 条记录,其中待审核 <strong>{{ (productTotal&&productTotal.waitAuditRecord) || 0 }}</strong> 条 </div>
+        <div slot="message">
+          共 <strong>{{ (productTotal&&(productTotal.totalRecord || productTotal.totalRecord==0)) ? productTotal.totalRecord : '--' }}</strong> 条记录,
+          其中待审核 <strong>{{ (productTotal&&(productTotal.waitAuditRecord || productTotal.waitAuditRecord==0)) ? productTotal.waitAuditRecord : '--' }}</strong> 条
+        </div>
       </a-alert>
       <!-- 列表 -->
       <s-table

+ 1 - 1
src/views/financialManagement/withdrawalManagement/list.vue

@@ -21,7 +21,7 @@
     <!-- 操作按钮 -->
     <div class="table-operator">
       <a-button v-if="$hasPermissions('B_withdrawalManagement_cashOut')" id="withdrawalManagementList-tx" type="primary" class="button-warning" @click="handleCashOut">申请提现</a-button>
-      <div style="display: inline-block;margin-left: 80px;">可提现余额: <strong>{{ accountInfo&&(accountInfo.balance || accountInfo.balance==0) ? accountInfo.balance : '--' }}</strong> 元</div>
+      <div style="display: inline-block;margin-left: 80px;">可提现余额: <strong>{{ accountInfo&&(accountInfo.balance || accountInfo.balance==0) ? '¥'+accountInfo.balance : '--' }}</strong> 元</div>
     </div>
     <!-- 列表 -->
     <s-table

+ 6 - 9
src/views/inventoryManagement/inventoryQuery/detailModal.vue

@@ -10,7 +10,10 @@
     :width="960">
     <!-- 合计 -->
     <a-alert type="info" showIcon style="margin-bottom:15px">
-      <div class="ftext" slot="message">现有库存总数量(个):<strong>{{ currentStock.currentQty || 0 }}</strong>;现有库存总成本(¥):<strong>{{ currentStock.putCost || 0 }}</strong>。</div>
+      <div class="ftext" slot="message">
+        现有库存总数量(个):<strong>{{ currentStock&&(currentStock.currentQty || currentStock.currentQty==0) ? currentStock.currentQty : '--' }}</strong>;
+        现有库存总成本(¥):<strong>{{ currentStock&&(currentStock.putCost || currentStock.putCost==0) ? currentStock.putCost : '--' }}</strong>。
+      </div>
     </a-alert>
     <!-- 库存详情 -->
     <s-table
@@ -87,10 +90,7 @@ export default {
           return data
         })
       },
-      currentStock: { // 合计信息
-        currentQty: '',
-        putCost: ''
-      }
+      currentStock: null
     }
   },
   methods: {
@@ -100,10 +100,7 @@ export default {
         if (res.status == 200 && res.data) {
           this.currentStock = res.data
         } else {
-          this.currentStock = { // 合计信息
-            currentQty: '',
-            putCost: ''
-          }
+          this.currentStock = null
         }
       })
     }

+ 4 - 1
src/views/inventoryManagement/inventoryQuery/list.vue

@@ -76,7 +76,10 @@
       </div>
       <!-- 合计 -->
       <a-alert type="info" showIcon style="margin-bottom:15px">
-        <div class="ftext" slot="message">现有库存总数量(个):<strong>{{ currentStock.currentStockQty || 0 }}</strong>;现有库存总成本(¥):<strong>{{ currentStock.currentStockCost || 0 }}</strong>。</div>
+        <div class="ftext" slot="message">
+          现有库存总数量(个):<strong>{{ currentStock&&(currentStock.currentStockQty || currentStock.currentStockQty==0) ? currentStock.currentStockQty : '--' }}</strong>;
+          现有库存总成本(¥):<strong>{{ currentStock&&(currentStock.currentStockCost || currentStock.currentStockCost==0) ? currentStock.currentStockCost : '--' }}</strong>。
+        </div>
       </a-alert>
       <!-- 列表 -->
       <s-table

+ 4 - 1
src/views/inventoryManagement/inventoryQuery/warehouseDetail.vue

@@ -65,7 +65,10 @@
       </div>
       <!-- 合计 -->
       <a-alert type="info" showIcon style="margin-bottom:15px">
-        <div class="ftext" slot="message">当前库存总数量(个):<strong>{{ (productTotal&&productTotal.totalQty) ? productTotal.totalQty : 0 }}</strong>;当前库存总成本(¥):<strong>{{ (productTotal&&productTotal.totalCost) ? productTotal.totalCost : 0 }}</strong>。</div>
+        <div class="ftext" slot="message">
+          当前库存总数量(个):<strong>{{ (productTotal&&(productTotal.totalQty || productTotal.totalQty==0)) ? productTotal.totalQty : '--' }}</strong>;
+          当前库存总成本(¥):<strong>{{ (productTotal&&(productTotal.totalCost || productTotal.totalCost==0)) ? productTotal.totalCost : '--' }}</strong>。
+        </div>
       </a-alert>
       <!-- 列表 -->
       <s-table

+ 2 - 2
src/views/inventoryManagement/warehouse/storingLocation/list.vue

@@ -5,7 +5,7 @@
         <!-- 自定义的二级文字标题 -->
         <template slot="subTitle">
           <a id="storingLocationList-back-btn" href="javascript:;" @click="handleBack"><a-icon type="left" /> 返回列表</a>
-          <strong style="color: rgba(0, 0, 0, 0.65);margin-left: 50px;">所属仓库:{{ $route.query.name }}</strong>
+          <strong style="color: rgba(0, 0, 0, 0.65);margin-left: 50px;">所属仓库:{{ $route.query.name || '--' }}</strong>
         </template>
       </a-page-header>
       <a-card size="small" :bordered="false" class="storingLocationList-cont">
@@ -83,7 +83,7 @@ export default {
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '仓位名称', dataIndex: 'name', align: 'center', ellipsis: true },
+        { title: '仓位名称', dataIndex: 'name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '排序', dataIndex: 'sort', align: 'center', width: 150, customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 160, align: 'center' }
       ],

+ 20 - 11
src/views/notice/detailModal.vue

@@ -12,10 +12,11 @@
       <a-descriptions bordered size="small" :column="2">
         <a-descriptions-item label="类别">{{ typeDictValue }}</a-descriptions-item>
         <a-descriptions-item label="可见性">{{ toAppNameDictValue }}</a-descriptions-item>
-        <a-descriptions-item label="公告标题">{{ detailsData.title||'--' }}</a-descriptions-item>
-        <a-descriptions-item label="发布时间">{{ detailsData.releaseDate||'--' }}</a-descriptions-item>
+        <a-descriptions-item label="公告标题">{{ detailsData&&detailsData.title||'--' }}</a-descriptions-item>
+        <a-descriptions-item label="发布时间">{{ detailsData&&detailsData.releaseDate||'--' }}</a-descriptions-item>
         <a-descriptions-item label="公告内容" :span="2">
-          <div v-html="detailsData.content" class="editor-box"></div>
+          <div v-if="detailsData&&detailsData.content" v-html="detailsData.content" class="editor-box"></div>
+          <span v-else>--</span>
         </a-descriptions-item>
         <a-descriptions-item label="图片" :span="2">
           <div style="display: flex;">
@@ -61,11 +62,11 @@ export default {
   computed: {
     typeDictValue () { //  类别  数据字典name
       let str = ''
-      if (this.detailsData.type == 'notity') {
+      if (this.detailsData&&this.detailsData.type == 'notity') {
         str = '公告'
-      } else if (this.detailsData.type == 'news_company') {
+      } else if (this.detailsData&&this.detailsData.type == 'news_company') {
         str = '企业新闻'
-      } else if (this.detailsData.type == 'news_trade') {
+      } else if (this.detailsData&&this.detailsData.type == 'news_trade') {
         str = '行业咨询'
       } else {
         str = '--'
@@ -74,11 +75,11 @@ export default {
     },
     toAppNameDictValue () { //  可见性  数据字典name
       let str = ''
-      if (this.detailsData.toAppName == '1,2') {
+      if (this.detailsData&&this.detailsData.toAppName == '1,2') {
         str = '所有'
-      } else if (this.detailsData.toAppName == '2') {
+      } else if (this.detailsData&&this.detailsData.toAppName == '2') {
         str = '经销商'
-      } else if (this.detailsData.toAppName == '1') {
+      } else if (this.detailsData&&this.detailsData.toAppName == '1') {
         str = '总部'
       } else {
         str = '--'
@@ -86,10 +87,18 @@ export default {
       return str
     },
     imgPathsArr () { //  图片数组
-      return this.detailsData.imgPaths ? this.detailsData.imgPaths.split(',') : []
+      let arr = []
+      if(this.detailsData && this.detailsData.imgPaths){
+        arr = this.detailsData.imgPaths.split(',')
+      }
+      return arr
     },
     attachPathsArr () { //  附件数组
-      return this.detailsData.attachList ? this.detailsData.attachList : []
+      let arr = []
+      if(this.detailsData && this.detailsData.attachList){
+        arr = this.detailsData.attachList
+      }
+      return arr
     }
   },
   data () {

+ 1 - 1
src/views/productManagement/priceChangeRecord/list.vue

@@ -181,7 +181,7 @@ export default {
         { title: '序号', dataIndex: 'no', width: 80, align: 'center', fixed: 'left' },
         { title: '变更时间', dataIndex: 'updateDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '产品名称', dataIndex: 'productEntity.name', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
-        { title: '产品编码', dataIndex: 'productEntity.code', align: 'center' },
+        { title: '产品编码', dataIndex: 'productEntity.code', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '品牌', dataIndex: 'productEntity.productBrandName', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '产品分类', scopedSlots: { customRender: 'productType' }, align: 'center' },
         { title: '单位', dataIndex: 'productEntity.unit', width: 100, align: 'center', customRender: function (text) { return text || '--' } }

+ 1 - 1
src/views/productManagement/productBrand/list.vue

@@ -85,7 +85,7 @@ export default {
         { title: '序号', dataIndex: 'no', width: 70, align: 'center' },
         { title: '产品品牌名称', dataIndex: 'brandName', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
         { title: '首字母', dataIndex: 'firstChar', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '创建时间', dataIndex: 'createDate', align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '状态', scopedSlots: { customRender: 'enabledFlag' }, width: 160, align: 'center' },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 120, align: 'center' }
       ],

+ 2 - 2
src/views/productManagement/productCategory/list.vue

@@ -67,8 +67,8 @@ export default {
         wrapperCol: { span: 16 }
       },
       columns: [
-        { title: '分类名称', dataIndex: 'productTypeName', align: 'left' },
-        { title: '创建时间', dataIndex: 'createDate', width: 320, align: 'center' },
+        { title: '分类名称', dataIndex: 'productTypeName', align: 'left', customRender: function (text) { return text || '--' } },
+        { title: '创建时间', dataIndex: 'createDate', width: 320, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 300, align: 'center' }
       ],
       // 加载数据方法 必须为 Promise 对象

+ 9 - 9
src/views/productManagement/productInfo/detailModal.vue

@@ -9,17 +9,17 @@
     @cancle="isShow=false"
     :width="800">
     <!-- 产品详情 -->
-    <div v-if="detailsData">
+    <div>
       <a-descriptions bordered :column="2" size="small">
-        <a-descriptions-item label="产品名称:">{{ detailsData.name || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="产品编码:">{{ detailsData.code || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="原厂编码:">{{ detailsData.origCode || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="基本单位:">{{ detailsData.unit || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="产品品牌:">{{ detailsData.productBrandName || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="产品名称:">{{ detailsData&&detailsData.name || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="产品编码:">{{ detailsData&&detailsData.code || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="原厂编码:">{{ detailsData&&detailsData.origCode || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="基本单位:">{{ detailsData&&detailsData.unit || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="产品品牌:">{{ detailsData&&detailsData.productBrandName || '--' }}</a-descriptions-item>
         <a-descriptions-item label="产品分类:">{{ productTypeName || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="经销批发价:">{{ (detailsData.specialPrice || detailsData.specialPrice==0) ? detailsData.specialPrice : '--' }}</a-descriptions-item>
-        <a-descriptions-item label="终端价:">{{ (detailsData.terminalPrice || detailsData.terminalPrice==0) ? detailsData.terminalPrice : '--' }}</a-descriptions-item>
-        <a-descriptions-item label="车主价:">{{ (detailsData.carOwnersPrice || detailsData.carOwnersPrice==0) ? detailsData.carOwnersPrice : '--' }}</a-descriptions-item>
+        <a-descriptions-item label="经销批发价:">{{ detailsData&&(detailsData.specialPrice || detailsData.specialPrice==0) ? detailsData.specialPrice : '--' }}</a-descriptions-item>
+        <a-descriptions-item label="终端价:">{{ detailsData&&(detailsData.terminalPrice || detailsData.terminalPrice==0) ? detailsData.terminalPrice : '--' }}</a-descriptions-item>
+        <a-descriptions-item label="车主价:">{{ detailsData&&(detailsData.carOwnersPrice || detailsData.carOwnersPrice==0) ? detailsData.carOwnersPrice : '--' }}</a-descriptions-item>
       </a-descriptions>
       <div class="btn-cont"><a-button id="product-management-detail-modal-back" @click="isShow = false">返回列表</a-button></div>
     </div>

+ 2 - 2
src/views/productManagement/productInfo/list.vue

@@ -159,7 +159,7 @@ export default {
       exportLoading: false, // 导出loading
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '产品编码', dataIndex: 'code', width: 220, align: 'center' },
+        { title: '产品编码', dataIndex: 'code', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '产品名称', dataIndex: 'name', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
         { title: '原厂编码', dataIndex: 'origCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '产品品牌', dataIndex: 'productBrandName', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
@@ -167,7 +167,7 @@ export default {
         { title: '经销批发价', dataIndex: 'specialPrice', width: 110, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '终端价', dataIndex: 'terminalPrice', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '车主价', dataIndex: 'carOwnersPrice', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '状态', scopedSlots: { customRender: 'enabledFlag' }, width: 140, align: 'center', fixed: 'right' },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 150, align: 'center', fixed: 'right' }
       ],

+ 0 - 4
src/views/productManagement/productInfoJg/list.vue

@@ -134,10 +134,6 @@ export default {
           const no = (data.pageNo - 1) * data.pageSize
           for (var i = 0; i < data.list.length; i++) {
             data.list[i].no = no + i + 1
-            const productTypeName1 = data.list[i].productTypeName1 ? data.list[i].productTypeName1 : ''
-            const productTypeName2 = data.list[i].productTypeName2 ? ' > ' + data.list[i].productTypeName2 : ''
-            const productTypeName3 = data.list[i].productTypeName3 ? ' > ' + data.list[i].productTypeName3 : ''
-            data.list[i].productTypeName = productTypeName1 + productTypeName2 + productTypeName3
           }
           this.disabled = false
           return data

+ 22 - 19
src/views/purchasingManagement/purchaseOrder/detail.vue

@@ -25,14 +25,17 @@
           <a-collapse-panel key="1" header="基础信息">
             <a-descriptions :column="3">
               <a-descriptions-item label="供应商">{{ (detail&&detail.purchaseTargetName) || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="支付方式">{{ detail&&detail.settleStyleEntity.name }}</a-descriptions-item>
-              <a-descriptions-item label="采购员工">{{ detail&&detail.operatorName }}</a-descriptions-item>
-              <a-descriptions-item label="收货人">{{ detail&&detail.consigneeName }}<span v-if="detail&&detail.consigneeTel">({{ detail&&detail.consigneeTel }})</span></a-descriptions-item>
+              <a-descriptions-item label="支付方式">{{ (detail&&detail.settleStyleEntity&&detail.settleStyleEntity.name) || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="采购员工">{{ detail&&detail.operatorName || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="收货人">{{ detail&&detail.consigneeName || '--' }}<span v-if="detail&&detail.consigneeTel">({{ detail&&detail.consigneeTel }})</span></a-descriptions-item>
               <a-descriptions-item label="收货地址">
-                {{ detail&&detail.shippingAddressProvinceName }}
-                {{ detail&&detail.shippingAddressCityName }}
-                {{ detail&&detail.shippingAddressCountyName }}
-                {{ detail&&detail.shippingAddress }}
+                <div v-if="detail&&(detail.shippingAddressProvinceName || detail.shippingAddressCityName || detail.shippingAddressCountyName || detail.shippingAddress)">
+                  {{ detail&&detail.shippingAddressProvinceName || '' }}
+                  {{ detail&&detail.shippingAddressCityName || '' }}
+                  {{ detail&&detail.shippingAddressCountyName || '' }}
+                  {{ detail&&detail.shippingAddress || '' }}
+                </div>
+                <span v-else>--</span>
               </a-descriptions-item>
             </a-descriptions>
           </a-collapse-panel>
@@ -45,15 +48,15 @@
             <!-- 总计 -->
             <a-alert type="info" showIcon style="margin-bottom:15px">
               <div slot="message">
-                产品款数:<strong>{{ detail ? ((detail.totalCategory || detail.totalCategory==0) ? detail.totalCategory : '--') : '--' }}</strong>,
-                采购数量合计:<strong>{{ detail ? ((detail.totalQty || detail.totalQty==0) ? detail.totalQty : '--') : '--' }}</strong>,
-                已收货数量:<strong>{{ detail ? ((detail.totalPutQty || detail.totalPutQty==0) ? detail.totalPutQty : '--') : '--' }}</strong>,
-                待收货数量:<strong>{{ detail ? ((detail.totalWaitPutQty || detail.totalWaitPutQty==0) ? detail.totalWaitPutQty : '--') : '--' }}</strong>,
-                取消数量:<strong>{{ detail ? ((detail.totalCancelQty || detail.totalCancelQty==0) ? detail.totalCancelQty : '--') : '--' }}</strong>,
-                采购金额合计:¥<strong>{{ detail ? ((detail.discountedAmount || detail.discountedAmount==0) ? detail.discountedAmount : '--') : '--' }}</strong>,
-                已收货金额:¥<strong>{{ detail ? ((detail.totalPutAmount || detail.totalPutAmount==0) ? detail.totalPutAmount : '--') : '--' }}</strong>,
-                待收货金额:¥<strong>{{ detail ? ((detail.totalWaitPutAmount || detail.totalWaitPutAmount==0) ? detail.totalWaitPutAmount : '--') : '--' }}</strong>,
-                取消金额:¥<strong>{{ detail ? ((detail.totalCancelAmount || detail.totalCancelAmount==0) ? detail.totalCancelAmount : '--') : '--' }}</strong>
+                产品款数:<strong>{{ detail && (detail.totalCategory || detail.totalCategory==0) ? detail.totalCategory : '--' }}</strong>,
+                采购数量合计:<strong>{{ detail && (detail.totalQty || detail.totalQty==0) ? detail.totalQty : '--' }}</strong>,
+                已收货数量:<strong>{{ detail && (detail.totalPutQty || detail.totalPutQty==0) ? detail.totalPutQty : '--' }}</strong>,
+                待收货数量:<strong>{{ detail && (detail.totalWaitPutQty || detail.totalWaitPutQty==0) ? detail.totalWaitPutQty : '--' }}</strong>,
+                取消数量:<strong>{{ detail && (detail.totalCancelQty || detail.totalCancelQty==0) ? detail.totalCancelQty : '--' }}</strong>,
+                采购金额合计:<strong>{{ detail && (detail.discountedAmount || detail.discountedAmount==0) ? '¥'+detail.discountedAmount : '--' }}</strong>,
+                已收货金额:<strong>{{ detail && (detail.totalPutAmount || detail.totalPutAmount==0) ? '¥'+detail.totalPutAmount : '--' }}</strong>,
+                待收货金额:<strong>{{ detail && (detail.totalWaitPutAmount || detail.totalWaitPutAmount==0) ? '¥'+detail.totalWaitPutAmount : '--' }}</strong>,
+                取消金额:<strong>{{ detail && (detail.totalCancelAmount || detail.totalCancelAmount==0) ? '¥'+detail.totalCancelAmount : '--' }}</strong>
               </div>
             </a-alert>
             <!-- 列表 -->
@@ -85,9 +88,9 @@
           <a-collapse-panel key="1" header="促销品详情">
             <!-- 总计 -->
             <a-alert type="info" showIcon style="margin-bottom:15px">
-              <div slot="message">产品款数 <strong>{{ detail&&detail.totalCategory }}</strong> ,
-                采购数量合计 <strong>{{ detail&&detail.totalQty }}</strong> ,
-                采购金额合计¥<strong>{{ detail&&detail.totalAmount }}</strong></div>
+              <div slot="message">产品款数 <strong>{{ detail&&(detail.totalCategory || detail.totalCategory==0) ? detail.totalCategory : '--' }}</strong> ,
+                采购数量合计 <strong>{{ detail&&(detail.totalQty || detail.totalQty==0) ? detail.totalQty : '--' }}</strong> ,
+                采购金额合计 <strong>{{ detail&&(detail.totalAmount || detail.totalAmount==0) ? '¥'+detail.totalAmount : '--' }}</strong></div>
             </a-alert>
             <!-- 列表 -->
             <s-table

+ 13 - 10
src/views/purchasingManagement/purchaseOrder/edit.vue

@@ -33,14 +33,17 @@
                 @click.stop="handleEditInfo" /> -->
             </template>
             <a-descriptions :column="2">
-              <a-descriptions-item label="供应商">{{ detail&&detail.purchaseTargetName }}</a-descriptions-item>
-              <a-descriptions-item label="支付方式">{{ detail&&detail.settleStyleEntity.name }}</a-descriptions-item>
-              <a-descriptions-item label="收货人">{{ detail&&detail.consigneeName }}({{ detail&&detail.consigneeTel }})</a-descriptions-item>
+              <a-descriptions-item label="供应商">{{ detail&&detail.purchaseTargetName || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="支付方式">{{ detail&&detail.settleStyleEntity&&detail.settleStyleEntity.name || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="收货人">{{ detail&&detail.consigneeName || '--' }}({{ detail&&detail.consigneeTel || '--' }})</a-descriptions-item>
               <a-descriptions-item label="收货地址">
-                {{ detail&&detail.shippingAddressProvinceName }} -
-                {{ detail&&detail.shippingAddressCityName }} -
-                {{ detail&&detail.shippingAddressCountyName }} -
-                {{ detail&&detail.shippingAddress }}
+                <div v-if="detail&&(detail.shippingAddressProvinceName || detail.shippingAddressCityName || detail.shippingAddressCountyName || detail.shippingAddress)">
+                  {{ detail&&detail.shippingAddressProvinceName || '' }}
+                  {{ detail&&detail.shippingAddressCityName || '' }}
+                  {{ detail&&detail.shippingAddressCountyName || '' }}
+                  {{ detail&&detail.shippingAddress || '' }}
+                </div>
+                <span v-else>--</span>
               </a-descriptions-item>
             </a-descriptions>
           </a-collapse-panel>
@@ -147,9 +150,9 @@
             <div>
               <!-- 总计 -->
               <a-alert type="info" showIcon style="margin-bottom:15px">
-                <div slot="message">产品款数 <strong>{{ detail ? ((detail.totalCategory || detail.totalCategory==0) ? detail.totalCategory : '--') : '--' }}</strong> ,
-                  采购数量合计 <strong>{{ detail ? ((detail.totalQty || detail.totalQty==0) ? detail.totalQty : '--') : '--' }}</strong> ,
-                  采购金额合计¥<strong>{{ detail ? ((detail.discountedAmount || detail.discountedAmount==0) ? detail.discountedAmount : '--') : '--' }}</strong></div>
+                <div slot="message">产品款数 <strong>{{ detail && (detail.totalCategory || detail.totalCategory==0) ? detail.totalCategory : '--' }}</strong> ,
+                  采购数量合计 <strong>{{ detail && (detail.totalQty || detail.totalQty==0) ? detail.totalQty : '--' }}</strong> ,
+                  采购金额合计 <strong>{{ detail && (detail.discountedAmount || detail.discountedAmount==0) ? '¥'+detail.discountedAmount : '--' }}</strong></div>
               </a-alert>
               <!-- 列表 -->
               <s-table

+ 5 - 1
src/views/purchasingManagement/purchaseOrder/list.vue

@@ -71,7 +71,11 @@
       </div>
       <!-- alert -->
       <a-alert type="info" showIcon style="margin-bottom:15px">
-        <div slot="message">共 <strong>{{ totalData.totalRecord }}</strong> 条记录,采购数量合计 <strong>{{ totalData.totalQty }}</strong> ,采购金额合计¥<strong>{{ totalData.totalAmount }}</strong> </div>
+        <div slot="message">
+          共 <strong>{{ totalData&&(totalData.totalRecord || totalData.totalRecord==0) ? totalData.totalRecord : '--' }}</strong> 条记录,
+          采购数量合计 <strong>{{ totalData&&(totalData.totalQty || totalData.totalQty==0) ? totalData.totalQty : '--' }}</strong> ,
+          采购金额合计 <strong>{{ totalData&&(totalData.totalAmount || totalData.totalAmount==0) ? '¥'+totalData.totalAmount : '--' }}</strong>
+        </div>
       </a-alert>
       <!-- 列表 -->
       <s-table

+ 8 - 8
src/views/purchasingManagement/purchaseReturn/detail.vue

@@ -22,14 +22,14 @@
     <a-card size="small" :bordered="false" class="purchaseReturnDetail-cont">
       <a-collapse :activeKey="['1']">
         <a-collapse-panel key="1" header="基础信息">
-          <a-descriptions :column="3" v-if="basicInfoData">
-            <a-descriptions-item label="客户名称">{{ basicInfoData.returnTargetName || '--' }}</a-descriptions-item>
-            <a-descriptions-item label="采退单号">{{ basicInfoData.purchaseReturnNo || '--' }}</a-descriptions-item>
-            <a-descriptions-item label="创建时间">{{ basicInfoData.createDate || '--' }}</a-descriptions-item>
-            <a-descriptions-item label="退货数量">{{ basicInfoData.totalQty || basicInfoData.totalQty==0 ? basicInfoData.totalQty : '--' }}</a-descriptions-item>
-            <a-descriptions-item label="坏件数量">{{ basicInfoData.totalBadQty || basicInfoData.totalBadQty == 0 ? basicInfoData.totalBadQty : '--' }}</a-descriptions-item>
-            <a-descriptions-item label="返库数量">{{ basicInfoData.totalBackStockQty || basicInfoData.totalBackStockQty == 0 ? basicInfoData.totalBackStockQty : '--' }}</a-descriptions-item>
-            <a-descriptions-item label="退货金额">{{ basicInfoData.totalAmount || basicInfoData.totalAmount == 0 ? basicInfoData.totalAmount : '--' }}</a-descriptions-item>
+          <a-descriptions :column="3">
+            <a-descriptions-item label="客户名称">{{ basicInfoData&&basicInfoData.returnTargetName || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="采退单号">{{ basicInfoData&&basicInfoData.purchaseReturnNo || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="创建时间">{{ basicInfoData&&basicInfoData.createDate || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="退货数量">{{ basicInfoData&&(basicInfoData.totalQty || basicInfoData.totalQty==0) ? basicInfoData.totalQty : '--' }}</a-descriptions-item>
+            <a-descriptions-item label="坏件数量">{{ basicInfoData&&(basicInfoData.totalBadQty || basicInfoData.totalBadQty == 0) ? basicInfoData.totalBadQty : '--' }}</a-descriptions-item>
+            <a-descriptions-item label="返库数量">{{ basicInfoData&&(basicInfoData.totalBackStockQty || basicInfoData.totalBackStockQty == 0) ? basicInfoData.totalBackStockQty : '--' }}</a-descriptions-item>
+            <a-descriptions-item label="退货金额">{{ basicInfoData&&(basicInfoData.totalAmount || basicInfoData.totalAmount == 0) ? basicInfoData.totalAmount : '--' }}</a-descriptions-item>
           </a-descriptions>
         </a-collapse-panel>
       </a-collapse>

+ 1 - 1
src/views/purchasingManagement/purchaseReturn/edit.vue

@@ -5,7 +5,7 @@
         <!-- 自定义的二级文字标题 -->
         <template slot="subTitle">
           <a id="purchaseReturnEdit-back-btn" href="javascript:;" @click="handleBack"><a-icon type="left" /> 返回列表</a>
-          <span style="margin: 0 15px;color: #666;">供应商名称:{{ $route.params.name }}</span>
+          <span style="margin: 0 15px;color: #666;">供应商名称:{{ $route.params.name || '--' }}</span>
         </template>
       </a-page-header>
       <!-- 选择产品 -->

+ 3 - 3
src/views/reportData/chainSalesDetailReport/list.vue

@@ -156,9 +156,9 @@
       <a-alert type="info" showIcon style="margin-bottom:15px">
         <div class="ftext" slot="message">
           产品总数量:<strong>{{ (totalData && (totalData.totalQty || totalData.totalQty==0)) ? totalData.totalQty : '--' }}</strong>;
-          总成本:<strong>{{ (totalData && (totalData.totalCost || totalData.totalCost==0)) ? totalData.totalCost : '--' }}</strong>;
-          总售价:<strong>{{ (totalData && (totalData.totalPrice || totalData.totalPrice==0)) ? totalData.totalPrice : '--' }}</strong>;
-          总毛利:<strong>{{ (totalData && (totalData.totalProfit || totalData.totalProfit==0)) ? totalData.totalProfit : '--' }}</strong>。
+          总成本:<strong>{{ (totalData && (totalData.totalCost || totalData.totalCost==0)) ? '¥'+totalData.totalCost : '--' }}</strong>;
+          总售价:<strong>{{ (totalData && (totalData.totalPrice || totalData.totalPrice==0)) ? '¥'+totalData.totalPrice : '--' }}</strong>;
+          总毛利:<strong>{{ (totalData && (totalData.totalProfit || totalData.totalProfit==0)) ? '¥'+totalData.totalProfit : '--' }}</strong>。
         </div>
       </a-alert>
       <!-- 列表 -->

+ 3 - 3
src/views/reportData/chainSalesReport/list.vue

@@ -106,9 +106,9 @@
         <div class="ftext" slot="message">
           总单数:<strong>{{ (totalData && (totalData.totalRowSize || totalData.totalRowSize==0)) ? totalData.totalRowSize : '--' }}</strong>;
           产品总数量:<strong>{{ (totalData && (totalData.totalQty || totalData.totalQty==0)) ? totalData.totalQty : '--' }}</strong>;
-          总成本:<strong>{{ (totalData && (totalData.totalCost || totalData.totalCost==0)) ? totalData.totalCost : '--' }}</strong>;
-          总售价:<strong>{{ (totalData && (totalData.totalPrice || totalData.totalPrice==0)) ? totalData.totalPrice : '--' }}</strong>;
-          总毛利:<strong>{{ (totalData && (totalData.totalProfit || totalData.totalProfit==0)) ? totalData.totalProfit : '--' }}</strong>。
+          总成本:<strong>{{ (totalData && (totalData.totalCost || totalData.totalCost==0)) ? '¥'+totalData.totalCost : '--' }}</strong>;
+          总售价:<strong>{{ (totalData && (totalData.totalPrice || totalData.totalPrice==0)) ? '¥'+totalData.totalPrice : '--' }}</strong>;
+          总毛利:<strong>{{ (totalData && (totalData.totalProfit || totalData.totalProfit==0)) ? '¥'+totalData.totalProfit : '--' }}</strong>。
         </div>
       </a-alert>
       <!-- 列表 -->

+ 12 - 33
src/views/salesManagement/giftRecord/list.vue

@@ -27,16 +27,7 @@
             </a-col>
             <a-col :md="6" :sm="24">
               <a-form-item label="赠送客户">
-                <a-select
-                  id="giftRecordList-customerSn"
-                  placeholder="请选择"
-                  allowClear
-                  v-model="queryParam.customerSn"
-                  :showSearch="true"
-                  option-filter-prop="children"
-                  :filter-option="filterOption">
-                  <a-select-option v-for="item in custAllList" :key="item.customerSn" :value="item.customerSn">{{ item.customerName }}</a-select-option>
-                </a-select>
+                <custList ref="custList" @change="custChange" v-model="queryParam.customerSn"></custList>
               </a-form-item>
             </a-col>
           </template>
@@ -66,12 +57,12 @@
 </template>
 
 <script>
-import { custAllList } from '@/api/customer'
-import { giftsDetailList } from '@/api/dealerProduct'
 import { STable, VSelect } from '@/components'
+import custList from '@/views/common/custList.vue'
 import rangeDate from '@/views/common/rangeDate.vue'
+import { giftsDetailList } from '@/api/dealerProduct'
 export default {
-  components: { STable, VSelect, rangeDate },
+  components: { STable, VSelect, rangeDate, custList },
   data () {
     return {
       tableHeight: 0,
@@ -112,8 +103,7 @@ export default {
           this.disabled = false
           return data
         })
-      },
-      custAllList: [] //  客户下拉数据
+      }
     }
   },
   methods: {
@@ -122,21 +112,9 @@ export default {
       this.queryParam.beginDate = date[0]
       this.queryParam.endDate = date[1]
     },
-    // 客户无分页列表数据
-    getCustAllList () {
-      const _this = this
-      custAllList().then(res => {
-        if (res.status == 200) {
-          _this.custAllList = res.data || []
-        } else {
-          _this.custAllList = []
-        }
-      })
-    },
-    filterOption (input, option) {
-      return (
-        option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
-      )
+    // 客户 change
+    custChange (obj) {
+      this.queryParam.customerSn = obj.key || undefined
     },
     //  重置
     resetSearchForm () {
@@ -147,13 +125,14 @@ export default {
       this.queryParam.productOrigCode = ''
       this.queryParam.salesBillNo = ''
       this.queryParam.customerSn = undefined
+      if (this.advanced) {
+        this.$refs.custList.resetForm()
+      }
       this.$refs.table.refresh(true)
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getCustAllList()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 9 - 44
src/views/salesManagement/salesQuery/chooseCustomModal.vue

@@ -21,15 +21,7 @@
         <a-row :gutter="15">
           <a-col :span="8">
             <a-form-model-item label="客户名称" prop="buyerSn">
-              <a-select
-                id="chooseCustom-buyerSn"
-                show-search
-                placeholder="请选择客户"
-                v-model="form.buyerSn"
-                :filter-option="filterOption"
-                @change="custChange">
-                <a-select-option v-for="item in custAllList" :key="item.id" :value="item.customerSn">{{ item.customerName }}</a-select-option>
-              </a-select>
+              <custList ref="custList" id="chooseCustom-buyerSn" @change="custChange" v-model="form.buyerSn"></custList>
             </a-form-model-item>
           </a-col>
           <a-col :span="16" v-if="$hasPermissions('B_customer_customerInfo_add')">
@@ -196,15 +188,16 @@
 
 <script>
 import { getArea } from '@/api/data'
-import { custAllList, custFindById, custSave, updateByCustomerSn } from '@/api/customer'
+import { custFindById, updateByCustomerSn } from '@/api/customer'
 import { salesSave } from '@/api/sales'
 import { getUserAllList } from '@/api/power-user'
 import { settleStyleQueryAll } from '@/api/settleStyle'
 import { VSelect } from '@/components'
+import custList from '@/views/common/custList.vue'
 import CustomerManagementEdit from '@/views/customerManagement/customerInfo/edit.vue'
 export default {
   name: 'ChooseCustomModal',
-  components: { VSelect, CustomerManagementEdit },
+  components: { VSelect, CustomerManagementEdit, custList },
   props: {
     show: [Boolean]
   },
@@ -273,7 +266,6 @@ export default {
         //   { required: true, message: '请选择业务员', trigger: 'change' }
         // ]
       },
-      custAllList: [], //  客户 下拉数据
       addrProvinceList: [], //  省下拉
       addrCityList: [], //  市下拉
       addrDistrictList: [], //  区下拉
@@ -299,20 +291,18 @@ export default {
       console.log(data, this.isEdit)
       this.isNewCust = false
       // 更新客户信息
-      this.custAllList.unshift(data)
-      setTimeout(() => {
-        this.custChange(data.customerSn)
-      }, 300)
+      this.$refs.custList.setData({ key: data.customerSn, label: data.customerName, row: data })
+      this.custChange({ key: data.customerSn, label: data.customerName, row: data })
     },
     // 业务员
     salesManChange (id) {
       this.form.salesManName = this.userList.find(item => item.id == id).name
     },
     // 客户 change
-    custChange (val) {
-      console.log(val, 'custChange')
+    custChange (obj) {
       const _this = this
-      const cust = this.custAllList.find(item => item.customerSn == val)
+      const cust = obj.row
+      this.form.buyerSn = cust.customerSn
       // 编辑
       if (this.isEdit) {
         this.$confirm({
@@ -426,19 +416,11 @@ export default {
               onOk () {
                 // 保存客户信息
                 _this.handleSaveCust()
-                // // 保存销售单
-                // if (_this.form.buyerSn) {
-                //   _this.salesSaveFun()
-                // }
               }
             })
           } else {
             // 保存客户信息
             _this.handleSaveCust()
-            // // 保存销售单
-            // if (_this.form.buyerSn) {
-            //   _this.salesSaveFun()
-            // }
           }
         } else {
           console.log('error submit!!')
@@ -474,17 +456,6 @@ export default {
       this.isNewCust = false
       this.$refs.newCust.getBaseData()
     },
-    // 客户无分页列表数据
-    getCustAllList () {
-      const _this = this
-      custAllList().then(res => {
-        if (res.status == 200) {
-          _this.custAllList = res.data || []
-        } else {
-          _this.custAllList = []
-        }
-      })
-    },
     // 获取业务员列表数据
     getUserAllList () {
       getUserAllList({ loginFlag: 1 }).then(res => {
@@ -549,11 +520,6 @@ export default {
         }
       })
     },
-    filterOption (input, option) {
-      return (
-        option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
-      )
-    },
     // 获取收款方式
     getSettleStyle () {
       settleStyleQueryAll().then(res => {
@@ -568,7 +534,6 @@ export default {
       this.opened = newValue
       if (newValue) {
         this.getArea('province')
-        this.getCustAllList()
         this.getUserAllList()
         this.getSettleStyle()
       }

+ 29 - 21
src/views/salesManagement/salesQuery/detail.vue

@@ -35,16 +35,24 @@
         <a-collapse :activeKey="['1']">
           <a-collapse-panel key="1" header="基础信息">
             <a-descriptions size="small" :column="3">
-              <a-descriptions-item label="客户名称">{{ detailData&&detailData.buyerName? detailData.buyerName : '--' }}</a-descriptions-item>
-              <a-descriptions-item label="客户地址">{{ detailData&&detailData.shippingAddressProvinceName ? detailData.shippingAddressProvinceName : '--' }}{{ detailData.shippingAddressCityName || '--' }}{{ detailData.shippingAddressCountyName || '--' }}{{ detailData.shippingAddress || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="收款方式">{{ detailData&&detailData.settleStyleEntity&&detailData.settleStyleEntity.name?detailData.settleStyleEntity.name: '--' }}</a-descriptions-item>
-              <a-descriptions-item label="联系电话">{{ detailData&&detailData.consigneeTel ? detailData.consigneeTel : '--' }}</a-descriptions-item>
-              <a-descriptions-item label="备注">{{ detailData&&detailData.remarks ? detailData.remarks : '--' }}</a-descriptions-item>
-              <a-descriptions-item label="销售单号">{{ detailData&&detailData.salesBillNo ? detailData.salesBillNo : '--' }}</a-descriptions-item>
-              <a-descriptions-item label="制单人">{{ detailData&&detailData.operatorName ? detailData.operatorName : '--' }}</a-descriptions-item>
-              <a-descriptions-item label="业务员">{{ detailData&&detailData.salesManName ? detailData.salesManName : '--' }}</a-descriptions-item>
-              <a-descriptions-item label="业务状态">{{ detailData&&detailData.billStatusDictValue ? detailData.billStatusDictValue : '--' }}</a-descriptions-item>
-              <a-descriptions-item label="财务状态">{{ detailData&&detailData.financialStatusDictValue ? detailData.financialStatusDictValue : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="客户名称">{{ detailData&&detailData.buyerName || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="客户地址">
+                <div v-if="detailData&&(detailData.shippingAddressProvinceName || detailData.shippingAddressCityName || detailData.shippingAddressCountyName || detailData.shippingAddress)">
+                  {{ detailData&&detailData.shippingAddressProvinceName || '' }}
+                  {{ detailData&&detailData.shippingAddressCityName || '' }}
+                  {{ detailData&&detailData.shippingAddressCountyName || '' }}
+                  {{ detailData&&detailData.shippingAddress || '' }}
+                </div>
+                <span v-else>--</span>
+              </a-descriptions-item>
+              <a-descriptions-item label="收款方式">{{ detailData&&detailData.settleStyleEntity&&detailData.settleStyleEntity.name || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="联系电话">{{ detailData&&detailData.consigneeTel || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="备注">{{ detailData&&detailData.remarks || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="销售单号">{{ detailData&&detailData.salesBillNo || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="制单人">{{ detailData&&detailData.operatorName || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="业务员">{{ detailData&&detailData.salesManName || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="业务状态">{{ detailData&&detailData.billStatusDictValue || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="财务状态">{{ detailData&&detailData.financialStatusDictValue || '--' }}</a-descriptions-item>
             </a-descriptions>
           </a-collapse-panel>
         </a-collapse>
@@ -53,17 +61,17 @@
         <!-- alert -->
         <a-alert type="info" style="margin-bottom: 15px;">
           <div slot="message">
-            总款数:<strong>{{ detailData&&detailData.totalCategory ? detailData.totalCategory : 0 }}</strong>;
-            总数量:<strong>{{ detailData&&detailData.totalQty ? detailData.totalQty : 0 }}</strong>;
-            总赠品数量:<strong>{{ detailData&&detailData.giftQty ? detailData.giftQty : 0 }}</strong>;
-            急件总款数:<strong>{{ detailData&&detailData.oosCategory ? detailData.oosCategory : 0 }}</strong>;
-            急件总数量:<strong>{{ detailData&&detailData.oosQty ? detailData.oosQty : 0 }}</strong>;<br/>
-            总售价:<strong>{{ detailData&&detailData.totalAmount ? detailData.totalAmount : 0 }}</strong>;
-            总成本:<strong>{{ detailData&&detailData.totalCost ? detailData.totalCost : 0 }}</strong>;
-            总毛利:<strong>{{ detailData&&detailData.grossProfit ? detailData.grossProfit : 0 }}</strong>;
-            折后总售价:<strong>{{ detailData&&detailData.discountedAmount ? detailData.discountedAmount : 0 }}</strong>;
-            折扣:<strong>{{ detailData&&detailData.discountRate ? detailData.discountRate : 0 }}%</strong>;
-            折扣金额:<strong>{{ detailData&&detailData.discountAmount ? detailData.discountAmount : 0 }}</strong>;
+            总款数:<strong>{{ detailData&&(detailData.totalCategory || detailData.totalCategory==0) ? detailData.totalCategory : '--' }}</strong>;
+            总数量:<strong>{{ detailData&&(detailData.totalQty || detailData.totalQty==0) ? detailData.totalQty : '--' }}</strong>;
+            总赠品数量:<strong>{{ detailData&&(detailData.giftQty || detailData.giftQty==0) ? detailData.giftQty : '--' }}</strong>;
+            急件总款数:<strong>{{ detailData&&(detailData.oosCategory || detailData.oosCategory==0) ? detailData.oosCategory : '--' }}</strong>;
+            急件总数量:<strong>{{ detailData&&(detailData.oosQty || detailData.oosQty==0) ? detailData.oosQty : '--' }}</strong>;<br/>
+            总售价:<strong>{{ detailData&&(detailData.totalAmount || detailData.totalAmount==0) ? detailData.totalAmount : '--' }}</strong>;
+            总成本:<strong>{{ detailData&&(detailData.totalCost || detailData.totalCost==0) ? detailData.totalCost : '--' }}</strong>;
+            总毛利:<strong>{{ detailData&&(detailData.grossProfit || detailData.grossProfit==0) ? detailData.grossProfit : '--' }}</strong>;
+            折后总售价:<strong>{{ detailData&&(detailData.discountedAmount || detailData.discountedAmount==0) ? detailData.discountedAmount : '--' }}</strong>;
+            折扣:<strong>{{ detailData&&(detailData.discountRate || detailData.discountRate==0) ? detailData.discountRate+'%' : '--' }}</strong>;
+            折扣金额:<strong>{{ detailData&&(detailData.discountAmount || detailData.discountAmount==0) ? detailData.discountAmount : '--' }}</strong>;
           </div>
         </a-alert>
         <!-- 列表 -->

+ 7 - 7
src/views/salesManagement/salesQuery/edit.vue

@@ -5,7 +5,7 @@
         <!-- 自定义的二级文字标题 -->
         <template slot="subTitle">
           <a id="salesEdit-back-btn" href="javascript:;" @click="handleBack"><a-icon type="left" /> 返回列表</a>
-          <span style="margin: 0 15px;color: #666;">客户名称:{{ detailData&&detailData.buyerName }}</span>
+          <span style="margin: 0 15px;color: #666;">客户名称:{{ detailData&&detailData.buyerName || '--' }}</span>
         </template>
         <!-- 操作区,位于 title 行的行尾 -->
         <template slot="extra" v-if="$hasPermissions('B_salesPrint')">
@@ -26,10 +26,10 @@
         <a-alert style="margin-bottom: 15px;" type="info">
           <div slot="message" class="total-bar">
             <div>
-              总售价:<strong>{{ detailData&&detailData.totalAmount || 0 }}</strong>;
-              总款数:<strong>{{ detailData&&detailData.totalCategory || 0 }}</strong>;
-              总数量:<strong>{{ detailData&&detailData.totalQty || 0 }}</strong>;
-              赠品总数量:<strong>{{ detailData&&detailData.giftQty || 0 }}</strong>;
+              总售价:<strong>{{ detailData&&(detailData.totalAmount || detailData.totalAmount==0) ? '¥'+detailData.totalAmount : '--' }}</strong>;
+              总款数:<strong>{{ detailData&&(detailData.totalCategory || detailData.totalCategory==0) ? detailData.totalCategory : '--' }}</strong>;
+              总数量:<strong>{{ detailData&&(detailData.totalQty || detailData.totalQty==0) ? detailData.totalQty : '--' }}</strong>;
+              赠品总数量:<strong>{{ detailData&&(detailData.giftQty || detailData.giftQty==0) ? detailData.giftQty : '--' }}</strong>;
             </div>
             <div>
               <div>
@@ -38,8 +38,8 @@
                 <a-button type="primary" @click="salesDiscount" class="button-info">打折</a-button>
               </div>
               <div>
-                折扣:<strong>{{ detailData&&detailData.discountRate || 0 }}%</strong>;
-                折后总售价:<strong>{{ detailData&&detailData.discountedAmount || 0 }}</strong>;
+                折扣:<strong>{{ detailData&&(detailData.discountRate || detailData.discountRate==0) ? detailData.discountRate+'%' : '--' }}</strong>;
+                折后总售价:<strong>{{ detailData&&(detailData.discountedAmount || detailData.discountedAmount==0) ? '¥'+detailData.discountedAmount : '--' }}</strong>;
               </div>
             </div>
           </div>

+ 13 - 35
src/views/salesManagement/salesQuery/list.vue

@@ -12,16 +12,7 @@
             </a-col>
             <a-col :md="6" :sm="24">
               <a-form-item label="客户名称" :label-col="{ span:7 }" :wrapper-col="{ span:17}">
-                <a-select
-                  id="salesManagementList-buyerName"
-                  placeholder="请选择客户"
-                  allowClear
-                  v-model="queryParam.buyerName"
-                  :showSearch="true"
-                  option-filter-prop="children"
-                  :filter-option="filterOption">
-                  <a-select-option v-for="item in custAllList" :key="item.customerSn" :value="item.customerName">{{ item.customerName }}</a-select-option>
-                </a-select>
+                <custList ref="custList" @change="custChange" v-model="queryParam.buyerSn"></custList>
               </a-form-item>
             </a-col>
             <a-col :md="6" :sm="24">
@@ -87,10 +78,10 @@
       <!-- alert -->
       <a-alert type="info" showIcon style="margin-bottom:15px">
         <div slot="message">
-          总售价:<strong>{{ totalData.totalAmount }}</strong>元;
-          总单数:<strong>{{ totalData.totalRecord }}</strong>;
-          总款数:<strong>{{ totalData.totalCategory }}</strong>;
-          总数量:<strong>{{ totalData.totalQty }}</strong>;
+          总售价:<strong>{{ totalData&&(totalData.totalAmount || totalData.totalAmount==0) ? totalData.totalAmount : '--' }}</strong>元;
+          总单数:<strong>{{ totalData&&(totalData.totalRecord || totalData.totalRecord==0) ? totalData.totalRecord : '--' }}</strong>;
+          总款数:<strong>{{ totalData&&(totalData.totalCategory || totalData.totalCategory==0) ? totalData.totalCategory : '--' }}</strong>;
+          总数量:<strong>{{ totalData&&(totalData.totalQty || totalData.totalQty==0) ? totalData.totalQty : '--' }}</strong>;
         </div>
       </a-alert>
       <!-- 列表 -->
@@ -183,13 +174,13 @@
 import { STable, VSelect } from '@/components'
 import chooseCustomModal from './chooseCustomModal.vue'
 import auditModal from '@/views/common/auditModal.vue'
-import { custAllList } from '@/api/customer'
 import { salesList, salesDel, salesWriteAudit, salesWriteStockOut, salesCount } from '@/api/sales'
 import { settleStyleQueryAll } from '@/api/settleStyle'
 import rangeDate from '@/views/common/rangeDate.vue'
+import custList from '@/views/common/custList.vue'
 export default {
   name: 'TableList',
-  components: { STable, VSelect, chooseCustomModal, rangeDate, auditModal },
+  components: { STable, VSelect, chooseCustomModal, rangeDate, auditModal, custList },
   data () {
     return {
       spinning: false,
@@ -197,13 +188,12 @@ export default {
       advanced: false, // 高级搜索 展开/关闭
       disabled: false, //  查询、重置按钮是否可操作
       openModal: false, // 选择客户弹框是否显示
-      custAllList: [], //  客户 下拉数据
       settleStyleList: [], // 收款方式
       // 查询参数
       queryParam: {
         beginDate: '',
         endDate: '',
-        buyerName: undefined, //  客户名称
+        buyerSn: undefined, //  客户名称
         salesBillNo: '', //  销售单号
         purchaseBillNo: '', //  采购单号
         payType: undefined, //  支付方式
@@ -353,36 +343,25 @@ export default {
         }
       })
     },
-    // 客户无分页列表数据
-    getCustAllList () {
-      const _this = this
-      custAllList().then(res => {
-        if (res.status == 200) {
-          _this.custAllList = res.data || []
-        } else {
-          _this.custAllList = []
-        }
-      })
+    // 客户 change
+    custChange (obj) {
+      this.queryParam.buyerSn = obj.key || undefined
     },
     // 重置
     resetSearchForm () {
       this.$refs.rangeDate.resetDate()
       this.queryParam.beginDate = ''
       this.queryParam.endDate = ''
-      this.queryParam.buyerName = undefined
+      this.queryParam.buyerSn = undefined
       this.queryParam.salesBillNo = ''
       this.queryParam.purchaseBillNo = ''
       this.queryParam.payType = undefined
       this.queryParam.settleStyleSn = undefined
       this.queryParam.billStatus = undefined
       this.queryParam.financialStatus = undefined
+      this.$refs.custList.resetForm()
       this.$refs.table.refresh(true)
     },
-    filterOption (input, option) {
-      return (
-        option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
-      )
-    },
     // 获取收款方式
     getSettleStyle () {
       settleStyleQueryAll().then(res => {
@@ -394,7 +373,6 @@ export default {
   },
   beforeRouteEnter (to, from, next) {
     next(vm => {
-      vm.getCustAllList()
       vm.getSettleStyle()
     })
   }

+ 9 - 40
src/views/salesManagement/salesReturn/chooseCustomModal.vue

@@ -21,15 +21,7 @@
         <a-row :gutter="15">
           <a-col :span="8">
             <a-form-model-item label="客户名称" prop="buyerSn">
-              <a-select
-                id="chooseCustom-buyerSn"
-                show-search
-                placeholder="请选择客户"
-                v-model="form.buyerSn"
-                :filter-option="filterOption"
-                @change="custChange">
-                <a-select-option v-for="item in custAllList" :key="item.id" :value="item.customerSn">{{ item.customerName }}</a-select-option>
-              </a-select>
+              <custList ref="custList" @change="custChange" v-model="form.buyerSn"></custList>
             </a-form-model-item>
           </a-col>
           <!-- <a-col :span="16">
@@ -134,13 +126,14 @@
 
 <script>
 import { getArea } from '@/api/data'
-import { custAllList, custFindById, updateByCustomerSn } from '@/api/customer'
+import { custFindById, updateByCustomerSn } from '@/api/customer'
 import { salesReturnSave } from '@/api/salesReturn'
 import { VSelect } from '@/components'
+import custList from '@/views/common/custList.vue'
 import CustomerManagementEdit from '@/views/customerManagement/customerInfo/edit.vue'
 export default {
   name: 'ChooseCustomModal',
-  components: { VSelect, CustomerManagementEdit },
+  components: { VSelect, CustomerManagementEdit, custList },
   props: {
     show: [Boolean]
   },
@@ -193,7 +186,6 @@ export default {
           { required: true, message: '请选择是否铺货出库', trigger: 'change' }
         ]
       },
-      custAllList: [], //  客户 下拉数据
       addrProvinceList: [], //  省下拉
       addrCityList: [], //  市下拉
       addrDistrictList: [], //  区下拉
@@ -216,20 +208,18 @@ export default {
       console.log(data, this.isEdit)
       this.isNewCust = false
       // 更新客户信息
-      this.custAllList.unshift(data)
-      setTimeout(() => {
-        this.custChange(data.customerSn)
-      }, 300)
+      this.$refs.custList.setData({ key: data.customerSn, label: data.customerName, row: data })
+      this.custChange({ key: data.customerSn, label: data.customerName, row: data })
     },
     cancelNewCust () {
       this.isNewCust = false
       this.$refs.newCust.getBaseData()
     },
     // 客户 change
-    custChange (val) {
-      console.log(val, 'custChange')
+    custChange (obj) {
       const _this = this
-      const cust = this.custAllList.find(item => item.customerSn == val)
+      const cust = obj.row
+      this.form.buyerSn = cust.customerSn
       // 编辑
       if (this.isEdit) {
         this.$confirm({
@@ -326,10 +316,6 @@ export default {
         if (valid) {
           // 保存客户信息
           _this.handleSaveCust()
-          // // 保存销售单
-          // if (_this.form.buyerSn) {
-          //   _this.salesSaveFun()
-          // }
         } else {
           console.log('error submit!!')
           return false
@@ -357,17 +343,6 @@ export default {
       this.$refs.ruleForm.resetFields()
       this.$emit('cancel')
     },
-    // 客户无分页列表数据
-    getCustAllList () {
-      const _this = this
-      custAllList().then(res => {
-        if (res.status == 200) {
-          _this.custAllList = res.data || []
-        } else {
-          _this.custAllList = []
-        }
-      })
-    },
     // 获取城市列表
     getCityList (val) {
       this.addrCityList = []
@@ -421,11 +396,6 @@ export default {
           }
         }
       })
-    },
-    filterOption (input, option) {
-      return (
-        option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
-      )
     }
   },
   watch: {
@@ -433,7 +403,6 @@ export default {
       this.opened = newValue
       if (newValue) {
         this.getArea('province')
-        this.getCustAllList()
       }
     }
   }

+ 22 - 9
src/views/salesManagement/salesReturn/detail.vue

@@ -18,13 +18,21 @@
       <a-card size="small" :bordered="false" class="salesReturnDetail-cont">
         <a-collapse :activeKey="['1']">
           <a-collapse-panel key="1" header="基础信息">
-            <a-descriptions size="small" :column="3" v-if="detailData">
-              <a-descriptions-item label="客户名称">{{ detailData.buyerName || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="客户地址">{{ detailData.provinceName || '--' }}{{ detailData.cityName || '--' }}{{ detailData.countyName || '--' }}{{ detailData.customerAddr || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="联系电话">{{ detailData.contactTel || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="备注">{{ detailData.remarks || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="退货单号">{{ detailData.salesReturnNo || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="业务状态">{{ detailData.stateDictValue || '--' }}</a-descriptions-item>
+            <a-descriptions size="small" :column="3">
+              <a-descriptions-item label="客户名称">{{ detailData&&detailData.buyerName || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="客户地址">
+                <div v-if="detailData&&(detailData.provinceName || detailData.cityName || detailData.countyName || detailData.customerAddr)">
+                  {{ detailData&&detailData.provinceName || '' }}
+                  {{ detailData&&detailData.cityName || '' }}
+                  {{ detailData&&detailData.countyName || '' }}
+                  {{ detailData&&detailData.customerAddr || '' }}
+                </div>
+                <span v-else>--</span>
+              </a-descriptions-item>
+              <a-descriptions-item label="联系电话">{{ detailData&&detailData.contactTel || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="备注">{{ detailData&&detailData.remarks || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="退货单号">{{ detailData&&detailData.salesReturnNo || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="业务状态">{{ detailData&&detailData.stateDictValue || '--' }}</a-descriptions-item>
             </a-descriptions>
           </a-collapse-panel>
         </a-collapse>
@@ -33,8 +41,13 @@
         <!-- alert -->
         <a-alert type="info" style="margin-bottom: 15px;" v-if="detailData">
           <div slot="message">
-            总款数:<strong>{{ countData.totalCategory || 0 }}</strong>;总数量:<strong>{{ countData.totalQty || 0 }}</strong>;废品数量:<strong>{{ countData.totalCelQty || 0 }}</strong>;<br/>
-            退货总金额:<strong>{{ countData.totalAmount || 0 }}</strong>;折扣金额:<strong>{{ countData.discountAmount || 0 }}</strong>;折扣:<strong>{{ countData.discountRate || 0 }}%</strong>;折后金额:<strong>{{ countData.discountedAmount || 0 }}</strong>;
+            总款数:<strong>{{ countData&&(countData.totalCategory || countData.totalCategory==0) ? countData.totalCategory : '--' }}</strong>;
+            总数量:<strong>{{ countData&&(countData.totalQty || countData.totalQty==0) ? countData.totalQty : '--' }}</strong>;
+            废品数量:<strong>{{ countData&&(countData.totalCelQty || countData.totalCelQty==0) ? countData.totalCelQty : '--' }}</strong>;<br/>
+            退货总金额:<strong>{{ countData&&(countData.totalAmount || countData.totalAmount==0) ? countData.totalAmount : '--' }}</strong>;
+            折扣金额:<strong>{{ countData&&(countData.discountAmount || countData.discountAmount==0) ? countData.discountAmount : '--' }}</strong>;
+            折扣:<strong>{{ countData&&(countData.discountRate || countData.discountRate==0) ? countData.discountRate+'%' : '--' }}</strong>;
+            折后金额:<strong>{{ countData&&(countData.discountedAmount || countData.discountedAmount==0) ? countData.discountedAmount : '--' }}</strong>;
           </div>
         </a-alert>
         <!-- 列表 -->

+ 13 - 35
src/views/salesManagement/salesReturn/list.vue

@@ -17,16 +17,7 @@
             </a-col>
             <a-col :md="6" :sm="24">
               <a-form-item label="客户名称" :label-col="{ span:7 }" :wrapper-col="{ span:17}">
-                <a-select
-                  id="salesReturn-buyerSn"
-                  placeholder="请选择客户"
-                  allowClear
-                  v-model="queryParam.buyerSn"
-                  :showSearch="true"
-                  option-filter-prop="children"
-                  :filter-option="filterOption">
-                  <a-select-option v-for="item in custAllList" :key="item.customerSn" :value="item.customerSn">{{ item.customerName }}</a-select-option>
-                </a-select>
+                <custList ref="custList" @change="custChange" v-model="queryParam.buyerSn"></custList>
               </a-form-item>
             </a-col>
             <template v-if="advanced">
@@ -67,10 +58,10 @@
       <!-- alert -->
       <a-alert type="info" style="margin-bottom: 15px;">
         <div slot="message">
-          退货总金额:<strong>{{ countData&&countData.totalAmount }}</strong>元;
-          总单数:<strong>{{ countData&&countData.totalBillNumber }}</strong>;
-          总款数:<strong>{{ countData&&countData.totalCategory }}</strong>;
-          总数量:<strong>{{ countData&&countData.totalQty }}</strong>;
+          退货总金额:<strong>{{ countData&&(countData.totalAmount || countData.totalAmount==0) ? countData.totalAmount : '--' }}</strong>元;
+          总单数:<strong>{{ countData&&(countData.totalBillNumber || countData.totalBillNumber==0) ? countData.totalBillNumber : '--' }}</strong>;
+          总款数:<strong>{{ countData&&(countData.totalCategory || countData.totalCategory==0) ? countData.totalCategory : '--' }}</strong>;
+          总数量:<strong>{{ countData&&(countData.totalQty || countData.totalQty==0) ? countData.totalQty : '--' }}</strong>;
         </div>
       </a-alert>
       <!-- 列表 -->
@@ -128,7 +119,7 @@
 import { STable, VSelect } from '@/components'
 import rangeDate from '@/views/common/rangeDate.vue'
 import chooseCustomModal from './chooseCustomModal.vue'
-import { custAllList } from '@/api/customer'
+import custList from '@/views/common/custList.vue'
 import { salesReturnList, salesReturnCount, salesReturnAudit, salesReturnDel } from '@/api/salesReturn'
 export default {
   name: 'TableList',
@@ -136,7 +127,8 @@ export default {
     STable,
     VSelect,
     chooseCustomModal,
-    rangeDate
+    rangeDate,
+    custList
   },
   data () {
     return {
@@ -146,7 +138,6 @@ export default {
       advanced: false,
       disabled: false, //  查询、重置按钮是否可操作
       openModal: false, // 选择客户弹框是否显示
-      custAllList: [], //  客户下拉数据
       // 查询参数
       queryParam: {
         beginDate: '',
@@ -272,29 +263,16 @@ export default {
       this.queryParam.buyerSn = undefined
       this.queryParam.salesReturnNo = ''
       this.queryParam.state = ''
+      this.$refs.custList.resetForm()
       this.$refs.table.refresh(true)
     },
-    // 客户无分页列表数据
-    getCustAllList () {
-      const _this = this
-      custAllList().then(res => {
-        if (res.status == 200) {
-          _this.custAllList = res.data || []
-        } else {
-          _this.custAllList = []
-        }
-      })
-    },
-    filterOption (input, option) {
-      return (
-        option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
-      )
+    // 客户 change
+    custChange (obj) {
+      this.queryParam.buyerSn = obj.key || undefined
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getCustAllList()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 6 - 6
src/views/salesManagement/salesReturn/salesReturnEdit.vue

@@ -26,10 +26,10 @@
         <a-alert style="margin-bottom: 15px;" type="info">
           <div slot="message" class="total-bar">
             <div>
-              <span>退货总金额:{{ countData&&countData.totalAmount }}元;</span>
-              <span>总款数:{{ countData&&countData.totalCategory }};</span>
-              <span>总数量:{{ countData&&countData.totalQty }};</span>
-              <span>废品总数量:{{ countData&&countData.totalCelQty }};</span>
+              <span>退货总金额:{{ countData&&(countData.totalAmount || countData.totalAmount==0) ? countData.totalAmount : '--' }}元;</span>
+              <span>总款数:{{ countData&&(countData.totalCategory || countData.totalCategory==0) ? countData.totalCategory : '--' }};</span>
+              <span>总数量:{{ countData&&(countData.totalQty || countData.totalQty==0) ? countData.totalQty : '--' }};</span>
+              <span>废品总数量:{{ countData&&(countData.totalCelQty || countData.totalCelQty==0) ? countData.totalCelQty : '--' }};</span>
             </div>
             <div>
               <div>
@@ -38,8 +38,8 @@
                 <a-button type="primary" @click="salesReturnDiscount" class="button-info">打折</a-button>
               </div>
               <div>
-                折扣:<strong>{{ ordeDetail&&ordeDetail.discountRate || 0 }}%</strong>;
-                折后总售价:<strong>{{ ordeDetail&&ordeDetail.discountedAmount || 0 }}</strong>;
+                折扣:<strong>{{ ordeDetail&&(ordeDetail.discountRate || ordeDetail.discountRate==0) ? ordeDetail.discountRate+'%' : '--' }}</strong>;
+                折后总售价:<strong>{{ ordeDetail&&(ordeDetail.discountedAmount || ordeDetail.discountedAmount==0) ? '¥'+ordeDetail.discountedAmount : '--' }}</strong>;
               </div>
             </div>
           </div>

+ 6 - 6
src/views/salesManagement/salesReturn/salesReturnGrabEdit.vue

@@ -26,10 +26,10 @@
         <a-alert style="margin-bottom: 15px;" type="info">
           <div slot="message" class="total-bar">
             <div>
-              <span>退货总金额:{{ countData&&countData.totalAmount }};</span>
-              <span>总款数:{{ countData&&countData.totalCategory }};</span>
-              <span>总数量:{{ countData&&countData.totalQty }};</span>
-              <span>废品总数量:{{ countData&&countData.totalCelQty }};</span>
+              <span>退货总金额:{{ countData&&(countData.totalAmount || countData.totalAmount==0) ? countData.totalAmount+'元' : '--' }};</span>
+              <span>总款数:{{ countData&&(countData.totalCategory || countData.totalCategory==0) ? countData.totalCategory : '--' }};</span>
+              <span>总数量:{{ countData&&(countData.totalQty || countData.totalQty==0) ? countData.totalQty : '--' }};</span>
+              <span>废品总数量:{{ countData&&(countData.totalCelQty || countData.totalCelQty==0) ? countData.totalCelQty : '--' }};</span>
             </div>
             <div>
               <div>
@@ -38,8 +38,8 @@
                 <a-button type="primary" @click="salesReturnDiscount" class="button-info">打折</a-button>
               </div>
               <div>
-                折扣:<strong>{{ ordeDetail&&ordeDetail.discountRate || 0 }}%</strong>;
-                折后总售价:<strong>{{ ordeDetail&&ordeDetail.discountedAmount || 0 }}</strong>;
+                折扣:<strong>{{ ordeDetail&&(ordeDetail.discountRate || ordeDetail.discountRate==0) ? ordeDetail.discountRate+'%' : '--' }}</strong>;
+                折后总售价:<strong>{{ ordeDetail&&(ordeDetail.discountedAmount || ordeDetail.discountedAmount==0) ? '¥'+ordeDetail.discountedAmount : '--' }}</strong>;
               </div>
             </div>
           </div>

+ 10 - 2
src/views/salesManagement/urgentItemsOffset/detail.vue

@@ -20,7 +20,15 @@
           <a-collapse-panel key="1" header="基础信息">
             <a-descriptions :column="3">
               <a-descriptions-item label="客户名称">{{ (detailData&&detailData.buyerName) || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="客户地址">{{ (detailData&&detailData.shippingAddressProvinceName) || '' }}{{ (detailData&&detailData.shippingAddressCityName) || '' }}{{ (detailData&&detailData.shippingAddressCountyName) || '' }}{{ (detailData&&detailData.shippingAddress) || '' }}</a-descriptions-item>
+              <a-descriptions-item label="客户地址">
+                <div v-if="detailData&&(detailData.shippingAddressProvinceName || detailData.shippingAddressCityName || detailData.shippingAddressCountyName || detailData.shippingAddress)">
+                  {{ (detailData&&detailData.shippingAddressProvinceName) || '' }}
+                  {{ (detailData&&detailData.shippingAddressCityName) || '' }}
+                  {{ (detailData&&detailData.shippingAddressCountyName) || '' }}
+                  {{ (detailData&&detailData.shippingAddress) || '' }}
+                </div>
+                <span v-else>--</span>
+              </a-descriptions-item>
               <a-descriptions-item label="联系电话">{{ detailData&&detailData.consigneeTel || '--' }}</a-descriptions-item>
               <a-descriptions-item label="收款方式">{{ (detailData&&detailData.settleStyleEntity&&detailData.settleStyleEntity.name) || '--' }}</a-descriptions-item>
               <a-descriptions-item label="急件单号">{{ (detailData&&detailData.urgentBillNo) || '--' }}</a-descriptions-item>
@@ -41,7 +49,7 @@
         <s-table
           class="sTable"
           ref="table"
-          size="default"
+          size="small"
           :rowKey="(record) => record.id"
           :columns="isWriteDown ? columns : unColumns"
           :data="loadData"

+ 8 - 31
src/views/salesManagement/urgentItemsOffset/list.vue

@@ -11,16 +11,7 @@
           </a-col>
           <a-col :md="6" :sm="24">
             <a-form-item label="客户名称">
-              <a-select
-                id="urgentItemsOffsetList-buyerSn"
-                placeholder="请选择"
-                allowClear
-                v-model="queryParam.buyerSn"
-                :showSearch="true"
-                option-filter-prop="children"
-                :filter-option="filterOption">
-                <a-select-option v-for="item in custAllList" :key="item.customerSn" :value="item.customerSn">{{ item.customerName }}</a-select-option>
-              </a-select>
+              <custList ref="custList" @change="custChange" v-model="queryParam.buyerSn"></custList>
             </a-form-item>
           </a-col>
           <a-col :md="6" :sm="24">
@@ -77,12 +68,12 @@
 </template>
 
 <script>
-import { custAllList } from '@/api/customer'
 import { urgentList } from '@/api/urgent'
 import { STable, VSelect } from '@/components'
 import rangeDate from '@/views/common/rangeDate.vue'
+import custList from '@/views/common/custList.vue'
 export default {
-  components: { STable, VSelect, rangeDate },
+  components: { STable, VSelect, rangeDate, custList },
   data () {
     return {
       tableHeight: 0,
@@ -96,7 +87,6 @@ export default {
         status: undefined //  状态
       },
       disabled: false, //  查询、重置按钮是否可操作
-      custAllList: [], //  客户下拉数据
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
         { title: '急件单号', scopedSlots: { customRender: 'urgentBillNo' }, width: 220, align: 'center' },
@@ -132,11 +122,6 @@ export default {
       this.queryParam.beginDate = date[0]
       this.queryParam.endDate = date[1]
     },
-    filterOption (input, option) {
-      return (
-        option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
-      )
-    },
     //  重置
     resetSearchForm () {
       this.$refs.rangeDate.resetDate()
@@ -146,28 +131,20 @@ export default {
       this.queryParam.salesBillNo = ''
       this.queryParam.urgentBillNo = ''
       this.queryParam.status = undefined
+      this.$refs.custList.resetForm()
       this.$refs.table.refresh(true)
     },
     //  详情
     handleDetail (row) {
       this.$router.push({ path: `/salesManagement/urgentItemsOffset/detail/${row.urgentBillSn}` })
     },
-    // 客户无分页列表数据
-    getCustAllList () {
-      const _this = this
-      custAllList().then(res => {
-        if (res.status == 200) {
-          _this.custAllList = res.data || []
-        } else {
-          _this.custAllList = []
-        }
-      })
+    // 客户 change
+    custChange (obj) {
+      this.queryParam.buyerSn = obj.key || undefined
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getCustAllList()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 2 - 2
vue.config.js

@@ -109,8 +109,8 @@ const vueConfig = {
     proxy: {
       '/api': {
         // target: 'http://192.168.16.103:8503/qpls-md',
-        target: 'http://qpls-md.360arrow.com.cn/qpls-md',
-        // target: 'http://380d150d.nat123.fun:38226/qpls-md',
+        target: 'http://qpls-md.360arrow.com.cn/qpls-md', //  Ô¤·¢²¼
+        // target: 'http://qpls-md.360arrow.com/qpls-md', //  Éú²ú
         // ws: false,
         ws: true,
         changeOrigin: true,