Преглед на файлове

Merge branch 'deploy_0804' of jianguan-web/jg-ocs-html into master

陈瑞 преди 3 години
родител
ревизия
bb15bc5135
променени са 100 файла, в които са добавени 1016 реда и са изтрити 934 реда
  1. 9 0
      src/api/predict.js
  2. 8 0
      src/api/productType.js
  3. 19 0
      src/api/reportData.js
  4. 1 1
      src/components/Menu/SideMenu.vue
  5. 18 8
      src/components/MultiTab/MultiTab.vue
  6. 1 1
      src/components/Table/index.js
  7. 19 16
      src/components/global.less
  8. 0 1
      src/components/index.less
  9. 2 2
      src/config/defaultSettings.js
  10. 0 10
      src/config/router.config.js
  11. 1 1
      src/layouts/BasicLayout.vue
  12. 17 12
      src/permission.js
  13. 2 2
      src/utils/mixin.js
  14. 26 12
      src/views/allocationManagement/transferOut/detail.vue
  15. 10 2
      src/views/allocationManagement/transferOut/edit.vue
  16. 8 11
      src/views/allocationManagement/transferOut/list.vue
  17. 7 1
      src/views/basicData/transferTypeManagement/list.vue
  18. 1 1
      src/views/basicData/warehouse/list.vue
  19. 3 3
      src/views/basicData/warehouse/storingLocation/list.vue
  20. 16 10
      src/views/common/auditModal.vue
  21. 9 6
      src/views/common/chooseCustomerModal.vue
  22. 6 1
      src/views/common/chooseImportModal.vue
  23. 6 6
      src/views/dealerManagement/dealerAccountManagement/detailModal.vue
  24. 1 1
      src/views/dealerManagement/dealerAccountManagement/list.vue
  25. 6 2
      src/views/dealerManagement/dealerRelationshipBinding/list.vue
  26. 5 1
      src/views/dealerManagement/marketingDivisionSet/editModal.vue
  27. 9 3
      src/views/dealerManagement/marketingDivisionSet/list.vue
  28. 50 36
      src/views/dealerManagement/merchantInfoManagement/detailModal.vue
  29. 44 35
      src/views/dealerManagement/merchantInfoManagement/edit.vue
  30. 10 9
      src/views/dealerManagement/merchantInfoManagement/list.vue
  31. 1 1
      src/views/dealerManagement/merchantInfoManagement/permissionSetting.vue
  32. 2 2
      src/views/dealerManagement/rebateSettings/list.vue
  33. 20 19
      src/views/financialManagement/financialCollection/list.vue
  34. 2 2
      src/views/financialManagement/inventoryReview/detail.vue
  35. 1 1
      src/views/financialManagement/inventoryReview/list.vue
  36. 4 4
      src/views/financialManagement/returnConfirmation/detailModal.vue
  37. 7 6
      src/views/financialManagement/returnConfirmation/list.vue
  38. 2 2
      src/views/financialManagement/warehousingConfirmation/list.vue
  39. 68 43
      src/views/inventoryManagement/intelligentReplenishment/detailModal.vue
  40. 8 5
      src/views/inventoryManagement/intelligentReplenishment/edit.vue
  41. 5 5
      src/views/inventoryManagement/intelligentReplenishment/explainQspj.vue
  42. 1 1
      src/views/inventoryManagement/intelligentReplenishment/explainXsbz.vue
  43. 1 1
      src/views/inventoryManagement/intelligentReplenishment/import.vue
  44. 22 12
      src/views/inventoryManagement/intelligentReplenishment/list.vue
  45. 1 0
      src/views/inventoryManagement/intelligentReplenishment/productRange.vue
  46. 1 1
      src/views/inventoryManagement/intelligentReplenishment/set.vue
  47. 1 1
      src/views/inventoryManagement/inventoryChecking/checkingTipsModal.vue
  48. 2 2
      src/views/inventoryManagement/inventoryChecking/detail.vue
  49. 2 2
      src/views/inventoryManagement/inventoryChecking/financialAuditDetail.vue
  50. 1 1
      src/views/inventoryManagement/inventoryChecking/list.vue
  51. 2 2
      src/views/inventoryManagement/inventoryChecking/makeInventory.vue
  52. 2 2
      src/views/inventoryManagement/inventoryChecking/makeInventoryDetail.vue
  53. 2 2
      src/views/inventoryManagement/inventoryChecking/overall.vue
  54. 3 3
      src/views/inventoryManagement/inventoryChecking/selfDisk.vue
  55. 5 6
      src/views/inventoryManagement/inventoryQuery/list.vue
  56. 7 4
      src/views/inventoryManagement/inventoryQuery/warehouseDetail.vue
  57. 5 6
      src/views/inventoryManagement/inventoryWarning/list.vue
  58. 8 2
      src/views/power/OperateJournal/OperateJournal.vue
  59. 1 1
      src/views/power/dataDictionary/dataDictionary.vue
  60. 1 1
      src/views/power/job/jobs.vue
  61. 1 1
      src/views/power/role/roleList.vue
  62. 1 1
      src/views/power/user/userList.vue
  63. 10 8
      src/views/productManagement/priceChangeRecord/list.vue
  64. 8 7
      src/views/productManagement/productBrand/detailModal.vue
  65. 2 2
      src/views/productManagement/productBrand/list.vue
  66. 2 2
      src/views/productManagement/productCategory/list.vue
  67. 21 17
      src/views/productManagement/productInfo/detailModal.vue
  68. 28 4
      src/views/productManagement/productInfo/edit.vue
  69. 7 12
      src/views/productManagement/productInfo/list.vue
  70. 3 3
      src/views/productManagement/productLaunchAudit/list.vue
  71. 12 11
      src/views/productManagement/productLevel/list.vue
  72. 5 6
      src/views/productManagement/productOfflineAudit/list.vue
  73. 23 13
      src/views/productManagement/productPricing/auditModal.vue
  74. 1 1
      src/views/productManagement/productPricing/editModal.vue
  75. 18 15
      src/views/productManagement/productPricing/list.vue
  76. 7 6
      src/views/productManagement/productUniversal/list.vue
  77. 1 1
      src/views/productManagement/purchaseBaseLimit/list.vue
  78. 1 1
      src/views/promotionRulesManagement/orderStatistics/detailModal.vue
  79. 13 12
      src/views/promotionRulesManagement/orderStatistics/list.vue
  80. 9 8
      src/views/promotionRulesManagement/productStatistics/list.vue
  81. 9 5
      src/views/promotionRulesManagement/promotionRules/detail.vue
  82. 6 6
      src/views/promotionRulesManagement/promotionRules/list.vue
  83. 3 3
      src/views/promotionRulesManagement/promotionRules/rule.vue
  84. 5 2
      src/views/purchasingManagement/bulkWarehousingOrder/detailModal.vue
  85. 9 2
      src/views/purchasingManagement/bulkWarehousingOrder/edit.vue
  86. 9 9
      src/views/purchasingManagement/bulkWarehousingOrder/list.vue
  87. 11 8
      src/views/reportData/actualSalesReport/list.vue
  88. 1 1
      src/views/reportData/allocationDetails/list.vue
  89. 1 1
      src/views/reportData/allocationOrderTotal/list.vue
  90. 9 5
      src/views/reportData/billingReturnReport/list.vue
  91. 211 384
      src/views/reportData/priceDifferenceDetailReport/list.vue
  92. 9 5
      src/views/reportData/returnSlipReport/list.vue
  93. 11 7
      src/views/reportData/salesAmountReport/list.vue
  94. 3 3
      src/views/reportData/salesDetails/list.vue
  95. 9 5
      src/views/reportData/salesReturnDetailReport/list.vue
  96. 9 5
      src/views/reportData/salesReturnReport/list.vue
  97. 10 6
      src/views/reportData/salesReturnsReport/list.vue
  98. 11 7
      src/views/reportData/salesSlipReport/list.vue
  99. 3 3
      src/views/salesManagement/backorder/detailModal.vue
  100. 2 2
      src/views/salesManagement/backorder/list.vue

+ 9 - 0
src/api/predict.js

@@ -99,3 +99,12 @@ export const predictProductInfoGoods = (params) => {
     method: 'post'
   })
 }
+//  智能补货  结果下载
+export const predictstockPredictExport = (params) => {
+  return axios({
+    url: `/predict/stockPredict/exportExcel/${params.sn}`,
+    data: params,
+    method: 'post',
+    responseType: 'blob'
+  })
+}

+ 8 - 0
src/api/productType.js

@@ -16,6 +16,14 @@ export const productTypeQuery = (params) => {
     method: 'post'
   })
 }
+//  产品分类 列表  多层分类查询   无分页   有启禁用
+export const productTypeQueryAll = (params) => {
+  return axios({
+    url: '/productType/queryAll',
+    data: params,
+    method: 'post'
+  })
+}
 // 产品分类  新增/编辑
 export const productTypeSave = params => {
   return axios({

+ 19 - 0
src/api/reportData.js

@@ -104,3 +104,22 @@ export const reportSalesReturnDetailExport = (params) => {
     responseType: 'blob'
   })
 }
+//  总部差价明细报表
+export const headRebateDetailReportList = (params) => {
+  const url = `/report/headRebateDetailReport/queryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post'
+  })
+}
+//  总部差价明细报表  合计
+export const headRebateDetailReportCount = (params) => {
+  return axios({
+    url: '/report/headRebateDetailReport/querySum',
+    data: params,
+    method: 'post'
+  })
+}

+ 1 - 1
src/components/Menu/SideMenu.vue

@@ -12,7 +12,7 @@
       :theme="theme"
       :mode="mode"
       @select="onSelect"
-      style="padding: 16px 0px;"></s-menu>
+      style="padding: 10px 0px;"></s-menu>
   </a-layout-sider>
 
 </template>

+ 18 - 8
src/components/MultiTab/MultiTab.vue

@@ -26,7 +26,7 @@ export default {
       }
       this.closeThat(val)
     }).$on('rename', ({ key, name }) => {
-      console.log('rename', key, name)
+      // console.log('rename', key, name)
       try {
         const item = this.pages.find(item => item.path === key)
         item.meta.customTitle = name
@@ -121,22 +121,32 @@ export default {
     }
   },
   watch: {
-    '$route': function (newVal) {
+    '$route': function (newVal, oldVal) {
+      // 父页面(列表)进入子页面(编辑、详情)再返回至父页面时关闭子页面页签   子页面点击“返回列表”
+      if (oldVal && oldVal.name && newVal.query.closeLastOldTab) {
+        if (oldVal.name.indexOf('List') == -1) { // 要关闭的页面不能是列表页
+          this.remove(oldVal.name) // 关闭子页面
+        }
+      }
       this.activeKey = newVal.name
       const index = this.tabsList.indexOf(newVal.name)
-      // 不存在
-      if (index < 0) {
+      // 解决页面地址相同参数不同时打开多个页签问题(例 详情页id或sn不同时)
+      if (index < 0) { // 不存在
         this.tabsList.push(newVal.name)
         this.pages.push(newVal)
-      } else {
-        // 已存在
+      } else { // 已存在
         this.pages.splice(index, 1, newVal)
       }
     },
     activeKey: function (newPathKey) {
       const row = this.pages.find(item => item.name == newPathKey)
-      // console.log(row.fullPath)
-      this.$router.push({ path: row.fullPath })
+      // console.log(row, '+++', row.fullPath)
+      if (row.fullPath.indexOf('/list') == -1) {
+        this.$router.push({ path: row.fullPath })
+      } else {
+        // this.$router.push({ path: row.fullPath, query: { closeLastOldTab: true } })  //  需求:切换页签需关掉子页面
+        this.$router.push({ path: row.path }) //  需求:切换页签不需关掉子页面
+      }
     }
   },
   render () {

+ 1 - 1
src/components/Table/index.js

@@ -11,7 +11,7 @@ export default {
 
       localLoading: false,
       localDataSource: [],
-      localPagination: Object.assign({}, this.pagination)
+      localPagination: Object.assign({'show-total':total => `共 ${total} 条`}, this.pagination)
     }
   },
   props: Object.assign({}, T.props, {

+ 19 - 16
src/components/global.less

@@ -18,7 +18,7 @@ body {
   &.tablet {
     .ant-layout-content {
       .content {
-        margin: 24px 0 0;
+        margin: 12px 0 0;
       }
     }
 
@@ -61,7 +61,7 @@ body {
   
   .trigger {
     font-size: 20px;
-    line-height: 64px;
+    line-height: 44px;
     padding: 0 24px;
     cursor: pointer;
     transition: color 0.3s;
@@ -94,7 +94,7 @@ body {
       position: fixed;
       z-index: 8;
       width: 100%;
-      top: 64px;
+      top: 44px;
       right:0;
       margin: auto;
     }
@@ -147,7 +147,7 @@ body {
       position: fixed;
       z-index: 8;
       width: 100%;
-      top: 64px;
+      top: 44px;
       right:0;
       margin: auto;
       &.ant-header-side-opened {
@@ -161,13 +161,16 @@ body {
   }
 
   .header {
-    height: 64px;
+    height: 44px;
     padding: 0 12px 0 0;
     background: #fff;
     box-shadow: 0 1px 4px rgba(0, 21, 41, 0.08);
     position: relative;
   }
-
+  .ant-layout-header{
+    height: 44px;
+    line-height: 44px;
+  }
   .header,
   .top-nav-header-index {
     .user-wrapper {
@@ -227,9 +230,9 @@ body {
           }
 
           .logo.top-nav-header {
-            flex: 0 0 56px;
+            flex: 0 0 36px;
             text-align: center;
-            line-height: 58px;
+            line-height: 38px;
             h1 {
               display: none;
             }
@@ -279,14 +282,14 @@ body {
       margin: auto;
       padding-left: 0;
       display: flex;
-      height: 64px;
+      height: 44px;
 
       .ant-menu.ant-menu-horizontal {
         max-width: 835px;
         flex: 0 1 835px;
         border: none;
-        height: 64px;
-        line-height: 64px;
+        height: 44px;
+        line-height: 44px;
       }
 
       .header-index-left {
@@ -296,9 +299,9 @@ body {
         .logo.top-nav-header {
           flex: 0 0 auto;
           width: auto;
-          height: 64px;
+          height: 44px;
           position: relative;
-          line-height: 64px;
+          line-height: 44px;
           transition: all 0.3s;
           overflow: hidden;
 
@@ -324,7 +327,7 @@ body {
       .header-index-right {
         flex: 0 0 238px;
         align-self: flex-end;
-        height: 64px;
+        height: 44px;
         overflow: hidden;
 
         .content-box {
@@ -414,10 +417,10 @@ body {
   
   .logo {
     position: relative;
-    height: 64px;
+    height: 44px;
     padding-left: 10px;
     overflow: hidden;
-    line-height: 64px;
+    line-height: 44px;
     background: #002140;
     transition: all .3s;
 

+ 0 - 1
src/components/index.less

@@ -4,7 +4,6 @@
 @ant-pro-prefix             : ant-pro;
 @ant-global-sider-zindex    : 106;
 @ant-global-header-zindex   : 105;
-
 .ant-input-disabled{
   color: #666;
   background-color: #f8f8f8;

+ 2 - 2
src/config/defaultSettings.js

@@ -19,7 +19,7 @@ export default {
   layout: 'sidemenu', // nav menu position: sidemenu or topmenu
   contentWidth: 'Fluid', // layout of content: Fluid or Fixed, only works when layout is topmenu
   fixedHeader: true, // sticky header
-  fixSiderbar: false, // sticky siderbar
+  fixSiderbar: true, // sticky siderbar
   autoHideHeader: false, //  auto hide header
   colorWeak: false,
   multiTab: true,
@@ -28,6 +28,6 @@ export default {
   storageOptions: {
     namespace: 'pro__', // key prefix
     name: 'ls', // name variable Vue.[ls] or this.[$ls],
-    storage: 'local' // storage name session, local, memory
+    storage: 'session' // storage name session, local, memory
   }
 }

+ 0 - 10
src/config/router.config.js

@@ -175,16 +175,6 @@ export const asyncRouterMap = [
                   hidden: true,
                   permission: 'M_outboundOrderList'
                 }
-              },
-              {
-                path: 'detail/:sn',
-                name: 'outboundOrderDetail',
-                component: () => import(/* webpackChunkName: "salesManagement" */ '@/views/salesManagement/outboundOrder/detail.vue'),
-                meta: {
-                  title: '出库明细',
-                  icon: 'export',
-                  hidden: true
-                }
               }
             ]
           },

+ 1 - 1
src/layouts/BasicLayout.vue

@@ -39,7 +39,7 @@
         @toggle="toggle"
       />
       <!-- layout content -->
-      <a-layout-content :style="{ height: '100%', margin: '24px 24px 0', paddingTop: multiTab&&fixedHeader ? '105px' : (!multiTab&&fixedHeader?'65px':'0') }">
+      <a-layout-content :style="{ height: '100%', margin: '24px 24px 0', paddingTop: multiTab&&fixedHeader ? '85px' : (!multiTab&&fixedHeader?'45px':'0') }">
         <transition name="page-transition">
           <route-view/>
         </transition>

+ 17 - 12
src/permission.js

@@ -32,7 +32,8 @@ router.beforeEach((to, from, next) => {
         store.dispatch('SetInfo', userInfo)
       } else {
         store.dispatch('Logout').then(() => {
-          next({ path: '/user/login', query: { redirect: to.fullPath } })
+          // next({ path: '/user/login', query: { redirect: to.fullPath } })
+          next({ path: '/user/login' })
         })
       }
       // console.log(store.getters.roles)
@@ -45,22 +46,24 @@ router.beforeEach((to, from, next) => {
             if (roles.permissionList.length == 0 || !roles) {
               store.dispatch('Logout').then(() => {
                 store.dispatch('ResetRoutes').then(() => {
-                  next({ path: '/user/login', query: { redirect: to.fullPath } })
+                  // next({ path: '/user/login', query: { redirect: to.fullPath } })
+                  next({ path: '/user/login' })
                 })
               })
             } else {
               store.dispatch('GenerateRoutes', { roles }).then(() => {
                 // 根据roles权限生成可访问的路由表
+                next({ ...to, replace: true })
                 // 动态添加可访问路由表
                 // router.addRoutes(store.getters.addRouters)
-                const redirect = decodeURIComponent(from.query.redirect || to.path)
-                if (to.path === redirect) {
-                  // hack方法 确保addRoutes已完成 ,set the replace: true so the navigation will not leave a history record
-                  next({ ...to, replace: true })
-                } else {
-                  // 跳转到目的路由
-                  next({ path: redirect })
-                }
+                // const redirect = decodeURIComponent(from.query.redirect || to.path)
+                // if (to.path === redirect) {
+                //   // hack方法 确保addRoutes已完成 ,set the replace: true so the navigation will not leave a history record
+                //   next({ ...to, replace: true })
+                // } else {
+                //   // 跳转到目的路由
+                //   next({ path: redirect })
+                // }
               })
             }
           })
@@ -70,7 +73,8 @@ router.beforeEach((to, from, next) => {
               description: '请求用户信息失败,请重试'
             })
             store.dispatch('Logout').then(() => {
-              next({ path: '/user/login', query: { redirect: to.fullPath } })
+              // next({ path: '/user/login', query: { redirect: to.fullPath } })
+              next({ path: '/user/login' })
             })
           })
       } else {
@@ -83,7 +87,8 @@ router.beforeEach((to, from, next) => {
       // 在免登录白名单,直接进入
       next()
     } else {
-      next({ path: '/user/login', query: { redirect: to.fullPath } })
+      // next({ path: '/user/login', query: { redirect: to.fullPath } })
+      next({ path: '/user/login' })
       NProgress.done() // if current page is login will not trigger afterEach hook, so manually handle it
     }
   }

+ 2 - 2
src/utils/mixin.js

@@ -57,9 +57,9 @@ const AppDeviceEnquire = {
       switch (deviceType) {
         case DEVICE_TYPE.DESKTOP:
           $store.commit('TOGGLE_DEVICE', 'desktop')
-          // $store.dispatch('setSidebar', true)
+          $store.dispatch('setSidebar', true)
           // 默认收起侧边栏
-          $store.dispatch('setSidebar', false)
+          // $store.dispatch('setSidebar', false)
           break
         case DEVICE_TYPE.TABLET:
           $store.commit('TOGGLE_DEVICE', 'tablet')

+ 26 - 12
src/views/allocationManagement/transferOut/detail.vue

@@ -1,9 +1,9 @@
 <template>
   <div class="allocateBillDetail-wrap">
     <a-spin :spinning="spinning" tip="Loading...">
-      <a-page-header :ghost="false" :backIcon="false" class="allocateBillDetail-back" >
+      <a-page-header :ghost="false" :backIcon="false" class="allocateBillDetail-back" :style="{ padding: !outBizSn ? '16px 24px' : '0px 24px' }" >
         <!-- 自定义的二级文字标题 -->
-        <template slot="subTitle">
+        <template slot="subTitle" v-if="!outBizSn">
           <a id="allocateBillDetail-back-btn" href="javascript:;" @click="handleBack"><a-icon type="left" /> 返回列表</a>
           <a-button
             v-if="isEdit"
@@ -35,7 +35,11 @@
       <a-card size="small" :bordered="false" class="allocateBillDetail-cont">
         <!-- 总计 -->
         <a-alert type="info" showIcon style="margin-bottom:15px">
-          <div slot="message">总数量:<strong>{{ (productTotal&&productTotal.totalQty) || 0 }}</strong> ,总成本(¥):<strong>{{ (productTotal&&productTotal.totalCost) || 0 }}</strong> ,总售价(¥):<strong>{{ (productTotal&&productTotal.totalPrice) || 0 }}</strong></div>
+          <div slot="message">
+            总数量:<strong>{{ (productTotal&&(productTotal.totalQty || productTotal.totalQty==0)) ? productTotal.totalQty : '--' }}</strong> ,
+            总成本(¥):<strong>{{ (productTotal&&(productTotal.totalCost || productTotal.totalCost==0)) ? productTotal.totalCost : '--' }}</strong> ,
+            总售价(¥):<strong>{{ (productTotal&&(productTotal.totalPrice || productTotal.totalPrice==0)) ? productTotal.totalPrice : '--' }}</strong>
+          </div>
         </a-alert>
         <!-- 列表 -->
         <s-table
@@ -61,6 +65,12 @@ import { getOperationalPrecision } from '@/libs/tools.js'
 import { allocateBillDetailList, allocateBillDetail, allocateBillDetailCount, allocateBillDetailPrint } from '@/api/allocateBill'
 export default {
   components: { STable, VSelect },
+  props: {
+    outBizSn: { //  有值则为弹框,无值则为页面
+      type: [Number, String],
+      default: ''
+    }
+  },
   data () {
     return {
       spinning: false,
@@ -74,12 +84,12 @@ export default {
         { title: '成本价', dataIndex: 'cost', width: 100, 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: 'qty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '成本小计(¥)', dataIndex: 'costSubtotal', width: 115, align: 'center' },
-        { title: '售价小计(¥)', dataIndex: 'priceSubtotal', width: 100, align: 'center' }
+        { title: '成本小计(¥)', dataIndex: 'costSubtotal', width: 115, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '售价小计(¥)', dataIndex: 'priceSubtotal', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } }
       ],
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
-        return allocateBillDetailList(Object.assign(parameter, { allocateSn: this.$route.params.sn })).then(res => {
+        return allocateBillDetailList(Object.assign(parameter, { allocateSn: this.outBizSn || this.$route.params.sn })).then(res => {
           const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
           for (var i = 0; i < data.list.length; i++) {
@@ -105,11 +115,11 @@ export default {
   methods: {
     //  返回列表
     handleBack () {
-      this.$router.push({ path: '/allocationManagement/transferOut/list' })
+      this.$router.push({ path: '/allocationManagement/transferOut/list', query: { closeLastOldTab: true } })
     },
     // 基本信息
     getDetail () {
-      allocateBillDetail({ sn: this.$route.params.sn }).then(res => {
+      allocateBillDetail({ sn: this.outBizSn || this.$route.params.sn }).then(res => {
         if (res.status == 200) {
           this.basicInfoData = res.data
         } else {
@@ -119,7 +129,7 @@ export default {
     },
     // 合计
     getDetailCount () {
-      allocateBillDetailCount({ allocateSn: this.$route.params.sn }).then(res => {
+      allocateBillDetailCount({ allocateSn: this.outBizSn || this.$route.params.sn }).then(res => {
         if (res.status == 200) {
           this.productTotal = res.data
         } else {
@@ -135,7 +145,7 @@ export default {
     handlePrint (type) {
       const _this = this
       _this.spinning = true
-      allocateBillDetailPrint({ sn: this.$route.params.sn, isPreview: type == 'preview' ? 1 : 0 }).then(res => {
+      allocateBillDetailPrint({ sn: this.outBizSn || this.$route.params.sn, isPreview: type == 'preview' ? 1 : 0 }).then(res => {
         _this.spinning = false
         if (res.type == 'application/json') {
           var reader = new FileReader()
@@ -166,10 +176,14 @@ export default {
       }
     }
   },
+  mounted () {
+    this.getDetail()
+    this.getDetailCount()
+  },
   beforeRouteEnter (to, from, next) {
     next(vm => {
-      vm.getDetail()
-      vm.getDetailCount()
+      // vm.getDetail()
+      // vm.getDetailCount()
     })
   }
 }

+ 10 - 2
src/views/allocationManagement/transferOut/edit.vue

@@ -68,7 +68,11 @@
           <a-collapse-panel key="1" header="已选产品">
             <!-- 总计 -->
             <a-alert type="info" showIcon style="margin-bottom:15px">
-              <div slot="message">总数量:<strong>{{ (productTotal&&productTotal.totalQty) || 0 }}</strong> ,总成本(¥):<strong>{{ (productTotal&&productTotal.totalCost) || 0 }}</strong> ,总售价(¥):<strong>{{ (productTotal&&productTotal.totalPrice) || 0 }}</strong></div>
+              <div slot="message">
+                总数量:<strong>{{ (productTotal&&(productTotal.totalQty || productTotal.totalQty==0)) ? productTotal.totalQty : '--' }}</strong> ,
+                总成本(¥):<strong>{{ (productTotal&&(productTotal.totalCost || productTotal.totalCost==0)) ? productTotal.totalCost : '--' }}</strong> ,
+                总售价(¥):<strong>{{ (productTotal&&(productTotal.totalPrice || productTotal.totalPrice==0)) ? productTotal.totalPrice : '--' }}</strong>
+              </div>
             </a-alert>
             <!-- 筛选条件 -->
             <a-row :gutter="15">
@@ -108,6 +112,7 @@
               :columns="chooseColumns"
               :dataSource="chooseLoadData"
               :scroll="{ x: 1335, y: 300 }"
+              :loading="loading"
               :pagination="choosePaginationProps"
               bordered>
               <!-- 调出数量 -->
@@ -166,6 +171,7 @@ export default {
         productName: ''
       },
       disabled: false, //  查询、重置按钮是否可操作
+      loading: false,
       chooseDisabled: false, //  查询、重置按钮是否可操作
       advanced: false, // 高级搜索 展开/关闭
       productBrandList: [], //  产品品牌  下拉数据
@@ -346,7 +352,7 @@ export default {
     },
     //  返回列表
     handleBack () {
-      this.$router.push({ path: '/allocationManagement/transferOut/list' })
+      this.$router.push({ path: '/allocationManagement/transferOut/list', query: { closeLastOldTab: true } })
     },
     //  已选产品 分页  一页多少条change
     changeChoosePageSize (current, pageSize) {
@@ -363,12 +369,14 @@ export default {
     getChooseProductList (pageNo) {
       this.choosePageNo = this.choosePageNo || pageNo
       this.chooseDisabled = true
+      this.loading = true
       const params = {
         pageNo: this.choosePageNo,
         pageSize: this.choosePageSize,
         allocateSn: this.$route.params.sn
       }
       allocateBillDetailList(Object.assign(params, this.chooseQueryParam)).then(res => {
+        this.loading = false
         if (res.status == 200) {
           //  合计
           this.getDetailCount(Object.assign(params, this.chooseQueryParam))

+ 8 - 11
src/views/allocationManagement/transferOut/list.vue

@@ -68,7 +68,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
@@ -78,10 +78,6 @@
         <template slot="allocateNo" slot-scope="text, record">
           <span :class="$hasPermissions('M_transferOut_detail')?'active':'common'" @click="handleDetail(record)">{{ record.allocateNo }}</span>
         </template>
-        <!-- 财务状态 -->
-        <template slot="settleState" slot-scope="text, record">
-          <a-badge :color="text=='FINISH'?'#87d068':'gold'" :text="record.settleStateDictValue" />
-        </template>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
           <a-button
@@ -112,7 +108,7 @@
     <!-- 新增 -->
     <basic-info-modal :openModal="openModal" @ok="handleOk" @close="openModal=false" />
     <!-- 审核 -->
-    <auditModal :openModal="visibleAudit" @close="visibleAudit=false" @ok="auditOrder('WAIT_OUT_WAREHOUSE')" @fail="auditOrder('AUDIT_REJECT')" />
+    <auditModal :openModal="visibleAudit" :spinning="spinning" @close="visibleAudit=false" @ok="auditOrder('WAIT_OUT_WAREHOUSE')" @fail="auditOrder('AUDIT_REJECT')" />
   </a-card>
 </template>
 
@@ -131,7 +127,6 @@ export default {
     return {
       spinning: false,
       advanced: false, // 高级搜索 展开/关闭
-      tableHeight: 0,
       time: [
         moment(getDate.getThreeMonthDays().starttime, 'YYYY-MM-DD'),
         moment(getDate.getCurrMonthDays().endtime, 'YYYY-MM-DD')
@@ -148,7 +143,7 @@ export default {
       exportLoading: 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: 'allocateNo' }, align: 'center' },
         { title: '调往对象', dataIndex: 'targetName', width: 220, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '客户类型', dataIndex: 'dealerLevelDictValue', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
@@ -165,9 +160,6 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
-        }
         return allocateBillList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
@@ -184,6 +176,11 @@ export default {
       openModal: false //  新增编辑  弹框
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 425 : 370)
+    }
+  },
   methods: {
     //  创建时间  change
     dateChange (date) {

+ 7 - 1
src/views/basicData/transferTypeManagement/list.vue

@@ -14,9 +14,10 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
+        :scroll="{ y: tableHeight }"
         :data="loadData"
         bordered>
         <!-- 操作 -->
@@ -76,6 +77,11 @@ export default {
       nowData: null //  当前记录数据
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - 310
+    }
+  },
   methods: {
     //  新增/编辑
     handleEdit (row) {

+ 1 - 1
src/views/basicData/warehouse/list.vue

@@ -25,7 +25,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"

+ 3 - 3
src/views/basicData/warehouse/storingLocation/list.vue

@@ -33,7 +33,7 @@
         <s-table
           class="sTable"
           ref="table"
-          size="default"
+          size="small"
           :rowKey="(record) => record.id"
           :columns="columns"
           :data="loadData"
@@ -82,7 +82,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: '操作', scopedSlots: { customRender: 'action' }, width: 160, align: 'center' }
       ],
       // 加载数据方法 必须为 Promise 对象
@@ -159,7 +159,7 @@ export default {
     },
     //  返回列表
     handleBack () {
-      this.$router.push({ path: '/basicData/warehouse/list' })
+      this.$router.push({ path: '/basicData/warehouse/list', query: { closeLastOldTab: true } })
     }
   }
 }

+ 16 - 10
src/views/common/auditModal.vue

@@ -7,17 +7,19 @@
     v-model="isShow"
     @cancle="isShow=false"
     :width="416">
-    <div class="audit-main">
-      <a-icon type="question-circle" style="color: #faad14;font-size: 22px;margin-right: 16px;" />
-      <div class="audit-cont">
-        <p class="audit-tit">提示</p>
-        <p class="audit-txt">请点击下方按钮确认操作?</p>
+    <a-spin :spinning="spinning" tip="Loading...">
+      <div class="audit-main">
+        <a-icon type="question-circle" style="color: #faad14;font-size: 22px;margin-right: 16px;" />
+        <div class="audit-cont">
+          <p class="audit-tit">提示</p>
+          <p class="audit-txt">请点击下方按钮确认操作?</p>
+        </div>
       </div>
-    </div>
-    <div class="btn-box">
-      <a-button type="primary" class="button-error" @click="handleAuditFail">审核不通过</a-button>
-      <a-button type="primary" class="button-info" @click="handleAuditOk">审核通过</a-button>
-    </div>
+      <div class="btn-box">
+        <a-button type="primary" class="button-error" @click="handleAuditFail">审核不通过</a-button>
+        <a-button type="primary" class="button-info" @click="handleAuditOk">审核通过</a-button>
+      </div>
+    </a-spin>
   </a-modal>
 </template>
 
@@ -28,6 +30,10 @@ export default {
     openModal: { //  弹框显示状态
       type: Boolean,
       default: false
+    },
+    spinning: {
+      type: Boolean,
+      default: false
     }
   },
   data () {

+ 9 - 6
src/views/common/chooseCustomerModal.vue

@@ -23,21 +23,21 @@
                 <a-form-item label="地区">
                   <a-col span="7">
                     <a-form-item prop="provinceSn" style="margin: 0;">
-                      <a-select v-model="queryParam.provinceSn" @change="getCityList" placeholder="请选择省">
+                      <a-select v-model="queryParam.provinceSn" allowClear @change="getCityList" placeholder="请选择省">
                         <a-select-option v-for="item in addrProvinceList" :value="item.id" :key="item.id + 'a'">{{ item.name }}</a-select-option>
                       </a-select>
                     </a-form-item>
                   </a-col>
                   <a-col span="7" offset="1">
                     <a-form-item prop="citySn" style="margin: 0;">
-                      <a-select v-model="queryParam.citySn" @change="getAreaList" placeholder="请选择市">
+                      <a-select v-model="queryParam.citySn" allowClear @change="getAreaList" placeholder="请选择市">
                         <a-select-option v-for="item in addrCityList" :value="item.id" :key="item.id + 'b'">{{ item.name }}</a-select-option>
                       </a-select>
                     </a-form-item>
                   </a-col>
                   <a-col span="7" offset="1">
                     <a-form-item prop="districtSn" style="margin: 0;">
-                      <a-select v-model="queryParam.districtSn" placeholder="请选择区/县">
+                      <a-select v-model="queryParam.districtSn" allowClear placeholder="请选择区/县">
                         <a-select-option v-for="item in addrDistrictList" :value="item.id" :key="item.id + 'c'">{{ item.name }}</a-select-option>
                       </a-select>
                     </a-form-item>
@@ -144,7 +144,6 @@ export default {
       this.$refs.table.refresh(true)
     },
     resetData () {
-      console.log('重置艾迪康')
       this.queryParam.dealerName = ''
       this.queryParam.provinceSn = undefined
       this.queryParam.citySn = undefined
@@ -171,13 +170,17 @@ export default {
       this.addrDistrictList = []
       this.queryParam.citySn = undefined
       this.queryParam.districtSn = undefined
-      this.getArea('city', val)
+      if (val) {
+        this.getArea('city', val)
+      }
     },
     // 获取区县列表
     getAreaList (val) {
       this.addrDistrictList = []
       this.queryParam.districtSn = undefined
-      this.getArea('district', val)
+      if (val) {
+        this.getArea('district', val)
+      }
     },
     //  省/市/区
     getArea (leve, sn) {

+ 6 - 1
src/views/common/chooseImportModal.vue

@@ -18,6 +18,7 @@
         :rowKey="(record) => record.goodsSn"
         :columns="nowColumns"
         :dataSource="loadData"
+        :loading="loading"
         :scroll="{ y: 200 }"
         :pagination="false"
         bordered>
@@ -32,6 +33,7 @@
         :rowKey="(record) => record.goodsCode"
         :columns="nowUnColumns"
         :dataSource="unLoadData"
+        :loading="loading"
         :scroll="{ y: 200 }"
         :pagination="false"
         bordered>
@@ -157,13 +159,16 @@ export default {
         { title: this.paramsData && this.paramsData.promoRuleType == 'PROMO_PROD' ? '特惠单价(¥)' : '换购单价(¥)', dataIndex: 'goodsPrice', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '备注', dataIndex: 'remark', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true }
       ],
-      unLoadData: []
+      unLoadData: [],
+      loading: false
     }
   },
   methods: {
     getData () {
       const _this = this
+      this.loading = true
       promoRuleGoods(this.paramsData).then(res => {
+        this.loading = false
         if (res.status == 200) {
           if (res.data.okGoodsList && res.data.okGoodsList.length > 0) {
             res.data.okGoodsList.map((item, index) => {

+ 6 - 6
src/views/dealerManagement/dealerAccountManagement/detailModal.vue

@@ -8,13 +8,13 @@
     v-model="isShow"
     @cancle="isShow=false"
     :width="800">
-    <div v-if="detailData">
+    <div>
       <a-descriptions bordered size="small" :column="2">
-        <a-descriptions-item label="经销商名称:">{{ (detailData.org&&detailData.org.name) || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="管理员姓名:">{{ detailData.name || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="管理员手机:">{{ detailData.phone || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="管理员账号:">{{ detailData.loginName || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="最大可开通用户数(含管理员账号):">{{ (detailData.org&&detailData.org.childUserMaxNum) || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="经销商名称:">{{ (detailData&&detailData.org&&detailData.org.name) ? detailData.org.name : '--' }}</a-descriptions-item>
+        <a-descriptions-item label="管理员姓名:">{{ detailData&&detailData.name ? detailData.name : '--' }}</a-descriptions-item>
+        <a-descriptions-item label="管理员手机:">{{ detailData&&detailData.phone ? detailData.phone : '--' }}</a-descriptions-item>
+        <a-descriptions-item label="管理员账号:">{{ detailData&&detailData.loginName ? detailData.loginName : '--' }}</a-descriptions-item>
+        <a-descriptions-item label="最大可开通用户数(含管理员账号):">{{ (detailData&&detailData.org&&detailData.org.childUserMaxNum) ? detailData.org.childUserMaxNum : '--' }}</a-descriptions-item>
       </a-descriptions>
       <div class="btn-cont"><a-button id="dealerAccountDetail-modal-back" @click="isShow = false">关闭</a-button></div>
     </div>

+ 1 - 1
src/views/dealerManagement/dealerAccountManagement/list.vue

@@ -35,7 +35,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"

+ 6 - 2
src/views/dealerManagement/dealerRelationshipBinding/list.vue

@@ -25,7 +25,7 @@
       <a-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.dealerSn"
         :columns="columns"
         :pagination="paginationProps"
@@ -33,6 +33,7 @@
         @expand="expand"
         :expandedRowKeys="expandedRowKeys"
         :expandRowByClick="true"
+        :loading="loading"
         :scroll="{ y: tableHeight }">
         <a-table
           slot="expandedRowRender"
@@ -82,6 +83,7 @@ export default {
     return {
       tableHeight: 0,
       spinning: false,
+      loading: false,
       formItemLayout: {
         labelCol: { span: 6 },
         wrapperCol: { span: 16 }
@@ -117,7 +119,7 @@ export default {
     }
   },
   mounted () {
-    this.tableHeight = window.innerHeight - 380
+    this.tableHeight = window.innerHeight - 370
     this.getList()
   },
   methods: {
@@ -155,7 +157,9 @@ export default {
         pageNo: this.pageNo,
         pageSize: this.pageSize
       }
+      this.loading = true
       dealerRelationList(Object.assign(params, this.queryParam, { dealerLevelList: this.tabInd == 1 ? ['PROVINCE'] : ['PROVINCE', 'CITY'] })).then(res => {
+        this.loading = false
         if (res.status == 200) {
           const data = res.data
           this.paginationProps.total = Number(res.data.count) || 0

+ 5 - 1
src/views/dealerManagement/marketingDivisionSet/editModal.vue

@@ -28,7 +28,7 @@
               placeholder="请输入分区名称(最多30个字符)"
               allowClear />
           </a-form-model-item>
-          <a-form-model-item label="省份/市">
+          <a-form-model-item label="省份/市" required>
             <div class="tree-node" id="treeNode">
               <div class="tree-box" v-for="item in addrProvinceList" :key="item.id">
                 <div class="tree-parent">
@@ -234,6 +234,10 @@ export default {
           this.subareaAreaList = []
           this.filterData(this.addrProvinceList)
           // console.log(this.subareaAreaList)
+          if (this.subareaAreaList.length == 0) {
+            this.$message.info('请先选择省份/市')
+            return
+          }
           // 编辑
           if (this.itemId) {
             formData.subareaSn = this.itemId

+ 9 - 3
src/views/dealerManagement/marketingDivisionSet/list.vue

@@ -2,18 +2,19 @@
   <a-card size="small" :bordered="false" class="marketingDivisionSetList-wrap">
     <a-spin :spinning="spinning" tip="Loading...">
       <!-- 操作按钮 -->
-      <div class="table-operator">
+      <div class="table-operator" style="border: 0;">
         <a-button id="marketingDivisionSetList-add" type="primary" v-if="$hasPermissions('B_marketingDivisionSet_add')" class="button-error" @click="handleEdit()">新增</a-button>
       </div>
       <!-- 列表 -->
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :showPagination="false"
         :data="loadData"
+        :scroll="{ y: tableHeight }"
         bordered>
         <!-- 市区 -->
         <template slot="cityArea" slot-scope="text, record">
@@ -63,7 +64,7 @@ export default {
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '分区名', dataIndex: 'subareaName', width: 200, align: 'center' },
+        { title: '分区名', dataIndex: 'subareaName', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '省份/市', scopedSlots: { customRender: 'cityArea' }, align: 'left' },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 150, align: 'center' }
       ],
@@ -85,6 +86,11 @@ export default {
       itemId: null //  当前产品id
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - 260
+    }
+  },
   methods: {
     //  重置
     resetSearchForm () {

+ 50 - 36
src/views/dealerManagement/merchantInfoManagement/detailModal.vue

@@ -9,19 +9,24 @@
     @cancle="isShow=false"
     :width="960">
     <a-spin :spinning="spinning" tip="Loading...">
-      <div v-if="form">
+      <div>
         <a-collapse :activeKey="['1','2','3']" class="merchantInfoManagement-cont-m">
           <a-collapse-panel key="1" header="基础信息">
             <a-descriptions :column="2" bordered size="small">
-              <a-descriptions-item label="经销商名称">{{ form.dealerName || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="经销商别名">{{ form.dealerAlias || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="商户类型">{{ form.dealerTypeDictValue || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="联系人1">{{ form.contact || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="联系手机1">{{ form.contactMobile || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="联系角色1">{{ form.contactRole || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="联系电话">{{ form.dealerTelephone || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="经销商名称">{{ form&&form.dealerName ? form.dealerName : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="经销商别名">{{ form&&form.dealerAlias ? form.dealerAlias : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="商户类型">{{ form&&form.dealerTypeDictValue ? form.dealerTypeDictValue : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="联系人1">{{ form&&form.contact ? form.contact : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="联系手机1">{{ form&&form.contactMobile ? form.contactMobile : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="联系角色1">{{ form&&form.contactRole ? form.contactRole : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="联系电话">{{ form&&form.dealerTelephone ? form.dealerTelephone : '--' }}</a-descriptions-item>
               <a-descriptions-item label="地址">
-                <span v-if="form.provinceName || form.cityName || form.districtName || form.address">{{ form.provinceName }}{{ form.cityName }}{{ form.districtName }}{{ form.address }}</span>
+                <span v-if="form&&(form.provinceName || form.cityName || form.districtName || form.address)">
+                  {{ form&&form.provinceName ? form.provinceName : '' }}
+                  {{ form&&form.cityName ? form.cityName : '' }}
+                  {{ form&&form.districtName ? form.districtName : '' }}
+                  {{ form&&form.address ? form.address : '' }}
+                </span>
                 <span v-else>--</span>
               </a-descriptions-item>
             </a-descriptions>
@@ -30,44 +35,49 @@
         <a-collapse class="merchantInfoManagement-cont-m">
           <a-collapse-panel key="2" header="公司信息">
             <a-descriptions :column="2" bordered size="small">
-              <a-descriptions-item label="经营方式">{{ form.busniessMode || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="经营项目">{{ form.busniessItmes || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="公司规模">{{ form.busniessScope || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="成立时间">{{ form.buildDate || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="经营方式">{{ form&&form.busniessMode ? form.busniessMode : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="经营项目">{{ form&&form.busniessItmes ? form.busniessItmes : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="公司规模">{{ form&&form.busniessScope ? form.busniessScope : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="成立时间">{{ form&&form.buildDate ? form.buildDate : '--' }}</a-descriptions-item>
               <a-descriptions-item label="一般纳税人">
-                <span v-if="form.isTaxpayer">{{ form.isTaxpayer == 1 ? '是':'否' }}</span>
+                <span v-if="form&&form.isTaxpayer">{{ form&&form.isTaxpayer == 1 ? '是':'否' }}</span>
                 <span v-else>--</span>
               </a-descriptions-item>
-              <a-descriptions-item label="身份证号码">{{ form.indentityCard || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="生日">{{ form.brithday || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="籍贯">{{ form.nativePlace || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="邮箱">{{ form.mail || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="联系人2">{{ form.contact2 || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="联系角色2">{{ form.contractRole2 || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="联系手机2">{{ form.contactMobile2 || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="邮政编码">{{ form.zipCode || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="收货人">{{ form.receiveContact || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="收货人电话">{{ form.receiveMobile || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="身份证号码">{{ form&&form.indentityCard ? form.indentityCard : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="生日">{{ form&&form.brithday ? form.brithday : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="籍贯">{{ form&&form.nativePlace ? form.nativePlace : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="邮箱">{{ form&&form.mail ? form.mail : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="联系人2">{{ form&&form.contact2 ? form.contact2 : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="联系角色2">{{ form&&form.contractRole2 ? form.contractRole2 : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="联系手机2">{{ form&&form.contactMobile2 ? form.contactMobile2 : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="邮政编码">{{ form&&form.zipCode ? form.zipCode : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="收货人">{{ form&&form.receiveContact ? form.receiveContact : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="收货人电话">{{ form&&form.receiveMobile ? form.receiveMobile : '--' }}</a-descriptions-item>
               <a-descriptions-item label="收货地址">
-                <span v-if="form.receiveProvinceName || form.receiveCityName || form.receiveDistrictName || form.receiveAddress">{{ form.receiveProvinceName }}{{ form.receiveCityName }}{{ form.receiveDistrictName }}{{ form.receiveAddress }}</span>
+                <span v-if="form&&(form.receiveProvinceName || form.receiveCityName || form.receiveDistrictName || form.receiveAddress)">
+                  {{ form&&form.receiveProvinceName ? form.receiveProvinceName : '' }}
+                  {{ form&&form.receiveCityName ? form.receiveCityName : '' }}
+                  {{ form&&form.receiveDistrictName ? form.receiveDistrictName : '' }}
+                  {{ form&&form.receiveAddress ? form.receiveAddress : '' }}
+                </span>
                 <span v-else>--</span>
               </a-descriptions-item>
-              <a-descriptions-item label="银行账户">{{ form.tradeAccountName || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="开户行">{{ form.tradeBankName || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="银行账号">{{ form.tradeBankAccount || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="银行账户">{{ form&&form.tradeAccountName ? form.tradeAccountName : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="开户行">{{ form&&form.tradeBankName ? form.tradeBankName : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="银行账号">{{ form&&form.tradeBankAccount ? form.tradeBankAccount : '--' }}</a-descriptions-item>
             </a-descriptions>
           </a-collapse-panel>
         </a-collapse>
         <a-collapse class="merchantInfoManagement-cont-m">
           <a-collapse-panel key="3" header="总部信息">
             <a-descriptions :column="2" bordered size="small">
-              <a-descriptions-item label="箭冠汽配代码">{{ form.jgAutoPartsCode || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="门头更换日期">{{ form.jgDoorHeaderChangeTime || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="箭冠汽配代码">{{ form&&form.jgAutoPartsCode ? form.jgAutoPartsCode : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="门头更换日期">{{ form&&form.jgDoorHeaderChangeTime ? form.jgDoorHeaderChangeTime : '--' }}</a-descriptions-item>
               <a-descriptions-item label="特约价是否可见">
-                <span v-if="form.isShowSpecialPrice">{{ form.isShowSpecialPrice == 1 ? '是':'否' }}</span>
+                <span v-if="form&&form.isShowSpecialPrice">{{ form&&form.isShowSpecialPrice == 1 ? '是':'否' }}</span>
                 <span v-else>--</span>
               </a-descriptions-item>
-              <a-descriptions-item label="备注">{{ form.remark || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="备注">{{ form&&form.remark ? form.remark : '--' }}</a-descriptions-item>
             </a-descriptions>
           </a-collapse-panel>
         </a-collapse>
@@ -83,12 +93,9 @@
           <a-button id="merchantInfoManagement-back" size="large" @click="isShow = false" style="font-size: 12px;">返回列表</a-button>
         </div>
       </div>
-      <div style="padding: 50px;text-align: center;" v-else>
-        <a-spin />
-      </div>
     </a-spin>
     <!-- 审核 -->
-    <auditModal :openModal="visibleAudit" @close="visibleAudit=false" @ok="auditOrder('PASS')" @fail="auditOrder('REJECT')" />
+    <auditModal :openModal="visibleAudit" :spinning="spinning" @close="visibleAudit=false" @ok="auditOrder('PASS')" @fail="auditOrder('REJECT')" />
   </a-modal>
 </template>
 
@@ -139,16 +146,23 @@ export default {
     },
     // 详情编辑
     getDetail () {
+      this.spinning = true
       if (this.isAudit) {
         dealerFindUpdateInfoBySn({ sn: this.itemId }).then(res => {
           if (res.status == 200) {
             this.form = res.data
+            this.spinning = false
+          } else {
+            this.spinning = false
           }
         })
       } else {
         dealerDetailBySn({ sn: this.itemId }).then(res => {
           if (res.status == 200) {
             this.form = res.data
+            this.spinning = false
+          } else {
+            this.spinning = false
           }
         })
       }

+ 44 - 35
src/views/dealerManagement/merchantInfoManagement/edit.vue

@@ -65,21 +65,21 @@
                       <!-- 地址 -->
                       <a-col span="8">
                         <a-form-model-item prop="provinceSn">
-                          <a-select id="merchantInfoManagementEdit-provinceSn" @change="getCityList" v-model="form.provinceSn" placeholder="请选择省">
+                          <a-select id="merchantInfoManagementEdit-provinceSn" allowClear @change="getCityList" v-model="form.provinceSn" placeholder="请选择省">
                             <a-select-option v-for="item in addrProvinceList" :value="item.areaSn" :key="item.areaSn + 'a'">{{ item.name }}</a-select-option>
                           </a-select>
                         </a-form-model-item>
                       </a-col>
                       <a-col span="8">
                         <a-form-model-item prop="citySn">
-                          <a-select id="merchantInfoManagementEdit-citySn" @change="getAreaList" v-model="form.citySn" placeholder="请选择市">
+                          <a-select id="merchantInfoManagementEdit-citySn" allowClear @change="getAreaList" v-model="form.citySn" placeholder="请选择市">
                             <a-select-option v-for="item in addrCityList" :value="item.areaSn" :key="item.areaSn + 'b'">{{ item.name }}</a-select-option>
                           </a-select>
                         </a-form-model-item>
                       </a-col>
                       <a-col span="8">
                         <a-form-model-item prop="districtSn">
-                          <a-select id="merchantInfoManagementEdit-districtSn" @change="areaCharged" v-model="form.districtSn" placeholder="请选择区/县">
+                          <a-select id="merchantInfoManagementEdit-districtSn" allowClear @change="areaCharged" v-model="form.districtSn" placeholder="请选择区/县">
                             <a-select-option v-for="item in addrDistrictList" :value="item.areaSn" :key="item.areaSn + 'c'">{{ item.name }}</a-select-option>
                           </a-select>
                         </a-form-model-item>
@@ -156,6 +156,7 @@
                       :disabledDate="disabledDate"
                       v-model="form.buildDate"
                       :format="dateFormat"
+                      allowClear
                       placeholder="请选择日期" />
                   </a-form-model-item>
                 </a-col>
@@ -188,6 +189,7 @@
                       :disabledDate="disabledDate"
                       v-model="form.brithday"
                       :format="dateFormat"
+                      allowClear
                       placeholder="请选择日期" />
                   </a-form-model-item>
                 </a-col>
@@ -247,21 +249,21 @@
                       <!-- 地址 -->
                       <a-col span="8">
                         <a-form-model-item prop="receiveProvinceSn">
-                          <a-select id="merchantInfoManagementEdit-receiveProvinceSn" @change="getCityList1" v-model="form.receiveProvinceSn" placeholder="请选择省">
+                          <a-select id="merchantInfoManagementEdit-receiveProvinceSn" allowClear @change="getCityList1" v-model="form.receiveProvinceSn" placeholder="请选择省">
                             <a-select-option v-for="item in addrProvinceList1" :value="item.areaSn" :key="item.areaSn + 'a'">{{ item.name }}</a-select-option>
                           </a-select>
                         </a-form-model-item>
                       </a-col>
                       <a-col span="8">
                         <a-form-model-item prop="receiveCitySn">
-                          <a-select id="merchantInfoManagementEdit-receiveCitySn" @change="getAreaList1" v-model="form.receiveCitySn" placeholder="请选择市">
+                          <a-select id="merchantInfoManagementEdit-receiveCitySn" allowClear @change="getAreaList1" v-model="form.receiveCitySn" placeholder="请选择市">
                             <a-select-option v-for="item in addrCityList1" :value="item.areaSn" :key="item.areaSn + 'b'">{{ item.name }}</a-select-option>
                           </a-select>
                         </a-form-model-item>
                       </a-col>
                       <a-col span="8">
                         <a-form-model-item prop="receiveDistrictSn">
-                          <a-select id="merchantInfoManagementEdit-receiveDistrictSn" @change="areaCharged1" v-model="form.receiveDistrictSn" placeholder="请选择区/县">
+                          <a-select id="merchantInfoManagementEdit-receiveDistrictSn" allowClear @change="areaCharged1" v-model="form.receiveDistrictSn" placeholder="请选择区/县">
                             <a-select-option v-for="item in addrDistrictList1" :value="item.areaSn" :key="item.areaSn + 'c'">{{ item.name }}</a-select-option>
                           </a-select>
                         </a-form-model-item>
@@ -335,6 +337,7 @@
                       id="merchantInfoManagementEdit-jgDoorHeaderChangeTime"
                       :disabledDate="disabledDate"
                       v-model="form.jgDoorHeaderChangeTime"
+                      allowClear
                       :format="dateFormat"
                       placeholder="请选择日期" />
                   </a-form-model-item>
@@ -558,71 +561,77 @@ export default {
     },
     // 返回
     handleBack () {
-      this.$router.push({ name: 'merchantInfoManagementList' })
+      this.$router.push({ path: '/dealerManagement/merchantInfoManagement/list', query: { closeLastOldTab: true } })
     },
     // 获取城市列表
     getCityList (val) {
-      const index = this.addrProvinceList.findIndex(item => item.areaSn == val)
-      if (index >= 0) {
-        this.form.provinceName = this.addrProvinceList[index].name
-      }
       this.addrCityList = []
       this.addrDistrictList = []
       this.form.citySn = undefined
       this.form.districtSn = undefined
       this.form.address = ''
-      this.getArea('city', val, 0)
+      if (val) {
+        this.getArea('city', val, 0)
+        this.form.provinceName = this.addrProvinceList.find(item => item.areaSn == val).name
+      } else {
+        this.form.provinceName = ''
+      }
     },
     // 获取区县列表
     getAreaList (val) {
-      const index = this.addrCityList.findIndex(item => item.areaSn == val)
-      if (index >= 0) {
-        this.form.cityName = this.addrCityList[index].name
-      }
       this.addrDistrictList = []
       this.form.districtSn = undefined
       this.form.address = ''
-      this.getArea('district', val, 0)
+      if (val) {
+        this.getArea('district', val, 0)
+        this.form.cityName = this.addrCityList.find(item => item.areaSn == val).name
+      } else {
+        this.form.cityName = ''
+      }
     },
     // 区县变更
     areaCharged (val) {
-      const index = this.addrDistrictList.findIndex(item => item.areaSn == val)
-      if (index >= 0) {
-        this.form.districtName = this.addrDistrictList[index].name
-      }
       this.form.address = ''
+      if (val) {
+        this.form.districtName = this.addrDistrictList.find(item => item.areaSn == val).name
+      } else {
+        this.form.districtName = ''
+      }
     },
     // 获取城市列表
     getCityList1 (val) {
-      const index = this.addrProvinceList1.findIndex(item => item.areaSn == val)
-      if (index >= 0) {
-        this.form.receiveProvinceName = this.addrProvinceList1[index].name
-      }
       this.addrCityList1 = []
       this.addrDistrictList1 = []
       this.form.receiveCitySn = undefined
       this.form.receiveDistrictSn = undefined
       this.form.receiveAddress = ''
-      this.getArea('city', val, 1)
+      if (val) {
+        this.getArea('city', val, 1)
+        this.form.receiveProvinceName = this.addrProvinceList1.find(item => item.areaSn == val).name
+      } else {
+        this.form.receiveProvinceName = ''
+      }
     },
     // 获取区县列表
     getAreaList1 (val) {
-      const index = this.addrCityList1.findIndex(item => item.areaSn == val)
-      if (index >= 0) {
-        this.form.receiveCityName = this.addrCityList1[index].name
-      }
       this.addrDistrictList1 = []
       this.form.receiveDistrictSn = undefined
       this.form.receiveAddress = ''
-      this.getArea('district', val, 1)
+      if (val) {
+        this.getArea('district', val, 1)
+        this.form.receiveCityName = this.addrCityList1.find(item => item.areaSn == val).name
+      } else {
+        this.form.receiveCityName = ''
+      }
     },
     // 区县变更
     areaCharged1 (val) {
-      const index = this.addrDistrictList1.findIndex(item => item.areaSn == val)
-      if (index >= 0) {
-        this.form.receiveDistrictName = this.addrDistrictList1[index].name
-      }
       this.form.receiveAddress = ''
+      if (val) {
+        this.form.receiveDistrictName = this.addrDistrictList1.find(item => item.areaSn == val).name
+      } else {
+        this.form.receiveDistrictName = ''
+      }
     },
     //  省/市/区
     getArea (leve, sn, index) {

+ 10 - 9
src/views/dealerManagement/merchantInfoManagement/list.vue

@@ -57,14 +57,14 @@
         <a-button id="merchantInfoManagementList-add" type="primary" v-if="$hasPermissions('B_merchantInfo_add')" class="button-error" @click="handleAdd">新增</a-button>
       </div>
       <!-- 总计 -->
-      <a-alert type="info" showIcon style="margin-bottom:15px">
+      <!-- <a-alert type="info" showIcon style="margin-bottom:15px">
         <div slot="message">合计:<strong>{{ total }}</strong>条</div>
-      </a-alert>
+      </a-alert> -->
       <!-- 列表 -->
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
@@ -116,7 +116,6 @@ export default {
     return {
       spinning: false,
       advanced: false, // 高级搜索 展开/关闭
-      tableHeight: 0,
       queryParam: { //  查询条件
         nameLike: '', //  商户名称、别名
         dealerType: undefined, //  商户类型
@@ -130,7 +129,7 @@ export default {
       total: 0,
       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: 'area' }, width: 200, align: 'center' },
         { title: '商户名称', scopedSlots: { customRender: 'dealerName' }, align: 'center', ellipsis: true },
         { title: '商户别名', dataIndex: 'dealerAlias', width: 200, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
@@ -148,13 +147,10 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 440
-        }
         return dealerQueryList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
-          this.total = data.count
+          this.total = data.count || 0
           for (var i = 0; i < data.list.length; i++) {
             data.list[i].no = no + i + 1
           }
@@ -169,6 +165,11 @@ export default {
       isAudit: false
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 430 : 375)
+    }
+  },
   methods: {
     //  重置列表
     resetSearchForm () {

+ 1 - 1
src/views/dealerManagement/merchantInfoManagement/permissionSetting.vue

@@ -314,7 +314,7 @@ export default {
     },
     // 返回
     handleBack () {
-      this.$router.push({ name: 'merchantInfoManagementList' })
+      this.$router.push({ path: '/dealerManagement/merchantInfoManagement/list', query: { closeLastOldTab: true } })
     },
     filterOption (input, option) {
       return (

+ 2 - 2
src/views/dealerManagement/rebateSettings/list.vue

@@ -20,7 +20,7 @@
     <s-table
       class="sTable"
       ref="table"
-      size="default"
+      size="small"
       :rowKey="(record) => record.id"
       :columns="columns"
       :data="loadData"
@@ -91,7 +91,7 @@ export default {
       loadData: parameter => {
         this.disabled = true
         if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
+          this.tableHeight = window.innerHeight - 320
         }
         return queryRebatePage(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data

+ 20 - 19
src/views/financialManagement/financialCollection/list.vue

@@ -75,21 +75,21 @@
                   <a-form-item label="经销商地区">
                     <a-col span="7">
                       <a-form-item prop="dealerProvinceSn" style="margin: 0;">
-                        <a-select v-model="queryParam.dealerProvinceSn" @change="getCityList" placeholder="请选择省">
+                        <a-select v-model="queryParam.dealerProvinceSn" allowClear @change="getCityList" placeholder="请选择省">
                           <a-select-option v-for="item in addrProvinceList" :value="item.id" :key="item.id + 'a'">{{ item.name }}</a-select-option>
                         </a-select>
                       </a-form-item>
                     </a-col>
                     <a-col span="7" offset="1">
                       <a-form-item prop="dealerCitySn" style="margin: 0;">
-                        <a-select v-model="queryParam.dealerCitySn" @change="getAreaList" placeholder="请选择市">
+                        <a-select v-model="queryParam.dealerCitySn" allowClear @change="getAreaList" placeholder="请选择市">
                           <a-select-option v-for="item in addrCityList" :value="item.id" :key="item.id + 'b'">{{ item.name }}</a-select-option>
                         </a-select>
                       </a-form-item>
                     </a-col>
                     <a-col span="7" offset="1">
                       <a-form-item prop="dealerCountySn" style="margin: 0;">
-                        <a-select v-model="queryParam.dealerCountySn" placeholder="请选择区/县">
+                        <a-select v-model="queryParam.dealerCountySn" allowClear placeholder="请选择区/县">
                           <a-select-option v-for="item in addrDistrictList" :value="item.id" :key="item.id + 'c'">{{ item.name }}</a-select-option>
                         </a-select>
                       </a-form-item>
@@ -110,14 +110,14 @@
         </a-form>
       </div>
       <!-- 总计 -->
-      <a-alert type="info" showIcon style="margin-bottom:15px">
+      <!-- <a-alert type="info" showIcon style="margin-bottom:15px">
         <div slot="message">合计:<strong>{{ total }}</strong>条</div>
-      </a-alert>
+      </a-alert> -->
       <!-- 列表 -->
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
@@ -127,10 +127,6 @@
         <template slot="salesBillNo" slot-scope="text, record">
           <span :class="$hasPermissions('B_salesDetail')?'active':'common'" @click="handleDetail(record)">{{ record.salesBillNo }}</span>
         </template>
-        <!-- 财务状态 -->
-        <template slot="financialStatus" slot-scope="text, record">
-          <a-badge :color="text=='FINISH'?'#87d068':'gold'" :text="record.financialStatusDictValue" />
-        </template>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
           <a-button
@@ -175,7 +171,6 @@ export default {
         dealerCitySn: undefined,
         dealerCountySn: undefined
       },
-      tableHeight: 0,
       disabled: false, //  查询、重置按钮是否可操作
       auditDate: [
         moment(getDate.getThreeMonthDays().starttime, 'YYYY-MM-DD'),
@@ -194,22 +189,19 @@ export default {
         { title: '收款方式', dataIndex: 'settleStyleSnDictValue', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '备注', dataIndex: 'remarks', width: 200, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '业务状态', dataIndex: 'billStatusDictValue', width: 120, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '财务状态', dataIndex: 'financialStatus', scopedSlots: { customRender: 'financialStatus' }, width: 120, align: 'center' },
+        { title: '财务状态', dataIndex: 'financialStatusDictValue', width: 120, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 100, align: 'center', fixed: 'right' }
       ],
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
-        }
         return salesReceiptList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
           for (var i = 0; i < data.list.length; i++) {
             data.list[i].no = no + i + 1
           }
-          this.total = data.count
+          this.total = data.count || 0
           this.disabled = false
           return data
         })
@@ -220,6 +212,11 @@ export default {
       addrDistrictList: [] //  区下拉
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 440 : 330)
+    }
+  },
   methods: {
     //  审核时间  change
     dateAuditChange (date) {
@@ -285,13 +282,17 @@ export default {
       this.addrDistrictList = []
       this.queryParam.dealerCitySn = undefined
       this.queryParam.dealerCountySn = undefined
-      this.getArea('city', val)
+      if (val) {
+        this.getArea('city', val)
+      }
     },
     // 获取区县列表
     getAreaList (val) {
       this.addrDistrictList = []
       this.queryParam.dealerCountySn = undefined
-      this.getArea('district', val)
+      if (val) {
+        this.getArea('district', val)
+      }
     },
     //  省/市/区
     getArea (leve, sn) {
@@ -333,7 +334,7 @@ export default {
 <style lang="less">
   .financialCollectionList-wrap{
     .sTable{
-      margin-top: 20px;
+      margin-top: 10px;
     }
 	.active{
 		color: #ed1c24;

+ 2 - 2
src/views/financialManagement/inventoryReview/detail.vue

@@ -64,7 +64,7 @@
           <s-table
             class="sTable"
             ref="table"
-            size="default"
+            size="small"
             :rowKey="(record) => record.id"
             :columns="columns"
             :data="loadData"
@@ -140,7 +140,7 @@ export default {
   methods: {
     //  返回列表
     handleBack () {
-      this.$router.push({ path: '/financialManagement/inventoryReview/list' })
+      this.$router.push({ path: '/financialManagement/inventoryReview/list', query: { closeLastOldTab: true } })
     }
   }
 }

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

@@ -42,7 +42,7 @@
     <s-table
       class="sTable"
       ref="table"
-      size="default"
+      size="small"
       :rowKey="(record) => record.id"
       :columns="columns"
       :data="loadData"

+ 4 - 4
src/views/financialManagement/returnConfirmation/detailModal.vue

@@ -21,10 +21,10 @@
               <a-descriptions-item label="客户名称">{{ detailData&&detailData.buyerName || '--' }}</a-descriptions-item>
               <a-descriptions-item label="销退单号">{{ detailData&&detailData.salesReturnBillNo || '--' }}</a-descriptions-item>
               <a-descriptions-item label="创建时间">{{ detailData&&detailData.createDate || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="退货数量">{{ detailData&&detailData.totalQty || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="坏件数量">{{ detailData&&detailData.totalBadQty || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="返库数量">{{ detailData&&detailData.totalBackStockQty || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="退货金额">{{ detailData&&detailData.totalAmount || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="退货数量">{{ detailData&&(detailData.totalQty || detailData.totalQty==0) ? detailData.totalQty : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="坏件数量">{{ detailData&&(detailData.totalBadQty || detailData.totalBadQty==0) ? detailData.totalBadQty : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="返库数量">{{ detailData&&(detailData.totalBackStockQty || detailData.totalBackStockQty==0) ? detailData.totalBackStockQty : '--' }}</a-descriptions-item>
+              <a-descriptions-item label="退货金额">{{ detailData&&(detailData.totalAmount || detailData.totalAmount==0) ? detailData.totalAmount : '--' }}</a-descriptions-item>
             </a-descriptions>
           </a-collapse-panel>
         </a-collapse>

+ 7 - 6
src/views/financialManagement/returnConfirmation/list.vue

@@ -59,7 +59,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
@@ -106,7 +106,6 @@ export default {
         grabFlag: undefined,
         billStatus: undefined //  状态
       },
-      tableHeight: 0,
       disabled: false, //  查询、重置按钮是否可操作
       advanced: false,
       columns: [
@@ -125,9 +124,6 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
-        }
         return salesReturnFinancialList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
@@ -142,6 +138,11 @@ export default {
       itemSn: ''
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 375 : 320)
+    }
+  },
   methods: {
     //  创建时间  change
     dateChange (date) {
@@ -214,7 +215,7 @@ export default {
 <style lang="less">
   .returnConfirmationList-wrap{
     .sTable{
-      margin-top: 20px;
+      margin-top: 10px;
     }
 	.active{
 		color: #ed1c24;

+ 2 - 2
src/views/financialManagement/warehousingConfirmation/list.vue

@@ -38,7 +38,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :row-selection="rowSelection"
         :rowKey="(record) => record.stockPutSn"
         :columns="columns"
@@ -121,7 +121,7 @@ export default {
       loadData: parameter => {
         this.disabled = true
         if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
+          this.tableHeight = window.innerHeight - 370
         }
         return stockPutList(Object.assign(parameter, this.queryParam, { confirm: true })).then(res => {
           const data = res.data

+ 68 - 43
src/views/inventoryManagement/intelligentReplenishment/detailModal.vue

@@ -8,48 +8,52 @@
     v-model="isShow"
     @cancle="isShow=false"
     :width="800">
-    <div>
-      <a-alert type="info" showIcon style="margin-bottom:15px">
-        <div slot="message">此预测单的各项参数信息如下</div>
-      </a-alert>
-      <div class="module-cont" v-if="detailData">
-        <p class="title">产品范围</p>
-        <a-tag color="blue" style="margin-bottom: 10px;">{{ detailData.stockPredictRange==0?'自选产品':'全部产品' }}</a-tag>
-        <a-table
-          class="sTable"
-          ref="table"
-          size="small"
-          :rowKey="(record) => record.id"
-          :columns="columns"
-          :data-source="loadData"
-          :scroll="{ y: 400 }"
-          :pagination="false"
-          bordered>
-        </a-table>
+    <a-spin :spinning="spinning" tip="Loading...">
+      <div>
+        <a-alert type="info" showIcon style="margin-bottom:15px">
+          <div slot="message">此预测单的各项参数信息如下</div>
+        </a-alert>
+        <div class="module-cont" v-if="detailData">
+          <p class="title">产品范围</p>
+          <a-tag color="blue" style="margin-bottom: 10px;">{{ detailData&&detailData.stockPredictRange==0?'自选产品':'全部产品' }}</a-tag>
+          <a-table
+            class="sTable"
+            ref="table"
+            size="small"
+            :rowKey="(record) => record.id"
+            :columns="columns"
+            :data-source="loadData"
+            :loading="loading"
+            :scroll="{ y: 400 }"
+            :pagination="false"
+            bordered>
+          </a-table>
+        </div>
+        <div class="module-cont">
+          <p class="title">销售保障法</p>
+          <p class="explain">保障倍数:<span>{{ (detailData&&detailData.saleEnsureNum) || '--' }}</span></p>
+        </div>
+        <div class="module-cont">
+          <p class="title">趋势平均法</p>
+          <p class="explain">服务水平:<span>{{ (detailData&&detailData.trendServiceLevel) || '--' }}%(对应的安全系数为{{ (detailData&&detailData.trendSafetyFactor) || '--' }})</span></p>
+        </div>
+        <div class="spin-cont" v-if="detailData&&detailData.state=='RUN'">
+          按照以上参数设置,系统正在计算中,请耐心等待...
+          <a-spin style="margin-left: 15px;" />
+        </div>
+        <div class="btn-cont">
+          <a-button type="primary" v-if="detailData&&detailData.state=='FINISH'" id="intelligentReplenishmentDetail-save" @click="handleDownload" style="margin-right: 15px;">结果下载</a-button>
+          <a-button id="intelligentReplenishmentDetail-back" @click="isShow = false">关闭</a-button>
+        </div>
       </div>
-      <div class="module-cont">
-        <p class="title">销售保障法</p>
-        <p class="explain">保障倍数:<span>{{ (detailData&&detailData.saleEnsureNum) || '--' }}</span></p>
-      </div>
-      <div class="module-cont">
-        <p class="title">趋势平均法</p>
-        <p class="explain">服务水平:<span>{{ (detailData&&detailData.trendServiceLevel) || '--' }}%(对应的安全系数为{{ (detailData&&detailData.trendSafetyFactor) || '--' }})</span></p>
-      </div>
-      <div class="spin-cont" v-if="detailData&&detailData.state=='RUN'">
-        按照以上参数设置,系统正在计算中,请耐心等待...
-        <a-spin style="margin-left: 15px;" />
-      </div>
-      <div class="btn-cont">
-        <!-- <a-button type="primary" id="intelligentReplenishmentDetail-save" @click="handleDownload">结果下载</a-button> -->
-        <a-button id="intelligentReplenishmentDetail-back" @click="isShow = false">关闭</a-button>
-      </div>
-    </div>
+    </a-spin>
   </a-modal>
 </template>
 
 <script>
+import moment from 'moment'
 import { STable } from '@/components'
-import { predictDetail, predictRangeList } from '@/api/predict'
+import { predictDetail, predictRangeList, predictstockPredictExport } from '@/api/predict'
 export default {
   name: 'IntelligentReplenishmentDetailModal',
   components: { STable },
@@ -66,6 +70,7 @@ export default {
   data () {
     return {
       isShow: this.openModal, //  是否打开弹框
+      spinning: false,
       detailsData: null, //  详情数据
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
@@ -73,7 +78,8 @@ export default {
         { title: '类型名称', dataIndex: 'rangeDataName', align: 'center', customRender: function (text) { return text || '--' } }
       ],
       loadData: [],
-      detailData: null
+      detailData: null,
+      loading: false
     }
   },
   methods: {
@@ -92,7 +98,9 @@ export default {
     },
     // 获取产品范围
     getPredictRange () {
+      this.loading = true
       predictRangeList({ 'sn': this.detailData.stockPredictSn }).then(res => {
+        this.loading = false
         if (res.status == 200) {
           res.data.map((item, index) => {
             item.no = index + 1
@@ -105,12 +113,29 @@ export default {
     },
     //  结果下载
     handleDownload () {
-      const params = this.queryParam
-      this.downloadLoading = true
-      // stockExport(params).then(res => {
-      //   this.downloadLoading = false
-      //   this.download(res)
-      // })
+      const _this = this
+      const params = {
+        sn: (this.detailData && this.detailData.stockPredictSn) || undefined
+      }
+      _this.downloadLoading = true
+      _this.spinning = true
+      predictstockPredictExport(params).then(res => {
+        _this.downloadLoading = false
+        _this.spinning = false
+        if (res.type == 'application/json') {
+          var reader = new FileReader()
+          reader.addEventListener('loadend', function () {
+            const obj = JSON.parse(reader.result)
+            _this.$notification.error({
+              message: '提示',
+              description: obj.message
+            })
+          })
+          reader.readAsText(res)
+        } else {
+          this.download(res)
+        }
+      })
     },
     download (data) {
       if (!data) { return }

+ 8 - 5
src/views/inventoryManagement/intelligentReplenishment/edit.vue

@@ -114,7 +114,7 @@ export default {
   methods: {
     // 返回
     handleBack () {
-      this.$router.push({ path: `/inventoryManagement/intelligentReplenishment/list` })
+      this.$router.push({ path: `/inventoryManagement/intelligentReplenishment/list`, query: { closeLastOldTab: true } })
     },
     // 详情
     getDetail () {
@@ -144,6 +144,7 @@ export default {
       const _this = this
       if (this.current == 0) { //  产品设置
         const params = {
+          id: this.detailData.id,
           stockPredictSn: this.$route.params.sn,
           stockPredictRange: this.form.stockPredictRange
         }
@@ -152,11 +153,13 @@ export default {
         this.$refs.ruleForm.validate(valid => {
           if (valid) {
             const params = {
+              id: this.detailData.id,
               stockPredictSn: _this.$route.params.sn,
               saleEnsureNum: _this.form.saleEnsureNum,
               trendSn: _this.form.trendSn,
               trendServiceLevel: _this.form.serviceLevel,
-              trendSafetyFactor: _this.form.safetyFactor
+              trendSafetyFactor: _this.form.safetyFactor,
+              stockPredictRange: this.form.stockPredictRange
             }
             _this.handleRun(params)
           } else {
@@ -208,9 +211,9 @@ export default {
     getTrendSn () {
       predictTrendList({ defaultFlag: 1 }).then(res => {
         if (res.status == 200) {
-          this.form.trendSn = res.data[0].trendSn
-          this.form.serviceLevel = res.data[0].serviceLevel
-          this.form.safetyFactor = res.data[0].safetyFactor
+          this.form.trendSn = (res.data && res.data[0] && res.data[0].trendSn) ? res.data[0].trendSn : undefined
+          this.form.serviceLevel = (res.data && res.data[0] && res.data[0].serviceLevel) ? res.data[0].serviceLevel : undefined
+          this.form.safetyFactor = (res.data && res.data[0] && res.data[0].safetyFactor) ? res.data[0].safetyFactor : undefined
         } else {
           this.form.trendSn = ''
           this.form.serviceLevel = ''

+ 5 - 5
src/views/inventoryManagement/intelligentReplenishment/explainQspj.vue

@@ -73,7 +73,7 @@
         </div>
         <div class="item-main">
           <img src="@/assets/explain/pressed_gray.png" width="12" class="item-icon" />
-          <p class="item-txt">计算安全库存 = 71的开方 × 90%的服务水平对应的安全系数 × 45/30的开方 = 8.43 × 1.28 × 1.22 = 13.16 ≈ 13(四舍五入)</p>
+          <p class="item-txt">计算安全库存 = 73的开方 × 90%的服务水平对应的安全系数 × 45/30的开方 = 8.54 × 1.28 × 1.22 = 13.34 ≈ 13(四舍五入)</p>
         </div>
         <div class="item-table">
           <a-table :columns="columnsKc" :data-source="dataSourceKc" bordered :pagination="false"></a-table>
@@ -146,10 +146,10 @@ export default {
         { title: '求和', dataIndex: 'sum', align: 'center' }
       ],
       dataSourceKc: [
-        { title: '实际销量', january: 55, february: 53, march: 54, april: 56, may: 58, june: 57, july: 52, august: 52, september: 56, october: 52, november: 53, december: 59, sum: 657 },
-        { title: '实际销量', january: 54, february: 54, march: 54, april: 54, may: 54, june: 54, july: 54, august: 54, september: 54, october: 54, november: 54, december: 54, sum: 648 },
-        { title: '实际销量', january: 1, february: -1, march: 0, april: 2, may: 4, june: 3, july: -2, august: -2, september: 2, october: -2, november: -1, december: 5, sum: 9 },
-        { title: '实际销量', january: 1, february: 1, march: 0, april: 4, may: 14, june: 9, july: 4, august: 4, september: 4, october: 4, november: 1, december: 25, sum: 71 }
+        { title: '实际销量', january: 55, february: 53, march: 54, april: 56, may: 58, june: 57, july: 52, august: 52, september: 56, october: 52, november: 53, december: 59, sum: '--' },
+        { title: '实际销量', january: 54, february: 54, march: 54, april: 54, may: 54, june: 54, july: 54, august: 54, september: 54, october: 54, november: 54, december: 54, sum: '--' },
+        { title: '实际销量', january: 1, february: -1, march: 0, april: 2, may: 4, june: 3, july: -2, august: -2, september: 2, october: -2, november: -1, december: 5, sum: '--' },
+        { title: '实际销量', january: 1, february: 1, march: 0, april: 4, may: 16, june: 9, july: 4, august: 4, september: 4, october: 4, november: 1, december: 25, sum: 73 }
       ]
     }
   }

+ 1 - 1
src/views/inventoryManagement/intelligentReplenishment/explainXsbz.vue

@@ -43,7 +43,7 @@
         </div>
         <div class="item-main">
           <img src="@/assets/explain/pressed_gray.png" width="12" class="item-icon" />
-          <p class="item-txt">计算预计月销量 = MAX { 59,(53+59)/2,(57+52+52+56+52+53+59)/6,55 } =59</p>
+          <p class="item-txt">计算预计月销量 = MAX { 59,(53+59)/2,(52+52+56+52+53+59)/6,55 } =59</p>
         </div>
         <div class="item-main">
           <img src="@/assets/explain/pressed_gray.png" width="12" class="item-icon" />

+ 1 - 1
src/views/inventoryManagement/intelligentReplenishment/import.vue

@@ -90,7 +90,7 @@ export default {
   methods: {
     // 返回
     handleBack () {
-      this.$router.push({ path: `/inventoryManagement/intelligentReplenishment/list` })
+      this.$router.push({ path: `/inventoryManagement/intelligentReplenishment/list`, query: { closeLastOldTab: true } })
     },
     // 返回基础设置页
     handleBackSet () {

+ 22 - 12
src/views/inventoryManagement/intelligentReplenishment/list.vue

@@ -13,7 +13,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
@@ -46,11 +46,10 @@
             size="small"
             type="link"
             class="button-warning"
-            :loading="downloadLoading"
             v-if="record.state == 'FINISH' && $hasPermissions('B_intelligentReplenishment_down')"
             @click="handleDownload(record)"
             id="chainTransferInList-download-btn">结果下载</a-button>
-			<span v-if="!(record.state == 'WAIT' && $hasPermissions('B_intelligentReplenishment_edit'))&&!(record.state == 'WAIT' && $hasPermissions('B_intelligentReplenishment_del'))&&!(record.state != 'WAIT' && $hasPermissions('B_intelligentReplenishment_detail'))&&!(record.state == 'FINISH' && $hasPermissions('B_intelligentReplenishment_down'))">--</span>
+          <span v-if="!(record.state == 'WAIT' && $hasPermissions('B_intelligentReplenishment_edit'))&&!(record.state == 'WAIT' && $hasPermissions('B_intelligentReplenishment_del'))&&!(record.state != 'WAIT' && $hasPermissions('B_intelligentReplenishment_detail'))&&!(record.state == 'FINISH' && $hasPermissions('B_intelligentReplenishment_down'))">--</span>
         </template>
       </s-table>
     </a-spin>
@@ -63,7 +62,7 @@
 import moment from 'moment'
 import { STable, VSelect } from '@/components'
 import intelligentReplenishmentDetailModal from './detailModal.vue'
-import { predictList, predictSave, predictDel } from '@/api/predict'
+import { predictList, predictSave, predictDel, predictstockPredictExport } from '@/api/predict'
 export default {
   components: { STable, VSelect, intelligentReplenishmentDetailModal },
   data () {
@@ -87,7 +86,6 @@ export default {
         })
       },
       itemSn: '', //  当前sn
-      downloadLoading: false,
       openDetailModal: false
     }
   },
@@ -143,13 +141,25 @@ export default {
       this.$refs.table.refresh(true)
     },
     //  结果下载
-    handleDownload () {
-      const params = this.queryParam
-      this.downloadLoading = true
-      // stockExport(params).then(res => {
-      //   this.downloadLoading = false
-      //   this.download(res)
-      // })
+    handleDownload (row) {
+      const _this = this
+      _this.spinning = true
+      predictstockPredictExport({ sn: row.stockPredictSn }).then(res => {
+        _this.spinning = false
+        if (res.type == 'application/json') {
+          var reader = new FileReader()
+          reader.addEventListener('loadend', function () {
+            const obj = JSON.parse(reader.result)
+            _this.$notification.error({
+              message: '提示',
+              description: obj.message
+            })
+          })
+          reader.readAsText(res)
+        } else {
+          this.download(res)
+        }
+      })
     },
     download (data) {
       if (!data) { return }

+ 1 - 0
src/views/inventoryManagement/intelligentReplenishment/productRange.vue

@@ -22,6 +22,7 @@
         :columns="columns"
         :data="loadData"
         :showPagination="false"
+        :scroll="{ y: 400 }"
         bordered>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">

+ 1 - 1
src/views/inventoryManagement/intelligentReplenishment/set.vue

@@ -86,7 +86,7 @@ export default {
   methods: {
     // 返回
     handleBack () {
-      this.$router.push({ path: `/inventoryManagement/intelligentReplenishment/list` })
+      this.$router.push({ path: `/inventoryManagement/intelligentReplenishment/list`, query: { closeLastOldTab: true } })
     },
     // 下一步
     handlerNextStep () {

+ 1 - 1
src/views/inventoryManagement/inventoryChecking/checkingTipsModal.vue

@@ -16,7 +16,7 @@
     <s-table
       class="sTable"
       ref="table"
-      size="default"
+      size="small"
       :rowKey="(record) => record.id"
       :columns="columns"
       :data="loadData"

+ 2 - 2
src/views/inventoryManagement/inventoryChecking/detail.vue

@@ -54,7 +54,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="record => record.id"
         :columns="columns"
         :data="loadData"
@@ -132,7 +132,7 @@ export default {
     resetSearchForm () {},
     //  返回列表
     handleBack () {
-      this.$router.push({ path: '/inventoryManagement/inventoryChecking/list' })
+      this.$router.push({ path: '/inventoryManagement/inventoryChecking/list', query: { closeLastOldTab: true } })
     },
     //  导出
     handleExport () {

+ 2 - 2
src/views/inventoryManagement/inventoryChecking/financialAuditDetail.vue

@@ -54,7 +54,7 @@
           <s-table
             class="sTable"
             ref="table"
-            size="default"
+            size="small"
             :rowKey="(record) => record.id"
             :columns="columns"
             :data="loadData"
@@ -133,7 +133,7 @@
       resetSearchForm(){},
       //  返回列表
       handleBack(){
-        this.$router.push({ path: '/inventoryManagement/inventoryChecking/list'})
+        this.$router.push({ path: '/inventoryManagement/inventoryChecking/list', query: { closeLastOldTab: true }})
       },
     }
   }

+ 1 - 1
src/views/inventoryManagement/inventoryChecking/list.vue

@@ -35,7 +35,7 @@
     <s-table
       class="sTable"
       ref="table"
-      size="default"
+      size="small"
       :rowKey="(record) => record.id"
       :columns="columns"
       :data="loadData"

+ 2 - 2
src/views/inventoryManagement/inventoryChecking/makeInventory.vue

@@ -46,7 +46,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
@@ -131,7 +131,7 @@ export default {
   methods: {
     //  返回列表
     handleBack () {
-      this.$router.push({ path: '/inventoryManagement/inventoryChecking/list' })
+      this.$router.push({ path: '/inventoryManagement/inventoryChecking/list', query: { closeLastOldTab: true } })
     },
     //  导入
     handleImport () {},

+ 2 - 2
src/views/inventoryManagement/inventoryChecking/makeInventoryDetail.vue

@@ -52,7 +52,7 @@
           <s-table
             class="sTable"
             ref="table"
-            size="default"
+            size="small"
             :rowKey="(record) => record.id"
             :columns="columns"
             :data="loadData"
@@ -131,7 +131,7 @@
       resetSearchForm(){},
       //  返回列表
       handleBack(){
-        this.$router.push({ path: '/inventoryManagement/inventoryChecking/list'})
+        this.$router.push({ path: '/inventoryManagement/inventoryChecking/list', query: { closeLastOldTab: true }})
       },
     }
   }

+ 2 - 2
src/views/inventoryManagement/inventoryChecking/overall.vue

@@ -18,7 +18,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
@@ -87,7 +87,7 @@ export default {
     },
     //  返回
     handleBack () {
-      this.$router.push({ path: '/inventoryManagement/inventoryChecking/list' })
+      this.$router.push({ path: '/inventoryManagement/inventoryChecking/list', query: { closeLastOldTab: true } })
     },
     //
     onChange () {}

+ 3 - 3
src/views/inventoryManagement/inventoryChecking/selfDisk.vue

@@ -100,7 +100,7 @@
             <s-table
               class="sTable"
               ref="table"
-              size="default"
+              size="small"
               :rowKey="(record) => record.id"
               :columns="columns"
               :data="loadData"
@@ -133,7 +133,7 @@
             <s-table
               class="sTable"
               ref="table"
-              size="default"
+              size="small"
               :rowKey="(record) => record.id"
               :columns="chooseColumns"
               :data="chooseLoadData"
@@ -295,7 +295,7 @@ export default {
     },
     //  返回列表
     handleBack () {
-      this.$router.push({ path: '/inventoryManagement/inventoryChecking/list' })
+      this.$router.push({ path: '/inventoryManagement/inventoryChecking/list', query: { closeLastOldTab: true } })
     },
     filterOption (input, option) {
       	return (

+ 5 - 6
src/views/inventoryManagement/inventoryQuery/list.vue

@@ -85,7 +85,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
@@ -115,7 +115,7 @@
             class="button-warning"
             @click="goWarehouseDetail(record)"
             id="inventoryQueryList-warehouseDetail-btn">出入库明细</a-button>
-			<span v-if="!$hasPermissions('B_inventoryQuery_detail')&&!$hasPermissions('B_inventoryQuery_rkDetail')">--</span>
+          <span v-if="!$hasPermissions('B_inventoryQuery_detail')&&!$hasPermissions('B_inventoryQuery_rkDetail')">--</span>
         </template>
       </s-table>
     </a-spin>
@@ -137,7 +137,6 @@ export default {
     return {
       spinning: false,
       advanced: false, // 高级搜索 展开/关闭
-      tableHeight: 0,
       queryParam: { //  查询条件
         productCode: '', //  产品编码
         productName: '', //  产品名称
@@ -171,9 +170,6 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 370
-        }
         // 排序
         if (parameter.sortField == 'currentStockQty') {
           parameter.sortField = 'qty'
@@ -209,6 +205,9 @@ export default {
     }
   },
   computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 425 : 370)
+    },
     stockQty () { //  库存总数量 合计
       const currentStockQty = this.currentStock && this.currentStock.currentStockQty ? Number(this.currentStock.currentStockQty) : 0
       const freezeQty = this.currentStock && this.currentStock.freezeQty ? Number(this.currentStock.freezeQty) : 0

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

@@ -35,7 +35,7 @@
             </a-col>
             <a-col :md="6" :sm="24">
               <a-form-item label="仓库">
-                <a-select id="inventoryQueryWarehouseDetail-warehouseSn" placeholder="请选择仓库" v-model="queryParam.warehouseSn" >
+                <a-select id="inventoryQueryWarehouseDetail-warehouseSn" allowClear placeholder="请选择仓库" v-model="queryParam.warehouseSn" >
                   <a-select-option v-for="item in warehouseList" :key="item.warehouseSn" :value="item.warehouseSn">{{ item.name }}</a-select-option>
                 </a-select>
               </a-form-item>
@@ -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
@@ -113,7 +116,7 @@ export default {
         { title: '产品编码', dataIndex: 'productCode', width: 220, align: 'center', fixed: 'left', 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: 'stockBatchNo', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '批次号', dataIndex: 'stockBatchNo', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单据类型', dataIndex: 'bizTypeDictValue', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单据审核时间', dataIndex: 'auditTime', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单位名称', dataIndex: 'unitName', width: 200, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
@@ -178,7 +181,7 @@ export default {
     },
     //  返回列表
     handleBack () {
-      this.$router.push({ path: '/inventoryManagement/inventoryQuery/list' })
+      this.$router.push({ path: '/inventoryManagement/inventoryQuery/list', query: { closeLastOldTab: true } })
     },
     // 仓库下拉数据
     getWarehouseList (type) {

+ 5 - 6
src/views/inventoryManagement/inventoryWarning/list.vue

@@ -91,7 +91,7 @@
       <a-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :row-selection="$hasPermissions('B_inventoryWarning_refresh')?{ selectedRowKeys: selectedRowKeys, onChange: onChange, onSelect: onSelectChange, onSelectAll: onSelectAllChange }:null"
         :rowKey="(record) => record.id"
         :columns="columns"
@@ -179,7 +179,6 @@ export default {
     return {
       spinning: false,
       advanced: false, // 高级搜索 展开/关闭
-      tableHeight: 0,
       queryParam: { //  查询条件
         productCode: '',
         productName: '',
@@ -228,6 +227,9 @@ export default {
     }
   },
   computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 425 : 370)
+    },
     hasSelected () {
       return this.selectedRowKeys.length > 0
     }
@@ -246,14 +248,12 @@ export default {
     },
     //  列表数据
     pageInit (pageNo) {
-      if (this.tableHeight == 0) {
-        this.tableHeight = window.innerHeight - 380
-      }
       this.disabled = true
       this.pageNo = pageNo || this.pageNo
       const params = Object.assign({ pageNo: this.pageNo, pageSize: this.pageSize }, this.queryParam)
       this.tableLoading = true
       stockWarnList(params).then(res => {
+        this.tableLoading = false
         if (res.status == 200) {
           const data = res.data
           this.paginationProps.total = Number(res.data.count) || 0
@@ -263,7 +263,6 @@ export default {
             data.list[i].no = no + i + 1
           }
           this.loadData = data.list
-          this.tableLoading = false
           this.disabled = false
         } else {
           this.paginationProps.total = 0

+ 8 - 2
src/views/power/OperateJournal/OperateJournal.vue

@@ -31,10 +31,11 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         rowKey="id"
         :columns="columns"
         :data="loadData"
+        :scroll="{ y: tableHeight }"
         bordered>
         <span slot="actDesc" slot-scope="text, record">{{ record.actDate }}-{{ record.actDesc }}</span>
         <span slot="actorName" slot-scope="text, record">{{ record.actorName }}-{{ record.actorPhone }}</span>
@@ -91,6 +92,11 @@ export default {
       }
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - 340
+    }
+  },
   methods: {
     //  时间  change
     dateChange (date) {
@@ -112,7 +118,7 @@ export default {
 <style lang="less">
   .operateJournal{
     .sTable{
-      margin-top: 10px;
+      margin-top: 0;
     }
   }
 </style>

+ 1 - 1
src/views/power/dataDictionary/dataDictionary.vue

@@ -75,7 +75,7 @@
           </div> -->
           <s-table
             ref="table"
-            size="default"
+            size="small"
             rowKey="id"
             :columns="columns"
             :data="loadData"

+ 1 - 1
src/views/power/job/jobs.vue

@@ -23,7 +23,7 @@
 
     <s-table
       ref="table"
-      size="default"
+      size="small"
       :rowKey="(record) => record.id"
       :columns="columns"
       :data="loadData"

+ 1 - 1
src/views/power/role/roleList.vue

@@ -32,7 +32,7 @@
       </div>
       <s-table
         ref="table"
-        size="default"
+        size="small"
         rowKey="id"
         :columns="columns"
         :data="loadData"

+ 1 - 1
src/views/power/user/userList.vue

@@ -32,7 +32,7 @@
       </div>
       <s-table
         ref="table"
-        size="default"
+        size="small"
         rowKey="id"
         :columns="columns"
         :data="loadData"

+ 10 - 8
src/views/productManagement/priceChangeRecord/list.vue

@@ -70,14 +70,14 @@
         </a-form>
       </div>
       <!-- 总计 -->
-      <a-alert type="info" showIcon style="margin-bottom:15px">
+      <!-- <a-alert type="info" showIcon style="margin-bottom:15px">
         <div slot="message">合计:<strong>{{ total }}</strong>条</div>
-      </a-alert>
+      </a-alert> -->
       <!-- 列表 -->
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
@@ -132,7 +132,6 @@ export default {
     return {
       spinning: false,
       advanced: false, // 高级搜索 展开/关闭
-      tableHeight: 0,
       queryParam: { //  查询条件
         beginDate: getDate.getThreeMonthDays().starttime,
         endDate: getDate.getCurrMonthDays().endtime,
@@ -154,7 +153,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', width: 220, align: 'center' },
+        { title: '产品编码', dataIndex: 'productEntity.code', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '品牌', dataIndex: 'productEntity.productBrandName', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '产品分类', scopedSlots: { customRender: 'productType' }, width: 200, align: 'center' },
         { title: '单位', dataIndex: 'productEntity.unit', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
@@ -213,9 +212,6 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 430
-        }
         return productPriceChangeList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
@@ -232,6 +228,11 @@ export default {
       productTypeList: [] //  分类下拉数据
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 425 : 370)
+    }
+  },
   methods: {
     //  创建时间  change
     dateChange (date) {
@@ -249,6 +250,7 @@ export default {
       this.queryParam.productTypeSn1 = ''
       this.queryParam.productTypeSn2 = ''
       this.queryParam.productTypeSn3 = ''
+      this.productType = []
       this.$refs.table.refresh(true)
     },
     // 审核

+ 8 - 7
src/views/productManagement/productBrand/detailModal.vue

@@ -8,16 +8,17 @@
     v-model="isShow"
     @cancle="isShow=false"
     :width="960">
-    <div v-if="detailsData">
-      <a-descriptions bordered size="default" :column="1">
-        <a-descriptions-item label="品牌名称:">{{ detailsData.brandName || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="品牌分类:">{{ detailsData.brandTypeDictValue || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="排序字母:">{{ detailsData.sortChar || '--' }}</a-descriptions-item>
+    <div>
+      <a-descriptions bordered size="small" :column="1">
+        <a-descriptions-item label="品牌名称:">{{ detailsData&&detailsData.brandName || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="品牌分类:">{{ detailsData&&detailsData.brandTypeDictValue || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="排序字母:">{{ detailsData&&detailsData.sortChar || '--' }}</a-descriptions-item>
         <a-descriptions-item label="品牌图片:">
-          <img :src="detailsData.imageUrl" title="点击查看大图" class="productPic" @click="getPreview(detailsData.imageUrl)" />
+          <img v-if="detailsData&&detailsData.imageUrl" :src="detailsData.imageUrl" title="点击查看大图" class="productPic" @click="getPreview(detailsData.imageUrl)" />
+          <span v-else>--</span>
         </a-descriptions-item>
         <a-descriptions-item label="品牌介绍:">
-          <div v-if="detailsData.brandIntroduce" v-html="detailsData.brandIntroduce"></div>
+          <div v-if="detailsData&&detailsData.brandIntroduce" v-html="detailsData.brandIntroduce"></div>
           <span v-else>--</span>
         </a-descriptions-item>
       </a-descriptions>

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

@@ -37,7 +37,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
@@ -113,7 +113,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: 'imageUrl' }, width: 140, align: 'center' },
         { title: '品牌名称', dataIndex: 'brandName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '品牌分类', dataIndex: 'brandTypeDictValue', align: 'center', customRender: function (text) { return text || '--' } },

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

@@ -9,7 +9,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
@@ -68,7 +68,7 @@ export default {
       },
       columns: [
         { title: '分类名称', dataIndex: 'productTypeName', align: 'left' },
-        { title: '创建时间', dataIndex: 'createDate', width: 320, align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: 320, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 300, align: 'center' }
       ],
       // 加载数据方法 必须为 Promise 对象

+ 21 - 17
src/views/productManagement/productInfo/detailModal.vue

@@ -9,16 +9,20 @@
     @cancle="isShow=false"
     :width="800">
     <!-- 产品详情 -->
-    <div v-if="detailsData">
+    <div>
       <a-descriptions bordered size="small" :column="2">
-        <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.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.productBrandName || '--' }}</a-descriptions-item>
         <a-descriptions-item label="产品分类:">{{ productTypeName || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="其他编码:">{{ detailsData.otherCode || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="包装数:">{{ detailsData.packQty || '--' }}{{ detailsData.unit || '--' }}/{{ detailsData.packQtyUnit || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="箭冠产品:">{{ detailsData.arrowFalgDictValue || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="其他编码:">{{ detailsData&&detailsData.otherCode || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="包装数:">
+          {{ detailsData&&detailsData.packQty || '--' }}
+          {{ detailsData&&detailsData.unit || '--' }}/
+          {{ detailsData&&detailsData.packQtyUnit || '--' }}
+        </a-descriptions-item>
+        <a-descriptions-item label="箭冠产品:">{{ detailsData&&detailsData.arrowFalgDictValue || '--' }}</a-descriptions-item>
         <a-descriptions-item label="产品图片:" :span="2">
           <div style="display: flex;">
             <p class="pic-box" v-for="(item,index) in fileList" :key="index">
@@ -27,17 +31,17 @@
           </div>
           <span v-if="fileList.length == 0">--</span>
         </a-descriptions-item>
-        <a-descriptions-item label="单位:">{{ detailsData.unit || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="产品尺寸:">{{ detailsData.size || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="产品内盒尺寸:">{{ detailsData.boxSize || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="产品重量:">{{ detailsData.weight || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="颜色:" span="2">{{ detailsData.color || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="单位:">{{ detailsData&&detailsData.unit || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="产品尺寸:">{{ detailsData&&detailsData.size || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="产品内盒尺寸:">{{ detailsData&&detailsData.boxSize || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="产品重量:">{{ detailsData&&detailsData.weight || '--' }}</a-descriptions-item>
+        <a-descriptions-item label="颜色:" span="2">{{ detailsData&&detailsData.color || '--' }}</a-descriptions-item>
         <a-descriptions-item label="产品说明:" span="2">
-          <div v-html="detailsData.description" v-if="detailsData.description" style="overflow-y: scroll;height: 300px;"></div>
+          <div v-html="detailsData.description" v-if="detailsData&&detailsData.description" style="overflow-y: scroll;height: 300px;"></div>
           <div v-else>--</div>
         </a-descriptions-item>
         <a-descriptions-item label="其他说明:" span="2">
-          <div v-html="detailsData.otherDesc" v-if="detailsData.otherDesc"></div>
+          <div v-html="detailsData.otherDesc" v-if="detailsData&&detailsData.otherDesc"></div>
           <div v-else>--</div>
         </a-descriptions-item>
       </a-descriptions>
@@ -65,8 +69,8 @@ export default {
   },
   computed: {
     productTypeName () {
-      const productTypeName2 = this.detailsData.productTypeName2 ? this.detailsData.productTypeName2 : ''
-      const productTypeName3 = this.detailsData.productTypeName3 ? ' > ' + this.detailsData.productTypeName3 : ''
+      const productTypeName2 = this.detailsData && this.detailsData.productTypeName2 ? this.detailsData.productTypeName2 : ''
+      const productTypeName3 = this.detailsData && this.detailsData.productTypeName3 ? ' > ' + this.detailsData.productTypeName3 : ''
       return productTypeName2 + productTypeName3
     }
   },

+ 28 - 4
src/views/productManagement/productInfo/edit.vue

@@ -215,7 +215,7 @@
 import { VSelect, Upload } from '@/components'
 import Editor from '@/components/WEeditor'
 import { productSave, productSnDetail } from '@/api/product'
-import { productTypeQuery } from '@/api/productType'
+import { productTypeQueryAll } from '@/api/productType'
 import { productBrandQuery } from '@/api/productBrand'
 export default {
   components: { VSelect, Upload, Editor },
@@ -344,7 +344,7 @@ export default {
     },
     // 返回
     handleBack () {
-      this.$router.push({ path: '/productManagement/productInfo/list' })
+      this.$router.push({ path: '/productManagement/productInfo/list', query: { closeLastOldTab: true } })
     },
     // 产品图片上传
     changeImage (file) {
@@ -376,14 +376,38 @@ export default {
     },
     //  产品分类  列表
     getProductType () {
-      productTypeQuery({}).then(res => {
+      productTypeQueryAll({}).then(res => {
         if (res.status == 200) {
-          this.productTypeList = res.data
+          if (res.data && res.data.length > 0) {
+            //  递归处理disabled禁用
+            this.recursionFun(res.data, false)
+            this.productTypeList = res.data
+          } else {
+            this.productTypeList = []
+          }
         } else {
           this.productTypeList = []
         }
       })
     },
+    //  递归函数
+    recursionFun (data, state) {
+      if (data) {
+        data.map((item, index) => {
+          // enabledFlag为0表示禁用,父级禁用则子级也为禁用
+          if ((item.enabledFlag && item.enabledFlag == 0) || state) {
+            item.disabled = true
+          } else {
+            item.disabled = false
+          }
+          if (item.children && item.children.length == 0) {
+            delete item.children
+          } else {
+            this.recursionFun(item.children, item.disabled)
+          }
+        })
+      }
+    },
     filterOption (input, option) {
       return (
         option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0

+ 7 - 12
src/views/productManagement/productInfo/list.vue

@@ -109,7 +109,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :row-selection=" showSelect ?{ selectedRowKeys: selectedRowKeys, onChange: onChange, onSelect: onSelectChange, onSelectAll: onSelectAllChange }:null"
         :rowKey="(record) => record.id"
         :columns="columns"
@@ -134,10 +134,6 @@
           <span v-if="record.productTypeName2 || record.productTypeName3">{{ record.productTypeName2 }} {{ record.productTypeName3 ? '>' : '' }} {{ record.productTypeName3 }}</span>
           <span v-else>--</span>
         </template>
-        <!-- 定价状态 -->
-        <template slot="pricingState" slot-scope="text, record">
-          <a-badge :color="record.pricingState=='WAIT_PRICING'?'gold':record.pricingState=='WAIT_PRICING_AUDIT'?'volcano':'#87d068'" :text="record.pricingStateDictValue" />
-        </template>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
           <a-button
@@ -199,7 +195,7 @@ import { STable, VSelect } from '@/components'
 import productInfoDetailModal from './detailModal.vue'
 import productInfoOfflineModal from './offlineModal.vue'
 import { productBrandQuery } from '@/api/productBrand'
-import { productTypeQuery } from '@/api/productType'
+import { productTypeQueryAll } from '@/api/productType'
 import { productList, productAudit, productBatchAudit, productDel, productOnline, productBatchOnline, productExport } from '@/api/product'
 export default {
   components: { STable, VSelect, productInfoDetailModal, productInfoOfflineModal },
@@ -207,7 +203,6 @@ export default {
     return {
       spinning: false,
       advanced: false, // 高级搜索 展开/关闭
-      tableHeight: 0,
       queryParam: { //  查询条件
         name: '', //  产品名称
         queryWord: '', // 产品编码/原厂编码
@@ -232,7 +227,7 @@ export default {
         { slots: { title: 'arrowFalgTitle' }, scopedSlots: { customRender: 'arrowFalg' }, width: 100, align: 'center' },
         { title: '最近修改时间', dataIndex: 'updateDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '产品状态', dataIndex: 'stateDictValue', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '定价状态', scopedSlots: { customRender: 'pricingState' }, width: 140, align: 'center' },
+        { title: '定价状态', dataIndex: 'pricingStateDictValue', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 250, align: 'center', fixed: 'right' }
       ],
       selectedRowKeys: [], // Check here to configure the default column
@@ -243,9 +238,6 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
-        }
         return productList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
@@ -265,6 +257,9 @@ export default {
     }
   },
   computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 425 : 370)
+    },
     hasSelected () {
       return this.selectedRowKeys.length > 0
     },
@@ -572,7 +567,7 @@ export default {
     },
     //  产品分类  列表
     getProductType () {
-      productTypeQuery({}).then(res => {
+      productTypeQueryAll({}).then(res => {
         if (res.status == 200) {
           this.productTypeList = res.data
         } else {

+ 3 - 3
src/views/productManagement/productLaunchAudit/list.vue

@@ -43,7 +43,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :row-selection="rowSelection"
         :rowKey="(record) => record.productSn"
         :columns="columns"
@@ -88,7 +88,7 @@ export default {
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
         { title: '产品名称', dataIndex: 'name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '产品编码', dataIndex: 'code', width: 220, align: 'center' },
+        { title: '产品编码', dataIndex: 'code', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '产品分类', scopedSlots: { customRender: 'productType' }, width: 200, align: 'center' },
         { title: '提交时间', dataIndex: 'onlineSubmitTime', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '提交人', dataIndex: 'onlineSubmitPerson', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
@@ -103,7 +103,7 @@ export default {
       loadData: parameter => {
         this.disabled = true
         if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
+          this.tableHeight = window.innerHeight - 370
         }
         return productOnlineList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data

+ 12 - 11
src/views/productManagement/productLevel/list.vue

@@ -61,19 +61,19 @@
       </a-form>
     </div>
     <!-- 操作按钮 -->
-    <div class="table-operator">
-      <!-- <a-button style="margin: 0 0 18px 0" id="productLevelList-import" type="primary" @click="handleImport">导入</a-button> -->
-      <!-- <a-button style="margin: 0 0 18px 8px" id="productLevelList-export" type="danger" @click="handleExport" :loading="exportLoading">导出</a-button> -->
-    </div>
+    <!-- <div class="table-operator">
+      <a-button style="margin: 0 0 18px 0" id="productLevelList-import" type="primary" @click="handleImport">导入</a-button>
+      <a-button style="margin: 0 0 18px 8px" id="productLevelList-export" type="danger" @click="handleExport" :loading="exportLoading">导出</a-button>
+    </div> -->
     <!-- 列表 -->
     <s-table
       class="sTable"
       ref="table"
-      size="default"
+      size="small"
       :rowKey="(record) => record.id"
       :columns="columns"
       :data="loadData"
-      :scroll="{ x: 1590 }"
+      :scroll="{ x: 1590, y: tableHeight }"
       bordered>
       <!-- 产品分类 -->
       <template slot="productType" slot-scope="text, record">
@@ -109,7 +109,6 @@ export default {
   data () {
     return {
       advanced: false, // 高级搜索 展开/关闭
-      tableHeight: 0,
       queryParam: { //  查询条件
         name: '', //  产品名称
         queryWord: '', // 产品编码/原厂编码
@@ -125,7 +124,7 @@ export default {
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
         { title: '产品名称', dataIndex: 'name', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
-        { title: '产品编码', dataIndex: 'code', width: 220, align: 'center' },
+        { title: '产品编码', dataIndex: 'code', width: 220, align: 'center', 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 || '--' } },
         { title: '产品分类', scopedSlots: { customRender: 'productType' }, width: 200, align: 'center' },
@@ -137,9 +136,6 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
-        }
         return productLevelList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
@@ -161,6 +157,11 @@ export default {
       nowData: null
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 380 : 320)
+    }
+  },
   methods: {
     //  重置
     resetSearchForm () {

+ 5 - 6
src/views/productManagement/productOfflineAudit/list.vue

@@ -88,7 +88,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :row-selection="rowSelection"
         :rowKey="(record) => record.productSn"
         :columns="columns"
@@ -138,11 +138,10 @@ export default {
         state: undefined //  状态
       },
       productType: [],
-      tableHeight: 0,
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
         { title: '产品名称', dataIndex: 'name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '产品编码', dataIndex: 'code', width: 220, align: 'center' },
+        { title: '产品编码', dataIndex: 'code', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '产品分类', scopedSlots: { customRender: 'productType' }, width: 200, align: 'center' },
         { title: '提交时间', dataIndex: 'offlineSubmitTime', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '提交人', dataIndex: 'offlineSubmitPerson', width: 140, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
@@ -159,9 +158,6 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
-        }
         return productOfflineList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
           this.disabled = false
@@ -173,6 +169,9 @@ export default {
     }
   },
   computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 425 : 370)
+    },
     hasSelected () {
       return this.selectedRowKeys.length > 0
     },

+ 23 - 13
src/views/productManagement/productPricing/auditModal.vue

@@ -10,35 +10,45 @@
     :width="800">
     <a-spin :spinning="spinning" tip="Loading...">
       <!-- 定价审核 -->
-      <div v-if="detailsData">
+      <div>
         <a-descriptions bordered :column="1">
           <a-descriptions-item label="成本价">
             <div v-if="detailsData && detailsData.supplierProductList" style="margin-top: 8px;">
-              <p v-for="(item, index) in detailsData.supplierProductList" :key="index" style="margin: 0;">{{ ((item.cost || item.cost==0) ? item.cost.toFixed(2) : '--') + ' 元 -- ' + item.supplierName + ';' }}</p>
+              <p v-for="(item, index) in detailsData.supplierProductList" :key="index" style="margin: 0;">{{ ((item.cost || item.cost==0) ? item.cost.toFixed(2) : '--') + ' 元 -- ' + (item.supplierName||'') + ';' }}</p>
             </div>
             <span v-else>--</span>
           </a-descriptions-item>
           <a-descriptions-item label="省级价">
-            {{ detailsData.afterProvincePrice }}
-            <span v-if="detailsData.afterProvincePrice != detailsData.beforeProvincePrice">(原{{ detailsData.beforeProvincePrice }})</span>
+            {{ detailsData && (detailsData.afterProvincePrice || detailsData.afterProvincePrice==0) ? detailsData.afterProvincePrice : '--' }}
+            <span v-if="detailsData && (detailsData.afterProvincePrice != detailsData.beforeProvincePrice)">
+              (原{{ (detailsData.beforeProvincePrice || detailsData.beforeProvincePrice==0) ? detailsData.beforeProvincePrice : '--' }})
+            </span>
           </a-descriptions-item>
           <a-descriptions-item label="市级价">
-            {{ detailsData.afterCityPrice }}
-            <span v-if="detailsData.afterCityPrice != detailsData.beforeCityPrice">(原{{ detailsData.beforeCityPrice }})</span>
+            {{ detailsData && (detailsData.afterCityPrice || detailsData.afterCityPrice==0) ? detailsData.afterCityPrice : '--' }}
+            <span v-if="detailsData && (detailsData.afterCityPrice != detailsData.beforeCityPrice)">
+              (原{{ (detailsData.beforeCityPrice || detailsData.beforeCityPrice==0) ? detailsData.beforeCityPrice : '--' }})
+            </span>
           </a-descriptions-item>
           <a-descriptions-item label="特约价">
-            {{ detailsData.afterSpecialPrice }}
-            <span v-if="detailsData.afterSpecialPrice != detailsData.beforeSpecialPrice">(原{{ detailsData.beforeSpecialPrice }})</span>
+            {{ detailsData && (detailsData.afterSpecialPrice || detailsData.afterSpecialPrice==0) ? detailsData.afterSpecialPrice : '--' }}
+            <span v-if="detailsData && (detailsData.afterSpecialPrice != detailsData.beforeSpecialPrice)">
+              (原{{ (detailsData.beforeSpecialPrice || detailsData.beforeSpecialPrice==0) ? detailsData.beforeSpecialPrice : '--' }})
+            </span>
           </a-descriptions-item>
           <a-descriptions-item label="终端价">
-            {{ detailsData.afterTerminalPrice }}
-            <span v-if="detailsData.afterTerminalPrice != detailsData.beforeTerminalPrice">(原{{ detailsData.beforeTerminalPrice }})</span>
+            {{ detailsData && (detailsData.afterTerminalPrice || detailsData.afterTerminalPrice==0) ? detailsData.afterTerminalPrice : '--' }}
+            <span v-if="detailsData && (detailsData.afterTerminalPrice != detailsData.beforeTerminalPrice)">
+              (原{{ (detailsData.beforeTerminalPrice || detailsData.beforeTerminalPrice==0) ? detailsData.beforeTerminalPrice : '--' }})
+            </span>
           </a-descriptions-item>
           <a-descriptions-item label="车主价">
-            {{ detailsData.afterCarOwnersPrice }}
-            <span v-if="detailsData.afterCarOwnersPrice != detailsData.beforeCarOwnersPrice">(原{{ detailsData.beforeCarOwnersPrice }})</span>
+            {{ detailsData && (detailsData.afterCarOwnersPrice || detailsData.afterCarOwnersPrice==0) ? detailsData.afterCarOwnersPrice : '--' }}
+            <span v-if="detailsData && (detailsData.afterCarOwnersPrice != detailsData.beforeCarOwnersPrice)">
+              (原{{ (detailsData.beforeCarOwnersPrice || detailsData.beforeCarOwnersPrice==0) ? detailsData.beforeCarOwnersPrice : '--' }})
+            </span>
           </a-descriptions-item>
-          <a-descriptions-item label="变更原因">{{ detailsData.changeReason }}</a-descriptions-item>
+          <a-descriptions-item label="变更原因">{{ detailsData && detailsData.changeReason || '--' }}</a-descriptions-item>
         </a-descriptions>
         <div class="btn-cont">
           <a-button type="primary" id="productPricingAudit-save" @click="handleAudit">审核通过</a-button>

+ 1 - 1
src/views/productManagement/productPricing/editModal.vue

@@ -21,7 +21,7 @@
         >
           <a-form-model-item label="成本价">
             <div v-if="detailData && detailData.supplierProductList" style="margin-top: 8px;">
-              <p v-for="(item, index) in detailData.supplierProductList" :key="index" style="margin: 0;line-height: 1.5em;">{{ ((item.cost || item.cost==0) ? item.cost.toFixed(2) : '--') + ' 元 -- ' + item.supplierName + ';' }}</p>
+              <p v-for="(item, index) in detailData.supplierProductList" :key="index" style="margin: 0;line-height: 1.5em;">{{ ((item.cost || item.cost==0) ? item.cost.toFixed(2) : '--') + ' 元 -- ' + (item.supplierName||'') + ';' }}</p>
             </div>
             <span v-else>--</span>
           </a-form-model-item>

+ 18 - 15
src/views/productManagement/productPricing/list.vue

@@ -61,14 +61,14 @@
       </a-form>
     </div>
     <!-- 总计 -->
-    <a-alert type="info" showIcon style="margin-bottom:15px">
+    <!-- <a-alert type="info" showIcon style="margin-bottom:15px">
       <div slot="message">合计:<strong>{{ total }}</strong>条</div>
-    </a-alert>
+    </a-alert> -->
     <!-- 列表 -->
     <s-table
       class="sTable"
       ref="table"
-      size="default"
+      size="small"
       :rowKey="(record) => record.id"
       :columns="columns"
       :data="loadData"
@@ -79,16 +79,12 @@
         <span v-if="record.productTypeName2 || record.productTypeName3">{{ record.productTypeName2 }} {{ record.productTypeName3 ? '>' : '' }} {{ record.productTypeName3 }}</span>
         <span v-else>--</span>
       </template>
-      <!-- 定价状态 -->
-      <template slot="pricingState" slot-scope="text, record">
-        <a-badge :color="record.pricingState=='WAIT_PRICING'?'gold':record.pricingState=='WAIT_PRICING_AUDIT'?'volcano':'#87d068'" :text="record.pricingStateDictValue" />
-      </template>
       <!-- 成本价 -->
       <template slot="sterminaldsdPrice" slot-scope="text, record">
         <div v-if="record.supplierProductList">
           <p v-for="(item, index) in record.supplierProductList" :key="index" style="margin: 0;">
             <span>{{ (item.cost || item.cost==0) ? item.cost.toFixed(2):'--' }}</span>元 -
-            <span>{{ item.supplierName }}</span>;
+            <span>{{ (item.supplierName||'') }}</span>;
           </p>
         </div>
         <span v-else>--</span>
@@ -102,7 +98,13 @@
           class="button-warning"
           @click="handleAudit(record)"
           id="productPricingList-audit-btn">审核</a-button>
-        <a-button size="small" type="link" v-if="$hasPermissions('B_productPricing_edit')" class="button-info" @click="handleEdit(record)" id="productPricingList-edit-btn">编辑</a-button>
+        <a-button
+          size="small"
+          type="link"
+          v-if="$hasPermissions('B_productPricing_edit')"
+          class="button-info"
+          @click="handleEdit(record)"
+          id="productPricingList-edit-btn">编辑</a-button>
         <span v-if="!(record.pricingState=='WAIT_PRICING_AUDIT' && $hasPermissions('B_productPricing_audit')) && !$hasPermissions('B_productPricing_edit')">--</span>
       </template>
     </s-table>
@@ -125,7 +127,6 @@ export default {
   data () {
     return {
       advanced: false, // 高级搜索 展开/关闭
-      tableHeight: 0,
       queryParam: { //  查询条件
         name: '', //  产品名称
         queryWord: '', // 产品编码/原厂编码
@@ -141,12 +142,12 @@ export default {
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
         { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '产品名称', dataIndex: 'name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '产品编码', dataIndex: 'code', width: 220, align: 'center' },
+        { title: '产品编码', dataIndex: 'code', width: 220, align: 'center', 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 || '--' } },
         { title: '产品分类', scopedSlots: { customRender: 'productType' }, width: 200, align: 'center' },
         { title: '产品状态', dataIndex: 'stateDictValue', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '定价状态', scopedSlots: { customRender: 'pricingState' }, width: 140, align: 'center' },
+        { title: '定价状态', dataIndex: 'pricingStateDictValue', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '成本价', scopedSlots: { customRender: 'sterminaldsdPrice' }, width: 200, align: 'center' },
         { title: '省级价', dataIndex: 'provincePrice', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '市级价', dataIndex: 'cityPrice', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
@@ -158,9 +159,6 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
-        }
         return productPricingList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
@@ -180,6 +178,11 @@ export default {
       productTypeList: [] //  分类下拉数据
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 375 : 320)
+    }
+  },
   methods: {
     //  重置
     resetSearchForm () {

+ 7 - 6
src/views/productManagement/productUniversal/list.vue

@@ -51,11 +51,11 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
-        :scroll="{ x: 1580 }"
+        :scroll="{ x: 1580, y: tableHeight }"
         bordered>
         <!-- 产品分类 -->
         <template slot="productType" slot-scope="text, record">
@@ -98,7 +98,6 @@ export default {
     return {
       spinning: false,
       advanced: false, // 高级搜索 展开/关闭
-      tableHeight: 0,
       queryParam: { //  查询条件
         productCode: '',
         productName: '',
@@ -123,9 +122,6 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
-        }
         return productUniversalCodeList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
@@ -140,6 +136,11 @@ export default {
       itemId: '' //  当前id
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 425 : 370)
+    }
+  },
   methods: {
     //  重置
     resetSearchForm () {

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

@@ -66,7 +66,7 @@
     <s-table
       class="sTable"
       ref="table"
-      size="default"
+      size="small"
       :rowKey="(record) => record.id"
       :columns="columns"
       :data="loadData"

+ 1 - 1
src/views/promotionRulesManagement/orderStatistics/detailModal.vue

@@ -56,7 +56,7 @@ export default {
       // 表头
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '产品编码', dataIndex: 'productEntity.code', width: 220, align: 'center' },
+        { title: '产品编码', dataIndex: 'productEntity.code', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '产品名称', dataIndex: 'productEntity.name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '原价', dataIndex: 'origPrice', width: 100, 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 : '--') } },

+ 13 - 12
src/views/promotionRulesManagement/orderStatistics/list.vue

@@ -54,19 +54,19 @@
     <!-- alert -->
     <a-alert type="info" showIcon style="margin-bottom:15px">
       <div slot="message">
-        促销品原价总额:<strong>{{ productTotal ? ((productTotal.totalOrigAmount || productTotal.totalOrigAmount==0) ? productTotal.totalOrigAmount : '--') : '--' }}</strong>,
-        促销品促销价总额:<strong>{{ productTotal ? ((productTotal.totalAmount || productTotal.totalAmount==0) ? productTotal.totalAmount : '--') : '--' }}</strong>,
-        节省总额:<strong>{{ productTotal ? ((productTotal.totalEconomizeAmount || productTotal.totalEconomizeAmount==0) ? productTotal.totalEconomizeAmount : '--') : '--' }}</strong>,
-        总单数:<strong>{{ productTotal ? ((productTotal.totalRecord || productTotal.totalRecord==0) ? productTotal.totalRecord : '--') : '--' }}</strong>,
-        总款数:<strong>{{ productTotal ? ((productTotal.totalCategory || productTotal.totalCategory==0) ? productTotal.totalCategory : '--') : '--' }}</strong>,
-        总数量:<strong>{{ productTotal ? ((productTotal.totalQty || productTotal.totalQty==0) ? productTotal.totalQty : '--') : '--' }}</strong>
+        促销品原价总额:<strong>{{ productTotal && (productTotal.totalOrigAmount || productTotal.totalOrigAmount==0) ? productTotal.totalOrigAmount : '--' }}</strong>,
+        促销品促销价总额:<strong>{{ productTotal && (productTotal.totalAmount || productTotal.totalAmount==0) ? productTotal.totalAmount : '--' }}</strong>,
+        节省总额:<strong>{{ productTotal && (productTotal.totalEconomizeAmount || productTotal.totalEconomizeAmount==0) ? productTotal.totalEconomizeAmount : '--' }}</strong>,
+        总单数:<strong>{{ productTotal && (productTotal.totalRecord || productTotal.totalRecord==0) ? productTotal.totalRecord : '--' }}</strong>,
+        总款数:<strong>{{ productTotal && (productTotal.totalCategory || productTotal.totalCategory==0) ? productTotal.totalCategory : '--' }}</strong>,
+        总数量:<strong>{{ productTotal && (productTotal.totalQty || productTotal.totalQty==0) ? productTotal.totalQty : '--' }}</strong>
       </div>
     </a-alert>
     <!-- 列表 -->
     <s-table
       class="sTable"
       ref="table"
-      size="default"
+      size="small"
       :rowKey="(record) => record.id"
       :columns="columns"
       :data="loadData"
@@ -104,7 +104,6 @@ export default {
     return {
       advanced: false, // 高级搜索 展开/关闭
       disabled: false, //  查询、重置按钮是否可操作
-      tableHeight: 0,
       // 查询参数
       queryParam: {
         beginDate: getDate.getCurrMonthDays().starttime,
@@ -121,7 +120,7 @@ export default {
       // 表头
       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: 'salesBillSourceDictValue', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '销售单号', dataIndex: 'salesBillNo', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '促销名称', dataIndex: 'promoName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
@@ -137,9 +136,6 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 440
-        }
         return salesPromoList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
@@ -162,6 +158,11 @@ export default {
       productTotal: null
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 430 : 375)
+    }
+  },
   methods: {
     //  创建时间  change
     dateChange (date) {

+ 9 - 8
src/views/promotionRulesManagement/productStatistics/list.vue

@@ -63,15 +63,15 @@
     <!-- alert -->
     <a-alert type="info" showIcon style="margin-bottom:15px">
       <div slot="message">
-        节省总金额:<strong>{{ productTotal ? ((productTotal.totalEconomizeAmount || productTotal.totalEconomizeAmount==0) ? productTotal.totalEconomizeAmount : '--') : '--' }}</strong>,
-        总数量:<strong>{{ productTotal ? ((productTotal.totalQty || productTotal.totalQty==0) ? productTotal.totalQty : '--') : '--' }}</strong>
+        节省总金额:<strong>{{ productTotal && (productTotal.totalEconomizeAmount || productTotal.totalEconomizeAmount==0) ? productTotal.totalEconomizeAmount : '--' }}</strong>,
+        总数量:<strong>{{ productTotal && (productTotal.totalQty || productTotal.totalQty==0) ? productTotal.totalQty : '--' }}</strong>
       </div>
     </a-alert>
     <!-- 列表 -->
     <s-table
       class="sTable"
       ref="table"
-      size="default"
+      size="small"
       :rowKey="(record, index) => index"
       :columns="columns"
       :data="loadData"
@@ -108,7 +108,6 @@ export default {
   data () {
     return {
       advanced: false, // 高级搜索 展开/关闭
-      tableHeight: 0,
       productType: [],
       queryParam: { //  查询条件
         beginDate: getDate.getCurrMonthDays().starttime,
@@ -129,7 +128,7 @@ export default {
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
         { title: '品牌', dataIndex: 'productEntity.productBrandName', width: 220, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '产品名称', dataIndex: 'productEntity.name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '产品编码', dataIndex: 'productEntity.code', width: 220, align: 'center' },
+        { title: '产品编码', dataIndex: 'productEntity.code', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '数量', dataIndex: 'qty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '单位', dataIndex: 'productEntity.unit', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '节省金额', dataIndex: 'totalEconomizeAmount', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? '¥' + text : '--') } },
@@ -138,9 +137,6 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
-        if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
-        }
         return salesDetailPromoList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
@@ -160,6 +156,11 @@ export default {
       productTotal: null
     }
   },
+  computed: {
+    tableHeight () {
+      return window.innerHeight - (this.advanced ? 430 : 375)
+    }
+  },
   methods: {
     //  时间  change
     dateChange (date) {

+ 9 - 5
src/views/promotionRulesManagement/promotionRules/detail.vue

@@ -37,6 +37,7 @@
         :rowKey="(record) => record.id"
         :columns="columns"
         :data-source="promoRuleList"
+        :loading="loading"
         :pagination="false"
         bordered>
         <!-- 操作 -->
@@ -99,7 +100,7 @@ export default {
       detailsData: null,
       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: 'promoRuleTypeDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '促销规则', dataIndex: 'promoRule', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 200, align: 'center', fixed: 'right' }
@@ -111,7 +112,7 @@ export default {
         { title: '客户名称', dataIndex: 'buyerName', align: 'center', customRender: function (text) { return text || '--' } }
       ],
       pColumns: [ //  正品
-        { title: '序号', scopedSlots: { customRender: 'no' }, width: 80, align: 'center', fixed: 'left' },
+        { title: '序号', scopedSlots: { customRender: 'no' }, width: 80, align: 'center' },
         { title: '类型', dataIndex: 'goodsTypeName', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '类型名称', dataIndex: 'goodsName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '产品名称', dataIndex: 'name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
@@ -119,7 +120,7 @@ export default {
         { title: '起订量限制', scopedSlots: { customRender: 'orderGoodsUnit' }, align: 'center' }
       ],
       promoColumns: [ //  促销品
-        { title: '序号', scopedSlots: { customRender: 'no' }, width: 80, align: 'center', fixed: 'left' },
+        { title: '序号', scopedSlots: { customRender: 'no' }, width: 80, align: 'center' },
         { title: '类型', dataIndex: 'goodsTypeName', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '类型名称', dataIndex: 'goodsName', width: 220, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '产品名称', dataIndex: 'name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
@@ -134,14 +135,17 @@ export default {
       lookLoadData: [],
       promoRuleList: [],
       nowColumns: [],
-      promoRuleType: '' //  当前查看类型     买产品送产品...
+      promoRuleType: '', //  当前查看类型     买产品送产品...
+      loading: false
     }
   },
   methods: {
     //  详情
     getDetail () {
       const _this = this
+      this.loading = true
       promoActiveDetailD({ sn: this.$route.params.sn }).then(res => {
+        this.loading = false
         if (res.status == 200) {
           _this.detailsData = res.data
           if (_this.detailsData.promoRuleList) {
@@ -209,7 +213,7 @@ export default {
     },
     //  返回列表
     handleBack () {
-      this.$router.push({ path: '/promotionRulesManagement/promotionRules/list' })
+      this.$router.push({ path: '/promotionRulesManagement/promotionRules/list', query: { closeLastOldTab: true } })
     }
   },
   watch: {

+ 6 - 6
src/views/promotionRulesManagement/promotionRules/list.vue

@@ -32,14 +32,14 @@
         <a-button id="promotionRulesList-add" type="primary" v-if="$hasPermissions('B_promotionRules_add')" class="button-error" @click="openModal=true">新增</a-button>
       </div>
       <!-- 总计 -->
-      <a-alert type="info" showIcon style="margin-bottom:15px">
+      <!-- <a-alert type="info" showIcon style="margin-bottom:15px">
         <div slot="message">合计: <strong>{{ total }}</strong>条</div>
-      </a-alert>
+      </a-alert> -->
       <!-- 列表 -->
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
@@ -117,7 +117,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: 'name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '促销时间', scopedSlots: { customRender: 'activeDate' }, width: 200, align: 'center' },
         { title: '参与客户', dataIndex: 'promoBuyerName', width: 220, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
@@ -129,7 +129,7 @@ export default {
       loadData: parameter => {
         this.disabled = true
         if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 450
+          this.tableHeight = window.innerHeight - 380
         }
         return promoActiveList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
@@ -144,7 +144,7 @@ export default {
             str = str.substr(0, str.length - 1)
             data.list[i].promoBuyerName = str || '全部客户'
           }
-          this.total = data.count
+          this.total = data.count || 0
           this.disabled = false
           return data
         })

+ 3 - 3
src/views/promotionRulesManagement/promotionRules/rule.vue

@@ -16,7 +16,7 @@
         <s-table
           class="sTable"
           ref="table"
-          size="default"
+          size="small"
           :rowKey="(record) => record.id"
           :columns="columns"
           :data="loadData"
@@ -57,7 +57,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: 'promoRuleTypeDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '促销规则', dataIndex: 'promoRule', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 200, align: 'center', fixed: 'right' }
@@ -131,7 +131,7 @@ export default {
     },
     //  返回列表
     handleBack () {
-      this.$router.push({ path: '/promotionRulesManagement/promotionRules/list' })
+      this.$router.push({ path: '/promotionRulesManagement/promotionRules/list', query: { closeLastOldTab: true } })
     }
   }
 }

+ 5 - 2
src/views/purchasingManagement/bulkWarehousingOrder/detailModal.vue

@@ -30,7 +30,10 @@
     <a-card size="small" :bordered="false" class="bulkWarehousingOrderDetail-cont">
       <!-- 总计 -->
       <a-alert type="info" showIcon style="margin-bottom:15px">
-        <div slot="message">入库数量 <strong>{{ (productTotal&&productTotal.totalQty) || 0 }}</strong> ,入库金额 <strong>{{ (productTotal&&productTotal.totalPrice) || 0 }}</strong></div>
+        <div slot="message">
+          入库数量 <strong>{{ (productTotal&&(productTotal.totalQty || productTotal.totalQty==0)) ? productTotal.totalQty : '--' }}</strong> ,
+          入库金额 <strong>{{ (productTotal&&(productTotal.totalPrice || productTotal.totalPrice==0)) ? productTotal.totalPrice : '--' }}</strong>
+        </div>
       </a-alert>
       <!-- 列表 -->
       <s-table
@@ -99,7 +102,7 @@ export default {
   methods: {
     //  返回列表
     handleBack () {
-      this.$router.push({ path: '/purchasingManagement/bulkWarehousingOrder/list' })
+      this.$router.push({ path: '/purchasingManagement/bulkWarehousingOrder/list', query: { closeLastOldTab: true } })
     },
     // 合计
     getDetailCount (params) {

+ 9 - 2
src/views/purchasingManagement/bulkWarehousingOrder/edit.vue

@@ -35,7 +35,10 @@
         </div>
         <!-- 总计 -->
         <a-alert type="info" showIcon style="margin-bottom:15px">
-          <div slot="message">入库数量 <strong>{{ (productTotal&&productTotal.totalQty) || 0 }}</strong> ,入库金额 <strong>{{ (productTotal&&productTotal.totalPrice) || 0 }}</strong></div>
+          <div slot="message">
+            入库数量 <strong>{{ (productTotal&&(productTotal.totalQty || productTotal.totalQty==0)) ? productTotal.totalQty : '--' }}</strong> ,
+            入库金额 <strong>{{ (productTotal&&(productTotal.totalPrice || productTotal.totalPrice==0)) ? productTotal.totalPrice : '--' }}</strong>
+          </div>
         </a-alert>
         <!-- 列表 -->
         <s-table
@@ -154,7 +157,7 @@ export default {
     },
     //  返回列表
     handleBack () {
-      this.$router.push({ path: '/purchasingManagement/bulkWarehousingOrder/list' })
+      this.$router.push({ path: '/purchasingManagement/bulkWarehousingOrder/list', query: { closeLastOldTab: true } })
     },
     // 合计
     getDetailCount (params) {
@@ -179,6 +182,10 @@ export default {
   .bulkWarehousingOrderEdit-wrap{
     .bulkWarehousingOrderEdit-cont{
       margin-bottom: 10px;
+      .table-operator{
+        border: 0;
+        padding-top: 0;
+      }
     }
   }
 </style>

+ 9 - 9
src/views/purchasingManagement/bulkWarehousingOrder/list.vue

@@ -43,7 +43,7 @@
       <s-table
         class="sTable"
         ref="table"
-        size="default"
+        size="small"
         :row-selection="rowSelection"
         :rowKey="(record) => record.sparePartsSn"
         :columns="columns"
@@ -54,10 +54,6 @@
         <template slot="sparePartsNo" slot-scope="text, record">
           <span :class="$hasPermissions('B_sparePartsDetail')?'active':'common'" @click="handleDetail(record)">{{ record.sparePartsNo }}</span>
         </template>
-        <!-- 财务状态 -->
-        <template slot="settleState" slot-scope="text, record">
-          <a-badge :color="text=='FINISH'?'#87d068':'gold'" :text="record.settleStateDictValue" />
-        </template>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
           <a-button
@@ -104,7 +100,7 @@ export default {
       },
       // 表头
       columns: [
-        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '入库单号', scopedSlots: { customRender: 'sparePartsNo' }, width: 220, align: 'center' },
         { title: '商户名称', dataIndex: 'supplierName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '入库数量', dataIndex: 'productTotalQty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
@@ -123,7 +119,7 @@ export default {
       loadData: parameter => {
         this.disabled = true
         if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 440
+          this.tableHeight = window.innerHeight - 380
         }
         return sparePartsList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data
@@ -256,8 +252,12 @@ export default {
 </script>
 <style lang="less">
   .bulkWarehousingOrderList-wrap{
-    .sTable{
-      margin-top: 15px;
+    .active{
+      color: #ed1c24;
+      cursor: pointer;
+    }
+    .common{
+      color: rgba(0, 0, 0, 0.65);
     }
   }
 </style>

+ 11 - 8
src/views/reportData/actualSalesReport/list.vue

@@ -22,13 +22,13 @@
               </a-form-model-item>
             </a-col>
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="客户类型">
+              <a-form-model-item label="客户级别">
                 <v-select
                   v-model="queryParam.dealer.dealerLevel"
                   ref="dealerLevel"
                   id="actualSalesReportList-allocateTypeSn"
                   code="DEALER_LEVEL"
-                  placeholder="请选择客户类型"
+                  placeholder="请选择客户级别"
                   allowClear></v-select>
               </a-form-model-item>
             </a-col>
@@ -163,7 +163,7 @@ export default {
         { title: '区域', dataIndex: 'dealer.subareaNameSet', width: 220, align: 'center', customRender: function (text) { return (text && text.length > 0) ? text.join('/') : '--' } },
         { title: '省份', dataIndex: 'dealer.provinceName', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '客户名称', dataIndex: 'dealer.dealerName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '客户类型', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户级别', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '品牌',
           align: 'center',
           children: [
@@ -194,8 +194,8 @@ export default {
                 },
                 {
                   title: '刹车片',
-                  dataIndex: 'pp4',
-                  align: 'jpScpAmount',
+                  dataIndex: 'jpScpAmount',
+                  align: 'center',
                   width: 100,
                   customRender: function (text) { return (text || text == 0) ? ('¥' + text) : '--' }
                 },
@@ -393,7 +393,6 @@ export default {
         'dealerLevel': undefined
       }
       this.totalData = null
-      this.$refs.rangeDate.resetDate()
       this.$refs.custList.resetForm()
       this.$refs.ruleForm.resetFields()
       this.$refs.table.clearTable()
@@ -404,13 +403,17 @@ export default {
       this.addrDistrictList = []
       this.queryParam.dealerCitySn = undefined
       this.queryParam.dealerCountySn = undefined
-      this.getArea('city', val)
+      if (val) {
+        this.getArea('city', val)
+      }
     },
     // 获取区县列表
     getAreaList (val) {
       this.addrDistrictList = []
       this.queryParam.dealerCountySn = undefined
-      this.getArea('district', val)
+      if (val) {
+        this.getArea('district', val)
+      }
     },
     //  省/市/区
     getArea (leve, sn) {

+ 1 - 1
src/views/reportData/allocationDetails/list.vue

@@ -98,7 +98,7 @@
               <a-col :md="6" :sm="24">
                 <a-form-model-item label="地区">
                   <a-form-model-item prop="dealerProvinceSn">
-                    <a-select id="allocationDetailsList-dealerProvinceSn" v-model="queryParam.dealerProvinceSn" placeholder="请选择省">
+                    <a-select id="allocationDetailsList-dealerProvinceSn" allowClear v-model="queryParam.dealerProvinceSn" placeholder="请选择省">
                       <a-select-option v-for="item in addrProvinceList" :value="item.areaSn" :key="item.areaSn + 'a'">{{ item.name }}</a-select-option>
                     </a-select>
                   </a-form-model-item>

+ 1 - 1
src/views/reportData/allocationOrderTotal/list.vue

@@ -128,7 +128,7 @@ export default {
         { title: '客户名称', dataIndex: 'targetName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '调拨数量', dataIndex: 'totalQty', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '成本价', dataIndex: 'totalCost', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '毛利', dataIndex: 'grossProfit', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '毛利', dataIndex: 'totalGrossProfit', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '操作员', dataIndex: 'creatorName', width: 120, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true }
       ],
       // 加载数据方法 必须为 Promise 对象

+ 9 - 5
src/views/reportData/billingReturnReport/list.vue

@@ -22,13 +22,13 @@
               </a-form-model-item>
             </a-col>
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="客户类型">
+              <a-form-model-item label="客户级别">
                 <v-select
                   v-model="queryParam.dealer.dealerLevel"
                   ref="dealerLevel"
                   id="billingReturnReportList-dealerLevel"
                   code="DEALER_LEVEL"
-                  placeholder="请选择客户类型"
+                  placeholder="请选择客户级别"
                   allowClear></v-select>
               </a-form-model-item>
             </a-col>
@@ -166,7 +166,7 @@ export default {
         { title: '区域', dataIndex: 'dealer.subareaNameSet', width: 220, align: 'center', customRender: function (text) { return (text && text.length > 0) ? text.join('/') : '--' } },
         { title: '省份', dataIndex: 'dealer.provinceName', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '客户名称', dataIndex: 'dealer.dealerName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '客户类型', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户级别', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '品牌',
           align: 'center',
           children: [
@@ -405,13 +405,17 @@ export default {
       this.addrDistrictList = []
       this.queryParam.dealerCitySn = undefined
       this.queryParam.dealerCountySn = undefined
-      this.getArea('city', val)
+      if (val) {
+        this.getArea('city', val)
+      }
     },
     // 获取区县列表
     getAreaList (val) {
       this.addrDistrictList = []
       this.queryParam.dealerCountySn = undefined
-      this.getArea('district', val)
+      if (val) {
+        this.getArea('district', val)
+      }
     },
     //  省/市/区
     getArea (leve, sn) {

+ 211 - 384
src/views/reportData/priceDifferenceDetailReport/list.vue

@@ -1,123 +1,131 @@
 <template>
-  <a-card size="small" :bordered="false" class="shortageStatisticsCList-wrap">
-    <!-- 搜索条件 -->
-    <div class="table-page-search-wrapper">
-      <a-form-model
-        id="priceDifferenceDetailReport-form"
-        layout="inline"
-        ref="ruleForm"
-        :model="queryParam"
-        :rules="rules"
-        @keyup.enter.native="$refs.table.refresh(true)">
-        <a-row :gutter="15">
-          <a-col :md="6" :sm="24">
-            <a-form-model-item label="日期" prop="time">
-              <rangeDate ref="rangeDate" :value="queryParam.time" @change="dateChange" />
-            </a-form-model-item>
-          </a-col>
-          <a-col :md="6" :sm="24">
-            <a-form-model-item label="单号">
-              <a-input placeholder="请输入单号" />
-            </a-form-model-item>
-          </a-col>
-          <a-col :md="6" :sm="24">
-            <a-form-model-item label="客户名称">
-              <custList ref="custList" id="shortageStatisticsCList-buyerSn" @change="custChange"></custList>
-            </a-form-model-item>
-          </a-col>
-          <template v-if="advanced">
+  <a-card size="small" :bordered="false" class="priceDifferenceDetailList-wrap">
+    <a-spin :spinning="spinning" tip="Loading...">
+      <!-- 搜索条件 -->
+      <div class="table-page-search-wrapper">
+        <a-form-model
+          id="priceDifferenceDetailList-form"
+          layout="inline"
+          ref="ruleForm"
+          :model="queryParam"
+          :rules="rules"
+          @keyup.enter.native="handleSearch">
+          <a-row :gutter="15">
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="客户类型">
-                <custList ref="custList" id="shortageStatisticsCList-buyerSn" @change="custChange"></custList>
+              <a-form-model-item label="日期" prop="time">
+                <rangeDate ref="rangeDate" :value="queryParam.time" @change="dateChange" />
               </a-form-model-item>
             </a-col>
-            <a-col :md="6" :sm="24">
-              <a-form-model-item label="品牌类别">
-                <a-select placeholder="选择品牌类别">
-                </a-select>
+            <a-col :md="5" :sm="24">
+              <a-form-model-item label="单号">
+                <a-input id="priceDifferenceDetailList-bizNo" v-model.trim="queryParam.bizNo" allowClear placeholder="请输入单号"/>
               </a-form-model-item>
             </a-col>
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="产品品牌">
-                <ProductBrand id="productInfoList-productBrandSn" v-model="queryParam.brandSn"></ProductBrand>
+              <a-form-model-item label="客户名称">
+                <custList id="priceDifferenceDetailList-custList" ref="custList" @change="custChange"></custList>
               </a-form-model-item>
             </a-col>
+            <template v-if="advanced">
+              <a-col :md="7" :sm="24">
+                <a-form-model-item label="客户级别">
+                  <v-select
+                    v-model="queryParam.dealer.dealerLevel"
+                    ref="dealerLevel"
+                    id="priceDifferenceDetailList-dealerLevel"
+                    code="DEALER_LEVEL"
+                    placeholder="请选择客户级别"
+                    allowClear></v-select>
+                </a-form-model-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="品牌分类">
+                  <v-select code="BRAND_TYPE" id="priceDifferenceDetailList-brandType" v-model="queryParam.product.brandType" allowClear placeholder="请选择品牌分类"></v-select>
+                </a-form-model-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="产品品牌">
+                  <ProductBrand id="priceDifferenceDetailList-productBrandSn" v-model="queryParam.product.productBrandSn"></ProductBrand>
+                </a-form-model-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="产品分类">
+                  <ProductType id="priceDifferenceDetailList-productType" v-model="productType" @change="changeProductType"></ProductType>
+                </a-form-model-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="所在区域">
+                  <subarea id="priceDifferenceDetailList-subareaSn" v-model="queryParam.dealer.subareaSn"></subarea>
+                </a-form-model-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="省级区域">
+                  <a-select id="priceDifferenceDetailList-provinceSn" allowClear v-model="queryParam.dealer.provinceSn" placeholder="请选择省">
+                    <a-select-option v-for="item in addrProvinceList" :value="item.areaSn" :key="item.areaSn + 'a'">{{ item.name }}</a-select-option>
+                  </a-select>
+                </a-form-model-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="类型" prop="bizType">
+                  <a-select id="priceDifferenceDetailList-bizType" allowClear v-model="queryParam.bizType" placeholder="请选择类型">
+                    <a-select-option v-for="item in bizTypeList" :value="item.value" :key="item.value">{{ item.name }}</a-select-option>
+                  </a-select>
+                </a-form-model-item>
+              </a-col>
+            </template>
+            <a-col :md="7" :sm="24">
+              <a-button
+                style="margin-bottom: 18px;"
+                type="primary"
+                class="button-warning"
+                size="small"
+                @click="handleStock"
+                id="priceDifferenceDetailList-stockDate">盘点区间日期</a-button>
+              <a-button style="margin: 0 0 18px 8px" type="primary" @click="handleSearch" :disabled="disabled" id="priceDifferenceDetailList-refresh">查询</a-button>
+              <a-button style="margin: 0 0 18px 8px" @click="resetSearchForm" :disabled="disabled" id="priceDifferenceDetailList-reset">重置</a-button>
+              <a @click="advanced=!advanced" style="margin-left: 8px">
+                {{ advanced ? '收起' : '展开' }}
+                <a-icon :type="advanced ? 'up' : 'down'"/>
+              </a>
+            </a-col>
+          </a-row>
+        </a-form-model>
+      </div>
+      <!-- 列表 -->
+      <s-table
+        class="sTable"
+        ref="table"
+        size="small"
+        :rowKey="(record) => record.id"
+        :columns="columns"
+        :data="loadData"
+        :scroll="{ x: 2800 }"
+        bordered>
+        <template slot="footer">
+          <a-row :gutter="15">
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="二级品类">
-                <ProductType id="productInfoList-productType" v-model="productType" @change="changeProductType"></ProductType>
-              </a-form-model-item>
+              分公司金额:{{ (totalData && (totalData.wholesalePrice1 || totalData.wholesalePrice1==0)) ? totalData.wholesalePrice1 : '--' }}
             </a-col>
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="所在区域">
-                <subarea id="shortageStatisticsCList-subarea" v-model="queryParam.subareaSn"></subarea>
-              </a-form-model-item>
+              加盟商金额:{{ (totalData && (totalData.wholesalePrice2 || totalData.wholesalePrice2==0)) ? totalData.wholesalePrice2 : '--' }}
             </a-col>
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="省级区域" prop="provinceSn">
-                <a-select id="supplierInfoEdit-provinceSn" @change="getCityList" v-model="queryParam.provinceSn" placeholder="请选择省">
-                  <a-select-option v-for="item in addrProvinceList" :value="item.areaSn" :key="item.areaSn + 'a'">{{ item.name }}</a-select-option>
-                </a-select>
-              </a-form-model-item>
+              特约加盟店金额:{{ (totalData && (totalData.wholesalePrice3 || totalData.wholesalePrice3==0)) ? totalData.wholesalePrice3 : '--' }}
             </a-col>
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="类型">
-                <subarea id="shortageStatisticsCList-subarea" v-model="queryParam.subareaSn"></subarea>
-              </a-form-model-item>
+              直接差价金额:{{ (totalData && (totalData.directRebateAmount || totalData.directRebateAmount==0)) ? totalData.directRebateAmount : '--' }}
             </a-col>
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="">
-                <a-checkbox>
-                  盘点区间日期
-                </a-checkbox>
-              </a-form-model-item>
+              间接差价金额:{{ (totalData && (totalData.indirectRebateAmount || totalData.indirectRebateAmount==0)) ? totalData.indirectRebateAmount : '--' }}
             </a-col>
-          </template>
-          <a-col :md="6" :sm="24">
-            <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="shortageStatisticsCList-refresh">查询</a-button>
-            <a-button style="margin-left: 8px" @click="resetSearchForm" :disabled="disabled" id="shortageStatisticsCList-reset">重置</a-button>
-            <a @click="advanced=!advanced" style="margin-left: 8px">
-              {{ advanced ? '收起' : '展开' }}
-              <a-icon :type="advanced ? 'up' : 'down'"/>
-            </a>
-          </a-col>
-        </a-row>
-      </a-form-model>
-    </div>
-    <!-- 列表 -->
-    <s-table
-      class="sTable"
-      ref="table"
-      size="small"
-      :rowKey="(record) => record.id"
-      :columns="columns"
-      :data="loadData"
-      :scroll="{ x: 2250, y: tableHeight }"
-      bordered>
-      <template slot="footer" slot-scope="currentPageData">
-        <a-row :gutter="15">
-          <a-col :md="4" :sm="24">
-            分公司金额:11175.40
-          </a-col>
-          <a-col :md="4" :sm="24">
-            加盟商金额:12182.40
-          </a-col>
-          <a-col :md="4" :sm="24">
-            特约加盟店金额:--
-          </a-col>
-          <a-col :md="4" :sm="24">
-            直接差价金额:1007.00
-          </a-col>
-          <a-col :md="4" :sm="24">
-            间接差价金额:0
-          </a-col>
-        </a-row>
-      </template>
-    </s-table>
+          </a-row>
+        </template>
+      </s-table>
+    </a-spin>
   </a-card>
 </template>
 
 <script>
-import moment from 'moment'
 import getDate from '@/libs/getDate.js'
 import { STable, VSelect } from '@/components'
 import rangeDate from '@/views/common/rangeDate.vue'
@@ -126,13 +134,13 @@ import subarea from '@/views/common/subarea.js'
 import { getArea } from '@/api/data'
 import ProductBrand from '@/views/common/productBrand.js'
 import ProductType from '@/views/common/productType.js'
-// import { oosBuyerList, oosBuyerDetailCount, oosBuyerDetailPageCount, oosDetailExport } from '@/api/oos'
+import { headRebateDetailReportList, headRebateDetailReportCount } from '@/api/reportData'
 export default {
   components: { STable, VSelect, custList, subarea, rangeDate, ProductBrand, ProductType },
   data () {
     return {
+      spinning: false,
       advanced: false, // 高级搜索 展开/关闭
-      tableHeight: 0,
       queryParam: { //  查询条件
         time: [
           getDate.getCurrMonthDays().starttime,
@@ -140,275 +148,118 @@ export default {
         ],
         beginDate: getDate.getCurrMonthDays().starttime,
         endDate: getDate.getCurrMonthDays().endtime,
-        buyerSn: undefined,
-        subareaSn: undefined, //  区域
-        provinceSn: undefined,
-        citySn: undefined,
-        districtSn: undefined
+        bizNo: '',
+        dealer: {
+          dealerSn: undefined,
+          dealerLevel: undefined,
+          subareaSn: undefined, //  区域
+          provinceSn: undefined
+        },
+        product: {
+          brandType: undefined,
+          productBrandSn: undefined, //  产品品牌
+          productTypeSn1: '', //  产品一级分类
+          productTypeSn2: '', //  产品二级分类
+          productTypeSn3: '' //  产品三级分类
+        },
+        bizType: undefined
+      },
+      rules: {
+        'time': [{ required: true, message: '请选择日期', trigger: 'change' }]
       },
-	  rules: {
-	    'time': [{ required: true, message: '请选择销售日期', trigger: 'change' }]
-	  },
       disabled: false, //  查询、重置按钮是否可操作
-      exportLoading: false, // 导出loading
       addrProvinceList: [], //  省下拉
-      addrCityList: [], //  市下拉
-      addrDistrictList: [], //  区下拉
       columns: [
-        { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
-        { title: '区域',
-          dataIndex: 'area',
-          width: 150,
-          align: 'center',
-          customRender: function (text) { return text || '--' }
-        },
-        { title: '订单号',
-          dataIndex: 'orderNo',
-          width: 150,
-          align: 'center',
-          customRender: function (text) { return text || '--' }
-        },
-        { title: '日期',
-          dataIndex: 'creatDate',
-          width: 200,
-          align: 'center',
-          customRender: function (text) { return text || '--' }
-        },
-        { title: '省份',
-          dataIndex: 'provinceName',
-          width: 100,
-          align: 'center',
-          customRender: function (text) { return text || '--' }
-        },
-        { title: '直接绑定客户名称',
-          dataIndex: 'zjCustName',
-          width: 200,
-          align: 'center',
-          customRender: function (text) { return text || '--' }
-        },
-        { title: '间接绑定客户名称',
-          dataIndex: 'djCustName',
-          width: 200,
-          align: 'center',
-          customRender: function (text) { return text || '--' }
-        },
-        { title: '客户名称',
-          dataIndex: 'custName',
-          width: 200,
-          align: 'center',
-          customRender: function (text) { return text || '--' }
-        },
-        { title: '客户类型',
-          dataIndex: 'custType',
-          width: 150,
-          align: 'center',
-          customRender: function (text) { return text || '--' }
-        },
-        { title: '品牌',
-          dataIndex: 'brand',
-          width: 100,
-          align: 'center',
-          customRender: function (text) { return text || '--' }
-        },
-        { title: '二级分类',
-          dataIndex: 'proCls',
-          width: 100,
-          align: 'center',
-          customRender: function (text) { return text || '--' }
-        },
-        { title: '数量',
-          dataIndex: 'nums',
-          width: 100,
-          align: 'center',
-          customRender: function (text) { return text || '--' }
-        },
-        { title: '分公司金额', width: 100, dataIndex: 'p1', align: 'center', customRender: function (text) { return text ? ('¥' + text) : '--' } },
-        { title: '加盟商金额', width: 100, dataIndex: 'p2', align: 'center', customRender: function (text) { return text ? ('¥' + text) : '--' } },
-        { title: '特约加盟商金额', width: 100, dataIndex: 'p3', align: 'center', customRender: function (text) { return text ? ('¥' + text) : '--' } },
-        { title: '直接差价', width: 100, dataIndex: 'p4', align: 'center', customRender: function (text) { return text ? ('¥' + text) : '--' } },
-        { title: '间接差价', width: 100, dataIndex: 'p5', align: 'center', customRender: function (text) { return text ? ('¥' + text) : '--' } },
-        { title: '类型', width: 100, dataIndex: 'type', align: 'center', customRender: function (text) { return text || '--' } }
+        { title: '序号', dataIndex: 'no', width: 80, align: 'center', fixed: 'left' },
+        { title: '区域', dataIndex: 'dealer.subareaNameSet', width: 220, align: 'center', customRender: function (text) { return (text && text.length > 0) ? text.join('/') : '--' } },
+        { title: '订单号', dataIndex: 'bizNo', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '日期', dataIndex: 'bizCreateDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '省份', dataIndex: 'dealer.provinceName', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '直接绑定客户名称', dataIndex: 'directDealerName', width: 200, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '间接绑定客户名称', dataIndex: 'indirectDealerName', width: 200, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '客户名称', dataIndex: 'dealer.dealerName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '客户级别', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '品牌', dataIndex: 'productBrandName', width: 200, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '二级分类', dataIndex: 'productTypeName2', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '数量', dataIndex: 'qty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '分公司金额', dataIndex: 'wholesalePrice1', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '加盟商金额', dataIndex: 'wholesalePrice2', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '特约加盟店金额', dataIndex: 'wholesalePrice3', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '直接差价', dataIndex: 'directRebateAmount', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '间接差价', dataIndex: 'indirectRebateAmount', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '类型', dataIndex: 'bizTypeValue', width: 100, align: 'center', customRender: function (text) { return text || '--' } }
       ],
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
-        // this.disabled = true
-        // if (this.tableHeight == 0) {
-        //   this.tableHeight = window.innerHeight - 380
-        // }
-        // const paramsPage = Object.assign(this.queryParam, { pageNo: parameter.pageNo, pageSize: parameter.pageSize }) //  有分页
-        // const params = Object.assign(parameter, this.queryParam) //  无分页
-        // return oosBuyerList(params).then(res => {
-        //   const data = res.data
-        //   const no = (data.pageNo - 1) * data.pageSize
-        //   for (var i = 0; i < data.list.length; i++) {
-        //     data.list[i].no = no + i + 1
-        //   }
-        //   this.disabled = false
-        //   return data
-        // })
-        const _this = this
-        return new Promise(function (resolve, reject) {
-          const data = {
-            pageNo: 1,
-            pageSize: 10,
-            list: [
-              {
-                area: 'A区',
-                orderNo: 'XS2106210000118',
-                creatDate: '2021/6/21 19:16:18',
-                provinceName: '浙江省',
-                zjCustName: '剪冠汽配杭州金球店',
-                djCustName: '',
-                custName: '剪冠汽配丽水龙泉店',
-                custType: '市级加盟商',
-                brand: '箭牌',
-                proCls: '滤清器',
-                nums: '100',
-                p1: '700.00',
-                p2: '780.00',
-                p3: '',
-                p4: '80.00',
-                p5: '0.00',
-                type: '采购差价'
-              },
-              {
-                area: 'B区/04区',
-                orderNo: 'XS2106210000168',
-                creatDate: '2021/6/21 16:23:06',
-                provinceName: '广西区',
-                zjCustName: '剪冠汽配南宁兴宁店',
-                djCustName: '',
-                custName: '剪冠汽配梧州万秀店',
-                custType: '市级加盟商',
-                brand: '冠牌',
-                proCls: '滤清器',
-                nums: '44',
-                p1: '362.00',
-                p2: '406.00',
-                p3: '',
-                p4: '44.00',
-                p5: '0.00',
-                type: '采购差价'
-              },
-              {
-                area: 'B区/04区',
-                orderNo: 'XS2106210000168',
-                creatDate: '2021/6/21 16:23:06',
-                provinceName: '广西区',
-                zjCustName: '剪冠汽配南宁兴宁店',
-                djCustName: '',
-                custName: '剪冠汽配梧州万秀店',
-                custType: '市级加盟商',
-                brand: '汇箭',
-                proCls: '蓄电池',
-                nums: '19',
-                p1: '3942.40',
-                p2: '4126.40',
-                p3: '',
-                p4: '184.00',
-                p5: '0.00',
-                type: '采购差价'
-              },
-              {
-                area: 'B区/04区',
-                orderNo: 'XS2106210000168',
-                creatDate: '2021/6/21 16:23:06',
-                provinceName: '广西区',
-                zjCustName: '剪冠汽配南宁兴宁店',
-                djCustName: '',
-                custName: '剪冠汽配梧州万秀店',
-                custType: '市级加盟商',
-                brand: '箭牌',
-                proCls: '滤清器',
-                nums: '186',
-                p1: '1691.00',
-                p2: '1886.00',
-                p3: '',
-                p4: '195.00',
-                p5: '0.00',
-                type: '采购差价'
-              },
-              {
-                area: 'D区/06区',
-                orderNo: 'XS2106210000045',
-                creatDate: '2021/6/21 16:00:37',
-                provinceName: '内蒙古',
-                zjCustName: '剪冠汽配锡林浩特快驰店',
-                djCustName: '',
-                custName: '剪冠汽配锡林浩特快驰店1',
-                custType: '市级加盟商',
-                brand: '箭牌',
-                proCls: '滤清器',
-                nums: '525',
-                p1: '4480.00',
-                p2: '4984.00',
-                p3: '',
-                p4: '504.00',
-                p5: '0.00',
-                type: '采购差价'
-              }
-            ],
-            count: 1
-          }
+        this.disabled = true
+        const params = Object.assign(parameter, this.queryParam)
+        delete params.time
+        this.spinning = true
+        return headRebateDetailReportList(params).then(res => {
+          // 总计
+          this.getCount(params)
+          const data = res.data
+          const no = (data.pageNo - 1) * data.pageSize
           for (var i = 0; i < data.list.length; i++) {
-            data.list[i].no = i + 1
+            data.list[i].no = no + i + 1
+            if (data.list[i].bizType) {
+              data.list[i].bizTypeValue = data.list[i].bizType == 'SALES' ? '采购差价' : data.list[i].bizType == 'SALES_RETURN' ? '退货差价' : ''
+            }
           }
-          _this.disabled = false
-          resolve(data)
+          this.disabled = false
+          this.spinning = false
+          return data
         })
       },
       productType: [],
-      productTotal: null,
-      currentTotal: null
+      bizTypeList: [
+        { value: 'SALES', name: '采购差价' },
+        { value: 'SALES_RETURN', name: '退货差价' }
+      ],
+      totalData: null
     }
   },
   methods: {
+    // 盘点库存日期
+    handleStock () {
+      this.$message.info('无盘点区间的起始/终止时间,请自行选择日期区间查询!')
+    },
     //  创建时间  change
     dateChange (date) {
       this.queryParam.time = date
       this.queryParam.beginDate = date[0] || ''
       this.queryParam.endDate = date[1] || ''
     },
-    custChange (obj) {
-      this.queryParam.buyerSn = obj.key
-    },
-    //  产品分类  change
-    changeProductType (val, opt) {
-      this.queryParam.productTypeSn1 = val[0] ? val[0] : ''
-      this.queryParam.productTypeSn2 = val[1] ? val[1] : ''
-      this.queryParam.productTypeSn3 = val[2] ? val[2] : ''
+    // 合计
+    getCount (params) {
+      headRebateDetailReportCount(params).then(res => {
+        if (res.status == 200) {
+          this.totalData = res.data
+        } else {
+          this.totalData = null
+        }
+      })
     },
-    // 获取城市列表
-    getCityList (val) {
-      const index = this.addrProvinceList.findIndex(item => item.areaSn == val)
-      if (index >= 0) {
-        this.queryParam.provinceName = this.addrProvinceList[index].name
-      }
-      this.addrCityList = []
-      this.addrDistrictList = []
-      this.queryParam.citySn = undefined
-      this.queryParam.districtSn = undefined
-      this.queryParam.address = ''
-      this.getArea('city', val)
+    //  查询
+    handleSearch () {
+      const _this = this
+      // this.$refs.ruleForm.validate(valid => {
+      //   if (valid) {
+      _this.$refs.table.refresh(true)
+      //   } else {
+      //     console.log('error submit!!')
+      //     return false
+      //   }
+      // })
     },
-    // 获取区县列表
-    getAreaList (val) {
-      const index = this.addrCityList.findIndex(item => item.areaSn == val)
-      if (index >= 0) {
-        this.queryParam.cityName = this.addrCityList[index].name
-      }
-      this.addrDistrictList = []
-      this.queryParam.districtSn = undefined
-      this.queryParam.address = ''
-      this.getArea('district', val)
+    custChange (val) {
+      this.queryParam.dealer.dealerSn = val.key
     },
-    // 区县变更
-    areaCharged (val) {
-      const index = this.addrDistrictList.findIndex(item => item.areaSn == val)
-      if (index >= 0) {
-        this.queryParam.districtName = this.addrDistrictList[index].name
-      }
-      this.queryParam.address = ''
+    //  产品分类  change
+    changeProductType (val, opt) {
+      this.queryParam.product.productTypeSn1 = val[0] ? val[0] : ''
+      this.queryParam.product.productTypeSn2 = val[1] ? val[1] : ''
+      this.queryParam.product.productTypeSn3 = val[2] ? val[2] : ''
     },
     //  省/市/区
     getArea (leve, sn) {
@@ -447,48 +298,24 @@ export default {
       this.$refs.rangeDate.resetDate(this.queryParam.time)
       this.queryParam.beginDate = getDate.getCurrMonthDays().starttime
       this.queryParam.endDate = getDate.getCurrMonthDays().endtime
-      this.queryParam.buyerSn = undefined
-      this.queryParam.subareaSn = undefined
-      this.queryParam.productName = ''
-      this.queryParam.productCode = ''
-      this.queryParam.productTypeSn1 = ''
-      this.queryParam.productTypeSn2 = ''
-      this.queryParam.productTypeSn3 = ''
-      this.queryParam.salesBillNo = ''
+      this.queryParam.bizNo = ''
+      this.queryParam.dealer.dealerSn = undefined
+      this.queryParam.dealer.dealerLevel = undefined
+      this.queryParam.dealer.subareaSn = undefined
+      this.queryParam.dealer.provinceSn = undefined
+      this.queryParam.product.brandType = ''
+      this.queryParam.product.productBrandSn = ''
+      this.queryParam.product.productTypeSn1 = ''
+      this.queryParam.product.productTypeSn2 = ''
+      this.queryParam.product.productTypeSn3 = ''
+      this.queryParam.bizType = undefined
       this.productType = []
-      this.$refs.table.refresh(true)
-    },
-    // 详情
-    handleDetail (row) {
-      this.$router.push({ name: 'salesDetail', params: { sn: row.salesBillSn } })
-    },
-    //  导出
-    handleExport () {
-      const params = this.queryParam
-      if (this.time && this.time.length) {
-        params.beginDate = moment(this.time[0]).format('YYYY-MM-DD')
-        params.endDate = moment(this.time[1]).format('YYYY-MM-DD')
-      } else {
-        params.beginDate = ''
-        params.endDate = ''
+      this.totalData = null
+      if (this.advanced) {
+        this.$refs.custList.resetForm()
       }
-      this.exportLoading = true
-      oosDetailExport(params).then(res => {
-        this.exportLoading = false
-        this.download(res)
-      })
-    },
-    download (data) {
-      if (!data) { return }
-      const url = window.URL.createObjectURL(new Blob([data]))
-      const link = document.createElement('a')
-      link.style.display = 'none'
-      link.href = url
-      const a = moment().format('YYYYMMDDHHmmss')
-      const fname = '缺货统计(按客户)' + a
-      link.setAttribute('download', fname + '.xlsx')
-      document.body.appendChild(link)
-      link.click()
+      this.$refs.ruleForm.resetFields()
+      this.$refs.table.clearTable()
     }
   },
   beforeRouteEnter (to, from, next) {

+ 9 - 5
src/views/reportData/returnSlipReport/list.vue

@@ -22,13 +22,13 @@
               </a-form-model-item>
             </a-col>
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="客户类型">
+              <a-form-model-item label="客户级别">
                 <v-select
                   v-model="queryParam.dealer.dealerLevel"
                   ref="dealerLevel"
                   id="returnSlipReportList-dealerLevel"
                   code="DEALER_LEVEL"
-                  placeholder="请选择客户类型"
+                  placeholder="请选择客户级别"
                   allowClear></v-select>
               </a-form-model-item>
             </a-col>
@@ -173,7 +173,7 @@ export default {
         { title: '退货单号', dataIndex: 'salesReturnBillNo', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '省份', dataIndex: 'dealer.provinceName', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '客户名称', dataIndex: 'dealer.dealerName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '客户类型', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户级别', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '品牌',
           align: 'center',
           children: [
@@ -412,13 +412,17 @@ export default {
       this.addrDistrictList = []
       this.queryParam.dealerCitySn = undefined
       this.queryParam.dealerCountySn = undefined
-      this.getArea('city', val)
+      if (val) {
+        this.getArea('city', val)
+      }
     },
     // 获取区县列表
     getAreaList (val) {
       this.addrDistrictList = []
       this.queryParam.dealerCountySn = undefined
-      this.getArea('district', val)
+      if (val) {
+        this.getArea('district', val)
+      }
     },
     //  省/市/区
     getArea (leve, sn) {

+ 11 - 7
src/views/reportData/salesAmountReport/list.vue

@@ -22,13 +22,13 @@
               </a-form-model-item>
             </a-col>
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="客户类型">
+              <a-form-model-item label="客户级别">
                 <v-select
                   v-model="queryParam.dealer.dealerLevel"
                   ref="dealerLevel"
                   id="salesAmountReportList-allocateTypeSn"
                   code="DEALER_LEVEL"
-                  placeholder="请选择客户类型"
+                  placeholder="请选择客户级别"
                   allowClear></v-select>
               </a-form-model-item>
             </a-col>
@@ -163,7 +163,7 @@ export default {
         { title: '区域', dataIndex: 'dealer.subareaNameSet', width: 220, align: 'center', customRender: function (text) { return (text && text.length > 0) ? text.join('/') : '--' } },
         { title: '省份', dataIndex: 'dealer.provinceName', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '客户名称', dataIndex: 'dealer.dealerName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '客户类型', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户级别', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '品牌',
           align: 'center',
           children: [
@@ -194,8 +194,8 @@ export default {
                 },
                 {
                   title: '刹车片',
-                  dataIndex: 'pp4',
-                  align: 'jpScpAmount',
+                  dataIndex: 'jpScpAmount',
+                  align: 'center',
                   width: 100,
                   customRender: function (text) { return (text || text == 0) ? ('¥' + text) : '--' }
                 },
@@ -404,13 +404,17 @@ export default {
       this.addrDistrictList = []
       this.queryParam.dealerCitySn = undefined
       this.queryParam.dealerCountySn = undefined
-      this.getArea('city', val)
+      if (val) {
+        this.getArea('city', val)
+      }
     },
     // 获取区县列表
     getAreaList (val) {
       this.addrDistrictList = []
       this.queryParam.dealerCountySn = undefined
-      this.getArea('district', val)
+      if (val) {
+        this.getArea('district', val)
+      }
     },
     //  省/市/区
     getArea (leve, sn) {

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

@@ -198,9 +198,9 @@ export default {
         { title: '销售单号', dataIndex: 'data2', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '省份', dataIndex: 'data3', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '客户名称', dataIndex: 'data4', width: 220, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '客户类型', dataIndex: 'data5', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '直接绑定客户类型', dataIndex: 'data6', width: 200, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '间接绑定客户类型', dataIndex: 'data7', width: 200, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '客户级别', dataIndex: 'data5', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '直接绑定客户级别', dataIndex: 'data6', width: 200, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '间接绑定客户级别', dataIndex: 'data7', width: 200, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '开单日期', dataIndex: 'data8', width: 160, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '销售日期', dataIndex: 'data9', width: 160, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '品牌', dataIndex: 'data10', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },

+ 9 - 5
src/views/reportData/salesReturnDetailReport/list.vue

@@ -38,13 +38,13 @@
                 </a-form-model-item>
               </a-col>
               <a-col :md="6" :sm="24">
-                <a-form-model-item label="客户类型">
+                <a-form-model-item label="客户级别">
                   <v-select
                     v-model="queryParam.dealerLevel"
                     ref="dealerLevel"
                     id="salesReturnDetailList-dealerLevel"
                     code="DEALER_LEVEL"
-                    placeholder="请选择客户类型"
+                    placeholder="请选择客户级别"
                     allowClear></v-select>
                 </a-form-model-item>
               </a-col>
@@ -238,7 +238,7 @@ export default {
         { title: '退货单号', dataIndex: 'salesReturnBillNo', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '省份', dataIndex: 'dealerProvinceName', width: 200, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '客户名称', dataIndex: 'dealerName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '客户类型', dataIndex: 'dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '客户级别', dataIndex: 'dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '直接绑定客户名称', dataIndex: 'directDealerName', width: 200, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '间接绑定客户名称', dataIndex: 'indirectDealerName', width: 200, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '退货完成日期', dataIndex: 'salesReturnDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
@@ -427,13 +427,17 @@ export default {
       this.addrDistrictList = []
       this.queryParam.dealerCitySn = undefined
       this.queryParam.dealerCountySn = undefined
-      this.getArea('city', val)
+      if (val) {
+        this.getArea('city', val)
+      }
     },
     // 获取区县列表
     getAreaList (val) {
       this.addrDistrictList = []
       this.queryParam.dealerCountySn = undefined
-      this.getArea('district', val)
+      if (val) {
+        this.getArea('district', val)
+      }
     },
     //  省/市/区
     getArea (leve, sn) {

+ 9 - 5
src/views/reportData/salesReturnReport/list.vue

@@ -22,13 +22,13 @@
               </a-form-model-item>
             </a-col>
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="客户类型">
+              <a-form-model-item label="客户级别">
                 <v-select
                   v-model="queryParam.dealer.dealerLevel"
                   ref="dealerLevel"
                   id="salesReturnReportList-dealerLevel"
                   code="DEALER_LEVEL"
-                  placeholder="请选择客户类型"
+                  placeholder="请选择客户级别"
                   allowClear></v-select>
               </a-form-model-item>
             </a-col>
@@ -166,7 +166,7 @@ export default {
         { title: '区域', dataIndex: 'dealer.subareaNameSet', width: 220, align: 'center', customRender: function (text) { return (text && text.length > 0) ? text.join('/') : '--' } },
         { title: '省份', dataIndex: 'dealer.provinceName', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '客户名称', dataIndex: 'dealer.dealerName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '客户类型', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户级别', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '品牌',
           align: 'center',
           children: [
@@ -405,13 +405,17 @@ export default {
       this.addrDistrictList = []
       this.queryParam.dealerCitySn = undefined
       this.queryParam.dealerCountySn = undefined
-      this.getArea('city', val)
+      if (val) {
+        this.getArea('city', val)
+      }
     },
     // 获取区县列表
     getAreaList (val) {
       this.addrDistrictList = []
       this.queryParam.dealerCountySn = undefined
-      this.getArea('district', val)
+      if (val) {
+        this.getArea('district', val)
+      }
     },
     //  省/市/区
     getArea (leve, sn) {

+ 10 - 6
src/views/reportData/salesReturnsReport/list.vue

@@ -33,13 +33,13 @@
                 </a-form-model-item>
               </a-col>
               <a-col :md="6" :sm="24">
-                <a-form-model-item label="客户类型">
+                <a-form-model-item label="客户级别">
                   <v-select
                     v-model="queryParam.dealerLevel"
                     ref="dealerLevel"
                     id="salesReturnsReportList-dealerLevel"
                     code="DEALER_LEVEL"
-                    placeholder="请选择客户类型"
+                    placeholder="请选择客户级别"
                     allowClear></v-select>
                 </a-form-model-item>
               </a-col>
@@ -79,7 +79,7 @@
                 size="small"
                 @click="handleStock"
                 id="salesReturnsReportList-stockDate">盘点区间日期</a-button>
-              <a-button style="margin: 0 0 18px 8px" type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="salesReturnsReportList-refresh">查询</a-button>
+              <a-button style="margin: 0 0 18px 8px" type="primary" @click="handleSearch" :disabled="disabled" id="salesReturnsReportList-refresh">查询</a-button>
               <a-button style="margin: 0 0 18px 8px" @click="resetSearchForm" :disabled="disabled" id="salesReturnsReportList-reset">重置</a-button>
               <a @click="advanced=!advanced" style="margin-left: 8px">
                 {{ advanced ? '收起' : '展开' }}
@@ -166,7 +166,7 @@ export default {
         { title: '退货单号', dataIndex: 'salesReturnBillNo', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '退货完成日期', dataIndex: 'salesReturnDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '客户名称', dataIndex: 'dealerName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '客户类型', dataIndex: 'dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户级别', dataIndex: 'dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '直接绑定客户名称', dataIndex: 'directDealerName', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '间接绑定客户名称', dataIndex: 'indirectDealerName', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '退货数量', dataIndex: 'totalQty', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
@@ -267,13 +267,17 @@ export default {
       this.addrDistrictList = []
       this.queryParam.dealerCitySn = undefined
       this.queryParam.dealerCountySn = undefined
-      this.getArea('city', val)
+      if (val) {
+        this.getArea('city', val)
+      }
     },
     // 获取区县列表
     getAreaList (val) {
       this.addrDistrictList = []
       this.queryParam.dealerCountySn = undefined
-      this.getArea('district', val)
+      if (val) {
+        this.getArea('district', val)
+      }
     },
     //  省/市/区
     getArea (leve, sn) {

+ 11 - 7
src/views/reportData/salesSlipReport/list.vue

@@ -22,13 +22,13 @@
               </a-form-model-item>
             </a-col>
             <a-col :md="6" :sm="24">
-              <a-form-model-item label="客户类型">
+              <a-form-model-item label="客户级别">
                 <v-select
                   v-model="queryParam.dealer.dealerLevel"
                   ref="dealerLevel"
                   id="salesSlipReportList-allocateTypeSn"
                   code="DEALER_LEVEL"
-                  placeholder="请选择客户类型"
+                  placeholder="请选择客户级别"
                   allowClear></v-select>
               </a-form-model-item>
             </a-col>
@@ -170,7 +170,7 @@ export default {
         { title: '销售单号', dataIndex: 'salesBillNo', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '省份', dataIndex: 'dealer.provinceName', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '客户名称', dataIndex: 'dealer.dealerName', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '客户类型', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户级别', dataIndex: 'dealer.dealerLevelDictValue', width: 200, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '品牌',
           align: 'center',
           children: [
@@ -201,8 +201,8 @@ export default {
                 },
                 {
                   title: '刹车片',
-                  dataIndex: 'pp4',
-                  align: 'jpScpAmount',
+                  dataIndex: 'jpScpAmount',
+                  align: 'center',
                   width: 100,
                   customRender: function (text) { return (text || text == 0) ? ('¥' + text) : '--' }
                 },
@@ -412,13 +412,17 @@ export default {
       this.addrDistrictList = []
       this.queryParam.dealer.citySn = undefined
       this.queryParam.dealer.districtSn = undefined
-      this.getArea('city', val)
+      if (val) {
+        this.getArea('city', val)
+      }
     },
     // 获取区县列表
     getAreaList (val) {
       this.addrDistrictList = []
       this.queryParam.dealer.districtSn = undefined
-      this.getArea('district', val)
+      if (val) {
+        this.getArea('district', val)
+      }
     },
     //  省/市/区
     getArea (leve, sn) {

+ 3 - 3
src/views/salesManagement/backorder/detailModal.vue

@@ -27,9 +27,9 @@
         <!-- alert -->
         <a-alert type="info" showIcon style="margin-bottom:10px">
           <div slot="message">
-            缺货总款数:<strong>{{ detailData ? ((detailData.totalCategory || detailData.totalCategory==0) ? detailData.totalCategory : '--') : '--' }}</strong>,
-            缺货总数量:<strong>{{ detailData ? ((detailData.totalQty || detailData.totalQty==0) ? detailData.totalQty : '--') : '--' }}</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.totalAmount || detailData.totalAmount==0) ? detailData.totalAmount : '--' }}</strong>
           </div></a-alert>
         <!-- 列表 -->
         <s-table

+ 2 - 2
src/views/salesManagement/backorder/list.vue

@@ -25,7 +25,7 @@
     <s-table
       class="sTable"
       ref="table"
-      size="default"
+      size="small"
       :rowKey="(record) => record.id"
       :columns="columns"
       :data="loadData"
@@ -73,7 +73,7 @@ export default {
       loadData: parameter => {
         this.disabled = true
         if (this.tableHeight == 0) {
-          this.tableHeight = window.innerHeight - 380
+          this.tableHeight = window.innerHeight - 315
         }
         return oosList(Object.assign(parameter, this.queryParam)).then(res => {
           const data = res.data

Някои файлове не бяха показани, защото твърде много файлове са промени