Jelajahi Sumber

Merge commit '06ef00b8a198aed2f9703de21600feb6c763e3d6' into HEAD

gitadmin 3 bulan lalu
induk
melakukan
cbd4909ece
35 mengubah file dengan 5979 tambahan dan 826 penghapusan
  1. 1 1
      public/version.json
  2. 94 0
      src/api/dealerAccount.js
  3. 58 0
      src/api/provinceServiceCenter.js
  4. 111 1
      src/api/reportData.js
  5. 70 0
      src/api/subsidyRule.js
  6. 333 271
      src/config/dealerManagement.js
  7. 211 192
      src/config/report/otherReport.js
  8. 342 317
      src/config/sysSetting.js
  9. 1 1
      src/views/allocationManagement/transferOut/edit.vue
  10. 1 1
      src/views/common/custList.vue
  11. 1 2
      src/views/common/quarterDate.vue
  12. 173 0
      src/views/dealerManagement/dealerAccount/checkAccountModal.vue
  13. 199 0
      src/views/dealerManagement/dealerAccount/checkRecordModal.vue
  14. 185 0
      src/views/dealerManagement/dealerAccount/chooseDepartUserModal.vue
  15. 257 0
      src/views/dealerManagement/dealerAccount/detail.vue
  16. 219 0
      src/views/dealerManagement/dealerAccount/list.vue
  17. 98 0
      src/views/dealerManagement/dealerAccount/verifyModal.vue
  18. 17 11
      src/views/dealerManagement/provincialWarehouseManagement/chooseDealer.vue
  19. 77 0
      src/views/dealerManagement/tireStorageManagement/addDealerModal.vue
  20. 142 0
      src/views/dealerManagement/tireStorageManagement/changeRecordList.vue
  21. 226 0
      src/views/dealerManagement/tireStorageManagement/list.vue
  22. 342 0
      src/views/reportData/tireSubsidyReport/incrementalSubsidyList.vue
  23. 349 0
      src/views/reportData/tireSubsidyReport/incrementalSubsidyYearList.vue
  24. 62 0
      src/views/reportData/tireSubsidyReport/index.vue
  25. 397 0
      src/views/reportData/tireSubsidyReport/serviceFreightDetailList.vue
  26. 339 0
      src/views/reportData/tireSubsidyReport/serviceFreightList.vue
  27. 12 12
      src/views/salesManagement/examineVerify/list.vue
  28. 28 15
      src/views/salesManagement/salesQueryNew/list.vue
  29. 384 0
      src/views/setting/tireSubsidySetting/addSubsidyList.vue
  30. 346 0
      src/views/setting/tireSubsidySetting/addSubsidyModal.vue
  31. 259 0
      src/views/setting/tireSubsidySetting/costAddModal.vue
  32. 321 0
      src/views/setting/tireSubsidySetting/costCollectionList.vue
  33. 280 0
      src/views/setting/tireSubsidySetting/editModal.vue
  34. 42 0
      src/views/setting/tireSubsidySetting/index.vue
  35. 2 2
      vue.config.js

+ 1 - 1
public/version.json

@@ -1,4 +1,4 @@
 {
-    "version": "2.2.53",
+    "version": "2.2.531",
     "message": "发现有新版本发布,确定更新系统?"
 }

+ 94 - 0
src/api/dealerAccount.js

@@ -0,0 +1,94 @@
+import { axios } from '@/utils/request'
+
+// 经销商账户列表   有分页
+export const dealerAccountList = (params) => {
+  const url = `/dealerAccount/queryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('经销商账户列表查询')
+    }
+  })
+}
+//  经销商账户  轮胎补贴金额详情列表   有分页
+export const dealerAccountFlowList = (params) => {
+  const url = `/dealerAccountFlow/queryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('轮胎补贴金额列表查询')
+    }
+  })
+}
+
+// 调账  保存
+export const dealerAccountSubmit = (params) => {
+  return axios({
+    url: '/dealerAccountChange/submit',
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('保存')
+    }
+  })
+}
+
+// 调账记录  列表  有分页
+export const dealerAccountRecordList = (params) => {
+  const url = `/dealerAccountChange/queryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('调账记录列表查询')
+    }
+  })
+}
+//  轮胎补贴金额 导出
+export const dealerAccountFlowExport = (params) => {
+  return axios({
+    url: '/dealerAccountFlow/exportExcel',
+    data: params,
+    method: 'post',
+    responseType: 'blob',
+    headers: {
+      'module': encodeURIComponent('导出')
+    }
+  })
+}
+
+// 经销商账户  列表导出
+export const dealerAccountExport = (params) => {
+  return axios({
+    url: '/dealerAccount/exportExcel',
+    data: params,
+    method: 'post',
+    responseType: 'blob',
+    headers: {
+      'module': encodeURIComponent('导出')
+    }
+  })
+}
+
+// 经销商账户  统计
+export const queryDealerAccount = (params) => {
+  return axios({
+    url: '/dealerAccount/queryDealerAccount',
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('保存')
+    }
+  })
+}

+ 58 - 0
src/api/provinceServiceCenter.js

@@ -0,0 +1,58 @@
+import { axios } from '@/utils/request'
+
+//  轮胎省仓管理列表  有分页
+export const tireStorageList = (params) => {
+  const url = `/provinceServiceCenter/queryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('列表查询')
+    }
+  })
+}
+
+// 选择经销商  列表
+export const chooseDealerList = (params) => {
+  const url = `/provinceServiceCenter/queryDealerPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('列表查询')
+    }
+  })
+}
+
+// 批量添加 经销商
+export const saveBatchDealerList = (params) => {
+  return axios({
+    url: '/provinceServiceCenter/saveBatch',
+    data: params,
+    method: 'post'
+  })
+}
+
+// 轮胎省仓管理   启用禁用
+export const tireStorageEnable = (params) => {
+  return axios({
+    url: '/provinceServiceCenter/updateDisableOrEnable',
+    data: params,
+    method: 'post'
+  })
+}
+
+// 变更记录
+export const changeRecordList = (params) => {
+  return axios({
+    url: '/provinceServiceCenter/changeRecord',
+    data: params,
+    method: 'post'
+  })
+}

+ 111 - 1
src/api/reportData.js

@@ -1316,6 +1316,117 @@ export const tireOutDetailListExport = (params) => {
 /*
 *   轮胎费用报表
 */
+// 服务费运费明细-分页列表
+export const subsidyDetailList = (params) => {
+  const url = `/report/subsidyDetail/queryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('服务费运费明细查询')
+    }
+  })
+}
+// 服务费运费明细-合计
+export const subsidyDetailCount = (params) => {
+  return axios({
+    url: '/report/subsidyDetail/queryCount',
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('服务费运费明细合计查询')
+    }
+  })
+}
+// 服务费运费明细-导出
+export const subsidyDetailExport = (params) => {
+  return axios({
+    url: '/report/subsidyDetail/export',
+    data: params,
+    method: 'post',
+    responseType: 'blob',
+    headers: {
+      'module': encodeURIComponent('服务费运费明细导出')
+    }
+  })
+}
+// 服务费运费-分页列表
+export const subsidyMonthList = (params) => {
+  const url = `/report/subsidyMonth/queryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('服务费运费列表查询')
+    }
+  })
+}
+// 服务费运费-合计
+export const subsidyMonthCount = (params) => {
+  return axios({
+    url: '/report/subsidyMonth/queryCount',
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('服务费运费合计查询')
+    }
+  })
+}
+// 服务费运费-导出
+export const subsidyMonthExport = (params) => {
+  return axios({
+    url: '/report/subsidyMonth/export',
+    data: params,
+    method: 'post',
+    responseType: 'blob',
+    headers: {
+      'module': encodeURIComponent('服务费运费导出')
+    }
+  })
+}
+// 增量补贴-分页列表
+export const subsidyStepList = (params) => {
+  const url = `/report/subsidyStep/queryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('增量补贴-分页列表')
+    }
+  })
+}
+// 增量补贴-合计
+export const subsidyStepCount = (params) => {
+  return axios({
+    url: '/report/subsidyStep/queryCount',
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('增量补贴-合计')
+    }
+  })
+}
+// 增量补贴-导出
+export const subsidyStepExport = (params) => {
+  return axios({
+    url: '/report/subsidyStep/export',
+    data: params,
+    method: 'post',
+    responseType: 'blob',
+    headers: {
+      'module': encodeURIComponent('增量补贴-导出')
+    }
+  })
+}
 
 // 轮胎费用报表   列表
 export const tireFeeReportList = (params) => {
@@ -1331,7 +1442,6 @@ export const tireFeeReportList = (params) => {
     }
   })
 }
-
 // 轮胎费用报表  统计
 export const tireFeeReportCount = (params) => {
   return axios({

+ 70 - 0
src/api/subsidyRule.js

@@ -0,0 +1,70 @@
+import { axios } from '@/utils/request'
+
+// 轮胎补贴配置列表  有分页
+export const tireSubsidyRuleList = (params) => {
+  const url = `/subsidyRule/queryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('列表查询')
+    }
+  })
+}
+
+// 新增  根据客户名称获取运费金额/补贴金额
+export const getSubsidyRuleList = (params) => {
+  return axios({
+    url: '/subsidyRule/getSubsidyRuleList',
+    data: params,
+    method: 'post'
+  })
+}
+
+// 保存
+export const subsidyRuleSave = (params) => {
+  return axios({
+    url: '/subsidyRule/save',
+    data: params,
+    method: 'post'
+  })
+}
+
+// 新增保存  错误提示
+export const createSubsidyRule = (params) => {
+  return axios({
+    url: '/subsidyRule/createSubsidyRule',
+    data: params,
+    method: 'post'
+  })
+}
+
+// 删除
+export const delSubsidyRule = (params) => {
+  return axios({
+    url: '/subsidyRule/delSubsidyRule',
+    data: params,
+    method: 'post'
+  })
+}
+
+// 结束
+export const endSubsidyRule = (params) => {
+  return axios({
+    url: '/subsidyRule/endSubsidyRule',
+    data: params,
+    method: 'post'
+  })
+}
+
+// 编辑
+export const editSubsidyRule = (params) => {
+  return axios({
+    url: '/subsidyRule/edit',
+    data: params,
+    method: 'post'
+  })
+}

+ 333 - 271
src/config/dealerManagement.js

@@ -6,276 +6,338 @@ import {
   PageView
 } from '@/layouts'
 export default {
-        path: '/dealerManagement',
-        redirect: '/dealerManagement/marketingDivisionSet',
-        component: PageView,
-        meta: {
-          title: '经销商管理',
-          icon: 'idcard',
-          permission: 'M_dealerManagement'
+  path: '/dealerManagement',
+  redirect: '/dealerManagement/marketingDivisionSet',
+  component: PageView,
+  meta: {
+    title: '经销商管理',
+    icon: 'idcard',
+    permission: 'M_dealerManagement'
+  },
+  children: [
+    {
+      path: '/dealerManagement/merchantInfoManagement',
+      redirect: '/dealerManagement/merchantInfoManagement/list',
+      name: 'merchantInfoManagement',
+      component: BlankLayout,
+      meta: {
+        title: '经销商资料管理',
+        icon: 'file-text',
+        permission: 'M_merchantInfoManagementList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'merchantInfoManagementList',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/merchantInfoManagement/list.vue'),
+          meta: {
+            title: '经销商资料列表',
+            icon: 'file-text',
+            hidden: true,
+            permission: 'M_merchantInfoManagementList'
+          }
+        },
+        {
+          path: 'add',
+          name: 'merchantInfoManagementAdd',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/merchantInfoManagement/edit.vue'),
+          meta: {
+            title: '新增经销商',
+            icon: 'file-text',
+            hidden: true
+          }
+        },
+        {
+          path: 'edit/:id',
+          name: 'merchantInfoManagementEdit',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/merchantInfoManagement/edit.vue'),
+          meta: {
+            title: '编辑经销商',
+            icon: 'file-text',
+            hidden: true
+          }
+        },
+        {
+          path: 'permissionSetting/:sn/:name/:dealerLevel',
+          name: 'merchantInfoManagementSet',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/merchantInfoManagement/permissionSettingNew.vue'),
+          meta: {
+            title: '经销权设置',
+            icon: 'file-text',
+            replaceTab: true,
+            hidden: true
+          }
         },
-        children: [
-          {
-            path: '/dealerManagement/merchantInfoManagement',
-            redirect: '/dealerManagement/merchantInfoManagement/list',
-            name: 'merchantInfoManagement',
-            component: BlankLayout,
-            meta: {
-              title: '经销商资料管理',
-              icon: 'file-text',
-              permission: 'M_merchantInfoManagementList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'merchantInfoManagementList',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/merchantInfoManagement/list.vue'),
-                meta: {
-                  title: '经销商资料列表',
-                  icon: 'file-text',
-                  hidden: true,
-                  permission: 'M_merchantInfoManagementList'
-                }
-              },
-              {
-                path: 'add',
-                name: 'merchantInfoManagementAdd',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/merchantInfoManagement/edit.vue'),
-                meta: {
-                  title: '新增经销商',
-                  icon: 'file-text',
-                  hidden: true
-                }
-              },
-              {
-                path: 'edit/:id',
-                name: 'merchantInfoManagementEdit',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/merchantInfoManagement/edit.vue'),
-                meta: {
-                  title: '编辑经销商',
-                  icon: 'file-text',
-                  hidden: true
-                }
-              },
-              {
-                path: 'permissionSetting/:sn/:name/:dealerLevel',
-                name: 'merchantInfoManagementSet',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/merchantInfoManagement/permissionSettingNew.vue'),
-                meta: {
-                  title: '经销权设置',
-                  icon: 'file-text',
-                  replaceTab: true,
-                  hidden: true
-                }
-              },
-              {
-                path: 'rebateBinding/:sn',
-                name: 'rebateBinding',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/rebateBinding/list.vue'),
-                meta: {
-                  title: '差价设置',
-                  icon: 'file-text',
-                  replaceTab: true,
-                  hidden: true
-                }
-              }
-            ]
-          },
-          {
-            path: '/dealerManagement/dealerAccountManagement',
-            redirect: '/dealerManagement/dealerAccountManagement/list',
-            name: 'dealerAccountManagement',
-            component: BlankLayout,
-            meta: {
-              title: '经销商账号管理',
-              icon: 'team',
-              permission: 'M_dealerAccountManagementList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'dealerAccountManagementList',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/dealerAccountManagement/list.vue'),
-                meta: {
-                  title: '经销商账号列表',
-                  icon: 'team',
-                  hidden: true,
-                  permission: 'M_dealerAccountManagementList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/promotionRulesManagement/dealerPromotions',
-            redirect: '/promotionRulesManagement/dealerPromotions/list',
-            name: 'dealerPromotionManagement',
-            component: BlankLayout,
-            meta: {
-              title: '经销商促销',
-              icon: 'setting',
-              permission: 'M_dealerPromotionManagementList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'dealerPromotionManagementList',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/promotionRulesManagement/dealerPromotions/list.vue'),
-                meta: {
-                  title: '经销商促销',
-                  icon: 'setting',
-                  hidden: true,
-                  permission: 'M_dealerPromotionManagementList'
-                }
-              },
-              {
-                path: 'detail',
-                name: 'dealerPromotionManagementDetail',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/promotionRulesManagement/dealerPromotions/detail.vue'),
-                meta: {
-                  title: '促销活动详情',
-                  icon: 'thunderbolt',
-                  hidden: true
-                }
-              },
-              {
-                path: 'ruleSet',
-                name: 'dealerPromotionManagementRule',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/promotionRulesManagement/dealerPromotions/detail.vue'),
-                meta: {
-                  title: '促销规则设置',
-                  icon: 'thunderbolt',
-                  replaceTab: true,
-                  hidden: true
-                }
-              }
-            ]
-          },
-          {
-            path: '/dealerManagement/provincialWarehouseManagement',
-            redirect: '/dealerManagement/provincialWarehouseManagement/list',
-            name: 'provincialWarehouse',
-            component: BlankLayout,
-            meta: {
-              title: '省仓管理',
-              icon: 'share-alt',
-              permission: 'M_provincialWarehouse'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'provincialWarehouseList',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/provincialWarehouseManagement/list.vue'),
-                meta: {
-                  title: '省仓管理列表',
-                  icon: 'share-alt',
-                  hidden: true,
-                  permission: 'M_provincialWarehouseList'
-                }
-              },
-              {
-                path: 'relatedDealers/:sn/:name',
-                name: 'relatedDealersList',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/provincialWarehouseManagement/relatedDealersList.vue'),
-                meta: {
-                  title: '省仓关联经销商',
-                  icon: 'share-alt',
-                  hidden: true,
-                  replaceTab: true,
-                  permission: 'M_relatedDealersList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/dealerManagement/marketingDivisionSetNew',
-            redirect: '/dealerManagement/marketingDivisionSetNew/list',
-            name: 'marketingDivisionSetNew',
-            component: BlankLayout,
-            meta: {
-              title: '营销分区设置',
-              icon: 'setting',
-              permission: 'M_marketingDivisionSetList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'marketingDivisionSetNewList',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/marketingDivisionSetNew/list.vue'),
-                meta: {
-                  title: '营销分区列表',
-                  icon: 'setting',
-                  hidden: true,
-                  permission: 'M_marketingDivisionSetList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/dealerManagement/businessOwnerSettings',
-            redirect: '/dealerManagement/businessOwnerSettings/list',
-            name: 'businessOwnerSettings',
-            component: BlankLayout,
-            meta: {
-              title: '数据权限配置',
-              icon: 'stock',
-              permission: 'M_businessOwnerSettings'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'businessOwnerSettingsList',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/businessOwnerSettings/list.vue'),
-                meta: {
-                  title: '数据权限配置列表',
-                  icon: 'stock',
-                  hidden: true,
-                  permission: 'M_businessOwnerSettingsList'
-                }
-              },
-              {
-                path: 'settingsIndex',
-                name: 'categorySet',
-                component: () => import(/* webpackChunkName: "salesManagement" */ '@/views/dealerManagement/businessOwnerSettings/settingsIndex.vue'),
-                meta: {
-                  title: '管辖品类权限设置',
-                  icon: 'user',
-                  hidden: true,
-                  replaceTab: true,
-                  permission: 'M_settingsIndex'
-                }
-              }
-            ]
-          },
-          {
-            path: '/dealerManagement/dealerZoneSearch',
-            redirect: '/dealerManagement/dealerZoneSearch/list',
-            name: 'dealerZoneSearch',
-            component: BlankLayout,
-            meta: {
-              title: '经销商所属分区查询',
-              icon: 'setting',
-              permission: 'M_dealerZoneSearch'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'dealerZoneSearchList',
-                component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/dealerZoneSearch/list.vue'),
-                meta: {
-                  title: '经销商所属分区查询',
-                  icon: 'setting',
-                  hidden: true,
-                  permission: 'M_dealerZoneSearchList'
-                }
-              }
-            ]
+        {
+          path: 'rebateBinding/:sn',
+          name: 'rebateBinding',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/rebateBinding/list.vue'),
+          meta: {
+            title: '差价设置',
+            icon: 'file-text',
+            replaceTab: true,
+            hidden: true
+          }
+        }
+      ]
+    },
+    {
+      path: '/dealerManagement/dealerAccountManagement',
+      redirect: '/dealerManagement/dealerAccountManagement/list',
+      name: 'dealerAccountManagement',
+      component: BlankLayout,
+      meta: {
+        title: '经销商账号管理',
+        icon: 'team',
+        permission: 'M_dealerAccountManagementList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'dealerAccountManagementList',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/dealerAccountManagement/list.vue'),
+          meta: {
+            title: '经销商账号列表',
+            icon: 'team',
+            hidden: true,
+            permission: 'M_dealerAccountManagementList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/dealerManagement/dealerAccount',
+      redirect: '/dealerManagement/dealerAccount/list',
+      name: 'dealerAccount',
+      component: BlankLayout,
+      meta: {
+        title: '经销商账户',
+        icon: 'team',
+        permission: 'M_dealerAccountList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'dealerAccountList',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/dealerAccount/list.vue'),
+          meta: {
+            title: '经销商账户列表',
+            icon: 'team',
+            hidden: true,
+            permission: 'M_dealerAccountList'
+          }
+        },
+        {
+          path: 'detail/:sn/:aSn',
+          name: 'dealerAccountDetail',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/dealerAccount/detail.vue'),
+          meta: {
+            title: '经销商账户明细',
+            icon: 'thunderbolt',
+            replaceTab: true,
+            hidden: true,
+            permission: 'M_dealerAccountDetail'
+          }
+        }
+      ]
+    },
+    {
+      path: '/promotionRulesManagement/dealerPromotions',
+      redirect: '/promotionRulesManagement/dealerPromotions/list',
+      name: 'dealerPromotionManagement',
+      component: BlankLayout,
+      meta: {
+        title: '经销商促销',
+        icon: 'setting',
+        permission: 'M_dealerPromotionManagementList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'dealerPromotionManagementList',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/promotionRulesManagement/dealerPromotions/list.vue'),
+          meta: {
+            title: '经销商促销',
+            icon: 'setting',
+            hidden: true,
+            permission: 'M_dealerPromotionManagementList'
+          }
+        },
+        {
+          path: 'detail',
+          name: 'dealerPromotionManagementDetail',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/promotionRulesManagement/dealerPromotions/detail.vue'),
+          meta: {
+            title: '促销活动详情',
+            icon: 'thunderbolt',
+            hidden: true
+          }
+        },
+        {
+          path: 'ruleSet',
+          name: 'dealerPromotionManagementRule',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/promotionRulesManagement/dealerPromotions/detail.vue'),
+          meta: {
+            title: '促销规则设置',
+            icon: 'thunderbolt',
+            replaceTab: true,
+            hidden: true
+          }
+        }
+      ]
+    },
+    {
+      path: '/dealerManagement/provincialWarehouseManagement',
+      redirect: '/dealerManagement/provincialWarehouseManagement/list',
+      name: 'provincialWarehouse',
+      component: BlankLayout,
+      meta: {
+        title: '省仓管理',
+        icon: 'share-alt',
+        permission: 'M_provincialWarehouse'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'provincialWarehouseList',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/provincialWarehouseManagement/list.vue'),
+          meta: {
+            title: '省仓管理列表',
+            icon: 'share-alt',
+            hidden: true,
+            permission: 'M_provincialWarehouseList'
+          }
+        },
+        {
+          path: 'relatedDealers/:sn/:name',
+          name: 'relatedDealersList',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/provincialWarehouseManagement/relatedDealersList.vue'),
+          meta: {
+            title: '省仓关联经销商',
+            icon: 'share-alt',
+            hidden: true,
+            replaceTab: true,
+            permission: 'M_relatedDealersList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/dealerManagement/tireStorageManagement',
+      redirect: '/dealerManagement/tireStorageManagement/list',
+      name: 'tireSavingWarehouse',
+      component: BlankLayout,
+      meta: {
+        title: '轮胎省仓管理',
+        icon: 'share-alt',
+        permission: 'M_tireSavingWarehouse'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'tireSavingWarehouseList',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/tireStorageManagement/list.vue'),
+          meta: {
+            title: '轮胎省仓管理列表',
+            icon: 'share-alt',
+            hidden: true,
+            permission: 'M_tireSavingWarehouseList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/dealerManagement/marketingDivisionSetNew',
+      redirect: '/dealerManagement/marketingDivisionSetNew/list',
+      name: 'marketingDivisionSetNew',
+      component: BlankLayout,
+      meta: {
+        title: '营销分区设置',
+        icon: 'setting',
+        permission: 'M_marketingDivisionSetList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'marketingDivisionSetNewList',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/marketingDivisionSetNew/list.vue'),
+          meta: {
+            title: '营销分区列表',
+            icon: 'setting',
+            hidden: true,
+            permission: 'M_marketingDivisionSetList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/dealerManagement/businessOwnerSettings',
+      redirect: '/dealerManagement/businessOwnerSettings/list',
+      name: 'businessOwnerSettings',
+      component: BlankLayout,
+      meta: {
+        title: '数据权限配置',
+        icon: 'stock',
+        permission: 'M_businessOwnerSettings'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'businessOwnerSettingsList',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/businessOwnerSettings/list.vue'),
+          meta: {
+            title: '数据权限配置列表',
+            icon: 'stock',
+            hidden: true,
+            permission: 'M_businessOwnerSettingsList'
+          }
+        },
+        {
+          path: 'settingsIndex',
+          name: 'categorySet',
+          component: () => import(/* webpackChunkName: "salesManagement" */ '@/views/dealerManagement/businessOwnerSettings/settingsIndex.vue'),
+          meta: {
+            title: '管辖品类权限设置',
+            icon: 'user',
+            hidden: true,
+            replaceTab: true,
+            permission: 'M_settingsIndex'
+          }
+        }
+      ]
+    },
+    {
+      path: '/dealerManagement/dealerZoneSearch',
+      redirect: '/dealerManagement/dealerZoneSearch/list',
+      name: 'dealerZoneSearch',
+      component: BlankLayout,
+      meta: {
+        title: '经销商所属分区查询',
+        icon: 'setting',
+        permission: 'M_dealerZoneSearch'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'dealerZoneSearchList',
+          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/dealerZoneSearch/list.vue'),
+          meta: {
+            title: '经销商所属分区查询',
+            icon: 'setting',
+            hidden: true,
+            permission: 'M_dealerZoneSearchList'
           }
-        ]
-      }
+        }
+      ]
+    }
+  ]
+}

+ 211 - 192
src/config/report/otherReport.js

@@ -1,195 +1,214 @@
-import {
-  UserLayout,
-  BasicLayout,
-  BlankLayout,
-  BigScreen,
-  PageView
-} from '@/layouts'
+import { UserLayout, BasicLayout, BlankLayout, BigScreen, PageView } from '@/layouts'
 
 export default {
-        path: '/otherReport',
-        redirect: '/reportData/salesOrderTotal',
-        component: PageView,
-        meta: {
-          title: '其它报表',
-          icon: 'project',
-          permission: 'M_otherReport'
-        },
-        children: [
-          {
-            path: '/reportData/tireSalesReport',
-            redirect: '/reportData/tireSalesReport/index',
-            name: 'tireSalesReport',
-            component: BlankLayout,
-            meta: {
-              title: '轮胎统计报表',
-              icon: 'profile',
-              permission: 'M_tireSalesReportList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'index',
-                name: 'tireSalesReportIndex',
-                component: () => import(/* webpackChunkName: "reportData" */ '@/views/reportData/tireSalesReport/index.vue'),
-                meta: {
-                  title: '轮胎统计报表',
-                  icon: 'profile',
-                  hidden: true,
-                  permission: 'M_tireSalesReportList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/reportData/tireFeeReport',
-            redirect: '/reportData/tireFeeReport/index',
-            name: 'tireFeeReport',
-            component: BlankLayout,
-            meta: {
-              title: '轮胎费用报表',
-              icon: 'profile',
-              permission: 'M_tireFeeReportList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'index',
-                name: 'tireFeeReportIndex',
-                component: () => import(/* webpackChunkName: "reportData" */ '@/views/reportData/tireFeeReport/index.vue'),
-                meta: {
-                  title: '轮胎费用报表',
-                  icon: 'profile',
-                  hidden: true,
-                  permission: 'M_tireFeeReportList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/reportData/expenseAccountBearerReport',
-            redirect: '/reportData/expenseAccountBearerReport/list',
-            name: 'expenseAccountBearerReport',
-            component: BlankLayout,
-            meta: {
-              title: '费用汇总报表(按承担方)',
-              icon: 'profile',
-              permission: 'M_expenseAccountBearerReportList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'expenseAccountBearerReportList',
-                component: () => import(/* webpackChunkName: "reportData" */ '@/views/reportData/expenseAccountReport/bearerList.vue'),
-                meta: {
-                  title: '费用汇总报表(按承担方)',
-                  icon: 'profile',
-                  hidden: true,
-                  permission: 'M_expenseAccountBearerReportList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/reportData/expenseAccountCategoryReport',
-            redirect: '/reportData/expenseAccountCategoryReport/list',
-            name: 'expenseAccountCategoryReport',
-            component: BlankLayout,
-            meta: {
-              title: '费用汇总报表(按品类)',
-              icon: 'profile',
-              permission: 'M_expenseAccountCategoryReportList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'expenseAccountCategoryReportList',
-                component: () => import(/* webpackChunkName: "reportData" */ '@/views/reportData/expenseAccountReport/categoryList.vue'),
-                meta: {
-                  title: '费用汇总报表(按品类)',
-                  icon: 'profile',
-                  hidden: true,
-                  permission: 'M_expenseAccountCategoryReportList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/reportData/receivedSendStorageReport',
-            redirect: '/reportData/receivedSendStorageReport/index',
-            name: 'receivedSendStorageReport',
-            component: BlankLayout,
-            meta: {
-              title: '收发存报表',
-              icon: 'profile',
-              permission: 'M_receivedSendStorageReport'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'index',
-                name: 'receivedSendStorageReportIndex',
-                component: () => import(/* webpackChunkName: "reportData" */ '@/views/reportData/receivedSendStorageReport/index.vue'),
-                meta: {
-                  title: '收发存报表',
-                  icon: 'profile',
-                  hidden: true,
-                  permission: 'M_receivedSendStorageReportList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/dataExport/exportSales',
-            redirect: '/dataExport/exportSales/list',
-            name: 'exportSales',
-            component: BlankLayout,
-            meta: {
-              title: '导出销售',
-              icon: 'gold',
-              permission: 'M_exportSales'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'exportSalesList',
-                component: () => import(/* webpackChunkName: "dataExport" */ '@/views/dataExport/exportSales/list.vue'),
-                meta: {
-                  title: '导出销售',
-                  icon: 'gold',
-                  hidden: true,
-                  permission: 'M_exportSales'
-                }
-              }
-            ]
-          },
-          {
-            path: '/dataExport/exportCheck',
-            redirect: '/dataExport/exportCheck/list',
-            name: 'exportCheck',
-            component: BlankLayout,
-            meta: {
-              title: '导出盘点',
-              icon: 'gold',
-              permission: 'M_exportCheck'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'exportCheckList',
-                component: () => import(/* webpackChunkName: "dataExport" */ '@/views/dataExport/exportCheck/list.vue'),
-                meta: {
-                  title: '导出盘点',
-                  icon: 'gold',
-                  hidden: true,
-                  permission: 'M_exportCheck'
-                }
-              }
-            ]
+  path: '/otherReport',
+  redirect: '/reportData/salesOrderTotal',
+  component: PageView,
+  meta: {
+    title: '其它报表',
+    icon: 'project',
+    permission: 'M_otherReport'
+  },
+  children: [
+    {
+      path: '/reportData/tireSalesReport',
+      redirect: '/reportData/tireSalesReport/index',
+      name: 'tireSalesReport',
+      component: BlankLayout,
+      meta: {
+        title: '轮胎统计报表',
+        icon: 'profile',
+        permission: 'M_tireSalesReportList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'index',
+          name: 'tireSalesReportIndex',
+          component: () => import(/* webpackChunkName: "reportData" */ '@/views/reportData/tireSalesReport/index.vue'),
+          meta: {
+            title: '轮胎统计报表',
+            icon: 'profile',
+            hidden: true,
+            permission: 'M_tireSalesReportList'
           }
-        ]
-      }
+        }
+      ]
+    },
+    // {
+    //   path: '/reportData/tireFeeReport',
+    //   redirect: '/reportData/tireFeeReport/index',
+    //   name: 'tireFeeReport',
+    //   component: BlankLayout,
+    //   meta: {
+    //     title: '轮胎费用报表',
+    //     icon: 'profile',
+    //     permission: 'M_tireFeeReportList'
+    //   },
+    //   hideChildrenInMenu: true,
+    //   children: [
+    //     {
+    //       path: 'index',
+    //       name: 'tireFeeReportIndex',
+    //       component: () => import(/* webpackChunkName: "reportData" */ '@/views/reportData/tireFeeReport/index.vue'),
+    //       meta: {
+    //         title: '轮胎费用报表',
+    //         icon: 'profile',
+    //         hidden: true,
+    //         permission: 'M_tireFeeReportList'
+    //       }
+    //     }
+    //   ]
+    // },
+    {
+      path: '/reportData/tireSubsidyReport',
+      redirect: '/reportData/tireSubsidyReport/index',
+      name: 'tireSubsidyReport',
+      component: BlankLayout,
+      meta: {
+        title: '轮胎补贴报表',
+        icon: 'profile',
+        permission: 'M_tireSubsidyList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'index',
+          name: 'tireSubsidyReportIndex',
+          component: () => import(/* webpackChunkName: "reportData" */ '@/views/reportData/tireSubsidyReport/index.vue'),
+          meta: {
+            title: '轮胎补贴报表',
+            icon: 'profile',
+            hidden: true,
+            permission: 'M_tireSubsidyList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/reportData/expenseAccountBearerReport',
+      redirect: '/reportData/expenseAccountBearerReport/list',
+      name: 'expenseAccountBearerReport',
+      component: BlankLayout,
+      meta: {
+        title: '费用汇总报表(按承担方)',
+        icon: 'profile',
+        permission: 'M_expenseAccountBearerReportList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'expenseAccountBearerReportList',
+          component: () => import(/* webpackChunkName: "reportData" */ '@/views/reportData/expenseAccountReport/bearerList.vue'),
+          meta: {
+            title: '费用汇总报表(按承担方)',
+            icon: 'profile',
+            hidden: true,
+            permission: 'M_expenseAccountBearerReportList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/reportData/expenseAccountCategoryReport',
+      redirect: '/reportData/expenseAccountCategoryReport/list',
+      name: 'expenseAccountCategoryReport',
+      component: BlankLayout,
+      meta: {
+        title: '费用汇总报表(按品类)',
+        icon: 'profile',
+        permission: 'M_expenseAccountCategoryReportList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'expenseAccountCategoryReportList',
+          component: () => import(/* webpackChunkName: "reportData" */ '@/views/reportData/expenseAccountReport/categoryList.vue'),
+          meta: {
+            title: '费用汇总报表(按品类)',
+            icon: 'profile',
+            hidden: true,
+            permission: 'M_expenseAccountCategoryReportList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/reportData/receivedSendStorageReport',
+      redirect: '/reportData/receivedSendStorageReport/index',
+      name: 'receivedSendStorageReport',
+      component: BlankLayout,
+      meta: {
+        title: '收发存报表',
+        icon: 'profile',
+        permission: 'M_receivedSendStorageReport'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'index',
+          name: 'receivedSendStorageReportIndex',
+          component: () => import(/* webpackChunkName: "reportData" */ '@/views/reportData/receivedSendStorageReport/index.vue'),
+          meta: {
+            title: '收发存报表',
+            icon: 'profile',
+            hidden: true,
+            permission: 'M_receivedSendStorageReportList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/dataExport/exportSales',
+      redirect: '/dataExport/exportSales/list',
+      name: 'exportSales',
+      component: BlankLayout,
+      meta: {
+        title: '导出销售',
+        icon: 'gold',
+        permission: 'M_exportSales'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'exportSalesList',
+          component: () => import(/* webpackChunkName: "dataExport" */ '@/views/dataExport/exportSales/list.vue'),
+          meta: {
+            title: '导出销售',
+            icon: 'gold',
+            hidden: true,
+            permission: 'M_exportSales'
+          }
+        }
+      ]
+    },
+    {
+      path: '/dataExport/exportCheck',
+      redirect: '/dataExport/exportCheck/list',
+      name: 'exportCheck',
+      component: BlankLayout,
+      meta: {
+        title: '导出盘点',
+        icon: 'gold',
+        permission: 'M_exportCheck'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'exportCheckList',
+          component: () => import(/* webpackChunkName: "dataExport" */ '@/views/dataExport/exportCheck/list.vue'),
+          meta: {
+            title: '导出盘点',
+            icon: 'gold',
+            hidden: true,
+            permission: 'M_exportCheck'
+          }
+        }
+      ]
+    }
+  ]
+}

+ 342 - 317
src/config/sysSetting.js

@@ -7,322 +7,347 @@ import {
 } from '@/layouts'
 
 export default {
-        path: '/setting',
-        redirect: '/basicData/warehouse',
-        component: PageView,
-        meta: {
-          title: '系统设置',
-          icon: 'setting',
-          permission: 'M_systemSet'
+  path: '/setting',
+  redirect: '/basicData/warehouse',
+  component: PageView,
+  meta: {
+    title: '系统设置',
+    icon: 'setting',
+    permission: 'M_systemSet'
+  },
+  children: [
+    {
+      path: '/basicData/warehouse',
+      redirect: '/basicData/warehouse/list',
+      name: 'warehouse',
+      component: BlankLayout,
+      meta: {
+        title: '仓库管理',
+        icon: 'deployment-unit',
+        permission: 'M_warehouseList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: '/basicData/warehouse/list',
+          name: 'warehouseList',
+          component: () => import(/* webpackChunkName: "basicData" */ '@/views/basicData/warehouse/list.vue'),
+          meta: {
+            title: '仓库列表',
+            icon: 'deployment-unit',
+            hidden: true,
+            permission: 'M_warehouseList'
+          }
         },
-        children: [
-          {
-            path: '/basicData/warehouse',
-            redirect: '/basicData/warehouse/list',
-            name: 'warehouse',
-            component: BlankLayout,
-            meta: {
-              title: '仓库管理',
-              icon: 'deployment-unit',
-              permission: 'M_warehouseList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: '/basicData/warehouse/list',
-                name: 'warehouseList',
-                component: () => import(/* webpackChunkName: "basicData" */ '@/views/basicData/warehouse/list.vue'),
-                meta: {
-                  title: '仓库列表',
-                  icon: 'deployment-unit',
-                  hidden: true,
-                  permission: 'M_warehouseList'
-                }
-              },
-              {
-                path: '/basicData/storingLocation/:sn',
-                name: 'storingLocationList',
-                component: () => import(/* webpackChunkName: "setting" */ '@/views/basicData/warehouse/storingLocation/list.vue'),
-                meta: {
-                  title: '仓位列表',
-                  icon: 'deployment-unit',
-                  replaceTab: true,
-                  hidden: true
-                }
-              }
-            ]
-          },
-          {
-            path: '/auth/user',
-            redirect: '/auth/user/list',
-            name: 'powerUser',
-            component: BlankLayout,
-            meta: {
-              title: '用户管理',
-              icon: 'user',
-              permission: 'M_userList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'powerUserList',
-                component: () => import(/* webpackChunkName: "auth" */ '@/views/power/user/userList.vue'),
-                meta: {
-                  title: '用户管理',
-                  icon: 'user',
-                  hidden: true,
-                  permission: 'M_userList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/auth/role',
-            redirect: '/auth/role/list',
-            name: 'powerRole',
-            component: BlankLayout,
-            meta: {
-              title: '角色管理',
-              icon: 'solution',
-              permission: 'M_roleList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'powerRoleList',
-                component: () => import(/* webpackChunkName: "auth" */ '@/views/power/role/roleList.vue'),
-                meta: {
-                  title: '角色管理',
-                  icon: 'solution',
-                  hidden: true,
-                  permission: 'M_roleList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/auth/adminMenus',
-            redirect: '/auth/adminMenus/list',
-            name: 'adminMenus',
-            component: BlankLayout,
-            meta: {
-              title: '菜单管理',
-              icon: 'appstore',
-              permission: 'M_menuList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'adminMenusList',
-                component: () => import(/* webpackChunkName: "auth" */ '@/views/bnSetting/menu/adminMenus.vue'),
-                meta: {
-                  title: '菜单管理',
-                  icon: 'appstore',
-                  hidden: true,
-                  permission: 'M_menuList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/setting/dataDictionary',
-            redirect: '/setting/dataDictionary/list',
-            name: 'dataDictionary',
-            component: BlankLayout,
-            meta: {
-              title: '数据字典管理',
-              icon: 'database',
-              permission: 'M_dataD_lookup'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'powerDD',
-                component: () => import(/* webpackChunkName: "setting" */ '@/views/power/dataDictionary/dataDictionary.vue'),
-                meta: {
-                  title: '数据字典管理',
-                  icon: 'database',
-                  hidden: true,
-                  permission: 'M_dataD_lookup'
-                }
-              }
-            ]
-          },
-          {
-            path: '/setting/OperateJournal',
-            redirect: '/setting/OperateJournal/list',
-            name: 'OperateJournal',
-            component: BlankLayout,
-            meta: {
-              title: '操作日志',
-              icon: 'read',
-              permission: 'M_OperateJournalList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'powerOperateJournal',
-                component: () => import(/* webpackChunkName: "setting" */ '@/views/power/OperateJournal/OperateJournal.vue'),
-                meta: {
-                  title: '操作日志',
-                  icon: 'read',
-                  permission: 'M_OperateJournalList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/setting/noticeManagement',
-            redirect: '/setting/noticeManagement/list',
-            name: 'noticeManagement',
-            component: BlankLayout,
-            meta: {
-              title: '公告管理',
-              icon: 'sketch',
-              permission: 'M_noticeManagementList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'noticeManagementList',
-                component: () => import(/* webpackChunkName: "setting" */ '@/views/setting/noticeManagement/list.vue'),
-                meta: {
-                  title: '公告列表',
-                  icon: 'sketch',
-                  hidden: true,
-                  permission: 'M_noticeManagementList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/setting/bigScreenSet',
-            redirect: '/setting/bigScreenSet/index',
-            name: 'bigScreenSet',
-            component: BlankLayout,
-            meta: {
-              title: '大屏参数设置',
-              icon: 'sketch',
-              permission: 'M_bigScreenSetIndex'
-            },
-            hideChildrenInMenu: true,
-            children: [{
-              path: 'index',
-              name: 'bigScreenSetIndex',
-              component: () => import(/* webpackChunkName: "setting" */'@/views/setting/bigScreenSet/index.vue'),
-              meta: {
-                title: '大屏参数设置',
-                icon: 'sketch',
-                hidden: true,
-                permission: 'M_bigScreenSetIndex'
-              }
-            }]
-          },
-          {
-            path: '/setting/erpMessageManagement',
-            redirect: '/setting/erpMessageManagement/list',
-            name: 'erpMessageManagement',
-            component: BlankLayout,
-            meta: {
-              title: 'ERP数据同步记录',
-              icon: 'sketch',
-              permission: 'M_erpMessageList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'erpMessageManagementList',
-                component: () => import(/* webpackChunkName: "setting" */ '@/views/setting/erpMessageManagement/list.vue'),
-                meta: {
-                  title: 'ERP数据同步列表',
-                  icon: 'sketch',
-                  hidden: true,
-                  permission: 'M_erpMessageList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/setting/erpAllotSettings',
-            redirect: '/setting/erpAllotSettings/list',
-            name: 'erpAllotSettings',
-            component: BlankLayout,
-            meta: {
-              title: '调拨类型管理',
-              icon: 'sketch',
-              permission: 'M_transferTypeManagementList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'erpAllotSettingsList',
-                component: () => import(/* webpackChunkName: "setting" */ '@/views/setting/erpAllotSettings/list.vue'),
-                meta: {
-                  title: '调拨类型管理',
-                  icon: 'sketch',
-                  hidden: true,
-                  permission: 'M_transferTypeManagementList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/setting/dataValidManagement',
-            redirect: '/setting/dataValidManagement/list',
-            name: 'dataValidManagement',
-            component: BlankLayout,
-            meta: {
-              title: '数据校验管理',
-              icon: 'sketch',
-              permission: 'M_dataVailidManageList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'dataValidManagementList',
-                component: () => import(/* webpackChunkName: "setting" */ '@/views/setting/dataValidManagement/list.vue'),
-                meta: {
-                  title: '数据校验管理',
-                  icon: 'sketch',
-                  hidden: true,
-                  permission: 'M_dataVailidManageList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/setting/checkDingTask',
-            redirect: '/setting/checkDingTask/list',
-            name: 'checkDingTask',
-            component: BlankLayout,
-            meta: {
-              title: '钉钉审批',
-              icon: 'sketch',
-              permission: 'M_dingAuditUpdate'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'checkDingTaskList',
-                component: () => import(/* webpackChunkName: "setting" */ '@/views/setting/checkDingTask/list.vue'),
-                meta: {
-                  title: '钉钉审批',
-                  icon: 'sketch',
-                  hidden: true,
-                  permission: 'M_dingAuditUpdate'
-                }
-              }
-            ]
+        {
+          path: '/basicData/storingLocation/:sn',
+          name: 'storingLocationList',
+          component: () => import(/* webpackChunkName: "setting" */ '@/views/basicData/warehouse/storingLocation/list.vue'),
+          meta: {
+            title: '仓位列表',
+            icon: 'deployment-unit',
+            replaceTab: true,
+            hidden: true
+          }
+        }
+      ]
+    },
+    {
+      path: '/auth/user',
+      redirect: '/auth/user/list',
+      name: 'powerUser',
+      component: BlankLayout,
+      meta: {
+        title: '用户管理',
+        icon: 'user',
+        permission: 'M_userList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'powerUserList',
+          component: () => import(/* webpackChunkName: "auth" */ '@/views/power/user/userList.vue'),
+          meta: {
+            title: '用户管理',
+            icon: 'user',
+            hidden: true,
+            permission: 'M_userList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/auth/role',
+      redirect: '/auth/role/list',
+      name: 'powerRole',
+      component: BlankLayout,
+      meta: {
+        title: '角色管理',
+        icon: 'solution',
+        permission: 'M_roleList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'powerRoleList',
+          component: () => import(/* webpackChunkName: "auth" */ '@/views/power/role/roleList.vue'),
+          meta: {
+            title: '角色管理',
+            icon: 'solution',
+            hidden: true,
+            permission: 'M_roleList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/auth/adminMenus',
+      redirect: '/auth/adminMenus/list',
+      name: 'adminMenus',
+      component: BlankLayout,
+      meta: {
+        title: '菜单管理',
+        icon: 'appstore',
+        permission: 'M_menuList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'adminMenusList',
+          component: () => import(/* webpackChunkName: "auth" */ '@/views/bnSetting/menu/adminMenus.vue'),
+          meta: {
+            title: '菜单管理',
+            icon: 'appstore',
+            hidden: true,
+            permission: 'M_menuList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/setting/dataDictionary',
+      redirect: '/setting/dataDictionary/list',
+      name: 'dataDictionary',
+      component: BlankLayout,
+      meta: {
+        title: '数据字典管理',
+        icon: 'database',
+        permission: 'M_dataD_lookup'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'powerDD',
+          component: () => import(/* webpackChunkName: "setting" */ '@/views/power/dataDictionary/dataDictionary.vue'),
+          meta: {
+            title: '数据字典管理',
+            icon: 'database',
+            hidden: true,
+            permission: 'M_dataD_lookup'
+          }
+        }
+      ]
+    },
+    {
+      path: '/setting/OperateJournal',
+      redirect: '/setting/OperateJournal/list',
+      name: 'OperateJournal',
+      component: BlankLayout,
+      meta: {
+        title: '操作日志',
+        icon: 'read',
+        permission: 'M_OperateJournalList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'powerOperateJournal',
+          component: () => import(/* webpackChunkName: "setting" */ '@/views/power/OperateJournal/OperateJournal.vue'),
+          meta: {
+            title: '操作日志',
+            icon: 'read',
+            permission: 'M_OperateJournalList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/setting/noticeManagement',
+      redirect: '/setting/noticeManagement/list',
+      name: 'noticeManagement',
+      component: BlankLayout,
+      meta: {
+        title: '公告管理',
+        icon: 'sketch',
+        permission: 'M_noticeManagementList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'noticeManagementList',
+          component: () => import(/* webpackChunkName: "setting" */ '@/views/setting/noticeManagement/list.vue'),
+          meta: {
+            title: '公告列表',
+            icon: 'sketch',
+            hidden: true,
+            permission: 'M_noticeManagementList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/setting/bigScreenSet',
+      redirect: '/setting/bigScreenSet/index',
+      name: 'bigScreenSet',
+      component: BlankLayout,
+      meta: {
+        title: '大屏参数设置',
+        icon: 'sketch',
+        permission: 'M_bigScreenSetIndex'
+      },
+      hideChildrenInMenu: true,
+      children: [{
+        path: 'index',
+        name: 'bigScreenSetIndex',
+        component: () => import(/* webpackChunkName: "setting" */'@/views/setting/bigScreenSet/index.vue'),
+        meta: {
+          title: '大屏参数设置',
+          icon: 'sketch',
+          hidden: true,
+          permission: 'M_bigScreenSetIndex'
+        }
+      }]
+    },
+    {
+      path: '/setting/erpMessageManagement',
+      redirect: '/setting/erpMessageManagement/list',
+      name: 'erpMessageManagement',
+      component: BlankLayout,
+      meta: {
+        title: 'ERP数据同步记录',
+        icon: 'sketch',
+        permission: 'M_erpMessageList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'erpMessageManagementList',
+          component: () => import(/* webpackChunkName: "setting" */ '@/views/setting/erpMessageManagement/list.vue'),
+          meta: {
+            title: 'ERP数据同步列表',
+            icon: 'sketch',
+            hidden: true,
+            permission: 'M_erpMessageList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/setting/erpAllotSettings',
+      redirect: '/setting/erpAllotSettings/list',
+      name: 'erpAllotSettings',
+      component: BlankLayout,
+      meta: {
+        title: '调拨类型管理',
+        icon: 'sketch',
+        permission: 'M_transferTypeManagementList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'erpAllotSettingsList',
+          component: () => import(/* webpackChunkName: "setting" */ '@/views/setting/erpAllotSettings/list.vue'),
+          meta: {
+            title: '调拨类型管理',
+            icon: 'sketch',
+            hidden: true,
+            permission: 'M_transferTypeManagementList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/setting/dataValidManagement',
+      redirect: '/setting/dataValidManagement/list',
+      name: 'dataValidManagement',
+      component: BlankLayout,
+      meta: {
+        title: '数据校验管理',
+        icon: 'sketch',
+        permission: 'M_dataVailidManageList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'dataValidManagementList',
+          component: () => import(/* webpackChunkName: "setting" */ '@/views/setting/dataValidManagement/list.vue'),
+          meta: {
+            title: '数据校验管理',
+            icon: 'sketch',
+            hidden: true,
+            permission: 'M_dataVailidManageList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/setting/tireSubsidySetting',
+      redirect: '/setting/tireSubsidySetting/index',
+      name: 'tireSubsidySetting',
+      component: BlankLayout,
+      meta: {
+        title: '轮胎补贴配置',
+        icon: 'sketch',
+        permission: 'M_tireSubsidySetting'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'index',
+          name: 'tireSubsidySettingIndex',
+          component: () => import(/* webpackChunkName: "setting" */ '@/views/setting/tireSubsidySetting/index.vue'),
+          meta: {
+            title: '轮胎补贴配置',
+            icon: 'sketch',
+            hidden: true,
+            permission: 'M_tireSubsidySettingIndex'
+          }
+        }
+      ]
+    },
+    {
+      path: '/setting/checkDingTask',
+      redirect: '/setting/checkDingTask/list',
+      name: 'checkDingTask',
+      component: BlankLayout,
+      meta: {
+        title: '钉钉审批',
+        icon: 'sketch',
+        permission: 'M_dingAuditUpdate'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'checkDingTaskList',
+          component: () => import(/* webpackChunkName: "setting" */ '@/views/setting/checkDingTask/list.vue'),
+          meta: {
+            title: '钉钉审批',
+            icon: 'sketch',
+            hidden: true,
+            permission: 'M_dingAuditUpdate'
           }
-        ]
-      }
+        }
+      ]
+    }
+  ]
+}

+ 1 - 1
src/views/allocationManagement/transferOut/edit.vue

@@ -262,7 +262,7 @@
           :data="chooseLoadData"
           :defaultLoadData="false"
           :pagination="{pageSizeOptions: ['20','50','100','200','500']}"
-          :pageSize="20"
+          :pageSize="50"
           :scroll="{ y: 300 }"
           bordered>
           <!-- 售价 -->

+ 1 - 1
src/views/common/custList.vue

@@ -58,7 +58,7 @@ export default {
       type: Array,
       default: function () { return [] }
     },
-    // 默认有权限
+    // 默认有经销商范围权限
     dataAuthFlag: {
       type: [String, Number],
       default: 1

+ 1 - 2
src/views/common/quarterDate.vue

@@ -22,7 +22,7 @@
         :value="currJd"
         @change="changeJd"
         allowClear>
-        <a-select-option v-for="item in quarter" :disabled="item.isToChoose" :value="item.id" :key="item.id">
+        <a-select-option v-for="item in quarter" :value="item.id" :key="item.id">
           {{ item.val }}
         </a-select-option>
       </a-select>
@@ -48,7 +48,6 @@ export default {
     return {
       date: this.value,
       toYears: new Date().getFullYear(), // 今年
-      // quarter: [{ id: 1, val: '一季度' }, { id: 2, val: '二季度' }, { id: 3, val: '三季度' }, { id: 4, val: '四季度' }], // 季度
       currYear: this.toYears,
       currJd: undefined
     }

+ 173 - 0
src/views/dealerManagement/dealerAccount/checkAccountModal.vue

@@ -0,0 +1,173 @@
+<template>
+  <a-modal
+    centered
+    class="checkAccount-modal"
+    :footer="null"
+    :maskClosable="false"
+    title="调账"
+    v-model="isShow"
+    @cancel="isShow=false"
+    :width="700">
+    <div>
+      <a-spin :spinning="spinning" tip="Loading...">
+        <a-form-model
+          id="checkAccountModal-form"
+          ref="ruleForm"
+          :model="form"
+          :rules="rules"
+          :label-col="formItemLayout.labelCol"
+          :wrapper-col="formItemLayout.wrapperCol"
+        >
+          <a-form-model-item label="客户名称">
+            {{ dealerName||'--' }}
+          </a-form-model-item>
+          <a-form-model-item label="调账金额" prop="changeAmount">
+            <a-input-number
+              id="checkAccountModal-changeAmount"
+              v-model="form.changeAmount"
+              style="width:90%;"
+              :max="99999999"
+              :precision="2"
+              placeholder="请输入调账金额"/>
+            <span style="margin-left:10px;">元</span>
+          </a-form-model-item>
+          <a-row :gutter="16">
+            <a-col :span="10">
+              <a-form-model-item label="调账前" :label-col="{span:10}" :wrapper-col="{ span: 10}">
+                {{ (dealerNum||dealerNum==0) ?toThousands(dealerNum):'--' }}
+              </a-form-model-item>
+            </a-col>
+            <a-col :span="12">
+              <a-form-model-item label="调账后" :label-col="{span:10}" :wrapper-col="{ span: 10}">
+                {{ (dealerNum||dealerNum==0) ?((form.changeAmount||form.changeAmount==0)&&form.changeAmount!='-') ?toThousands(dealerNum*1+form.changeAmount*1):'--' :'--' }}
+              </a-form-model-item>
+            </a-col>
+          </a-row>
+          <a-form-model-item label="备注">
+            <a-input
+              id="checkAccountModal-remark"
+              v-model="form.remark"
+              style="width:90%;"
+              :maxLength="50"
+              type="textarea"
+              placeholder="请输入备注(最多50字符)"/>
+          </a-form-model-item>
+        </a-form-model>
+        <div class="btn-cont">
+          <a-button type="primary" id="checkAccountModal-save" @click="handleSubmit">提交</a-button>
+          <a-button id="checkAccountModal-cancel" @click="isShow = false" style="margin-left: 15px;">取消</a-button>
+        </div>
+      </a-spin>
+    </div>
+    <!-- 提交  选择审批人员 -->
+    <chooseDepartUserModal :openModal="openDepartUserModal" @close="openDepartUserModal=false" @submit="handleSave"></chooseDepartUserModal>
+  </a-modal>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import chooseDepartUserModal from './chooseDepartUserModal.vue'
+// 接口
+import { dealerAccountSubmit } from '@/api/dealerAccount'
+export default {
+  name: 'CheckAccountModal',
+  mixins: [commonMixin],
+  components: { chooseDepartUserModal },
+  props: {
+    openModal: { //  弹框显示状态
+      type: Boolean,
+      default: false
+    },
+    dealerName: {
+      type: String,
+      default: ''
+    },
+    dealerNum: {
+      type: [String, Number],
+      default: ''
+    }
+  },
+  data () {
+    return {
+      isShow: this.openModal, //  是否打开弹框
+      spinning: false, // 页面加载状态
+      formItemLayout: {// form表单中label设置
+        labelCol: { span: 4 },
+        wrapperCol: { span: 18 }
+      },
+      // 提交数据
+      form: {
+        dealerSn: undefined, // 客户sn
+        changeAmount: undefined, // 调账金额
+        remark: undefined// 备注
+      },
+      // 必填项判断
+      rules: {
+        changeAmount: [{ required: true, message: '请输入调账金额', trigger: 'blur' },
+          { pattern: /^(?!0$).+/, message: '调账金额不能为0', trigger: 'blur' }
+        ]
+      },
+      openDepartUserModal: false // 打开 选择审批人员 弹窗
+    }
+  },
+  methods: {
+    // 提交  调起选择审批人员
+    handleSubmit () {
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          this.openDepartUserModal = true
+        } else {
+          console.log('error submit!!')
+          return false
+        }
+      })
+    },
+    // 保存
+    handleSave (val) {
+      const _this = this
+      val.dealerSn = this.$route.params.sn
+      _this.form = { ..._this.form, ...val }
+      _this.spinning = true
+      dealerAccountSubmit(_this.form).then(res => {
+        if (res.status == 200) {
+          _this.$emit('ok')
+          _this.isShow = false
+        }
+        _this.spinning = false
+      })
+    },
+    resetFormData () {
+      this.form.dealerSn = undefined
+      this.form.changeAmount = undefined
+      this.form.remark = undefined
+      this.$refs.ruleForm.resetFields()
+    }
+  },
+  watch: {
+    //  父页面传过来的弹框状态
+    openModal (newValue, oldValue) {
+      this.isShow = newValue
+    },
+    //  重定义的弹框状态
+    isShow (newValue, oldValue) {
+      if (!newValue) {
+        this.$emit('close')
+        this.resetFormData()
+      }
+    }
+  }
+}
+</script>
+
+<style lang="less">
+  .checkAccount-modal{
+    .ant-modal-body {
+      padding: 40px 40px 24px;
+    }
+    .btn-cont {
+      text-align: center;
+      margin: 35px 0 30px;
+    }
+  }
+</style>

+ 199 - 0
src/views/dealerManagement/dealerAccount/checkRecordModal.vue

@@ -0,0 +1,199 @@
+<template>
+  <!-- 调账记录 -->
+  <a-drawer
+    :title="'调账记录('+$route.params.name+')'"
+    placement="right"
+    closable
+    :visible="isShow"
+    class="checkRecord-modal"
+    @close="isShow=false"
+    width="78%">
+    <a-spin :spinning="spinning" tip="Loading...">
+      <!-- 搜索条件 -->
+      <div ref="tableSearch" class="table-page-search-wrapper">
+        <a-form layout="inline" id="checkRecordModal-form" @keyup.enter.native="$refs.table.refresh(true)">
+          <a-row :gutter="15">
+            <a-col :md="6" :sm="24">
+              <a-form-model-item label="申请日期">
+                <rangeDate
+                  ref="rangeDate"
+                  :value="time"
+                  id="checkRecordModal-time"
+                  @change="dateChange" />
+              </a-form-model-item>
+            </a-col>
+            <a-col :md="6" :sm="24">
+              <a-form-model-item label="入账类型">
+                <v-select
+                  v-model="queryParam.amountType"
+                  ref="amountType"
+                  id="checkRecordModal-amountType"
+                  code="DEALER_AMOUNT_TYPE"
+                  placeholder="请选择入账类型"
+                  allowClear></v-select>
+              </a-form-model-item>
+            </a-col>
+            <a-col :md="6" :sm="24">
+              <a-form-model-item label="审核状态">
+                <v-select
+                  v-model="queryParam.status"
+                  id="checkRecordModal-status"
+                  code="DEALER_ADJU_ADUIT"
+                  placeholder="请选择审核状态"
+                  allowClear></v-select>
+              </a-form-model-item>
+            </a-col>
+            <a-col :md="4" :sm="24">
+              <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="dealerAccountNewList-refresh">查询</a-button>
+              <a-button style="margin:0 5px" @click="resetSearchForm" :disabled="disabled" id="dealerAccountNewList-reset">重置</a-button>
+            </a-col>
+          </a-row>
+        </a-form>
+      </div>
+      <!-- 列表 -->
+      <s-table
+        class="sTable fixPagination"
+        ref="table"
+        :style="{ height:770+'px' }"
+        size="small"
+        :rowKey="(record) => record.id"
+        :columns="columns"
+        :data="loadData"
+        :pageSize="30"
+        :scroll="{ y: 730 }"
+        :defaultLoadData="false"
+        bordered>
+        <!-- 记账日期   审核通过时显示审核时间 -->
+        <template slot="postingDate" slot-scope="text, record">
+          {{ record.status==='AUDIT_PASS'?record.auditDate:'--' }}
+        </template>
+        <!-- 操作 -->
+        <template slot="action" slot-scope="text, record">
+          <a-button
+            size="small"
+            type="link"
+            v-if="$hasPermissions('B_dealerAccount_edit')"
+            class="button-info"
+            @click="handleCheck(record)"
+            :id="'checkRecordModal-audit-btn'+record.id">审核进度</a-button>
+        </template>
+      </s-table>
+    </a-spin>
+    <!-- 审核进度 -->
+    <verifyModal v-drag :openModal="openVerifyModal" :itemSn="itemSn" @close="openVerifyModal=false"></verifyModal>
+  </a-drawer>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import { STable, VSelect } from '@/components'
+import rangeDate from '@/views/common/rangeDate.vue'
+import verifyModal from './verifyModal.vue'
+// 接口
+import { dealerAccountRecordList } from '@/api/dealerAccount'
+
+export default {
+  name: 'CheckRecordModal',
+  mixins: [commonMixin],
+  components: { STable, VSelect, rangeDate, verifyModal },
+  props: {
+    openModal: { //  弹框显示状态
+      type: Boolean,
+      default: false
+    }
+  },
+  data () {
+    const _this = this
+    return {
+      spinning: false,
+      disabled: false, // 查询、重置按钮是否可操作
+      isShow: this.openModal, //  是否打开弹框
+      time: [], // 申请时间
+      queryParam: {
+        beginDate: '', // 开始时间
+        endDate: '', // 结束时间
+        amountType: undefined, // 入账类型
+        status: undefined// 审核状态
+      },
+      openVerifyModal: false, // 审核进度弹窗
+      itemSn: null, // 当前行sn
+      columns: [
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
+        { title: '申请时间', dataIndex: 'createDate', width: '13%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '审核时间', dataIndex: 'auditDate', width: '13%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '记账日期', width: '13%', align: 'center', scopedSlots: { customRender: 'postingDate' } },
+        { title: '入账类型', dataIndex: 'amountTypeDictValue', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '金额(¥)', dataIndex: 'changeAmount', width: '13%', align: 'right', customRender: text => { return (text || text == 0) ? _this.toThousands(text) : '--' } },
+        { title: '审核状态', dataIndex: 'statusDictValue', width: '13%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '操作', scopedSlots: { customRender: 'action' }, width: '13%', align: 'center' },
+        { title: '备注', dataIndex: 'remark', width: '15%', align: 'center', customRender: function (text) { return text || '--' } }
+      ],
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        this.spinning = true
+        this.queryParam.dealerSn = this.$route.params.sn
+        return dealerAccountRecordList(Object.assign(parameter, this.queryParam)).then(res => {
+          let data
+          if (res.status == 200) {
+            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
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  methods: {
+    // 审核进度
+    handleCheck (row) {
+      this.itemSn = row.accountChangeSn
+      this.openVerifyModal = true
+    },
+    //  日期选择  change
+    dateChange (date) {
+      if (date[0] && date[1]) {
+        this.time = date
+      } else {
+        this.time = []
+      }
+      this.queryParam.beginDate = date[0] || ''
+      this.queryParam.endDate = date[1] || ''
+    },
+    // 重置
+    resetSearchForm () {
+      this.time = []
+      this.queryParam.beginDate = ''
+      this.queryParam.endDate = ''
+      this.queryParam.amountType = undefined
+      this.queryParam.status = undefined
+      this.$refs.rangeDate.resetDate()
+      this.$refs.table.refresh(true)
+    }
+  },
+  watch: {
+    //  父页面传过来的弹框状态
+    openModal (newValue, oldValue) {
+      this.isShow = newValue
+    },
+    //  重定义的弹框状态
+    isShow (newValue, oldValue) {
+      if (!newValue) {
+        this.$emit('close')
+        this.resetSearchForm()
+      } else {
+        this.$nextTick(() => {
+          this.$refs.table.refresh(true)
+        })
+      }
+    }
+  }
+}
+</script>

+ 185 - 0
src/views/dealerManagement/dealerAccount/chooseDepartUserModal.vue

@@ -0,0 +1,185 @@
+<template>
+  <a-modal
+    centered
+    class="departUser-modal"
+    :footer="null"
+    :maskClosable="false"
+    title="选择审批人员"
+    v-model="isShow"
+    @cancel="cancel"
+    :width="700">
+    <a-spin :spinning="spinning" tip="Loading...">
+      <div>
+        <div class="departUser-con">
+          <a-form-model
+            id="departUser-form"
+            ref="ruleForm"
+            :model="form"
+            :rules="rules"
+            :label-col="formItemLayout.labelCol"
+            :wrapper-col="formItemLayout.wrapperCol">
+            <a-form-model-item label="申请人员" prop="applyPersonSn">
+              <employee style="width: 100%;" @change="employeeChange" id="departUser-Employee" v-model="form.applyPersonSn"></employee>
+            </a-form-model-item>
+            <a-form-model-item label="审批人员" prop="approvers">
+              <dingDepartUser
+                ref="departUserApp"
+                @loaded="uploading=false"
+                id="departUser-approvers"
+                :disabled="uploading"
+                v-model="form.approvers"
+                @change="changeApprovers"
+                allowClear
+                placeholder="请选择审批人员"
+              ></dingDepartUser>
+            </a-form-model-item>
+            <a-form-model-item label="抄送人" prop="ccList">
+              <dingDepartUser
+                ref="departUserCc"
+                @loaded="uploading=false"
+                :disabled="uploading"
+                id="departUser-ccList"
+                v-model="form.ccList"
+                allowClear
+                placeholder="请选择抄送人"
+              ></dingDepartUser>
+            </a-form-model-item>
+          </a-form-model>
+        </div>
+        <div class="btn-cont">
+          <a-button type="primary" id="departUser-save" @click="handleSave">确定</a-button>
+          <a-button :loading="uploading" style="margin-left: 15px;" @click="updateUser">刷新人员</a-button>
+          <a-button id="departUser-back" @click="cancel" style="margin-left: 15px;">取消</a-button>
+        </div>
+      </div>
+    </a-spin>
+  </a-modal>
+</template>
+
+<script>
+import { VSelect, Upload } from '@/components'
+import dingDepartUser from '@/views/common/dingDepartUser.js'
+import employee from '@/views/expenseManagement/expenseReimbursement/employee.js'
+import { sign } from 'core-js/fn/number'
+export default {
+  name: 'ChooseDepartUserModal',
+  components: { dingDepartUser, employee, VSelect, Upload },
+  props: {
+    openModal: { //  弹框显示状态
+      type: Boolean,
+      default: false
+    }
+  },
+  data () {
+    return {
+      uploading: false,
+      spinning: false,
+      isShow: this.openModal, //  是否打开弹框
+      formItemLayout: {
+        labelCol: { span: 4 },
+        wrapperCol: { span: 16 }
+      },
+      form: {
+        applyPersonSn: undefined,
+        approvers: [], // 审批人
+        ccList: [] // 抄送人
+      },
+      rules: {
+        applyPersonSn: [
+          { required: true, message: '请选择申请人员', trigger: 'change' }
+        ],
+        approvers: [
+          { required: true, type: 'array', message: '请选择审批人员', trigger: 'change' }
+        ]
+      }
+    }
+  },
+  methods: {
+    // 申请人员
+    employeeChange (v, r) {
+      this.$nextTick(() => {
+        this.$refs.ruleForm.validateField(['applyPersonSn'])
+      })
+    },
+    updateUser () {
+      this.uploading = true
+      this.$refs.departUserApp.updateDeptUser()
+      this.$refs.departUserCc.updateDeptUser()
+    },
+    changeApprovers (value) {
+      this.form.approvers = value
+      this.$refs.ruleForm.clearValidate()
+    },
+    getTreeVal (data) {
+      const ret = []
+      data.map(item => {
+        ret.push(item.value)
+      })
+      return ret.join(',')
+    },
+    // 确定
+    handleSave (e) {
+      e.preventDefault()
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          const form = JSON.parse(JSON.stringify(_this.form))
+          if (form.approvers) {
+            form.approvers = this.getTreeVal(form.approvers)
+          }
+          if (form.ccList) {
+            form.ccList = this.getTreeVal(form.ccList)
+          }
+          this.$emit('submit', form)
+          this.$emit('close')
+        } else {
+          return false
+        }
+      })
+    },
+    getDetail (data) {
+      this.form = Object.assign(this.form, {
+        applyPersonSn: data.applyPersonSn
+      })
+    },
+    resetForm () {
+      this.$nextTick(() => {
+        this.$refs.ruleForm.resetFields()
+      })
+      this.form = {
+        applyPersonSn: undefined,
+        ccList: undefined,
+        approvers: undefined
+      }
+    },
+    cancel () {
+      this.isShow = false
+    }
+  },
+  watch: {
+    //  父页面传过来的弹框状态
+    openModal (newValue, oldValue) {
+      this.isShow = newValue
+    },
+    //  重定义的弹框状态
+    isShow (newValue, oldValue) {
+      if (!newValue) {
+        this.$emit('close')
+        this.resetForm()
+      }
+    }
+  }
+}
+</script>
+
+<style lang="less">
+  .departUser-modal{
+    .ant-modal-body {
+      padding: 30px 40px 24px;
+    }
+    .btn-cont {
+      text-align: center;
+      margin: 35px 0 10px;
+    }
+  }
+</style>

+ 257 - 0
src/views/dealerManagement/dealerAccount/detail.vue

@@ -0,0 +1,257 @@
+<template>
+  <div class="dealerAccountDetail-wrap">
+    <a-spin :spinning="spinning" tip="Loading...">
+      <div>
+        <a-page-header :ghost="false" :backIcon="false" class="header-bar">
+          <!-- 自定义的二级文字标题 -->
+          <template slot="subTitle">
+            <a id="dealerAccountDetail-back-btn" href="javascript:;" @click="handleBack"><a-icon type="left" /> 返回列表</a>
+            <span v-if="totalData" class="subTitle-word text-overflow" style="margin:0 15px;vertical-align: middle;"><span>轮胎补贴金额({{ totalData.dealerEntity?totalData.dealerEntity.dealerName?totalData.dealerEntity.dealerName:'--':'--' }}):¥</span><span style="font-size:20px;" >{{ (totalData.subsidyTire||totalData.subsidyTire==0)?toThousands(totalData.subsidyTire):'--' }}</span></span>
+            <span v-else>--</span>
+            <a-button
+              type="danger"
+              v-if="$hasPermissions('B_checkAccount')"
+              style="margin-right:15px;"
+              ghost
+              id="dealerAccountDetail-checkAccount"
+              @click="openCheckAccountModal = true">调账</a-button>
+            <a-button
+              type="primary"
+              v-if="$hasPermissions('B_checkRecord')"
+              class="button-info"
+              ghost
+              id="dealerAccountDetail-checkRecord"
+              @click="openCheckRecordModal=true">调账记录</a-button>
+          </template>
+        </a-page-header>
+      </div>
+      <a-card size="small" :bordered="false">
+        <div ref="tableSearch" class="table-page-search-wrapper newTableSearchName" >
+          <a-form-model
+            layout="inline"
+            :model="queryParam"
+            id="dealerAccountDetail-form"
+            @keyup.enter.native="$refs.table.refresh(true)">
+            <a-row :gutter="15">
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="时间">
+                  <rangeDate ref="rangeDate" id="dealerAccountDetail-time" :value="time" @change="dateChange" />
+                </a-form-model-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="业务类型">
+                  <v-select
+                    v-model="queryParam.flowBizType"
+                    ref="flowBizType"
+                    id="dealerAccountDetail-flowBizType"
+                    code="FLOW_BIZ_TYPE"
+                    placeholder="请选择业务类型"
+                    allowClear></v-select>
+                </a-form-model-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="入账类型">
+                  <v-select
+                    v-model="queryParam.amountType"
+                    ref="amountType"
+                    id="dealerAccountDetail-amountType"
+                    code="DEALER_AMOUNT_TYPE"
+                    placeholder="请选择入账类型"
+                    allowClear></v-select>
+                </a-form-model-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="dealerAccountDetail-refresh">查询</a-button>
+                <a-button style="margin-left: 5px" @click="resetSearchForm" :disabled="disabled" id="dealerAccountDetail-reset">重置</a-button>
+                <a-button
+                  style="margin-left: 10px"
+                  type="primary"
+                  class="button-warning"
+                  @click="handleExport"
+                  :disabled="disabled"
+                  :loading="exportLoading"
+                  v-if="$hasPermissions('B_dealerAccountDetail_export')"
+                  id="dealerAccountDetail-export">导出</a-button>
+              </a-col>
+            </a-row>
+          </a-form-model>
+        </div>
+        <!-- 列表 -->
+        <s-table
+          class="sTable fixPagination"
+          ref="table"
+          size="small"
+          :rowKey="(record) => record.id"
+          :columns="columns"
+          :data="loadData"
+          :defaultLoadData="false"
+          :pageSize="30"
+          :style="{ height: tableHeight+60+'px' }"
+          :scroll="{ y: tableHeight-10 }"
+          bordered>
+        </s-table>
+      </a-card>
+    </a-spin>
+    <!-- 调账 -->
+    <check-account-modal
+      v-drag
+      ref="checkAccountModal"
+      :dealerName="totalData&&totalData.dealerEntity&&totalData.dealerEntity.dealerName?totalData.dealerEntity.dealerName:''"
+      :dealerNum="totalData&&totalData.subsidyTire?totalData.subsidyTire:''"
+      :openModal="openCheckAccountModal"
+      @ok="$refs.table.refresh(true)"
+      @close="openCheckAccountModal = false" />
+    <!-- 调账记录 -->
+    <check-record-modal v-drag :openModal="openCheckRecordModal" @ok="$refs.table.refresh(true)" @close="openCheckRecordModal = false" />
+  </div>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import { STable, VSelect } from '@/components'
+import rangeDate from '@/views/common/rangeDate.vue'
+import checkAccountModal from './checkAccountModal.vue'
+import checkRecordModal from './checkRecordModal.vue'
+import { hdExportExcel } from '@/libs/exportExcel'
+// 接口
+import { dealerAccountFlowList, dealerAccountFlowExport, queryDealerAccount } from '@/api/dealerAccount'
+export default {
+  name: 'DealerAccountDetail',
+  mixins: [commonMixin],
+  components: { STable, VSelect, rangeDate, checkAccountModal, checkRecordModal },
+  data () {
+    const _this = this
+    return {
+      spinning: false,
+      tableHeight: 0, // 表格高度
+      disabled: false, //  查询、重置按钮是否可操作
+      exportLoading: false, // 导出时加载状态
+      openCheckAccountModal: false, // 打开调账弹窗
+      openCheckRecordModal: false, // 打开调账记录弹窗
+      // 查询参数
+      time: [],
+      queryParam: {
+        beginDate: '', // 开始时间
+        endDate: '', // 结束时间
+        flowBizType: undefined, // 业务类型
+        amountType: undefined // 入账类型
+      },
+      columns: [
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
+        { title: '记账日期', dataIndex: 'accountDate', width: '16%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '业务类型', dataIndex: 'flowBizTypeDictValue', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '入账类型', dataIndex: 'amountTypeDictValue', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '金额(¥)', dataIndex: 'flowAmount', width: '16%', align: 'center', customRender: text => { return (text || text == 0) ? _this.toThousands(text) : '--' } },
+        { title: '备注', dataIndex: 'remark', width: '16%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true }
+      ],
+      totalData: null,
+      loadData: parameter => {
+        this.disabled = true
+        this.spinning = true
+        this.queryParam.dealerSn = this.$route.params.sn
+        const params = Object.assign(parameter, this.queryParam)
+        // 获取列表数据  有分页
+        return dealerAccountFlowList(params).then(res => {
+          let data
+          if (res.status == 200) {
+            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.getCount()
+          }
+          this.disabled = false
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  methods: {
+    //  时间  change
+    dateChange (date) {
+      if (date[0] && date[1]) {
+        this.time = date
+      } else {
+        this.time = []
+      }
+      this.queryParam.beginDate = date[0] || ''
+      this.queryParam.endDate = date[1] || ''
+    },
+    getCount () {
+      queryDealerAccount({ accountSn: this.$route.params.aSn }).then(res => {
+        if (res.status == 200 && res.data) {
+          this.totalData = res.data
+        } else {
+          this.totalData = null
+        }
+      })
+    },
+    // 重置
+    resetSearchForm () {
+      this.queryParam = {
+        beginDate: '', // 开始时间
+        endDate: '', // 结束时间
+        flowBizType: undefined, // 业务类型
+        amountType: undefined // 入账类型
+      }
+      this.time = []
+      this.$refs.rangeDate.resetDate()
+      this.$refs.table.refresh(true)
+    },
+    // 导出
+    handleExport () {
+      const _this = this
+      _this.exportLoading = true
+      _this.spinning = true
+      hdExportExcel(dealerAccountFlowExport, _this.queryParam, '轮胎补贴金额列表', function () {
+        _this.exportLoading = false
+        _this.spinning = false
+      })
+    },
+    //  返回
+    handleBack () {
+      this.$router.push({ name: 'dealerAccountList' })
+    },
+    // 初始化
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+      _this.$refs.table.refresh(true)
+    },
+    // 计算列表高度
+    setTableH () {
+      const searchHeight = this.$refs.tableSearch.offsetHeight
+      this.tableHeight = window.innerHeight - searchHeight - 240
+    }
+  },
+  watch: {
+    '$store.state.app.winHeight' (newValue, oldValue) { //  窗口变更时,需同时更改表格高度
+      this.setTableH()
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+    }
+  },
+  activated () {
+    // 如果是新页签打开,则重置当前页面
+    if (this.$store.state.app.isNewTab) {
+      this.pageInit()
+    }
+    // 仅刷新列表,不重置页面
+    if (this.$store.state.app.updateList) {
+      this.pageInit()
+    }
+  },
+  beforeRouteEnter (to, from, next) {
+    next(vm => {})
+  }
+}
+</script>

+ 219 - 0
src/views/dealerManagement/dealerAccount/list.vue

@@ -0,0 +1,219 @@
+<template>
+  <div>
+    <a-card size="small" :bordered="false" class="dealerAccountNewList-wrap searchBoxNormal">
+      <!-- 搜索条件 -->
+      <div ref="tableSearch" class="table-page-search-wrapper">
+        <a-form layout="inline" id="dealerAccountNewList-form" @keyup.enter.native="$refs.table.refresh(true)">
+          <a-row :gutter="15">
+            <a-col :md="5" :sm="24">
+              <a-form-item label="经销商名称">
+                <custList ref="custList" dataAuthFlag="0" id="dealerAccountNewList-dealerName" placeholder="请输入经销商名称搜索" @change="custChange"></custList>
+              </a-form-item>
+            </a-col>
+            <a-col :md="5" :sm="24">
+              <a-form-item label="区域">
+                <subarea id="dealerAccountNewList-subarea" ref="subarea" @change="subareaChange"></subarea>
+              </a-form-item>
+            </a-col>
+            <a-col :md="5" :sm="24">
+              <a-form-item label="商户级别">
+                <v-select code="DEALER_LEVEL" id="dealerAccountNewList-dealerLevel" v-model="queryParam.dealerLevel" allowClear placeholder="请选择商户级别"></v-select>
+              </a-form-item>
+            </a-col>
+            <a-col :md="5" :sm="24">
+              <a-form-item label="商户类型">
+                <dealerType id="dealerAccountNewList-dealerType" changeOnSelect v-model="dealerType" @change="getDealerType" allowClear></dealertype>
+              </a-form-item>
+            </a-col>
+            <a-col :md="4" :sm="24">
+              <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="dealerAccountNewList-refresh">查询</a-button>
+              <a-button style="margin:0 5px;" @click="resetSearchForm" :disabled="disabled" id="dealerAccountNewList-reset">重置</a-button>
+              <a-button
+                type="primary"
+                v-if="$hasPermissions('B_dealerAccountExport')"
+                class="button-warning"
+                @click="handleExport"
+                :disabled="disabled"
+                :loading="exportLoading"
+                id="dealerAccountNewList-export">导出</a-button>
+            </a-col>
+          </a-row>
+        </a-form>
+      </div>
+    </a-card>
+    <a-card size="small" :bordered="false">
+      <a-spin :spinning="spinning" tip="Loading...">
+        <!-- 列表 -->
+        <s-table
+          class="sTable fixPagination"
+          ref="table"
+          :style="{ height: tableHeight+70+'px' }"
+          size="small"
+          :rowKey="(record) => record.id"
+          :columns="columns"
+          :data="loadData"
+          :pageSize="30"
+          :scroll="{ y: tableHeight }"
+          :defaultLoadData="false"
+          bordered>
+          <!-- 轮胎补贴金额 -->
+          <template slot="moneyNum" slot-scope="text, record">
+            <span v-if="$hasPermissions('M_dealerAccountDetail')&&(record.subsidyTire||record.subsidyTire==0)" :id="'dealerAccountNewList-tireMoney'+record.id" class="link-bule" @click="handleDetail(record)">{{ toThousands(record.subsidyTire) }}</span>
+            <span v-else>{{ toThousands(record.subsidyTire) }}</span>
+          </template>
+          <!-- 商户类型 -->
+          <template slot="dealerType" slot-scope="text, record">
+            {{ record.dealerTypeName1 }}{{ record.dealerTypeName1?'>':'' }}{{ record.dealerTypeName2 }}
+          </template>
+        </s-table>
+      </a-spin>
+    </a-card>
+
+  </div>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import { STable, VSelect } from '@/components'
+import subarea from '@/views/common/subarea.js'
+import dealerType from '@/views/common/dealerType.js'
+import custList from '@/views/common/custList.vue'
+import { hdExportExcel } from '@/libs/exportExcel'
+// 接口
+import { dealerAccountList, dealerAccountExport } from '@/api/dealerAccount'
+export default {
+  name: 'DealerAccountNewList',
+  mixins: [commonMixin],
+  components: { STable, VSelect, custList, subarea, dealerType },
+  data () {
+    return {
+      spinning: false,
+      tableHeight: 0, // 表格高度
+      disabled: false, //  查询、重置按钮是否可操作
+      exportLoading: false, // 导出加载状态
+      queryParam: { //  查询条件
+        dealerSn: undefined, // 经销商sn
+        subareaArea: {
+          subareaSn: undefined, //  区域
+          subareaAreaSn: undefined // 分区
+        },
+        dealerLevel: undefined, // 商户级别
+        dealerType1: undefined, //  商户类型
+        dealerType2: undefined //  商户类型
+      },
+      dealerType: [], // 所选商户类型 列表
+      columns: [
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
+        { title: '经销商名称', dataIndex: 'dealerEntity.dealerName', width: '20%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '轮胎补贴金额(¥)', scopedSlots: { customRender: 'moneyNum' }, width: '12%', align: 'right' },
+        { title: '区域', dataIndex: 'subareaArea.subareaName', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '分区', dataIndex: 'subareaArea.subareaAreaName', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '商户级别', dataIndex: 'dealerEntity.dealerLevelDictValue', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '商户类型', dataIndex: 'dealerType', scopedSlots: { customRender: 'dealerType' }, width: '16%', align: 'center', ellipsis: true },
+        { title: '创建时间', dataIndex: 'createDate', width: '10%', align: 'center', customRender: function (text) { return text || '--' } }
+      ],
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        this.spinning = true
+        return dealerAccountList(Object.assign(parameter, this.queryParam)).then(res => {
+          let data
+          if (res.status == 200) {
+            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
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  methods: {
+    // 客户名称 change
+    custChange (val) {
+      this.queryParam.dealerSn = val.key
+    },
+    // 区域  change
+    subareaChange (val) {
+      this.queryParam.subareaArea.subareaSn = val[0] ? val[0] : undefined
+      this.queryParam.subareaArea.subareaAreaSn = val[1] ? val[1] : undefined
+    },
+    // 商户类型 change
+    getDealerType (v, o) {
+      this.queryParam.dealerType1 = v[0]
+      this.queryParam.dealerType2 = v[1]
+    },
+    // 轮胎补贴金额  点击跳转详情页
+    handleDetail (row) {
+      this.$router.push({ name: 'dealerAccountDetail', params: { sn: row.dealerSn, aSn: row.accountSn } })
+    },
+    //  重置
+    resetSearchForm () {
+      this.queryParam.dealerSn = undefined
+      this.queryParam.subareaArea.subareaSn = undefined
+      this.queryParam.subareaArea.subareaAreaSn = undefined
+      this.queryParam.dealerLevel = undefined
+      this.queryParam.dealerType1 = undefined
+      this.queryParam.dealerType2 = undefined
+      this.dealerType = []
+      this.$refs.custList.resetForm()
+      this.$refs.subarea.clearData()
+      this.$refs.table.refresh(true)
+    },
+    //  导出
+    handleExport () {
+      const _this = this
+      // _this.$store.state.app.curActionPermission = 'B_sales_export'
+      _this.exportLoading = true
+      _this.spinning = true
+      hdExportExcel(dealerAccountExport, _this.queryParam, '经销商账户列表', function () {
+        _this.exportLoading = false
+        _this.spinning = false
+        _this.showExport = true
+        // _this.$store.state.app.curActionPermission = ''
+      })
+    },
+    // 初始化
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
+    // 计算表格高度
+    setTableH () {
+      const tableSearchH = this.$refs.tableSearch.offsetHeight
+      this.tableHeight = window.innerHeight - tableSearchH - 195
+    }
+  },
+  watch: {
+    '$store.state.app.winHeight' (newValue, oldValue) { //  窗口变更时,需同时更改表格高度
+      this.setTableH()
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
+  activated () {
+    // 如果是新页签打开,则重置当前页面
+    if (this.$store.state.app.isNewTab) {
+      this.pageInit()
+      this.resetSearchForm()
+    }
+    // 仅刷新列表,不重置页面
+    if (this.$store.state.app.updateList) {
+      this.$refs.table.refresh()
+      this.pageInit()
+    }
+  }
+}
+</script>

+ 98 - 0
src/views/dealerManagement/dealerAccount/verifyModal.vue

@@ -0,0 +1,98 @@
+<template>
+  <a-modal
+    centered
+    :footer="null"
+    :maskClosable="false"
+    title="调账审核进度"
+    v-model="isShow"
+    @cancel="isShow=false"
+    width="50%">
+    <p>说明:以下信息来自钉钉</p>
+    <a-spin :spinning="spinning" tip="Loading...">
+      <s-table
+        class="sTable fixPagination"
+        ref="table"
+        size="small"
+        :rowKey="(record) => record.id"
+        :columns="columns"
+        :data="loadData"
+        :scroll="{ y: 500 }"
+        :showPagination="false"
+        :defaultLoadData="false"
+        bordered>
+      </s-table>
+    </a-spin>
+  </a-modal>
+</template>
+
+<script>
+import { STable } from '@/components'
+import { getProcessInstance } from '@/api/expenseManagement'
+export default {
+  name: 'VerifyModal',
+  components: { STable },
+  props: {
+    openModal: {
+      type: Boolean,
+      default: false
+    },
+    itemSn: { // sn
+      type: [Number, String],
+      default: ''
+    }
+  },
+  data () {
+    return {
+      spinning: false,
+      isShow: this.openModal,
+      columns: [{ title: '序号', dataIndex: 'no', width: '8%', align: 'center' },
+        { title: '人员姓名', width: '12%', dataIndex: 'approvalName', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '人员类型', dataIndex: 'processTaskType', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '状态', dataIndex: 'approvalStateDictValue', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '审批意见', dataIndex: 'approvalOpinion', width: '20%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '附件', dataIndex: 'attachmentNames', width: '20%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '操作时间', dataIndex: 'approvalTime', width: '20%', align: 'center', customRender: function (text) { return text || '--' } }],
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.spinning = true
+        delete parameter.tableId
+        delete parameter.index
+        return getProcessInstance({ businessType: 'DEALER_ACCOUNT_CHANGE', businessSn: this.itemSn }).then(res => {
+          let data
+          if (res.status == 200) {
+            data = res.data ? res.data[0] ? res.data[0].opinionList ? res.data[0].opinionList : [] : [] : []
+            const no = 0
+            for (var i = 0; i < data.length; i++) {
+              data[i].no = no + i + 1
+            }
+            this.disabled = false
+          }
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  watch: {
+    openModal (nVal, oVal) {
+      this.isShow = nVal
+    },
+    isShow (nVal, oVal) {
+      if (!nVal) {
+        this.$emit('close')
+        this.$refs.table.clearTable()
+      } else {
+        this.$nextTick(() => {
+          this.$refs.table.refresh()
+        })
+      }
+    },
+    itemSn (nVal, oVal) {
+
+    }
+  }
+}
+</script>
+
+<style>
+</style>

+ 17 - 11
src/views/dealerManagement/provincialWarehouseManagement/chooseDealer.vue

@@ -73,6 +73,7 @@ import subarea from '@/views/common/subarea.js'
 import dealerType from '@/views/common/dealerType.js'
 // 组件
 import { dealerQueryList } from '@/api/dealer'
+import { chooseDealerList } from '@/api/provinceServiceCenter'
 export default {
   name: 'ChooseDealer',
   mixins: [commonMixin],
@@ -110,21 +111,24 @@ export default {
       },
       rowSelectionInfo: null, // 已选列表数据
       columns: [
-        { title: '经销商名称', dataIndex: 'dealerName', width: '30%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '商户别名', dataIndex: 'dealerAlias', align: 'left', width: '30%', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '商户类型', dataIndex: 'dealerTypeName', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '商户级别', dataIndex: 'dealerLevelDictValue', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '地区', scopedSlots: { customRender: 'addressInfo' }, width: '30%', align: 'center', ellipsis: true },
-        { title: '所在区域', dataIndex: 'subareaArea.subareaName', width: '20%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '所在分区', dataIndex: 'subareaArea.subareaAreaName', width: '20%', align: 'center', customRender: function (text) { return text || '--' } }
+        { title: '经销商名称', dataIndex: 'dealerName', width: '26%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '商户别名', dataIndex: 'dealerAlias', align: 'left', width: '26%', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '商户类型', dataIndex: 'dealerTypeName', width: '18%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '商户级别', dataIndex: 'dealerLevelDictValue', width: '18%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '地区', scopedSlots: { customRender: 'addressInfo' }, width: '28%', align: 'center', ellipsis: true },
+        { title: '所在区域', dataIndex: 'subareaArea.subareaName', width: '18%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '所在分区', dataIndex: 'subareaArea.subareaAreaName', width: '18%', align: 'center', customRender: function (text) { return text || '--' } }
       ],
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
         this.spinning = true
-        this.queryParam.notDealerSn = this.itemSn
-        this.queryParam.pageType = this.pageType
-        return dealerQueryList(Object.assign(parameter, this.queryParam)).then(res => {
+        if (this.pageType === 'dealerPromotion') {
+          this.queryParam.notDealerSn = this.itemSn
+          this.queryParam.pageType = this.pageType
+        }
+        const ajaxName = this.pageType === 'dealerPromotion' ? dealerQueryList : chooseDealerList
+        return ajaxName(Object.assign(parameter, this.queryParam)).then(res => {
           let data
           if (res.status == 200) {
             data = res.data
@@ -210,8 +214,10 @@ export default {
     },
     // 初始化
     pageInit (data) {
-      this.setTableH()
       this.resetSearchForm()
+      this.$nextTick(() => {
+        this.setTableH()
+      })
     },
     // 计算表格高度
     setTableH () {

+ 77 - 0
src/views/dealerManagement/tireStorageManagement/addDealerModal.vue

@@ -0,0 +1,77 @@
+<template>
+  <!-- 关联经销商 -->
+  <a-drawer
+    title="选择经销商"
+    placement="right"
+    closable
+    :visible="isShow"
+    class="lookUpCustomers-modal"
+    @close="isShow=false"
+    width="72%">
+    <div class="dealerModalCon">
+      <chooseDealer ref="dealerChoose" pageType="tireStorage" @plAdd="handleAddDealer"></chooseDealer>
+    </div>
+  </a-drawer>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import chooseDealer from '@/views/dealerManagement/provincialWarehouseManagement/chooseDealer.vue'
+import { saveBatchDealerList } from '@/api/provinceServiceCenter'
+
+export default {
+  name: 'AddDealerModal',
+  mixins: [commonMixin],
+  components: { chooseDealer },
+  props: {
+    openModal: { //  弹框显示状态
+      type: Boolean,
+      default: false
+    }
+  },
+  data () {
+    return {
+      isShow: this.openModal //  是否打开弹框
+    }
+  },
+  methods: {
+    handleAddDealer (list) {
+      const newList = list.map(item => {
+        return {
+          dealerSn: item.dealerSn,
+          dealerName: item.dealerName,
+          dealerLevel: item.dealerLevel
+        }
+      })
+      this.spinning = true
+      saveBatchDealerList(newList).then(res => {
+        if (res.status == 200) {
+          this.$message.success(res.message)
+        }
+        this.spinning = false
+        this.$emit('ok')
+        this.isShow = false
+      })
+    }
+  },
+  watch: {
+    //  父页面传过来的弹框状态
+    openModal (newValue, oldValue) {
+      this.isShow = newValue
+    },
+    //  重定义的弹框状态
+    isShow (newValue, oldValue) {
+      if (!newValue) {
+        this.$refs.dealerChoose.resetSearchForm()
+        this.$refs.dealerChoose.clearSelect()
+        this.$emit('close')
+      } else {
+        this.$nextTick(() => {
+          this.$refs.dealerChoose.pageInit()
+        })
+      }
+    }
+  }
+}
+</script>

+ 142 - 0
src/views/dealerManagement/tireStorageManagement/changeRecordList.vue

@@ -0,0 +1,142 @@
+<template>
+  <a-modal
+    centered
+    class="addProvincialWarehouse-modal"
+    :footer="null"
+    :maskClosable="false"
+    :title="modalTit"
+    v-model="isShow"
+    @cancel="isShow=false"
+    :width="700">
+    <a-spin :spinning="spinning" tip="Loading...">
+      <s-table
+        class="sTable fixPagination"
+        ref="table"
+        :style="{ maxHeight: 300+'px' }"
+        size="small"
+        :rowKey="(record) => record.id"
+        :columns="columns"
+        :data="loadData"
+        :showPagination="false"
+        :scroll="{ y: 270 }"
+        :defaultLoadData="false"
+        bordered>
+      </s-table>
+    </a-spin>
+  </a-modal>
+</template>
+
+<script>
+// 组件
+import { STable } from '@/components'
+// 接口
+import { changeRecordList } from '@/api/provinceServiceCenter'
+export default {
+  name: 'AddProvincialWarehouseModal',
+  components: { STable },
+  props: {
+    openModal: { //  弹框显示状态
+      type: Boolean,
+      default: false
+    }
+  },
+  data () {
+    return {
+      spinning: false,
+      isShow: this.openModal, //  是否打开弹框
+      modalTit: '变更记录', // 标题
+      dealerSn: null, // 经销商sn
+      // 表格列表
+      columns: [
+        { title: '序号', dataIndex: 'no', width: '6%', align: 'center' },
+        { title: '启用时间', dataIndex: 'useDate', width: '47%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '禁用时间', dataIndex: 'disableDate', width: '47%', align: 'center', customRender: function (text) { return text || '--' } }
+      ],
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        this.spinning = true
+        return changeRecordList(Object.assign(parameter, { dealerSn: this.dealerSn })).then(res => {
+          let data
+          if (res.status == 200) {
+            data = res.data
+            // 计算表格序号
+            for (var i = 0; i < data.length; i++) {
+              data[i].no = i + 1
+            }
+            this.disabled = false
+          }
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  methods: {
+    // 初始化
+    pageInit (itemObj) {
+      const _this = this
+      _this.dealerSn = itemObj.dealerSn
+      _this.modalTit = '变更记录(' + itemObj.dealerName + ')'
+      _this.$nextTick(() => {
+        _this.$refs.table.refresh(true)
+      })
+    }
+  },
+  watch: {
+    //  父页面传过来的弹框状态
+    openModal (newValue, oldValue) {
+      this.isShow = newValue
+    },
+    //  重定义的弹框状态
+    isShow (newValue, oldValue) {
+      if (!newValue) {
+        this.$emit('close')
+      }
+    }
+  }
+}
+</script>
+
+<style lang="less">
+  .addProvincialWarehouse-modal{
+    .ant-modal-body {
+      padding: 40px 40px 24px;
+    }
+    .btn-cont {
+      text-align: center;
+      margin: 35px 0 10px;
+    }
+    .tree-node{
+      height: 300px;
+      overflow: auto;
+      .tree-box{
+        .tree-parent{
+          display: flex;
+          align-items: center;
+          border-bottom: 1px solid #eee;
+          padding: 0 10px;
+          > span{
+            margin:0 5px;
+            &:first-child{
+              flex-grow: 1;
+            }
+            &:last-child{
+              cursor: pointer;
+            }
+          }
+        }
+        .tree-child{
+          padding: 10px 10px 10px 35px;
+          display: flex;
+          align-items: center;
+          flex-wrap:wrap ;
+          > div{
+            margin:0 5px;
+          }
+        }
+      }
+
+    }
+  }
+</style>

+ 226 - 0
src/views/dealerManagement/tireStorageManagement/list.vue

@@ -0,0 +1,226 @@
+<template>
+  <div>
+    <a-card size="small" :bordered="false" class="tireStorageManagement-wrap searchBoxNormal">
+      <!-- 搜索条件 -->
+      <div ref="tableSearch" class="table-page-search-wrapper">
+        <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)">
+          <a-row :gutter="15">
+            <a-col :md="6" :sm="24">
+              <a-form-item label="轮胎省仓名称">
+                <custList dataAuthFlag="0" ref="provinceDealerList" id="tireStorageManagement-provinceDealerName" placeholder="请输入轮胎省仓名称" @change="custProvinceChange"></custList>
+              </a-form-item>
+            </a-col>
+            <a-col :md="6" :sm="24">
+              <a-form-item label="轮胎省仓状态">
+                <v-select code="ENABLE_FLAG" id="tireStorageManagement-status" v-model="queryParam.status" allowClear placeholder="请选择轮胎省仓状态"></v-select>
+              </a-form-item>
+            </a-col>
+            <a-col :md="6" :sm="24">
+              <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="tireStorageManagement-refresh">查询</a-button>
+              <a-button style="margin-left: 5px" @click="resetSearchForm" :disabled="disabled" id="tireStorageManagement-reset">重置</a-button>
+            </a-col>
+          </a-row>
+        </a-form>
+      </div>
+    </a-card>
+    <a-card size="small" :bordered="false">
+      <a-spin :spinning="spinning" tip="Loading...">
+        <!-- 操作按钮 -->
+        <div class="table-operator" v-if="$hasPermissions('B_tireSavingWarehouse_add')">
+          <a-button id="tireStorageManagement-add" type="primary" @click="openAddModal = true">新增</a-button>
+        </div>
+        <!-- 列表 -->
+        <s-table
+          class="sTable fixPagination"
+          ref="table"
+          :style="{ height: tableHeight+70+'px' }"
+          size="small"
+          :rowKey="(record) => record.id"
+          :columns="columns"
+          :data="loadData"
+          :pageSize="30"
+          :scroll="{ y: tableHeight }"
+          :defaultLoadData="false"
+          bordered>
+          <!-- 省仓状态 -->
+          <template slot="tireStatus" slot-scope="text, record">
+            <a-switch
+              :id="'tireStorageManagement-enableFlag'+record.id"
+              v-if="$hasPermissions('B_tireSavingWarehouse_enable')"
+              checkedChildren="启用"
+              unCheckedChildren="禁用"
+              @change="openStatusModal(record)"
+              :checked="record.status == 1 ? true : false" />
+            <span v-else :style="{color:(record.status==1?'#00aa00':'#999')}"> {{ record.status==1? '已启用': '已禁用' }} </span>
+          </template>
+          <!-- 操作 -->
+          <template slot="action" slot-scope="text, record">
+            <a-button
+              size="small"
+              type="link"
+              v-if="$hasPermissions('B_tireSavingWarehouse_record')"
+              class="button-info"
+              @click="handleChangeRecord(record)"
+              :id="'tireStorageManagement-record-btn'+record.id">变更记录</a-button>
+            <span v-else>--</span>
+          </template>
+        </s-table>
+      </a-spin>
+    </a-card>
+    <!-- 新增/编辑 -->
+    <add-dealer-modal v-drag :openModal="openAddModal" @ok="$refs.table.refresh(true)" @close="openAddModal = false" />
+    <!-- 变更记录 -->
+    <change-record-list ref="changeRecord" v-drag :openModal="openRecordModal" @close="openRecordModal=false"></change-record-list>
+  </div>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import { STable, VSelect } from '@/components'
+import addDealerModal from './addDealerModal.vue'
+import changeRecordList from './changeRecordList.vue'
+import custList from '@/views/common/custList.vue'
+// 接口
+import { tireStorageList, tireStorageEnable } from '@/api/provinceServiceCenter'
+export default {
+  name: 'TireStorageManagement',
+  mixins: [commonMixin],
+  components: { STable, VSelect, addDealerModal, changeRecordList, custList },
+  data () {
+    return {
+      spinning: false,
+      tableHeight: 0, // 列表高度
+      disabled: false, //  查询、重置按钮是否可操作
+      openAddModal: false, //  新增 弹框
+      openRecordModal: false, // 变更记录 弹窗
+      //  查询条件
+      queryParam: {
+        dealerEntity: {
+          dealerName: undefined// 轮胎省仓名称
+        },
+        dealerSn: undefined, // 轮胎省仓sn
+        status: undefined// 轮胎省仓状态
+      },
+      columns: [
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '区域', dataIndex: 'subareaArea.subareaName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '分区', dataIndex: 'subareaArea.subareaAreaName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '轮胎省仓名称', dataIndex: 'dealerEntity.dealerName', width: '18%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '轮胎省仓状态', scopedSlots: { customRender: 'tireStatus' }, width: '9%', align: 'center' },
+        { title: '操作', scopedSlots: { customRender: 'action' }, width: '11%', align: 'center' }
+      ],
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        this.spinning = true
+        return tireStorageList(Object.assign(parameter, this.queryParam)).then(res => {
+          let data
+          if (res.status == 200) {
+            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
+          }
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  methods: {
+    // 变更记录
+    handleChangeRecord (row) {
+      this.$refs.changeRecord.pageInit({ dealerSn: row.dealerSn, dealerName: row.dealerEntity.dealerName })
+      this.openRecordModal = true
+    },
+    // 轮胎省仓客户名称 change
+    custProvinceChange (val) {
+      this.queryParam.dealerEntity.dealerName = val.name
+      this.queryParam.dealerSn = val.key
+    },
+    //  重置
+    resetSearchForm () {
+      this.queryParam.dealerEntity.dealerName = undefined
+      this.queryParam.dealerSn = undefined
+      this.queryParam.status = undefined
+      this.$refs.provinceDealerList.resetForm()
+      this.$refs.table.refresh(true)
+    },
+    // 打开启用 禁用 弹窗
+    openStatusModal (record) {
+      const _this = this
+      if (record.status == 1) {
+        this.$confirm({
+          title: '提示',
+          content: '禁用后该经销商不是轮胎省仓,确定禁用轮胎省仓吗?',
+          centered: true,
+          onOk () {
+            const ajaxData = {
+              serviceCenterSn: record.serviceCenterSn,
+              status: '0'
+            }
+            _this.changeStatus(ajaxData)
+          }
+        })
+      } else {
+        const params = {
+          serviceCenterSn: record.serviceCenterSn,
+          status: '1'
+        }
+        _this.changeStatus(params)
+      }
+    },
+    // 启用 禁用
+    changeStatus (params) {
+      this.spinning = true
+      tireStorageEnable(params).then(res => {
+        if (res.status == 200) {
+          this.$message.success(res.message)
+        }
+        this.spinning = false
+        this.$refs.table.refresh()
+      })
+    },
+    // 初始化
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
+    // 计算表格高度
+    setTableH () {
+      const tableSearchH = this.$refs.tableSearch.offsetHeight
+      this.tableHeight = window.innerHeight - tableSearchH - 240
+    }
+  },
+  watch: {
+    '$store.state.app.winHeight' (newValue, oldValue) { //  窗口变更时,需同时更改表格高度
+      this.setTableH()
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
+  activated () {
+    // 如果是新页签打开,则重置当前页面
+    if (this.$store.state.app.isNewTab) {
+      this.pageInit()
+      this.resetSearchForm()
+    }
+    // 仅刷新列表,不重置页面
+    if (this.$store.state.app.updateList) {
+      this.$refs.table.refresh()
+      this.pageInit()
+    }
+  }
+}
+</script>

+ 342 - 0
src/views/reportData/tireSubsidyReport/incrementalSubsidyList.vue

@@ -0,0 +1,342 @@
+<template>
+  <div>
+    <a-card size="small" :bordered="false" class="incSubSidy-wrap searchBoxNormal">
+      <!-- 搜索条件 -->
+      <div class="table-page-search-wrapper" ref="tableSearch">
+        <a-form-model
+          id="incSubSidy-form"
+          ref="ruleForm"
+          class="form-model-con"
+          layout="inline"
+          :rules="rules"
+          :model="queryParam">
+          <a-row :gutter="15" type="flex">
+            <a-col :flex="1">
+              <a-form-model-item prop="queryDate">
+                <div style="display: inline;" slot="label">
+                  <a-popover placement="top">
+                    <template slot="content">
+                      <p>1、销售单(非转单)下推时间</p>
+                      <p>2、销售单(转单)转单完结时间</p>
+                      <p>3、销售退货单客服确认时间</p>
+                    </template>
+                    查询季度 <a-icon type="question-circle" />
+                  </a-popover>
+                </div>
+                <quarterDate ref="quarterDate" id="incSubSidy-time" :value="timeInfo" @change="dateChange" />
+              </a-form-model-item>
+            </a-col>
+            <a-col :flex="1">
+              <a-form-item label="所在区域">
+                <subarea id="incSubSidy-subarea" ref="subarea" @change="subareaChange"></subarea>
+              </a-form-item>
+            </a-col>
+            <a-col :flex="1">
+              <a-form-model-item label="地区">
+                <AreaList id="incSubSidy-areaList" changeOnSelect ref="areaList" @change="areaChange" defValKey="id"></AreaList>
+              </a-form-model-item>
+            </a-col>
+            <a-col :flex="2">
+              <a-form-model-item label="客户名称">
+                <custList id="incSubSidy-dealerName" dataAuthFlag="0" placeholder="请输入客户名称" ref="custList" @change="custChange" />
+              </a-form-model-item>
+            </a-col>
+            <a-col :flex="2">
+              <a-button
+                type="primary"
+                @click="handleSearch"
+                :disabled="disabled"
+                id="incSubSidy-refresh">查询</a-button>
+              <a-button
+                style="margin-left: 8px"
+                @click="resetSearchForm"
+                :disabled="disabled"
+                id="incSubSidy-reset">重置</a-button>
+              <a-button
+                style="margin-left: 10px"
+                type="primary"
+                class="button-warning"
+                @click="handleExport"
+                :disabled="disabled"
+                :loading="exportLoading"
+                v-if="$hasPermissions('M_tireSubsidyExport')"
+                id="incSubSidy-export">导出</a-button>
+            </a-col>
+          </a-row>
+        </a-form-model>
+      </div>
+    </a-card>
+    <a-card size="small" :bordered="false">
+      <a-spin :spinning="spinning" tip="Loading...">
+        <!-- 列表 -->
+        <s-table
+          class="sTable fixPagination"
+          ref="table"
+          size="small"
+          :rowKey="(record) => record.no"
+          rowKeyName="no"
+          :style="{ height: tableHeight+20+'px' }"
+          :columns="columns"
+          :data="loadData"
+          :scroll="{ y: tableHeight-80}"
+          :pageSize="30"
+          :defaultLoadData="false"
+          bordered>
+          <!-- 季度增量补贴金额 -->
+          <template slot="subsidyAmount" slot-scope="text, record">
+            <span v-if="record.subsidyAmount||record.subsidyAmount==0">
+              <span v-if="record.subsidyAmount>=0">{{ toThousands(record.subsidyAmount) }}</span>
+              <span style="color:#ED1C24;" v-else>{{ toThousands(record.subsidyAmount) }}</span>
+            </span>
+            <span v-else>--</span>
+          </template>
+          <!-- 统计 -->
+          <template slot="footer">
+            <a-row :gutter="15">
+              <a-col :md="4" :sm="24">总部合计数量:{{ (totalData && (totalData.headTotalQty || totalData.headTotalQty==0)) ? totalData.headTotalQty: '--' }}</a-col>
+              <a-col :md="4" :sm="24">合计订货数量:{{ (totalData && (totalData.totalQty || totalData.totalQty==0)) ? totalData.totalQty: '--' }}</a-col>
+              <a-col :md="4" :sm="24">增量补贴金额:{{ (totalData && (totalData.subsidyAmount || totalData.subsidyAmount==0)) ? toThousands(totalData.subsidyAmount): '--' }}</a-col>
+            </a-row>
+          </template>
+        </s-table>
+      </a-spin>
+    </a-card>
+  </div>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+import { hdExportExcel } from '@/libs/exportExcel'
+import moment from 'moment'
+// 组件
+import { STable, VSelect } from '@/components'
+import quarterDate from '@/views/common/quarterDate.vue'
+import subarea from '@/views/common/subarea.js'
+import AreaList from '@/views/common/areaList.js'
+import custList from '@/views/common/custList.vue'
+// 接口
+import { subsidyStepList, subsidyStepCount, subsidyStepExport } from '@/api/reportData'
+export default {
+  name: 'QuarterQueryList',
+  mixins: [commonMixin],
+  components: { STable, VSelect, quarterDate, subarea, AreaList, custList },
+  data () {
+    return {
+      spinning: false,
+      disabled: false, //  查询、重置按钮是否可操作
+      advanced: false, // 高级搜索 展开/关闭
+      tableHeight: 0, // 表格高度
+      exportLoading: false, // 导出按钮加载状态
+      timeInfo: [], // 日期
+      //  查询条件
+      queryParam: {
+        subsidyType: 'QUARTER', // 轮胎季度费用报表
+        queryDate: undefined, // 选择年份+季度
+        subareaArea: {
+          subareaSn: '', // 区域
+          subareaAreaSn: '' // 分区
+        },
+        belongDealerSn: undefined, // 客户sn
+        dealer: {
+          provinceSn: undefined, // 省
+          citySn: undefined, // 市
+          districtSn: undefined // 区
+        }
+      },
+      totalData: null, // 合计
+      rules: {
+        'queryDate': [{ required: true, message: '请选择查询年度', trigger: 'change' }]
+      },
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        this.spinning = true
+        const dateStr = this.queryParam.queryDate
+        const year = dateStr.substr(0, 4)
+        const quarter = dateStr.substr(5, 1)
+        const params = Object.assign(parameter, this.queryParam, { bizYear: year, bizQuarter: quarter == 'u' ? undefined : quarter })
+        console.log(params)
+        // 获取列表数据  有分页
+        return subsidyStepList(params).then(res => {
+          let data
+          if (res.status == 200) {
+            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
+              data.list[i].quarter = ['一', '二', '三', '四'][data.list[i].bizQuarter - 1] + '季度'
+            }
+            this.disabled = false
+            // 获取统计数据
+            this.getCount(params)
+          }
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  watch: {
+    advanced (newValue, oldValue) {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
+    '$store.state.app.winHeight' (newValue, oldValue) { //  窗口变更时,需同时更改表格高度
+      this.setTableH()
+    }
+  },
+  computed: {
+    columns () {
+      const _this = this
+      const arr = [
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
+        { title: '年度', dataIndex: 'bizYear', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '季度', dataIndex: 'quarter', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '区域', dataIndex: 'subareaArea.subareaName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '分区', dataIndex: 'subareaArea.subareaAreaName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '省份', dataIndex: 'provinceName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户名称', dataIndex: 'dealerName', width: '15%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '总部订货数量', dataIndex: 'salesQty', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '总部退货数量', dataIndex: 'returnQty', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '总部合计数量', dataIndex: 'headTotalQty', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '转单订货数量', dataIndex: 'transferQty', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '合计订货数量', dataIndex: 'totalQty', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '季度目标', dataIndex: 'subsidyTarget', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '季度增量补贴', dataIndex: 'subsidyValue', width: '10%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
+        { title: '增量补贴金额', dataIndex: 'subsidyAmount', width: '10%', align: 'right', scopedSlots: { customRender: 'subsidyAmount' } }
+      ]
+      return arr
+    }
+  },
+  methods: {
+    // 获取季度默认值
+    getQuarterVal () {
+      // 获取当月是今年的第几季度
+      const lastQuarter = moment().quarter()
+      // 获取今年年份
+      const thisYear = moment().year()
+      this.timeInfo = [thisYear, lastQuarter]
+      this.queryParam.queryDate = thisYear + '0' + lastQuarter
+    },
+    // 查询
+    handleSearch () {
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          _this.$refs.table.refresh(true)
+        } else {
+          _this.$message.error('请选择查询年度')
+          return false
+        }
+      })
+    },
+    // 客户名称 change
+    custChange (val) {
+      this.queryParam.dealerName = val.name
+      this.queryParam.belongDealerSn = val.key
+    },
+    // 统计
+    getCount (params) {
+      subsidyStepCount(params).then(res => {
+        if (res.status == 200 && res.data) {
+          this.totalData = res.data
+        } else {
+          this.totalData = null
+        }
+      })
+    },
+    // 地区
+    areaChange (val) {
+      this.queryParam.dealer.provinceSn = val[0] ? val[0] : undefined
+      this.queryParam.dealer.citySn = val[1] ? val[1] : undefined
+      this.queryParam.dealer.districtSn = val[2] ? val[2] : undefined
+    },
+    //  日期选择  change
+    dateChange (date, valStr) {
+      console.log(date)
+      this.timeInfo = date[0] && date[1] ? date : []
+      if (date && date.length && date[0]) {
+        this.queryParam.queryDate = date[0] + '0' + date[1]
+      } else {
+        this.queryParam.queryDate = undefined
+      }
+    },
+    // 区域分区  change
+    subareaChange (val) {
+      this.queryParam.subareaArea.subareaSn = val[0] ? val[0] : ''
+      this.queryParam.subareaArea.subareaAreaSn = val[1] ? val[1] : ''
+    },
+    //  重置
+    resetSearchForm () {
+      this.queryParam.subsidyType = 'QUARTER'
+      this.queryParam.queryDate = undefined
+      this.queryParam.dealer.provinceSn = undefined
+      this.queryParam.dealer.citySn = undefined
+      this.queryParam.dealer.districtSn = undefined
+      this.queryParam.subareaArea.subareaSn = ''
+      this.queryParam.subareaArea.subareaAreaSn = ''
+      this.queryParam.belongDealerSn = undefined // 客户sn
+      this.queryParam.dealerName = undefined
+      this.$refs.subarea.clearData()
+      this.$refs.custList.resetForm()
+      this.totalData = null
+      this.$refs.areaList.clearData()
+      this.$refs.table.clearTable()
+      this.$refs.ruleForm.resetFields()
+      this.getQuarterVal()
+    },
+    //  导出  必填判断
+    handleExport () {
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          _this.exportList()
+        } else {
+          _this.$message.error('请选择查询季度')
+          return false
+        }
+      })
+    },
+    // 导出
+    exportList () {
+      const _this = this
+      _this.exportLoading = true
+      _this.spinning = true
+      const dateStr = this.queryParam.queryDate
+      const year = dateStr.substr(0, 4)
+      const quarter = dateStr.substr(5, 1)
+      const params = Object.assign(this.queryParam, { bizYear: year, bizQuarter: quarter == 'u' ? undefined : quarter })
+      hdExportExcel(subsidyStepExport, params, '增量补贴报表(' + this.queryParam.queryDate + '季度)-', function () {
+        _this.exportLoading = false
+        _this.spinning = false
+      })
+    },
+    // 初始化
+    pageInit () {
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        this.setTableH()
+      })
+      this.resetSearchForm()
+    },
+    // 计算表格高度
+    setTableH () {
+      const tableSearchH = this.$refs.tableSearch.offsetHeight
+      this.tableHeight = window.innerHeight - tableSearchH - 230
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+    }
+  },
+  activated () {
+    // 如果是新页签打开,则重置当前页面
+    if (this.$store.state.app.isNewTab) {
+      this.pageInit()
+    }
+  }
+}
+</script>

+ 349 - 0
src/views/reportData/tireSubsidyReport/incrementalSubsidyYearList.vue

@@ -0,0 +1,349 @@
+<template>
+  <div>
+    <a-card size="small" :bordered="false" class="incSubSidyYear-wrap searchBoxNormal">
+      <!-- 搜索条件 -->
+      <div class="table-page-search-wrapper" ref="tableSearch">
+        <a-form-model
+          id="incSubSidyYear-form"
+          ref="ruleForm"
+          class="form-model-con"
+          layout="inline"
+          :rules="rules"
+          :model="queryParam">
+          <a-row :gutter="15" type="flex">
+            <a-col :flex="1">
+              <a-form-model-item prop="bizYear">
+                <div style="display: inline;" slot="label">
+                  <a-popover placement="top">
+                    <template slot="content">
+                      <p>1、销售单(非转单)下推时间</p>
+                      <p>2、销售单(转单)转单完结时间</p>
+                      <p>3、销售退货单客服确认时间</p>
+                    </template>
+                    查询年份 <a-icon type="question-circle" />
+                  </a-popover>
+                </div>
+                <a-select
+                  id="yearQueryList-time"
+                  style="width: 100%"
+                  placeholder="请选择年份"
+                  :value="queryParam.bizYear"
+                  @change="changeYear"
+                  allowClear>
+                  <a-select-option v-for="item in years" :value="item" :key="item">
+                    {{ item }}
+                  </a-select-option>
+                </a-select>
+              </a-form-model-item>
+            </a-col>
+            <a-col :flex="1">
+              <a-form-item label="所在区域">
+                <subarea id="incSubSidyYear-subarea" ref="subarea" @change="subareaChange"></subarea>
+              </a-form-item>
+            </a-col>
+            <a-col :flex="1">
+              <a-form-model-item label="地区">
+                <AreaList id="incSubSidyYear-areaList" changeOnSelect ref="areaList" @change="areaChange" defValKey="id"></AreaList>
+              </a-form-model-item>
+            </a-col>
+            <a-col :flex="2">
+              <a-form-model-item label="客户名称">
+                <custList id="incSubSidyYear-dealerName" dataAuthFlag="0" placeholder="请输入客户名称" ref="custList" @change="custChange" />
+              </a-form-model-item>
+            </a-col>
+            <a-col :flex="2">
+              <a-button
+                type="primary"
+                @click="handleSearch"
+                :disabled="disabled"
+                id="incSubSidyYear-refresh">查询</a-button>
+              <a-button
+                style="margin-left: 8px"
+                @click="resetSearchForm"
+                :disabled="disabled"
+                id="incSubSidyYear-reset">重置</a-button>
+              <a-button
+                style="margin-left: 10px"
+                type="primary"
+                class="button-warning"
+                @click="handleExport"
+                :disabled="disabled"
+                :loading="exportLoading"
+                v-if="$hasPermissions('M_tireSubsidyExport')"
+                id="incSubSidyYear-export">导出</a-button>
+            </a-col>
+          </a-row>
+        </a-form-model>
+      </div>
+    </a-card>
+    <a-card size="small" :bordered="false">
+      <a-spin :spinning="spinning" tip="Loading...">
+        <!-- 列表 -->
+        <s-table
+          class="sTable fixPagination"
+          ref="table"
+          size="small"
+          :rowKey="(record) => record.no"
+          rowKeyName="no"
+          :style="{ height: tableHeight+20+'px' }"
+          :columns="columns"
+          :data="loadData"
+          :scroll="{ y: tableHeight-80}"
+          :pageSize="30"
+          :defaultLoadData="false"
+          bordered>
+          <!-- 季度增量补贴金额 -->
+          <template slot="subsidyAmount" slot-scope="text, record">
+            <span v-if="record.subsidyAmount||record.subsidyAmount==0">
+              <span v-if="record.subsidyAmount>=0">{{ toThousands(record.subsidyAmount) }}</span>
+              <span style="color:#ED1C24;" v-else>{{ toThousands(record.subsidyAmount) }}</span>
+            </span>
+            <span v-else>--</span>
+          </template>
+          <!-- 剩余增量补贴金额 -->
+          <template slot="settleAmountWait" slot-scope="text, record">
+            <span v-if="record.settleAmountWait||record.settleAmountWait==0">
+              <span style="color:#ED1C24;" v-if="record.settleAmountWait>0">{{ toThousands(record.settleAmountWait) }}</span>
+              <span v-else>{{ toThousands(record.settleAmountWait) }}</span>
+            </span>
+            <span v-else>--</span>
+          </template>
+          <!-- 统计 -->
+          <template slot="footer">
+            <a-row :gutter="15">
+              <a-col :md="4" :sm="24">总部合计数量:{{ (totalData && (totalData.headTotalQty || totalData.headTotalQty==0)) ? totalData.headTotalQty: '--' }}</a-col>
+              <a-col :md="4" :sm="24">合计订货数量:{{ (totalData && (totalData.totalQty || totalData.totalQty==0)) ? totalData.totalQty: '--' }}</a-col>
+              <a-col :md="4" :sm="24">增量已贴金额:{{ (totalData && (totalData.settleAmountFinish || totalData.settleAmountFinish==0)) ? toThousands(totalData.settleAmountFinish): '--' }}</a-col>
+              <a-col :md="4" :sm="24">剩余增量补贴金额:{{ (totalData && (totalData.settleAmountWait || totalData.settleAmountWait==0)) ? toThousands(totalData.settleAmountWait): '--' }}</a-col>
+            </a-row>
+          </template>
+        </s-table>
+      </a-spin>
+    </a-card>
+  </div>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+import { hdExportExcel } from '@/libs/exportExcel'
+import moment from 'moment'
+// 组件
+import { STable, VSelect } from '@/components'
+import subarea from '@/views/common/subarea.js'
+import AreaList from '@/views/common/areaList.js'
+import custList from '@/views/common/custList.vue'
+// 接口
+import { subsidyStepList, subsidyStepCount, subsidyStepExport } from '@/api/reportData'
+export default {
+  name: 'QuarterQueryList',
+  mixins: [commonMixin],
+  components: { STable, VSelect, subarea, AreaList, custList },
+  data () {
+    return {
+      spinning: false,
+      disabled: false, //  查询、重置按钮是否可操作
+      advanced: false, // 高级搜索 展开/关闭
+      tableHeight: 0, // 表格高度
+      exportLoading: false, // 导出按钮加载状态
+      toYears: new Date().getFullYear(), // 今年
+      //  查询条件
+      queryParam: {
+        subsidyType: 'YEAR', // 轮胎年度费用报表
+        bizYear: moment().year(), // 选择年份
+        subareaArea: {
+          subareaSn: '', // 区域
+          subareaAreaSn: '' // 分区
+        },
+        customSn: undefined, // 客户sn
+        dealer: {
+          dealerName: undefined, // 客户名称
+          provinceSn: undefined, // 省
+          citySn: undefined, // 市
+          districtSn: undefined // 区
+        }
+      },
+      totalData: null, // 合计
+      rules: {
+        'bizYear': [{ required: true, message: '请选择查询年份', trigger: 'change' }]
+      },
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        this.spinning = true
+        const params = Object.assign(parameter, this.queryParam)
+        // 获取列表数据  有分页
+        return subsidyStepList(params).then(res => {
+          let data
+          if (res.status == 200) {
+            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
+            // 获取统计数据
+            this.getCount(params)
+          }
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  watch: {
+    advanced (newValue, oldValue) {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
+    '$store.state.app.winHeight' (newValue, oldValue) { //  窗口变更时,需同时更改表格高度
+      this.setTableH()
+    }
+  },
+  computed: {
+    // 获取年份数据
+    years () {
+      const years = []
+      const lens = (this.toYears - 2023) + 1
+      for (let i = 0; i < lens; i++) {
+        years.push(this.toYears - i)
+      }
+      return years
+    },
+    columns () {
+      const _this = this
+      const arr = [
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
+        { title: '区域', dataIndex: 'subareaArea.subareaName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '分区', dataIndex: 'subareaArea.subareaAreaName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '省份', dataIndex: 'provinceName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户名称', dataIndex: 'dealerName', width: '15%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '总部订货数量', dataIndex: 'salesQty', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '总部退货数量', dataIndex: 'returnQty', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '总部合计数量', dataIndex: 'headTotalQty', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '转单订货数量', dataIndex: 'transferQty', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '合计订货数量', dataIndex: 'totalQty', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '年度目标', dataIndex: 'subsidyTarget', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '年度增量补贴', dataIndex: 'subsidyValue', width: '10%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
+        { title: '增量补贴金额', dataIndex: 'subsidyAmount', width: '10%', align: 'right', scopedSlots: { customRender: 'subsidyAmount' } },
+        { title: '增量已补金额', dataIndex: 'settleAmountFinish', width: '10%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
+        { title: '剩余增量补贴金额', dataIndex: 'settleAmountWait', width: '10%', align: 'right', scopedSlots: { customRender: 'settleAmountWait' } }
+      ]
+      return arr
+    }
+  },
+  methods: {
+    // 选择查询年份  change
+    changeYear (val) {
+      if (!val) {
+        this.queryParam.bizYear = void 0
+      } else {
+        this.queryParam.bizYear = val
+      }
+    },
+    // 查询
+    handleSearch () {
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          _this.$refs.table.refresh(true)
+        } else {
+          _this.$message.error('请选择查询年')
+          return false
+        }
+      })
+    },
+    // 客户名称 change
+    custChange (val) {
+      this.queryParam.dealerName = val.name
+      this.queryParam.belongDealerSn = val.key
+    },
+    // 统计
+    getCount (params) {
+      subsidyStepCount(params).then(res => {
+        if (res.status == 200 && res.data) {
+          this.totalData = res.data
+        } else {
+          this.totalData = null
+        }
+      })
+    },
+    // 地区
+    areaChange (val) {
+      this.queryParam.dealer.provinceSn = val[0] ? val[0] : undefined
+      this.queryParam.dealer.citySn = val[1] ? val[1] : undefined
+      this.queryParam.dealer.districtSn = val[2] ? val[2] : undefined
+    },
+    // 区域分区  change
+    subareaChange (val) {
+      this.queryParam.subareaArea.subareaSn = val[0] ? val[0] : ''
+      this.queryParam.subareaArea.subareaAreaSn = val[1] ? val[1] : ''
+    },
+    //  重置
+    resetSearchForm () {
+      this.queryParam.subsidyType = 'YEAR'
+      this.queryParam.bizYear = moment().year()
+      this.queryParam.dealer.provinceSn = undefined
+      this.queryParam.dealer.citySn = undefined
+      this.queryParam.dealer.districtSn = undefined
+      this.queryParam.dealerName = undefined
+      this.queryParam.belongDealerSn = undefined
+      this.queryParam.subareaArea.subareaSn = ''
+      this.queryParam.subareaArea.subareaAreaSn = ''
+      this.$refs.subarea.clearData()
+      this.$refs.custList.resetForm()
+      this.totalData = null
+      this.$refs.areaList.clearData()
+      this.$refs.table.clearTable()
+      this.$refs.ruleForm.resetFields()
+    },
+    //  导出  必填判断
+    handleExport () {
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          _this.exportList()
+        } else {
+          _this.$message.error('请选择查询年度')
+          return false
+        }
+      })
+    },
+    // 导出
+    exportList () {
+      const _this = this
+      _this.exportLoading = true
+      _this.spinning = true
+      hdExportExcel(subsidyStepExport, _this.queryParam, '增量补贴报表(' + this.queryParam.bizYear + '年度)-', function () {
+        _this.exportLoading = false
+        _this.spinning = false
+      })
+    },
+    // 初始化
+    pageInit () {
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        this.setTableH()
+      })
+      this.resetSearchForm()
+    },
+    // 计算表格高度
+    setTableH () {
+      const tableSearchH = this.$refs.tableSearch.offsetHeight
+      this.tableHeight = window.innerHeight - tableSearchH - 230
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+    }
+  },
+  activated () {
+    // 如果是新页签打开,则重置当前页面
+    if (this.$store.state.app.isNewTab) {
+      this.pageInit()
+    }
+  }
+}
+</script>

+ 62 - 0
src/views/reportData/tireSubsidyReport/index.vue

@@ -0,0 +1,62 @@
+<template>
+  <div>
+    <a-card size="small" :bordered="false">
+      <a-tabs default-active-key="1" @change="handleChange">
+        <a-tab-pane key="1" tab="服务费运费明细报表" force-render>
+          <serviceFreightDetailList ref="tableList1"></serviceFreightDetailList>
+        </a-tab-pane>
+        <a-tab-pane key="2" tab="服务费运费报表" force-render>
+          <serviceFreightList ref="tableList2"></serviceFreightList>
+        </a-tab-pane>
+        <a-tab-pane key="3" tab="增量补贴报表(季度)" force-render>
+          <incrementalSubsidyList ref="tableList3"></incrementalSubsidyList>
+        </a-tab-pane>
+        <a-tab-pane key="4" tab="增量补贴报表(年度)" force-render>
+          <incrementalSubsidyYearList ref="tableList4"></incrementalSubsidyYearList>
+        </a-tab-pane>
+      </a-tabs>
+    </a-card>
+  </div>
+</template>
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import serviceFreightList from './serviceFreightList.vue'
+import incrementalSubsidyList from './incrementalSubsidyList.vue'
+import incrementalSubsidyYearList from './incrementalSubsidyYearList.vue'
+import serviceFreightDetailList from './serviceFreightDetailList.vue'
+export default {
+  name: 'TireFeeReportIndex',
+  mixins: [commonMixin],
+  components: { serviceFreightList, incrementalSubsidyList, incrementalSubsidyYearList, serviceFreightDetailList },
+  data () {
+    return {
+      tabVal: 1 // tab值
+    }
+  },
+  methods: {
+    // 切换tab值  change
+    handleChange (val) {
+      this.tabVal = val
+    },
+    // 初始化
+    pageInit () {
+      if (this.tabVal == 1) {
+        this.$refs.tableList1.pageInit()
+      }
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+    }
+  },
+  activated () {
+    // 如果是新页签打开,则重置当前页面
+    if (this.$store.state.app.isNewTab) {
+      this.pageInit()
+    }
+  }
+}
+
+</script>

+ 397 - 0
src/views/reportData/tireSubsidyReport/serviceFreightDetailList.vue

@@ -0,0 +1,397 @@
+<template>
+  <div>
+    <a-card size="small" :bordered="false" class="sfdetail-wrap searchBoxNormal">
+      <!-- 搜索条件 -->
+      <div class="table-page-search-wrapper" ref="tableSearch">
+        <a-form-model
+          id="sfdetail-form"
+          ref="ruleForm"
+          class="form-model-con"
+          layout="inline"
+          :rules="rules"
+          :model="queryParam">
+          <a-row :gutter="15">
+            <a-col :md="6" :sm="24">
+              <a-form-model-item prop="time">
+                <div style="display: inline;" slot="label">
+                  <a-popover placement="top">
+                    <template slot="content">
+                      <p>1、销售单(非转单)下推时间</p>
+                      <p>2、销售单(转单)转单完结时间</p>
+                      <p>3、销售退货单客服确认时间</p>
+                    </template>
+                    查询日期 <a-icon type="question-circle" />
+                  </a-popover>
+                </div>
+                <rangeDate
+                  ref="rangeDate"
+                  :value="queryParam.time"
+                  id="sfdetail-time"
+                  @change="dateChange" />
+              </a-form-model-item>
+            </a-col>
+            <a-col :md="6" :sm="24">
+              <a-form-item label="记账主体">
+                <custList id="sfdetail-belongDealer" dataAuthFlag="0" placeholder="请输入记账主体" ref="belongDealer" @change="belongDealerChange" />
+              </a-form-item>
+            </a-col>
+            <a-col :md="6" :sm="24">
+              <a-form-item label="业务单号">
+                <a-input id="sfdetail-bizNo" v-model.trim="queryParam.bizNo" allowClear placeholder="请输入业务单号"/>
+              </a-form-item>
+            </a-col>
+            <template v-if="advanced">
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="客户名称">
+                  <custList id="sfdetail-custName" dataAuthFlag="0" placeholder="请输入客户名称" ref="custList" @change="custChange" />
+                </a-form-model-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="业务类型">
+                  <v-select
+                    v-model="queryParam.bizType"
+                    ref="bizType"
+                    id="sfdetail-bizType"
+                    code="SUBSIDY_BIZ_TYPE"
+                    placeholder="请选择业务类型"
+                    allowClear></v-select>
+                </a-form-model-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-item label="发货经销商">
+                  <custList id="sfdetail-transferDealerSn" dataAuthFlag="0" placeholder="请输入发货经销商" ref="dealerTireScopeList" @change="custTireChange" />
+                </a-form-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="轮胎省仓">
+                  <v-select
+                    v-model="queryParam.belongProvinceFlag"
+                    id="sfdetail-belongProvinceFlag"
+                    code="Flag"
+                    placeholder="请选择轮胎省仓"
+                    allowClear></v-select>
+                </a-form-model-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-item label="所在区域">
+                  <subarea id="sfdetail-subarea" ref="subarea" @change="subareaChange"></subarea>
+                </a-form-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-model-item label="地区">
+                  <AreaList id="sfdetail-areaList" changeOnSelect ref="areaList" @change="areaChange" defValKey="id"></AreaList>
+                </a-form-model-item>
+              </a-col>
+            </template>
+            <a-col :md="6" :sm="24">
+              <a-button
+                type="primary"
+                @click="handleSearch"
+                :disabled="disabled"
+                id="sfdetail-refresh">查询</a-button>
+              <a-button
+                style="margin-left: 8px"
+                @click="resetSearchForm"
+                :disabled="disabled"
+                id="sfdetail-reset">重置</a-button>
+              <a-button
+                style="margin-left: 10px"
+                type="primary"
+                class="button-warning"
+                @click="handleExport"
+                :disabled="disabled"
+                :loading="exportLoading"
+                v-if="$hasPermissions('M_tireSubsidyExport')"
+                id="sfdetail-export">导出</a-button>
+              <a @click="advanced=!advanced" style="margin-left: 5px">
+                {{ advanced ? '收起' : '展开' }}
+                <a-icon :type="advanced ? 'up' : 'down'" />
+              </a>
+            </a-col>
+          </a-row>
+        </a-form-model>
+      </div>
+    </a-card>
+    <a-card size="small" :bordered="false">
+      <a-spin :spinning="spinning" tip="Loading...">
+        <!-- 列表 -->
+        <s-table
+          class="sTable fixPagination"
+          ref="table"
+          size="small"
+          :rowKey="(record) => record.no"
+          rowKeyName="no"
+          :style="{ height: tableHeight+70+'px' }"
+          :columns="columns"
+          :data="loadData"
+          :pageSize="30"
+          :scroll="{ y: tableHeight-50}"
+          :defaultLoadData="false"
+          bordered>
+          <template slot="footer">
+            <a-row :gutter="15">
+              <a-col :md="6" :sm="24" v-if="$hasPermissions('M_tireSubsidyList_salesPrice')">服务费金额:{{ (totalData && (totalData.subsidyServiceAmount || totalData.subsidyServiceAmount==0)) ? toThousands(totalData.subsidyServiceAmount): '--' }}</a-col>
+              <a-col :md="6" :sm="24">运费补贴金额:{{ (totalData && (totalData.subsidyShippingAmount || totalData.subsidyShippingAmount==0)) ? toThousands(totalData.subsidyShippingAmount): '--' }}</a-col>
+            </a-row>
+          </template>
+        </s-table>
+      </a-spin>
+    </a-card>
+  </div>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+import { hdExportExcel } from '@/libs/exportExcel'
+import moment from 'moment'
+import getDate from '@/libs/getDate.js'
+// 组件
+import { STable, VSelect } from '@/components'
+import rangeDate from '@/views/common/rangeDate.vue'
+import subarea from '@/views/common/subarea.js'
+import AreaList from '@/views/common/areaList.js'
+import custList from '@/views/common/custList.vue'
+// 接口
+import { subsidyDetailList, subsidyDetailCount, subsidyDetailExport } from '@/api/reportData'
+export default {
+  name: 'ServiceFreightDetailList',
+  mixins: [commonMixin],
+  components: { STable, VSelect, rangeDate, subarea, AreaList, custList },
+  data () {
+    return {
+      spinning: false,
+      disabled: false, //  查询、重置按钮是否可操作
+      advanced: false, // 高级搜索 展开/关闭
+      tableHeight: 0, // 表格高度
+      exportLoading: false, // 导出按钮加载状态
+      //  查询条件
+      queryParam: {
+        time: [
+          moment(getDate.getCurrMonthDays().starttime, 'YYYY-MM-DD'),
+          moment(getDate.getCurrMonthDays().endtime, 'YYYY-MM-DD')
+        ], // 日期
+        beginDate: getDate.getCurrMonthDays().starttime, // 开始时间
+        endDate: getDate.getCurrMonthDays().endtime, // 结束时间
+        bizNo: undefined, // 业务单号
+        bizType: undefined, // 业务类型
+        belongProvinceFlag: undefined, // 是否轮胎省仓
+        subareaArea: {
+          subareaSn: undefined, // 区域
+          subareaAreaSn: undefined // 分区
+        },
+        dealer: {
+          provinceSn: undefined,
+          citySn: undefined,
+          districtSn: undefined
+        },
+        belongDealerSn: undefined,
+        transferDealerSn: undefined,
+        bizDealerSn: undefined
+      },
+      totalData: null, // 合计
+      showOutDetail: false, // 出库明细弹窗
+      rules: {
+        'time': [{ required: true, message: '请选择查询日期', trigger: 'change' }]
+      },
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        this.spinning = true
+        const oldParams = Object.assign(parameter, this.queryParam)
+        const params = JSON.parse(JSON.stringify(oldParams))
+        delete params.time
+        // 获取列表数据  有分页
+        return subsidyDetailList(params).then(res => {
+          let data
+          if (res.status == 200) {
+            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
+            // 获取统计数据
+            this.getCount(params)
+          }
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  watch: {
+    advanced (newValue, oldValue) {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
+    '$store.state.app.winHeight' (newValue, oldValue) { //  窗口变更时,需同时更改表格高度
+      this.setTableH()
+    }
+  },
+  computed: {
+    columns () {
+      const _this = this
+      const arr = [
+        { title: '序号', dataIndex: 'no', width: '40px', align: 'center' },
+        { title: '业务单号', dataIndex: 'bizNo', width: '120px', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '区域', dataIndex: 'subareaArea.subareaName', width: '80px', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '分区', dataIndex: 'subareaArea.subareaAreaName', width: '80px', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '省份', dataIndex: 'provinceName', width: '80px', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '记账主体', dataIndex: 'belongDealerName', width: '150px', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '轮胎省仓', dataIndex: 'belongProvinceFlagDictValue', width: '80px', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '销售数量', dataIndex: 'bizQty', width: '80px', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '服务费比例', dataIndex: 'subsidyServiceDiff', width: '80px', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text * 100) + '%' : '--') } },
+        { title: '运费补贴', dataIndex: 'subsidyShippingDiff', width: '80px', align: 'center', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
+        { title: '运费补贴金额', dataIndex: 'subsidyShippingAmount', width: '100px', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
+        { title: '客户名称', dataIndex: 'bizDealerName', width: '150px', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        // { title: '发货经销商', dataIndex: 'transferDealerName', width: '150px', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '业务类型', dataIndex: 'bizTypeDictValue', width: '100px', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true }
+      ]
+      if (_this.$hasPermissions('M_tireSubsidyList_salesPrice')) {
+        arr.splice(8, 0, { title: '销售金额', dataIndex: 'bizAmount', width: '100px', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
+        arr.splice(10, 0, { title: '服务费金额', dataIndex: 'subsidyServiceAmount', width: '100px', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
+      }
+      return arr
+    }
+  },
+  methods: {
+    // 查询
+    handleSearch () {
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          _this.$refs.table.refresh(true)
+        } else {
+          _this.$message.error('请选择查询时间')
+          return false
+        }
+      })
+    },
+    //  日期选择  change
+    dateChange (date) {
+      if (date[0] && date[1]) {
+        this.queryParam.time = date
+      } else {
+        this.queryParam.time = []
+      }
+      this.queryParam.beginDate = date[0]
+      this.queryParam.endDate = date[1]
+    },
+    // 选择发货经销商
+    custTireChange (val) {
+      this.queryParam.transferDealerSn = val.key
+    },
+    // 记账主体
+    belongDealerChange (val) {
+      this.queryParam.belongDealerSn = val.key
+    },
+    // 客户名称 change
+    custChange (val) {
+      this.queryParam.bizDealerSn = val.key
+    },
+    // 统计
+    getCount (params) {
+      subsidyDetailCount(params).then(res => {
+        if (res.status == 200 && res.data) {
+          this.totalData = res.data
+        } else {
+          this.totalData = null
+        }
+      })
+    },
+    // 地区省份
+    areaChange (val) {
+      this.queryParam.dealer.provinceSn = val[0] ? val[0] : undefined
+      this.queryParam.dealer.citySn = val[1] ? val[1] : undefined
+      this.queryParam.dealer.districtSn = val[2] ? val[2] : undefined
+    },
+    // 区域分区  change
+    subareaChange (val) {
+      this.queryParam.subareaArea.subareaSn = val[0] ? val[0] : undefined
+      this.queryParam.subareaArea.subareaAreaSn = val[1] ? val[1] : undefined
+    },
+    //  重置
+    resetSearchForm () {
+      this.queryParam.time = [
+        moment(getDate.getCurrMonthDays().starttime, 'YYYY-MM-DD'),
+        moment(getDate.getCurrMonthDays().endtime, 'YYYY-MM-DD')
+      ]
+      this.$refs.rangeDate.resetDate(this.queryParam.time)
+      this.queryParam.beginDate = getDate.getCurrMonthDays().starttime
+      this.queryParam.endDate = getDate.getCurrMonthDays().endtime
+      this.queryParam.bizNo = undefined
+      this.queryParam.bizType = undefined
+      this.queryParam.belongDealerSn = undefined
+      this.queryParam.transferDealerSn = undefined
+      this.queryParam.bizDealerSn = undefined
+      this.queryParam.belongProvinceFlag = undefined
+      this.queryParam.dealer.provinceSn = undefined
+      this.queryParam.dealer.citySn = undefined
+      this.queryParam.dealer.districtSn = undefined
+      this.queryParam.subareaArea.subareaSn = undefined
+      this.queryParam.subareaArea.subareaAreaSn = undefined
+      this.$refs.belongDealer.resetForm()
+      if (this.advanced) {
+        this.$refs.dealerTireScopeList.resetForm()
+        this.$refs.custList.resetForm()
+        this.$refs.subarea.clearData()
+        this.$refs.areaList.clearData()
+      }
+      this.totalData = null
+      this.$refs.table.clearTable()
+      this.$refs.ruleForm.resetFields()
+    },
+    //  导出  必填判断
+    handleExport () {
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          _this.exportList()
+        } else {
+          _this.$message.error('请选择查询时间')
+          return false
+        }
+      })
+    },
+    // 导出
+    exportList () {
+      const _this = this
+      const params = JSON.parse(JSON.stringify(_this.queryParam))
+      _this.$store.state.app.curActionPermission = 'M_tireSubsidyExport'
+      _this.exportLoading = true
+      _this.spinning = true
+      hdExportExcel(subsidyDetailExport, params, '轮胎服务费运费明细报表-', function () {
+        _this.exportLoading = false
+        _this.spinning = false
+        _this.$store.state.app.curActionPermission = ''
+      })
+    },
+    // 初始化
+    pageInit () {
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        this.setTableH()
+      })
+      this.resetSearchForm()
+    },
+    // 计算表格高度
+    setTableH () {
+      const tableSearchH = this.$refs.tableSearch.offsetHeight
+      this.tableHeight = window.innerHeight - tableSearchH - 280
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+    }
+  },
+  activated () {
+    // 如果是新页签打开,则重置当前页面
+    if (this.$store.state.app.isNewTab) {
+      this.pageInit()
+    }
+  }
+}
+</script>

+ 339 - 0
src/views/reportData/tireSubsidyReport/serviceFreightList.vue

@@ -0,0 +1,339 @@
+<template>
+  <div>
+    <a-card size="small" :bordered="false" class="serviceFreight-wrap searchBoxNormal">
+      <!-- 搜索条件 -->
+      <div class="table-page-search-wrapper" ref="tableSearch">
+        <a-form-model
+          id="serviceFreight-form"
+          ref="ruleForm"
+          class="form-model-con"
+          layout="inline"
+          :rules="rules"
+          :model="queryParam">
+          <a-row :gutter="15" type="flex">
+            <a-col :flex="1">
+              <a-form-model-item prop="queryDate">
+                <div style="display: inline;" slot="label">
+                  <a-popover placement="top">
+                    <template slot="content">
+                      <p>1、销售单(非转单)下推时间</p>
+                      <p>2、销售单(转单)转单完结时间</p>
+                      <p>3、销售退货单客服确认时间</p>
+                    </template>
+                    查询月份 <a-icon type="question-circle" />
+                  </a-popover>
+                </div>
+                <a-month-picker
+                  id="serviceFreight-monthBox"
+                  class="monthBox"
+                  :disabled-date="disabledDate"
+                  v-model="monthVal"
+                  placeholder="请选择月份"
+                  @change="onChangeMonth" />
+              </a-form-model-item>
+            </a-col>
+            <a-col :flex="1">
+              <a-form-item label="所在区域">
+                <subarea id="serviceFreight-subarea" ref="subarea" @change="subareaChange"></subarea>
+              </a-form-item>
+            </a-col>
+            <a-col :flex="1">
+              <a-form-model-item label="地区">
+                <AreaList id="serviceFreight-areaList" changeOnSelect ref="areaList" @change="areaChange" defValKey="id"></AreaList>
+              </a-form-model-item>
+            </a-col>
+            <a-col :flex="2">
+              <a-form-model-item label="记账主体">
+                <custList id="serviceFreight-belongDealer" dataAuthFlag="0" placeholder="请输入记账主体" ref="belongDealer" @change="belongDealerChange" />
+              </a-form-model-item>
+            </a-col>
+            <a-col :flex="2">
+              <a-button
+                type="primary"
+                @click="handleSearch"
+                :disabled="disabled"
+                id="serviceFreight-refresh">查询</a-button>
+              <a-button
+                style="margin-left: 8px"
+                @click="resetSearchForm"
+                :disabled="disabled"
+                id="serviceFreight-reset">重置</a-button>
+              <a-button
+                style="margin-left: 10px"
+                type="primary"
+                class="button-warning"
+                @click="handleExport"
+                :disabled="disabled"
+                :loading="exportLoading"
+                v-if="$hasPermissions('M_tireSubsidyExport')"
+                id="serviceFreight-export">导出</a-button>
+            </a-col>
+          </a-row>
+        </a-form-model>
+      </div>
+    </a-card>
+    <a-card size="small" :bordered="false">
+      <a-spin :spinning="spinning" tip="Loading...">
+        <!-- 列表 -->
+        <s-table
+          class="sTable fixPagination"
+          ref="table"
+          size="small"
+          :rowKey="(record) => record.no"
+          rowKeyName="no"
+          :style="{ height: tableHeight+20+'px' }"
+          :columns="columns"
+          :data="loadData"
+          :scroll="{ y: tableHeight-80}"
+          :pageSize="30"
+          :defaultLoadData="false"
+          bordered>
+          <template slot="footer">
+            <a-row :gutter="15">
+              <a-col :md="6" :sm="24" v-if="$hasPermissions('M_tireSubsidyList_salesPrice')">服务费金额合计:{{ (totalData && (totalData.subsidyServiceTotal || totalData.subsidyServiceTotal==0)) ? toThousands(totalData.subsidyServiceTotal): '--' }}</a-col>
+              <a-col :md="6" :sm="24">运费补贴金额合计:{{ (totalData && (totalData.subsidyShippingTotal || totalData.subsidyShippingTotal==0)) ? toThousands(totalData.subsidyShippingTotal): '--' }}</a-col>
+            </a-row>
+          </template>
+        </s-table>
+      </a-spin>
+    </a-card>
+  </div>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+import { hdExportExcel } from '@/libs/exportExcel'
+import moment from 'moment'
+// 组件
+import { STable, VSelect } from '@/components'
+import subarea from '@/views/common/subarea.js'
+import AreaList from '@/views/common/areaList.js'
+import custList from '@/views/common/custList.vue'
+// 接口
+import { subsidyMonthList, subsidyMonthCount, subsidyMonthExport } from '@/api/reportData'
+export default {
+  name: 'MonthQueryList',
+  mixins: [commonMixin],
+  components: { STable, VSelect, subarea, AreaList, custList },
+  data () {
+    return {
+      spinning: false,
+      disabled: false, //  查询、重置按钮是否可操作
+      advanced: false, // 高级搜索 展开/关闭
+      tableHeight: 0, // 表格高度
+      exportLoading: false, // 导出按钮加载状态
+      monthVal: moment().format('YYYY-MM'), // 初始化月份值
+      //  查询条件
+      queryParam: {
+        queryDate: moment().format('YYYY-MM'), // 选择月份
+        dealer: {
+          provinceSn: undefined, // 省
+          citySn: undefined, // 市
+          districtSn: undefined // 区
+        },
+        belongDealerSn: undefined, // 记账主体
+        subareaArea: {
+          subareaSn: '', // 区域
+          subareaAreaSn: '' // 分区
+        }
+      },
+      totalData: null, // 合计
+      rules: {
+        'queryDate': [{ required: true, message: '请选择查询月份', trigger: 'change' }]
+      },
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        this.spinning = true
+        const params = Object.assign(parameter, this.queryParam)
+        params.bizYear = params.queryDate.split('-')[0]
+        params.bizMonth = params.queryDate.split('-')[1]
+        delete params.queryDate
+        // 获取列表数据  有分页
+        return subsidyMonthList(params).then(res => {
+          let data
+          if (res.status == 200) {
+            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
+              data.list[i].mothDay = data.list[i].bizMonth + '月'
+            }
+            this.disabled = false
+            this.getCount(params)
+          }
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  watch: {
+    advanced (newValue, oldValue) {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
+    '$store.state.app.winHeight' (newValue, oldValue) { //  窗口变更时,需同时更改表格高度
+      this.setTableH()
+    }
+  },
+  computed: {
+    columns () {
+      const _this = this
+      const arr = [
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
+        { title: '月份', dataIndex: 'mothDay', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '区域', dataIndex: 'subareaArea.subareaName', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '分区', dataIndex: 'subareaArea.subareaAreaName', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '省份', dataIndex: 'provinceName', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '记账主体', dataIndex: 'dealerName', width: '15%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '运费补贴金额(记)', dataIndex: 'subsidyShippingSales', width: '10%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
+        { title: '运费补贴金额(扣)', dataIndex: 'subsidyShippingReturn', width: '10%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
+        { title: '运费补贴金额合计', dataIndex: 'subsidyShippingTotal', width: '10%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } }
+      ]
+      if (_this.$hasPermissions('M_tireSubsidyList_salesPrice')) {
+        arr.splice(6, 0, { title: '服务费金额(记)', dataIndex: 'subsidyServiceSales', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
+        arr.splice(7, 0, { title: '服务费金额(扣)', dataIndex: 'subsidyServiceReturn', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
+        arr.splice(8, 0, { title: '服务费金额合计', dataIndex: 'subsidyServiceTotal', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
+      }
+      return arr
+    }
+  },
+  methods: {
+    // 选择月份  禁用选择当月以后日期
+    disabledDate (current) {
+      return current && current >= moment().endOf('day')
+    },
+    // 选择月份 change
+    onChangeMonth (date, dateString) {
+      this.monthVal = dateString
+      if (date && dateString != '') {
+        this.queryParam.queryDate = dateString
+      } else {
+        this.queryParam.queryDate = void 0
+      }
+    },
+    // 查询
+    handleSearch () {
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          _this.$refs.table.refresh(true)
+        } else {
+          _this.$message.error('请选择查询月份')
+          return false
+        }
+      })
+    },
+    // 记账主体
+    belongDealerChange (val) {
+      this.queryParam.belongDealerSn = val.key
+    },
+    // 统计
+    getCount (params) {
+      subsidyMonthCount(params).then(res => {
+        if (res.status == 200 && res.data) {
+          this.totalData = res.data
+        } else {
+          this.totalData = null
+        }
+      })
+    },
+    // 地区
+    areaChange (val) {
+      this.queryParam.dealer.provinceSn = val[0] ? val[0] : undefined
+      this.queryParam.dealer.citySn = val[1] ? val[1] : undefined
+      this.queryParam.dealer.districtSn = val[2] ? val[2] : undefined
+    },
+    // 区域分区  change
+    subareaChange (val) {
+      this.queryParam.subareaArea.subareaSn = val[0] ? val[0] : ''
+      this.queryParam.subareaArea.subareaAreaSn = val[1] ? val[1] : ''
+    },
+    //  重置
+    resetSearchForm () {
+      this.monthVal = moment().format('YYYY-MM')
+      this.queryParam.queryDate = moment().format('YYYY-MM')
+      this.queryParam.dealer.provinceSn = undefined
+      this.queryParam.dealer.citySn = undefined
+      this.queryParam.dealer.districtSn = undefined
+      this.queryParam.dealer.dealerName = undefined
+      this.queryParam.subareaArea.subareaSn = ''
+      this.queryParam.subareaArea.subareaAreaSn = ''
+      this.queryParam.dealerLevel = undefined
+      this.queryParam.belongDealerSn = undefined
+      this.$refs.belongDealer.resetForm()
+      this.totalData = null
+      this.$refs.subarea.clearData()
+      this.$refs.areaList.clearData()
+      this.$refs.table.clearTable()
+      this.$refs.ruleForm.resetFields()
+    },
+    //  导出  必填判断
+    handleExport () {
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          _this.exportList()
+        } else {
+          _this.$message.error('请选择查询月份')
+          return false
+        }
+      })
+    },
+    // 导出
+    exportList () {
+      const _this = this
+      const params = JSON.parse(JSON.stringify(_this.queryParam))
+      params.bizYear = params.queryDate.split('-')[0]
+      params.bizMonth = params.queryDate.split('-')[1]
+      _this.$store.state.app.curActionPermission = 'M_tireSubsidyExport'
+      delete params.queryDate
+      _this.exportLoading = true
+      _this.spinning = true
+      hdExportExcel(subsidyMonthExport, params, '轮胎服务费运费报表(' + this.queryParam.queryDate + '月份)-', function () {
+        _this.exportLoading = false
+        _this.spinning = false
+        _this.$store.state.app.curActionPermission = ''
+      })
+    },
+    // 初始化
+    pageInit () {
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        this.setTableH()
+      })
+      this.resetSearchForm()
+    },
+    // 计算表格高度
+    setTableH () {
+      const tableSearchH = this.$refs.tableSearch.offsetHeight
+      this.tableHeight = window.innerHeight - tableSearchH - 230
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+    }
+  },
+  activated () {
+    // 如果是新页签打开,则重置当前页面
+    if (this.$store.state.app.isNewTab) {
+      this.pageInit()
+    }
+  }
+}
+</script>
+<style lang="less" scoped>
+  .monthBox{
+    width: 100%;
+    /deep/.ant-calendar-picker-icon{
+      display:none !important;
+    }
+    /deep/.ant-calendar-picker input{
+      text-align:center;
+    }
+  }
+</style>

+ 12 - 12
src/views/salesManagement/examineVerify/list.vue

@@ -6,7 +6,7 @@
         <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)">
           <a-row :gutter="15">
             <a-col :md="6" :sm="24">
-              <a-form-item label="创建时间">
+              <a-form-item label="下推时间">
                 <rangeDate ref="rangeDate" :value="time" @change="dateChange" />
               </a-form-item>
             </a-col>
@@ -204,8 +204,8 @@ export default {
         moment(getDate.getCurrMonthDays().endtime, 'YYYY-MM-DD')
       ],
       queryParam: { //  查询条件
-        beginDate: getDate.getThreeMonthDays().starttime,
-        endDate: getDate.getCurrMonthDays().endtime,
+        pushedBeginDate: getDate.getThreeMonthDays().starttime,
+        pushedEndDate: getDate.getCurrMonthDays().endtime,
         buyerSn: undefined, //  客户名称
         salesBillNo: '', //  销售单号
         dispatchBillNo: '', // 备货单号
@@ -261,7 +261,7 @@ export default {
     columns () {
       const arr = [
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
-        { title: '创建时间', dataIndex: 'createDate', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '下推时间', dataIndex: 'pushedDate', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单据来源', dataIndex: 'salesBillEntity.salesBillSourceDictValue', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '销售单号', scopedSlots: { customRender: 'salesBillNo' }, width: '9%', align: 'center' },
         { title: '备货单号', scopedSlots: { customRender: 'dispatchBillNo' }, width: '9%', align: 'center' },
@@ -274,10 +274,10 @@ export default {
         { title: '打印次数', dataIndex: 'stockUpPrintTimes', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '8%', align: 'center' }
       ]
-	  // 仓库管理权限设置是否显示 (当客户有且只有一条仓库管理权限时,不显示仓库信息)
-	  if (this.isShowWarehouse) {
-	    arr.splice(7, 0, { title: '仓库', dataIndex: 'warehouseName', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true })
-	  }
+      // 仓库管理权限设置是否显示 (当客户有且只有一条仓库管理权限时,不显示仓库信息)
+      if (this.isShowWarehouse) {
+        arr.splice(7, 0, { title: '仓库', dataIndex: 'warehouseName', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true })
+      }
       if (this.$hasPermissions('M_examineVerifyList_salesPrice')) { //  售价权限
         arr.splice(this.isShowWarehouse ? 9 : 8, 0, { title: '售价', dataIndex: 'totalAmount', width: '5%', align: 'right', customRender: text => ((text || text == 0) ? this.toThousands(text) : '--') })
       }
@@ -291,8 +291,8 @@ export default {
     },
     //  时间  change
     dateChange (date) {
-      this.queryParam.beginDate = date[0]
-      this.queryParam.endDate = date[1]
+      this.queryParam.pushedBeginDate = date[0]
+      this.queryParam.pushedEndDate = date[1]
     },
     subareaChange (val) {
       this.queryParam.subareaArea.subareaSn = val[0] ? val[0] : undefined
@@ -301,8 +301,8 @@ export default {
     //  重置
     resetSearchForm () {
       this.$refs.rangeDate.resetDate(this.time)
-      this.queryParam.beginDate = getDate.getThreeMonthDays().starttime
-      this.queryParam.endDate = getDate.getCurrMonthDays().endtime
+      this.queryParam.pushedBeginDate = getDate.getThreeMonthDays().starttime
+      this.queryParam.pushedEndDate = getDate.getCurrMonthDays().endtime
       this.queryParam.buyerSn = undefined
       this.$refs.dealerSubareaScopeList.resetForm()
       this.queryParam.salesBillNo = ''

+ 28 - 15
src/views/salesManagement/salesQueryNew/list.vue

@@ -144,23 +144,31 @@
             <a-button type="primary" v-if="$hasPermissions('B_salesAdd')" @click="handleAdd">新增</a-button>
             <a-button type="primary" class="button-info" v-if="$hasPermissions('B_convertExpense')" @click="toWaitCostOrder">批量转</a-button>
           </div>
-          <div style="flex-grow: 1;display: flex;justify-content: space-between;align-items: center;">
+          <div style="flex-grow: 1;display: flex;justify-content: space-between;align-items: center;flex-wrap: wrap;">
             <div class="tongji-bar">
-              <div>
-                总单数:<strong>{{ totalData&&(totalData.totalRecord || totalData.totalRecord==0) ? totalData.totalRecord : '--' }}</strong>;
-                总款数:<strong>{{ totalData&&totalData.totalCategory || totalData.totalCategory == 0 ? totalData.totalCategory : '--' }}</strong>;
-                总数量:<strong>{{ totalData&&(totalData.totalQty || totalData.totalQty==0) ? totalData.totalQty : '--' }}</strong>;
-                已下推数量:<strong>{{ totalData&&(totalData.totalPushedQty || totalData.totalPushedQty==0) ? totalData.totalPushedQty : '--' }}</strong>;
-                已发货数量:<strong>{{ totalData&&(totalData.totalDispatchQty || totalData.totalDispatchQty==0) ? totalData.totalDispatchQty : '--' }}</strong>;
-                已取消数量:<strong>{{ totalData&&(totalData.totalCancelQty || totalData.totalCancelQty==0) ? totalData.totalCancelQty : '--' }}</strong>;
-                待下推数量:<strong>{{ totalData&&(totalData.totalUnpushedQty || totalData.totalUnpushedQty==0) ? totalData.totalUnpushedQty : '--' }}</strong>;
+              <div class="tongji-bar-col">
+                <div>总单数:<strong>{{ totalData&&(totalData.totalRecord || totalData.totalRecord==0) ? totalData.totalRecord : '0' }}</strong>;</div>
+                <div>总款数:<strong>{{ totalData&&totalData.totalCategory || totalData.totalCategory == 0 ? totalData.totalCategory : '0' }}</strong>;</div>
               </div>
-              <div v-if="$hasPermissions('M_salesQueryList_salesPrice')">
-                总售价:<strong>{{ totalData&&(totalData.totalAmount || totalData.totalAmount==0) ? toThousands(totalData.totalAmount) : '--' }}</strong>;
-                已下推金额:<strong>{{ totalData&&(totalData.totalPushedAmount || totalData.totalPushedAmount==0) ? toThousands(totalData.totalPushedAmount) : '--' }}</strong>;
-                已取消金额:<strong>{{ totalData&&(totalData.totalCancelAmount || totalData.totalCancelAmount==0) ? toThousands(totalData.totalCancelAmount) : '--' }}</strong>;
-                待下推金额:<strong>{{ totalData&&(totalData.totalUnpushedAmount || totalData.totalUnpushedAmount==0) ? toThousands(totalData.totalUnpushedAmount) : '--' }}</strong>;
-                已发货金额:<strong>{{ totalData&&(totalData.totalDispatchAmount || totalData.totalDispatchAmount==0) ? toThousands(totalData.totalDispatchAmount) : '--' }}</strong>;
+              <div class="tongji-bar-col">
+                <div>总数量:<strong>{{ totalData&&(totalData.totalQty || totalData.totalQty==0) ? totalData.totalQty : '0' }}</strong>;</div>
+                <div v-if="$hasPermissions('M_salesQueryList_salesPrice')">总售价:<strong>{{ totalData&&(totalData.totalAmount || totalData.totalAmount==0) ? toThousands(totalData.totalAmount) : '0' }}</strong>;</div>
+              </div>
+              <div class="tongji-bar-col">
+                <div>待审核数量:<strong>{{ totalData&&(totalData.totalWaitAuditQty || totalData.totalWaitAuditQty==0) ? totalData.totalWaitAuditQty : '0' }}</strong>;</div>
+                <div v-if="$hasPermissions('M_salesQueryList_salesPrice')">待审核金额:<strong>{{ totalData&&(totalData.totalWaitAuditAmount || totalData.totalWaitAuditAmount==0) ? toThousands(totalData.totalWaitAuditAmount) : '0' }}</strong>;</div>
+              </div>
+              <div class="tongji-bar-col">
+                <div>待下推数量:<strong>{{ totalData&&(totalData.totalUnpushedQty || totalData.totalUnpushedQty==0) ? totalData.totalUnpushedQty : '0' }}</strong>;</div>
+                <div v-if="$hasPermissions('M_salesQueryList_salesPrice')">待下推金额:<strong>{{ totalData&&(totalData.totalUnpushedAmount || totalData.totalUnpushedAmount==0) ? toThousands(totalData.totalUnpushedAmount) : '0' }}</strong>;</div>
+              </div>
+              <div class="tongji-bar-col">
+                <div>下推数量:<strong>{{ totalData&&(totalData.totalPushedQty || totalData.totalPushedQty==0) ? totalData.totalPushedQty : '0' }}</strong>;</div>
+                <div v-if="$hasPermissions('M_salesQueryList_salesPrice')">下推金额:<strong>{{ totalData&&(totalData.totalPushedAmount || totalData.totalPushedAmount==0) ? toThousands(totalData.totalPushedAmount) : '0' }}</strong>;</div>
+              </div>
+              <div class="tongji-bar-col">
+                <div>转单数量:<strong>{{ totalData&&(totalData.totalTransferQty || totalData.totalTransferQty==0) ? totalData.totalTransferQty : '0' }}</strong>;</div>
+                <div v-if="$hasPermissions('M_salesQueryList_salesPrice')">转单金额:<strong>{{ totalData&&(totalData.totalTransferAmount || totalData.totalTransferAmount==0) ? toThousands(totalData.totalTransferAmount) : '0' }}</strong>;</div>
               </div>
             </div>
             <div>
@@ -904,5 +912,10 @@ export default {
         text-overflow: ellipsis;
       }
     }
+    .tongji-bar{
+      flex:1;
+      display: flex;
+      align-items: center;
+    }
   }
 </style>

+ 384 - 0
src/views/setting/tireSubsidySetting/addSubsidyList.vue

@@ -0,0 +1,384 @@
+<template>
+  <div>
+    <a-card size="small" :bordered="false" class="addSubsidyList-wrap searchBoxNormal">
+      <!-- 搜索条件 -->
+      <div class="table-page-search-wrapper" ref="tableSearch">
+        <a-form-model
+          id="addSubsidyList-form"
+          ref="ruleForm"
+          class="form-model-con"
+          layout="inline"
+          :model="queryParam">
+          <a-row :gutter="15">
+            <a-col :md="5" :sm="24">
+              <a-form-model-item label="客户名称">
+                <custList dataAuthFlag="0" ref="dealerSubareaScopeList" id="addSubsidyList-dealerName" placeholder="请输入客户名称" @change="custChange"></custList>
+              </a-form-model-item>
+            </a-col>
+            <a-col :md="5" :sm="24">
+              <a-form-item label="区域">
+                <subarea id="addSubsidyList-subarea" ref="subarea" @change="subareaChange"></subarea>
+              </a-form-item>
+            </a-col>
+            <a-col :md="5" :sm="24">
+              <a-form-model-item label="地区">
+                <AreaList id="addSubsidyList-areaList" changeOnSelect ref="areaList" @change="areaChange" defValKey="id"></AreaList>
+              </a-form-model-item>
+            </a-col>
+            <a-col :md="5" :sm="24">
+              <a-form-model-item label="状态">
+                <v-select
+                  v-model="queryParam.subsidyQueryStatus"
+                  id="addSubsidyList-subsidyQueryStatus"
+                  code="INCREMENT_SUBSIDY_QUERY_STATUS"
+                  placeholder="请选择状态"
+                  allowClear></v-select>
+              </a-form-model-item>
+            </a-col>
+            <a-col :md="4" :sm="24">
+              <a-button
+                type="primary"
+                @click="$refs.table.refresh(true)"
+                :disabled="disabled"
+                id="addSubsidyList-refresh">查询</a-button>
+              <a-button
+                style="margin-left: 8px"
+                @click="resetSearchForm"
+                :disabled="disabled"
+                id="addSubsidyList-reset">重置</a-button>
+            </a-col>
+          </a-row>
+        </a-form-model>
+      </div>
+    </a-card>
+    <a-card size="small" :bordered="false">
+      <a-spin :spinning="spinning" tip="Loading...">
+        <!-- 操作按钮 -->
+        <div class="table-operator">
+          <a-button v-if="$hasPermissions('B_tireSubsidySetting_add')" id="addSubsidyList-add" type="primary" @click="handleAdd">新增</a-button>
+        </div>
+        <!-- 列表 -->
+        <s-table
+          class="sTable fixPagination"
+          ref="table"
+          size="small"
+          :rowKey="(record) => record.id"
+          :style="{ height: tableHeight+70+'px' }"
+          :columns="columns"
+          :data="loadData"
+          :scroll="{ y: tableHeight}"
+          :defaultLoadData="false"
+          bordered>
+          <!-- 客户名称 -->
+          <template slot="customName" slot-scope="text, record">
+            {{ record.dealerEntity&&record.dealerEntity.dealerName?record.dealerEntity.dealerName:record.defaultFlag==1?'默认':'--' }}
+          </template>
+          <!-- 结束时间 -->
+          <template slot="endDate" slot-scope="text, record">
+            {{ record.status==='END'? record.ruleEndDate:'--' }}
+          </template>
+          <!-- 操作 -->
+          <template slot="action" slot-scope="text, record">
+            <a-button
+              size="small"
+              type="link"
+              class="button-info"
+              @click="handleEdit(record)"
+              v-if="$hasPermissions('B_tireSubsidySetting_edit')&&record.status=='IN_USE' && record.isSomeTimeFlag"
+              :id="'addSubsidyList-edit-btn'+record.id"
+            >
+              编辑
+            </a-button>
+            <a-button
+              size="small"
+              type="link"
+              class="button-error"
+              :id="'costCollectionList-end-btn'+record.id"
+              v-if="$hasPermissions('B_tireSubsidySetting_end')&&record.status=='IN_USE'&&record.defaultFlag==0&&!record.isSomeTimeFlag"
+              @click="handleEndOrDel(record,'end')"
+            >
+              结束
+            </a-button>
+            <a-button
+              size="small"
+              type="link"
+              class="button-error"
+              @click="handleEndOrDel(record)"
+              v-if="$hasPermissions('B_tireSubsidySetting_del')&&record.status=='IN_USE'&&record.defaultFlag==0&&record.isSomeTimeFlag"
+              :id="'addSubsidyList-del-btn'+record.id"
+            >
+              删除
+            </a-button>
+            <span v-if="record.status=='END'">--</span>
+          </template>
+        </s-table>
+      </a-spin>
+    </a-card>
+    <!-- 新增 -->
+    <add-subsidy-modal v-drag :openModal="openAddSubsidyModal" :pageType="pageType" @ok="$refs.table.refresh(true)" @close="openAddSubsidyModal = false" />
+    <!-- 编辑 -->
+    <edit-modal
+      v-drag
+      :openModal="openEditSubsidyModal"
+      ref="editSubsidyModal"
+      :pageType="pageType"
+      @ok="$refs.table.refresh(true)"
+      @close="openEditSubsidyModal = false" ></edit-modal>
+  </div>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import { STable, VSelect } from '@/components'
+import subarea from '@/views/common/subarea.js'
+import AreaList from '@/views/common/areaList.js'
+import addSubsidyModal from './addSubsidyModal.vue'
+import editModal from './editModal.vue'
+import custList from '@/views/common/custList.vue'
+// 接口
+import { tireSubsidyRuleList, endSubsidyRule, delSubsidyRule } from '@/api/subsidyRule'
+export default {
+  name: 'AddSubsidyList',
+  mixins: [commonMixin],
+  components: { STable, VSelect, subarea, AreaList, custList, addSubsidyModal, editModal },
+  props: {
+    pageType: { //  弹框显示状态
+      type: String,
+      default: ''
+    }
+  },
+  data () {
+    return {
+      spinning: false,
+      disabled: false, //  查询、重置按钮是否可操作
+      tableHeight: 0, // 表格高度
+      //  查询条件
+      queryParam: {
+        subareaArea: {
+          subareaSn: '', // 区域
+          subareaAreaSn: '' // 分区
+        },
+        dealerSn: undefined, // 客户sn
+        dealerName: undefined, // 客户名称
+        provinceSn: undefined, // 省
+        citySn: undefined, // 市
+        districtSn: undefined, // 区
+        ruleType: undefined, // 页面类型
+        subsidyQueryStatus: 'NOT_FINISH'// 状态
+      },
+      openAddSubsidyModal: false, // 新增弹窗
+      openEditSubsidyModal: false, // 编辑弹窗
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        this.spinning = true
+        this.queryParam.ruleType = this.pageType
+        const params = Object.assign(parameter, this.queryParam)
+        // 获取列表数据  有分页
+        return tireSubsidyRuleList(params).then(res => {
+          let data
+          if (res.status == 200) {
+            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
+              if (data.list[i].ruleStartDate) {
+                data.list[i].ruleStartDate = this.pageType === 'SUBSIDY_QUARTER_FEE' ? this.getYearAndQuarter(data.list[i].ruleStartDate).showWords : this.getYear(data.list[i].ruleStartDate)
+              }
+              if (data.list[i].ruleEndDate) {
+                data.list[i].ruleEndDate = this.pageType === 'SUBSIDY_QUARTER_FEE' ? this.getYearAndQuarter(data.list[i].ruleEndDate).showWords : this.getYear(data.list[i].ruleEndDate)
+              }
+              if (data.list[i].ruleStartDate) {
+                data.list[i].isSomeTimeFlag = this.pageType === 'SUBSIDY_QUARTER_FEE' ? this.isSameQuarter(data.list[i].ruleStartDate) : this.isSameYear(data.list[i].ruleStartDate)
+              }
+            }
+          }
+          this.disabled = false
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  watch: {
+    '$store.state.app.winHeight' (newValue, oldValue) { //  窗口变更时,需同时更改表格高度
+      this.setTableH()
+    }
+  },
+  computed: {
+    columns () {
+      const _this = this
+      const arr = [
+        { title: '序号', dataIndex: 'no', width: '5%', align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '区域', dataIndex: 'subareaArea.subareaName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '分区', dataIndex: 'subareaArea.subareaAreaName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户名称', dataIndex: 'dealerEntity.dealerName', width: '15%', align: 'center', scopedSlots: { customRender: 'customName' }, ellipsis: true },
+        { title: '开始' + (_this.pageType === 'SUBSIDY_QUARTER_FEE' ? '季度' : '年份'), dataIndex: 'ruleStartDate', width: '13%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '结束' + (_this.pageType === 'SUBSIDY_QUARTER_FEE' ? '季度' : '年份'), dataIndex: 'ruleEndDate', width: '13%', align: 'center', scopedSlots: { customRender: 'endDate' } },
+        { title: '增量补贴(' + (_this.pageType === 'SUBSIDY_QUARTER_FEE' ? '季度)' : '年度)'),
+          children: [
+            { title: '1阶目标(条)', dataIndex: 'ruleTarget1', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+            { title: '1阶补贴(元)', dataIndex: 'ruleValue1', width: '12%', align: 'right', customRender: text => { return (text || text == 0) ? _this.toThousands(text) : '--' } },
+            { title: '2阶目标(条)', dataIndex: 'ruleTarget2', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+            { title: '2阶补贴(元)', dataIndex: 'ruleValue2', width: '12%', align: 'right', customRender: text => { return (text || text == 0) ? _this.toThousands(text) : '--' } },
+            { title: '3阶目标(条)', dataIndex: 'ruleTarget3', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+            { title: '3阶补贴(元)', dataIndex: 'ruleValue3', width: '12%', align: 'right', customRender: text => { return (text || text == 0) ? _this.toThousands(text) : '--' } }
+          ] },
+        { title: '状态', dataIndex: 'statusDictValue', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '操作', scopedSlots: { customRender: 'action' }, width: '11%', align: 'center' }
+      ]
+      return arr
+    }
+  },
+  methods: {
+    // 计算是第几季度
+    getYearAndQuarter (dateString) {
+      // 解析日期字符串
+      const date = new Date(dateString)
+      // 获取年份
+      const year = date.getFullYear()
+      // 获取月份
+      const month = date.getMonth() + 1 // getMonth() 返回的是0-11,所以要加1
+      // 确定季度
+      let quarter
+      if (month >= 1 && month <= 3) {
+        quarter = 1
+      } else if (month >= 4 && month <= 6) {
+        quarter = 2
+      } else if (month >= 7 && month <= 9) {
+        quarter = 3
+      } else {
+        quarter = 4
+      }
+      return { showWords: year + '年' + quarter + '季度', quarter }
+    },
+    // 获取年份
+    getYear (dateString) {
+      const year = new Date(dateString).getFullYear()
+      return year
+    },
+    // 当前时间与创建时间是否属于同一年
+    isSameYear (fixedDate) {
+      // 获取当前时间
+      const currentDate = new Date()
+      const currentYear = currentDate.getFullYear()
+
+      // 比较年份
+      return currentYear === fixedDate
+    },
+    // 当前时间与创建时间是否属于同一季度
+    isSameQuarter (inputVal) {
+      const currentDate = new Date()
+      const quarterNum = this.getYearAndQuarter(currentDate).quarter
+      const yearNum = currentDate.getFullYear()
+      const fullWord = yearNum + '年' + quarterNum + '季度'
+      return fullWord === inputVal
+    },
+    // 新增
+    handleAdd () {
+      this.openAddSubsidyModal = true
+    },
+    // 客户名称 change
+    custChange (val) {
+      this.queryParam.dealerName = val.name
+      this.queryParam.dealerSn = val.key
+    },
+    // 地区
+    areaChange (val) {
+      this.queryParam.provinceSn = val[0] ? val[0] : undefined
+      this.queryParam.citySn = val[1] ? val[1] : undefined
+      this.queryParam.districtSn = val[2] ? val[2] : undefined
+    },
+    // 区域分区  change
+    subareaChange (val) {
+      this.queryParam.subareaArea.subareaSn = val[0] ? val[0] : ''
+      this.queryParam.subareaArea.subareaAreaSn = val[1] ? val[1] : ''
+    },
+    //  重置
+    resetSearchForm () {
+      this.queryParam.provinceSn = undefined
+      this.queryParam.citySn = undefined
+      this.queryParam.districtSn = undefined
+      this.queryParam.dealerName = undefined
+      this.queryParam.dealerSn = undefined
+      this.queryParam.ruleType = undefined
+      this.queryParam.subareaArea.subareaSn = ''
+      this.queryParam.subareaArea.subareaAreaSn = ''
+      this.queryParam.subsidyQueryStatus = 'NOT_FINISH'
+      this.$refs.subarea.clearData()
+      this.$refs.dealerSubareaScopeList.resetForm()
+      this.$refs.areaList.clearData()
+      this.$refs.table.refresh(true)
+    },
+    // 编辑
+    handleEdit (row) {
+      const sendData = {
+        dealerName: row.dealerEntity && row.dealerEntity.dealerName ? row.dealerEntity.dealerName : undefined,
+        defaultFlag: row.defaultFlag,
+        ruleSn: row.ruleSn,
+        ruleTarget1: row.ruleTarget1 || undefined,
+        ruleValue1: row.ruleValue1 || undefined,
+        ruleTarget2: row.ruleTarget2 || undefined,
+        ruleValue2: row.ruleValue2 || undefined,
+        ruleTarget3: row.ruleTarget3 || undefined,
+        ruleValue3: row.ruleValue3 || undefined
+      }
+      this.$refs.editSubsidyModal.getFormData(sendData)
+      this.openEditSubsidyModal = true
+    },
+    // 结束  删除
+    handleEndOrDel (row, type) {
+      const ajaxName = type === 'end' ? endSubsidyRule : delSubsidyRule
+      let tipWord = null
+      if (this.pageType === 'SUBSIDY_QUARTER_FEE') {
+        tipWord = '确定' + (type === 'end' ? '结束' : '删除') + '季度补贴吗?' + (type === 'end' ? '结束' : '删除') + '后以默认季度补贴计算'
+      } else {
+        tipWord = '确定' + (type === 'end' ? '结束' : '删除') + '年度增量补贴吗?' + (type === 'end' ? '结束' : '删除') + '后以默认年度增量补贴计算'
+      }
+      const _this = this
+      _this.$confirm({
+        title: '提示',
+        content: tipWord,
+        centered: true,
+        onOk () {
+          ajaxName({ ruleSn: row.ruleSn, ruleType: _this.pageType }).then(res => {
+            if (res.status == 200) {
+              if (res.data && res.data === 'FALSE') {
+                _this.$info({
+                  title: '提示',
+                  content: '当前规则不可操作,请刷新后重试',
+                  centered: true,
+                  onOk () {
+                    console.log('知道了')
+                  }
+                })
+              } else {
+                _this.$message.success(res.message)
+                _this.$refs.table.refresh(true)
+              }
+            }
+          })
+        }
+      })
+    },
+    // 初始化
+    pageInit () {
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        this.setTableH()
+      })
+      this.resetSearchForm()
+    },
+    // 计算表格高度
+    setTableH () {
+      const tableSearchH = this.$refs.tableSearch.offsetHeight
+      this.tableHeight = window.innerHeight - tableSearchH - 300
+    }
+  },
+  mounted () {
+    this.pageInit()
+  }
+}
+</script>

+ 346 - 0
src/views/setting/tireSubsidySetting/addSubsidyModal.vue

@@ -0,0 +1,346 @@
+<template>
+  <a-modal
+    centered
+    class="addSubsidy-modal"
+    :footer="null"
+    :maskClosable="false"
+    title="新增"
+    v-model="isShow"
+    @cancel="isShow=false"
+    :width="700">
+    <div>
+      <a-spin :spinning="spinning" tip="Loading...">
+        <a-form-model
+          id="addSubsidyModal-form"
+          ref="ruleForm"
+          :model="form"
+          :rules="rules"
+          :label-col="formItemLayout.labelCol"
+          :wrapper-col="formItemLayout.wrapperCol"
+        >
+          <div class="formList" style="margin-bottom:15px;">
+            <a-radio-group id="addSubsidyModal-defaultFlag" v-model="form.defaultFlag" @change="defaultChange">
+              <a-radio :value="0" id="addSubsidyModal-defaultFlag0">
+                指定客户
+              </a-radio>
+              <a-radio :value="1" id="addSubsidyModal-defaultFlag1">
+                默认
+              </a-radio>
+            </a-radio-group>
+          </div>
+          <a-form-model-item label="客户名称" prop="dealerSn" v-if="form.defaultFlag==0">
+            <custList style="width:90%;" dataAuthFlag="0" ref="dealerSubareaScopeList" id="addSubsidyModal-dealerName" @change="custChange"></custList>
+          </a-form-model-item>
+          <a-form-model-item label="增量补贴(季度)" prop="ruleTarget1">
+            <div>
+              大于等于<a-input-number
+                v-model="form.ruleTarget1"
+                :min="1"
+                style="width:80px;margin:0 6px;"
+                :max="999999"
+                id="addSubsidyModal-ruleTarget1"
+                :precision="0"
+                placeholder="请输入"/>条,每条补贴
+              <a-input-number
+                v-model="form.ruleValue1"
+                :min="0.01"
+                id="addSubsidyModal-ruleValue1"
+                style="width:80px;margin:0 6px;"
+                :max="999999"
+                :precision="2"
+                placeholder="请输入"/>元
+            </div>
+            <div>
+              大于等于<a-input-number
+                v-model="form.ruleTarget2"
+                :min="form.ruleTarget1"
+                style="width:80px;margin:0 6px;"
+                :max="999999"
+                id="addSubsidyModal-ruleTarget2"
+                :precision="0"
+                placeholder="请输入"/>条,每条补贴
+              <a-input-number
+                v-model="form.ruleValue2"
+                :min="form.ruleValue1"
+                id="addSubsidyModal-ruleValue2"
+                style="width:80px;margin:0 6px;"
+                :max="999999"
+                :precision="2"
+                placeholder="请输入"/>元
+            </div>
+            <div>
+              大于等于<a-input-number
+                v-model="form.ruleTarget3"
+                :min="form.ruleTarget2"
+                style="width:80px;margin:0 6px;"
+                :max="999999"
+                id="addSubsidyModal-ruleTarget3"
+                :precision="0"
+                placeholder="请输入"/>条,每条补贴
+              <a-input-number
+                v-model="form.ruleValue3"
+                :min="form.ruleValue2"
+                id="addSubsidyModal-ruleValue3"
+                style="width:80px;margin:0 6px;"
+                :max="999999"
+                :precision="2"
+                placeholder="请输入"/>元
+            </div>
+          </a-form-model-item>
+          <div class="formList formBoxList" v-if="feeDataList&&feeDataList.length>0">
+            <div v-for="item in feeDataList" :key="item.id" style="display:flex;align-items:baseline;">
+              <span>{{ item.effectType==1?'当前':'次月' }}增量补贴({{ pageType==='SUBSIDY_QUARTER_FEE'?'季':'年' }}度):</span>
+              <div>
+                <p v-if="item.ruleTarget1">大于等于{{ item.ruleTarget1 }}条,每条补贴{{ item.ruleValue1 }}元;</p>
+                <p v-if="item.ruleTarget2">大于等于{{ item.ruleTarget2 }}条,每条补贴{{ item.ruleValue2 }}元;</p>
+                <p v-if="item.ruleTarget3">大于等于{{ item.ruleTarget3 }}条,每条补贴{{ item.ruleValue3 }}元;</p>
+              </div>
+            </div>
+          </div>
+        </a-form-model>
+        <div class="btn-cont">
+          <a-button id="addSubsidyModal-cancel" @click="isShow = false" style="margin-right: 15px;">取消</a-button>
+          <a-button type="primary" id="addSubsidyModal-save" @click="handleSave">保存</a-button>
+        </div>
+      </a-spin>
+    </div>
+  </a-modal>
+</template>
+
+<script>
+// 组件
+import { VSelect } from '@/components'
+import custList from '@/views/common/custList.vue'
+// 接口
+import { subsidyRuleSave, createSubsidyRule, getSubsidyRuleList } from '@/api/subsidyRule'
+export default {
+  name: 'AddSubsidyModal',
+  components: { VSelect, custList },
+  props: {
+    openModal: { //  弹框显示状态
+      type: Boolean,
+      default: false
+    },
+    pageType: { //  页面类型
+      type: String,
+      default: ''
+    }
+  },
+  data () {
+    return {
+      isShow: this.openModal, //  是否打开弹框
+      spinning: false,
+      formItemLayout: {
+        labelCol: { span: 5 },
+        wrapperCol: { span: 17 }
+      },
+      // 提交数据
+      form: {
+        defaultFlag: 0, // 0指定客户  1默认
+        dealerSn: undefined, // 客户名称
+        ruleTarget1: undefined, // 增量补贴
+        ruleValue1: undefined,
+        ruleTarget2: undefined,
+        ruleValue2: undefined,
+        ruleTarget3: undefined,
+        ruleValue3: undefined
+      },
+      // 必填项判断
+      rules: {
+        dealerSn: [{ required: true, message: '请选择客户名称', trigger: 'change' }],
+        ruleTarget1: [{ required: true, message: '增量补贴不能为空', trigger: 'blur' }]
+      },
+      feeDataList: null
+    }
+  },
+  methods: {
+    // 客户名称 change
+    custChange (val) {
+      if (val && val.key) {
+        this.form.dealerSn = val.key
+        this.getHistoryData({ dealerSn: val.key, subsidyQueryStatus: 'NOT_FINISH', ruleType: this.pageType })
+      } else {
+        this.feeDataList = null
+      }
+    },
+    // 0指定客户  1默认客户  change
+    defaultChange (e) {
+      this.form.defaultFlag = e.target.value
+      this.form.dealerSn = undefined
+      if (e.target.value == '1') {
+        this.getHistoryData({ defaultFlag: 1, subsidyQueryStatus: 'NOT_FINISH', ruleType: this.pageType })
+      } else {
+        this.feeDataList = null
+      }
+    },
+    // 获取当月/次月  历史数据值
+    getHistoryData (ajaxData) {
+      this.spinning = true
+      getSubsidyRuleList(ajaxData).then(res => {
+        if (res.status == 200) {
+          this.feeDataList = res.data
+        } else {
+          this.feeDataList = null
+        }
+        this.spinning = false
+      })
+    },
+    // 保存
+    handleSave () {
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          // 为空判断
+          const newForm = JSON.parse(JSON.stringify(_this.form))
+          delete newForm.defaultFlag
+          delete newForm.dealerSn
+          delete newForm.ruleType
+          const flag = _this.isValid(newForm)
+          if (!flag) {
+            _this.$message.error('季度增量补贴【条数】与【补贴】不符合填写规则!')
+            return
+          }
+
+          _this.form.ruleType = _this.pageType
+          _this.spinning = true
+          subsidyRuleSave(_this.form).then(res => {
+            if (res.status == 200) {
+              if (!res.data) {
+                _this.isShow = false
+                _this.$message.success(res.message)
+                _this.$emit('ok')
+              } else {
+                _this.openTip(res.data)
+              }
+            }
+            _this.spinning = false
+          })
+        } else {
+          console.log('error submit!!')
+          return false
+        }
+      })
+    },
+    // 为空判断
+    isValid (obj) {
+      const { ruleTarget1, ruleValue1, ruleTarget2, ruleValue2, ruleTarget3, ruleValue3 } = obj
+
+      // 检查第一阶梯是否填写
+      if (!ruleTarget1 || !ruleValue1) {
+        return false
+      }
+
+      // 如果第三阶梯存在,检查第二阶梯是否存在以及值是否正确
+      if (ruleTarget3 || ruleValue3) {
+        if ((!ruleTarget2 || !ruleValue2) || (!ruleTarget3 || !ruleValue3)) {
+          return false
+        } else {
+          if (ruleValue1 >= ruleValue2 || ruleValue2 >= ruleValue3 || ruleTarget1 >= ruleTarget2 || ruleTarget2 >= ruleTarget3) {
+            return false
+          }
+        }
+      }
+
+      // 如果只有第二阶梯存在(没有第三阶梯),检查值是否正确
+      if ((ruleTarget2 || ruleValue2) && (!ruleTarget3 && !ruleValue3)) {
+        if (!ruleTarget2 || !ruleValue2) {
+          return false
+        } else {
+          if (ruleValue1 >= ruleValue2 || ruleTarget1 >= ruleTarget2) {
+            return false
+          }
+        }
+      }
+      // 所有条件都满足,返回true
+      return true
+    },
+    openTip (code) {
+      const _this = this
+      if (code === 'WAIT') {
+        this.$confirm({
+          title: '提示',
+          content: '将重新生成新的' + (_this.pageType === 'SUBSIDY_QUARTER_FEE' ? '季' : '年') + '度补贴,并结束当前' + (_this.pageType === 'SUBSIDY_QUARTER_FEE' ? '季' : '年') + '度增量补贴。',
+          centered: true,
+          onOk () {
+            createSubsidyRule(_this.form).then(res => {
+              if (res.status == 200) {
+                if (res.data && res.data === 'IN_USE') {
+                  const tipWord = '已存在【启用中】的' + (_this.pageType === 'SUBSIDY_QUARTER_FEE' ? '季' : '年') + '度增量补贴'
+                  _this.setInfoModal(tipWord)
+                } else {
+                  _this.isShow = false
+                  _this.$message.success(res.message)
+                  _this.$emit('ok')
+                }
+              }
+            })
+          }
+        })
+      } else {
+        const tipWord = '已存在【启用中】的' + (_this.pageType === 'SUBSIDY_QUARTER_FEE' ? '季' : '年') + '度增量补贴'
+        this.setInfoModal(tipWord)
+      }
+    },
+    // 提示弹窗
+    setInfoModal (tip) {
+      this.$info({
+        title: '提示',
+        content: tip,
+        centered: true,
+        onOk () {
+          console.log('知道了')
+        }
+      })
+    },
+    // 重置
+    resetFormData () {
+      if (this.form.defaultFlag == 0) {
+        this.$refs.dealerSubareaScopeList.resetForm()
+      }
+      this.form.defaultFlag = 0
+      this.form.dealerSn = undefined
+      this.form.ruleTarget1 = undefined
+      this.form.ruleValue1 = undefined
+      this.form.ruleTarget2 = undefined
+      this.form.ruleValue2 = undefined
+      this.form.ruleTarget3 = undefined
+      this.form.ruleValue3 = undefined
+      this.feeDataList = null
+      this.$refs.ruleForm.resetFields()
+    }
+  },
+  watch: {
+    //  父页面传过来的弹框状态
+    openModal (newValue, oldValue) {
+      this.isShow = newValue
+    },
+    //  重定义的弹框状态
+    isShow (newValue, oldValue) {
+      if (!newValue) {
+        this.$emit('close')
+        this.resetFormData()
+      }
+    }
+  }
+}
+</script>
+
+<style lang="less">
+  .addSubsidy-modal{
+    .formList{
+      margin-left:60px;
+    }
+    .formBoxList{
+      div{
+        margin-bottom:5px;
+      }
+    }
+    .ant-modal-body {
+      padding: 40px 40px 24px;
+    }
+    .btn-cont {
+      text-align: center;
+      margin: 35px 0 30px;
+    }
+  }
+</style>

+ 259 - 0
src/views/setting/tireSubsidySetting/costAddModal.vue

@@ -0,0 +1,259 @@
+<template>
+  <a-modal
+    centered
+    class="costAdd-modal"
+    :footer="null"
+    :maskClosable="false"
+    title="新增"
+    v-model="isShow"
+    @cancel="isShow=false"
+    :width="700">
+    <div>
+      <a-spin :spinning="spinning" tip="Loading...">
+        <a-form-model
+          id="costAddModal-form"
+          ref="ruleForm"
+          :model="form"
+          :rules="rules"
+          :label-col="formItemLayout.labelCol"
+          :wrapper-col="formItemLayout.wrapperCol"
+        >
+          <div class="formList" style="margin-bottom:15px;">
+            <a-radio-group id="costAddModal-defaultFlag" v-model="form.defaultFlag" @change="defaultChange">
+              <a-radio :value="0" id="costAddModal-defaultFlag0">
+                指定客户
+              </a-radio>
+              <a-radio :value="1" id="costAddModal-defaultFlag1">
+                默认
+              </a-radio>
+            </a-radio-group>
+          </div>
+          <a-form-model-item label="客户名称" prop="dealerSn" v-if="form.defaultFlag==0">
+            <custList dataAuthFlag="0" style="width:90%;" ref="dealerSubareaScopeList" id="costAddModal-dealerName" @change="custChange"></custList>
+          </a-form-model-item>
+          <a-form-model-item :label="pageType==='SERVICE_FEE'?'服务费比例':'运费补贴'" prop="ruleValue1">
+            <a-input-number
+              id="costAddModal-ruleValue1"
+              v-model="form.ruleValue1"
+              :min="0"
+              style="width:90%;"
+              :max="pageType==='SERVICE_FEE'?100:99"
+              :precision="2"
+              :placeholder="'请输入'+(pageType==='SERVICE_FEE'?'服务费比例':'运费补贴')"/>
+            <span style="margin-left:10px;">{{ pageType==='SERVICE_FEE'?'%':'元' }}</span>
+          </a-form-model-item>
+          <a-form-model-item label="生效方式" prop="effectType">
+            <a-radio-group v-model="form.effectType" id="costAddModal-effectType">
+              <a-radio :value="0" id="costAddModal-effectType0">
+                立即生效
+              </a-radio>
+              <a-radio :value="1" id="costAddModal-effectType1">
+                次月生效
+              </a-radio>
+            </a-radio-group>
+          </a-form-model-item>
+          <div class="formList formBoxList" v-if="feeDataList&&feeDataList.length>0">
+            <div v-for="item in feeDataList" :key="item.id">{{ item.effectType==1?'当前':'次月' }}{{ pageType==='SERVICE_FEE'?'服务费比例':'运费补贴' }}:{{ pageType==='SERVICE_FEE'?toThousands(item.ruleValue1*100):toThousands(item.ruleValue1) }}{{ pageType==='SERVICE_FEE'?'%':'元' }};</div>
+          </div>
+        </a-form-model>
+        <div class="btn-cont">
+          <a-button id="costAddModal-cancel" @click="isShow = false" style="margin-right: 15px;">取消</a-button>
+          <a-button type="primary" id="costAddModal-save" @click="handleSave">保存</a-button>
+        </div>
+      </a-spin>
+    </div>
+  </a-modal>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import { VSelect } from '@/components'
+import custList from '@/views/common/custList.vue'
+// 接口
+import { getSubsidyRuleList, subsidyRuleSave, createSubsidyRule } from '@/api/subsidyRule'
+export default {
+  name: 'CostAddModal',
+  mixins: [commonMixin],
+  components: { VSelect, custList },
+  props: {
+    openModal: { //  弹框显示状态
+      type: Boolean,
+      default: false
+    },
+    pageType: { //  页面类型
+      type: String,
+      default: ''
+    }
+  },
+  data () {
+    return {
+      isShow: this.openModal, //  是否打开弹框
+      spinning: false, // 页面加载状态
+      formItemLayout: {// form表单中label设置
+        labelCol: { span: 4 },
+        wrapperCol: { span: 17 }
+      },
+      // 提交数据
+      form: {
+        defaultFlag: 0, // 0指定客户  1默认
+        dealerSn: undefined, // 客户名称
+        ruleValue1: undefined, // 服务费比例
+        ruleType: undefined, // 弹窗类型
+        effectType: undefined// 生效方式
+      },
+      // 必填项判断
+      rules: {
+        dealerSn: [{ required: true, message: '请选择客户名称', trigger: 'change' }],
+        ruleValue1: [{ required: true, message: '请输入服务费比例', trigger: 'blur' }],
+        effectType: [{ required: true, message: '请选择生效方式', trigger: 'change' }]
+      },
+      feeDataList: null // 当月/次月费用数据
+    }
+  },
+  methods: {
+    // 客户名称 change
+    custChange (val) {
+      if (val && val.key) {
+        this.form.dealerSn = val.key
+        this.getHistoryData({ dealerSn: val.key, subsidyQueryStatus: 'NOT_FINISH', ruleType: this.pageType })
+      } else {
+        this.feeDataList = null
+      }
+    },
+    // 0指定客户  1默认客户  change
+    defaultChange (e) {
+      this.form.defaultChange = e.target.value
+      this.form.dealerSn = undefined
+      if (e.target.value == '1') {
+        this.getHistoryData({ defaultFlag: 1, subsidyQueryStatus: 'NOT_FINISH', ruleType: this.pageType })
+      } else {
+        this.feeDataList = null
+      }
+    },
+    // 获取当月/次月  历史数据值
+    getHistoryData (ajaxData) {
+      this.spinning = true
+      getSubsidyRuleList(ajaxData).then(res => {
+        if (res.status == 200) {
+          this.feeDataList = res.data
+        } else {
+          this.feeDataList = null
+        }
+        this.spinning = false
+      })
+    },
+    // 保存
+    handleSave () {
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          _this.form.ruleType = _this.pageType
+          _this.spinning = true
+          subsidyRuleSave(this.form).then(res => {
+            if (res.status == 200) {
+              if (!res.data) {
+                _this.isShow = false
+                _this.$message.success(res.message)
+                _this.$emit('ok')
+              } else {
+                _this.openTip(res.data)
+              }
+            }
+            _this.spinning = false
+          }).catch(err => {
+            _this.spinning = false
+          })
+        } else {
+          console.log('error submit!!')
+          return false
+        }
+      })
+    },
+    openTip (code) {
+      const _this = this
+      if (code === 'IN_USE') {
+        this.$confirm({
+          title: '提示',
+          content: '将重新生成新的' + (_this.pageType === 'SERVICE_FEE' ? '服务费比例' : '运费补贴') + ',并结束当前' + (_this.pageType === 'SERVICE_FEE' ? '服务费比例。' : '运费补贴。'),
+          centered: true,
+          onOk () {
+            createSubsidyRule(_this.form).then(res => {
+              if (res.status == 200) {
+                if (res.data && res.data === 'IN_USE') {
+                  const tipWord = '已存在【未开始】的' + (_this.pageType === 'SERVICE_FEE' ? '服务费比例' : '运费补贴')
+                  _this.setInfoModal(tipWord)
+                } else {
+                  _this.isShow = false
+                  _this.$message.success(res.message)
+                  _this.$emit('ok')
+                }
+              }
+            })
+          }
+        })
+      } else {
+        const tipWord = '已存在【未开始】的' + (_this.pageType === 'SERVICE_FEE' ? '服务费比例' : '运费补贴')
+        _this.setInfoModal(tipWord)
+      }
+    },
+    // 提示弹窗
+    setInfoModal (tip) {
+      this.$info({
+        title: '提示',
+        content: tip,
+        centered: true,
+        onOk () {
+          console.log('知道了')
+        }
+      })
+    },
+    // 重置
+    resetFormData () {
+      if (this.form.defaultFlag == 0) {
+        this.$refs.dealerSubareaScopeList.resetForm()
+      }
+      this.form.defaultFlag = 0
+      this.form.dealerSn = undefined
+      this.form.ruleValue1 = undefined
+      this.form.ruleType = undefined
+      this.form.effectType = undefined
+      this.feeDataList = null
+      this.$refs.ruleForm.resetFields()
+    }
+  },
+  watch: {
+    //  父页面传过来的弹框状态
+    openModal (newValue, oldValue) {
+      this.isShow = newValue
+    },
+    //  重定义的弹框状态
+    isShow (newValue, oldValue) {
+      if (!newValue) {
+        this.$emit('close')
+        this.resetFormData()
+      }
+    }
+  }
+}
+</script>
+
+<style lang="less">
+  .costAdd-modal{
+    .formList{
+      margin-left:42px;
+    }
+    .formBoxList{
+      div{
+        margin-bottom:5px;
+      }
+    }
+    .ant-modal-body {
+      padding: 40px 40px 24px;
+    }
+    .btn-cont {
+      text-align: center;
+      margin: 35px 0 30px;
+    }
+  }
+</style>

+ 321 - 0
src/views/setting/tireSubsidySetting/costCollectionList.vue

@@ -0,0 +1,321 @@
+<template>
+  <div>
+    <a-card size="small" :bordered="false" class="costCollectionList-wrap searchBoxNormal">
+      <!-- 搜索条件 -->
+      <div class="table-page-search-wrapper" ref="tableSearch">
+        <a-form-model
+          id="costCollectionList-form"
+          ref="ruleForm"
+          class="form-model-con"
+          layout="inline"
+          :model="queryParam">
+          <a-row :gutter="15">
+            <a-col :md="5" :sm="24">
+              <a-form-model-item label="客户名称">
+                <custList dataAuthFlag="0" ref="dealerSubareaScopeList" id="costCollectionList-dealerName" placeholder="请输入客户名称" @change="custChange"></custList>
+              </a-form-model-item>
+            </a-col>
+            <a-col :md="5" :sm="24">
+              <a-form-item label="区域">
+                <subarea id="costCollectionList-subarea" ref="subarea" @change="subareaChange"></subarea>
+              </a-form-item>
+            </a-col>
+            <a-col :md="5" :sm="24">
+              <a-form-model-item label="地区">
+                <AreaList id="costCollectionList-areaList" changeOnSelect ref="areaList" @change="areaChange" defValKey="id"></AreaList>
+              </a-form-model-item>
+            </a-col>
+            <a-col :md="5" :sm="24">
+              <a-form-model-item label="状态">
+                <v-select
+                  v-model="queryParam.subsidyQueryStatus"
+                  id="costCollectionList-subsidyQueryStatus"
+                  code="SUBSIDY_QUERY_STATUS"
+                  placeholder="请选择状态"
+                  allowClear></v-select>
+              </a-form-model-item>
+            </a-col>
+            <a-col :md="4" :sm="24">
+              <a-button
+                type="primary"
+                @click="$refs.table.refresh(true)"
+                :disabled="disabled"
+                id="costCollectionList-refresh">查询</a-button>
+              <a-button
+                style="margin-left: 8px"
+                @click="resetSearchForm"
+                :disabled="disabled"
+                id="costCollectionList-reset">重置</a-button>
+            </a-col>
+          </a-row>
+        </a-form-model>
+      </div>
+    </a-card>
+    <a-card size="small" :bordered="false">
+      <a-spin :spinning="spinning" tip="Loading...">
+        <!-- 操作按钮 -->
+        <div class="table-operator">
+          <a-button id="costCollectionList-add-btn" type="primary" @click="handleAdd">新增</a-button>
+        </div>
+        <!-- 列表 -->
+        <s-table
+          class="sTable fixPagination"
+          ref="table"
+          size="small"
+          :rowKey="(record) => record.id"
+          :style="{ height: tableHeight+70+'px' }"
+          :columns="columns"
+          :data="loadData"
+          :scroll="{ y: tableHeight}"
+          :defaultLoadData="false"
+          bordered>
+          <!-- 客户名称 -->
+          <template slot="customName" slot-scope="text, record">
+            {{ record.dealerEntity&&record.dealerEntity.dealerName?record.dealerEntity.dealerName:record.defaultFlag==1?'默认':'--' }}
+          </template>
+          <!-- 结束时间 -->
+          <template slot="endDate" slot-scope="text, record">
+            {{ record.status==='END'? record.ruleEndDate:'--' }}
+          </template>
+          <!-- 操作 -->
+          <template slot="action" slot-scope="text, record">
+            <a-button
+              size="small"
+              type="link"
+              class="button-info"
+              @click="handleEdit(record)"
+              v-if="$hasPermissions('B_tireSubsidySetting_edit')&&record.status=='WAIT'"
+              :id="'costCollectionList-edit-btn'+record.id"
+            >
+              编辑
+            </a-button>
+            <a-button
+              size="small"
+              type="link"
+              class="button-error"
+              :id="'costCollectionList-end-btn'+record.id"
+              v-if="$hasPermissions('B_tireSubsidySetting_end')&&record.status=='IN_USE'&&record.defaultFlag==0"
+              @click="handleEndOrDel(record,'end')"
+            >
+              结束
+            </a-button>
+            <a-button
+              size="small"
+              type="link"
+              class="button-error"
+              @click="handleEndOrDel(record,'del')"
+              v-if="$hasPermissions('B_tireSubsidySetting_del')&&record.status=='WAIT'"
+              :id="'costCollectionList-del-btn'+record.id"
+            >
+              删除
+            </a-button>
+            <span v-if="record.status=='IN_USE'&&record.defaultFlag==1">--</span>
+          </template>
+        </s-table>
+      </a-spin>
+    </a-card>
+    <!-- 新增 -->
+    <cost-add-modal v-drag :openModal="openCostAddModal" :pageType="pageType" @ok="$refs.table.refresh(true)" @close="openCostAddModal = false" />
+    <!-- 编辑 -->
+    <edit-modal
+      v-drag
+      :openModal="openCostEditModal"
+      ref="costEditModal"
+      :pageType="pageType"
+      @ok="$refs.table.refresh(true)"
+      @close="openCostEditModal = false" ></edit-modal>
+  </div>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import { STable, VSelect } from '@/components'
+import subarea from '@/views/common/subarea.js'
+import AreaList from '@/views/common/areaList.js'
+import costAddModal from './costAddModal.vue'
+import editModal from './editModal.vue'
+import custList from '@/views/common/custList.vue'
+// 接口
+import { tireSubsidyRuleList, delSubsidyRule, endSubsidyRule } from '@/api/subsidyRule'
+export default {
+  name: 'CostCollectionList',
+  mixins: [commonMixin],
+  components: { STable, VSelect, subarea, AreaList, custList, costAddModal, editModal },
+  props: {
+    pageType: { //  弹框显示状态
+      type: String,
+      default: ''
+    }
+  },
+  data () {
+    return {
+      spinning: false,
+      disabled: false, //  查询、重置按钮是否可操作
+      advanced: true, // 高级搜索 展开/关闭
+      tableHeight: 0, // 表格高度
+      openCostAddModal: false, // 新增弹窗
+      openCostEditModal: false, // 编辑弹窗
+      exportLoading: false, // 导出按钮加载状态
+      showExport: false, // 导出弹窗
+      timeInfo: [], // 日期
+      //  查询条件
+      queryParam: {
+        subareaArea: {
+          subareaSn: '', // 区域
+          subareaAreaSn: '' // 分区
+        },
+        dealerSn: undefined, // 客户sn
+        dealerName: undefined, // 客户名称
+        provinceSn: undefined, // 省
+        citySn: undefined, // 市
+        districtSn: undefined, // 区
+        ruleType: undefined, // 页面类型
+        subsidyQueryStatus: 'NOT_FINISH'// 状态默认值
+      },
+      totalData: null, // 合计
+      rules: {
+        'queryDate': [{ required: true, message: '请选择查询季度', trigger: 'change' }]
+      },
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        this.spinning = true
+        // 获取列表数据  有分页
+        this.queryParam.ruleType = this.pageType
+        const params = Object.assign(parameter, this.queryParam)
+        return tireSubsidyRuleList(params).then(res => {
+          let data
+          if (res.status == 200) {
+            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
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  watch: {
+    '$store.state.app.winHeight' (newValue, oldValue) { //  窗口变更时,需同时更改表格高度
+      this.setTableH()
+    }
+  },
+  computed: {
+    columns () {
+      const _this = this
+      const arr = [
+        { title: '序号', dataIndex: 'no', width: '5%', align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '区域', dataIndex: 'subareaArea.subareaName', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '分区', dataIndex: 'subareaArea.subareaAreaName', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户名称', dataIndex: 'dealerEntity.dealerName', width: '20%', align: 'left', scopedSlots: { customRender: 'customName' }, ellipsis: true },
+        { title: '开始时间', dataIndex: 'ruleStartDate', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '结束时间', dataIndex: 'ruleEndDate', width: '12%', align: 'center', scopedSlots: { customRender: 'endDate' } },
+        { title: '状态', dataIndex: 'statusDictValue', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '操作', scopedSlots: { customRender: 'action' }, width: '10%', align: 'center' }
+      ]
+      if (this.pageType === 'SERVICE_FEE') {
+        arr.splice(7, 0, { title: '服务费比例(%)', dataIndex: 'ruleValue1', width: '12%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text * 100) + '%' : '--') } })
+      } else {
+        arr.splice(7, 0, { title: '运费补贴(元)', dataIndex: 'ruleValue1', width: '12%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
+      }
+      return arr
+    }
+  },
+  methods: {
+    // 新增
+    handleAdd () {
+      this.openCostAddModal = true
+    },
+    // 客户名称 change
+    custChange (val) {
+      this.queryParam.dealerName = val.name
+      this.queryParam.dealerSn = val.key
+    },
+    // 地区
+    areaChange (val) {
+      this.queryParam.provinceSn = val[0] ? val[0] : undefined
+      this.queryParam.citySn = val[1] ? val[1] : undefined
+      this.queryParam.districtSn = val[2] ? val[2] : undefined
+    },
+    // 区域分区  change
+    subareaChange (val) {
+      this.queryParam.subareaArea.subareaSn = val[0] ? val[0] : ''
+      this.queryParam.subareaArea.subareaAreaSn = val[1] ? val[1] : ''
+    },
+    //  重置
+    resetSearchForm () {
+      this.queryParam.provinceSn = undefined
+      this.queryParam.citySn = undefined
+      this.queryParam.districtSn = undefined
+      this.queryParam.dealerName = undefined
+      this.queryParam.dealerSn = undefined
+      this.queryParam.ruleType = undefined
+      this.queryParam.subareaArea.subareaSn = ''
+      this.queryParam.subareaArea.subareaAreaSn = ''
+      this.queryParam.subsidyQueryStatus = 'NOT_FINISH'
+      this.$refs.subarea.clearData()
+      this.$refs.dealerSubareaScopeList.resetForm()
+      this.$refs.areaList.clearData()
+      this.$refs.table.refresh(true)
+    },
+    // 编辑
+    handleEdit (row) {
+      const sendData = {
+        dealerName: row.dealerEntity && row.dealerEntity.dealerName ? row.dealerEntity.dealerName : undefined,
+        ruleStartDate: row.ruleStartDate,
+        ruleValue1: this.pageType === 'SERVICE_FEE' ? (row.ruleValue1 * 100) : row.ruleValue1,
+        defaultFlag: row.defaultFlag,
+        ruleSn: row.ruleSn
+      }
+      this.$refs.costEditModal.getFormData(sendData)
+      this.openCostEditModal = true
+    },
+    // 结束  删除
+    handleEndOrDel (row, type) {
+      const ajaxName = type === 'end' ? endSubsidyRule : delSubsidyRule
+      let tipWord = null
+      if (this.pageType === 'SERVICE_FEE') {
+        tipWord = type === 'end' ? '确定结束服务费比例吗?结束后以默认服务费比例计算' : '确定删除服务费比例吗?'
+      } else {
+        tipWord = type === 'end' ? '确定结束运费补贴吗?结束后以默认运费补贴计算' : '确定删除运费补贴吗?'
+      }
+      const _this = this
+      _this.$confirm({
+        title: '提示',
+        content: tipWord,
+        centered: true,
+        onOk () {
+          ajaxName({ ruleSn: row.ruleSn, ruleType: _this.pageType }).then(res => {
+            if (res.status == 200) {
+              _this.$message.success(res.message)
+              _this.$refs.table.refresh(true)
+            }
+          })
+        }
+      })
+    },
+    // 初始化
+    pageInit () {
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        this.setTableH()
+      })
+      this.resetSearchForm()
+    },
+    // 计算表格高度
+    setTableH () {
+      const tableSearchH = this.$refs.tableSearch.offsetHeight
+      this.tableHeight = window.innerHeight - tableSearchH - 300
+    }
+  },
+  mounted () {
+    this.pageInit()
+  }
+}
+</script>

+ 280 - 0
src/views/setting/tireSubsidySetting/editModal.vue

@@ -0,0 +1,280 @@
+<template>
+  <a-modal
+    centered
+    class="editTireSetting-modal"
+    :footer="null"
+    :maskClosable="false"
+    title="编辑"
+    v-model="isShow"
+    @cancel="isShow=false"
+    :width="700">
+    <div>
+      <a-spin :spinning="spinning" tip="Loading...">
+        <a-form-model
+          id="editTireSettingModal-form"
+          ref="ruleForm"
+          :model="form"
+          :rules="rules"
+          :label-col="formItemLayout.labelCol"
+          :wrapper-col="formItemLayout.wrapperCol"
+        >
+          <a-form-model-item label="客户名称" v-if="form.defaultFlag==0">
+            {{ form.dealerName||'--' }}
+          </a-form-model-item>
+          <div v-if="pageType==='SERVICE_FEE' || pageType==='SHIPPING_FEE'">
+            <a-form-model-item label="开始时间">
+              {{ form.ruleStartDate||'--' }}
+            </a-form-model-item>
+            <a-form-model-item :label="pageType==='SERVICE_FEE'?'服务费比例':'运费补贴'" prop="ruleValue1">
+              <a-input-number
+                id="editTireSettingModal-ruleValue1"
+                v-model="form.ruleValue1"
+                :min="0"
+                style="width:90%;"
+                :max="pageType==='SERVICE_FEE'?100:99"
+                :precision="2"
+                :placeholder="'请输入'+(pageType==='SERVICE_FEE'?'服务费比例':'运费补贴')"/>
+              <span style="margin-left:10px;">{{ pageType==='SERVICE_FEE'?'%':'元' }}</span>
+            </a-form-model-item>
+          </div>
+          <div v-else>
+            <a-form-model-item label="增量补贴(季度)" prop="ruleTarget1">
+              <div>
+                大于等于<a-input-number
+                  v-model="form.ruleTarget1"
+                  :min="1"
+                  style="width:80px;margin:0 6px;"
+                  :max="99999999"
+                  id="addSubsidyModal-ruleTarget1"
+                  :precision="0"
+                  placeholder="请输入"/>条,每条补贴
+                <a-input-number
+                  v-model="form.ruleValue1"
+                  :min="0.01"
+                  id="addSubsidyModal-ruleValue1"
+                  style="width:80px;margin:0 6px;"
+                  :max="999999"
+                  :precision="2"
+                  placeholder="请输入"/>元
+              </div>
+              <div>
+                大于等于<a-input-number
+                  v-model="form.ruleTarget2"
+                  :min="form.ruleTarget1"
+                  style="width:80px;margin:0 6px;"
+                  :max="999999"
+                  id="addSubsidyModal-ruleTarget2"
+                  :precision="0"
+                  placeholder="请输入"/>条,每条补贴
+                <a-input-number
+                  v-model="form.ruleValue2"
+                  :min="form.ruleValue1"
+                  id="addSubsidyModal-ruleValue2"
+                  style="width:80px;margin:0 6px;"
+                  :max="999999"
+                  :precision="2"
+                  placeholder="请输入"/>元
+              </div>
+              <div>
+                大于等于<a-input-number
+                  v-model="form.ruleTarget3"
+                  :min="form.ruleTarget2"
+                  style="width:80px;margin:0 6px;"
+                  :max="999999"
+                  id="addSubsidyModal-ruleTarget3"
+                  :precision="0"
+                  placeholder="请输入"/>条,每条补贴
+                <a-input-number
+                  v-model="form.ruleValue3"
+                  :min="form.ruleValue2"
+                  id="addSubsidyModal-ruleValue3"
+                  style="width:80px;margin:0 6px;"
+                  :max="999999"
+                  :precision="2"
+                  placeholder="请输入"/>元
+              </div>
+            </a-form-model-item>
+          </div>
+        </a-form-model>
+        <div class="btn-cont">
+          <a-button id="editTireSettingModal-cancel" @click="isShow = false" style="margin-right: 15px;">取消</a-button>
+          <a-button type="primary" id="editTireSettingModal-save" @click="handleSave">保存</a-button>
+        </div>
+      </a-spin>
+    </div>
+  </a-modal>
+</template>
+
+<script>
+// 接口
+import { editSubsidyRule } from '@/api/subsidyRule'
+export default {
+  name: 'EditTireSettingModal',
+  props: {
+    openModal: { //  弹框显示状态
+      type: Boolean,
+      default: false
+    },
+    pageType: { //  页面类型
+      type: String,
+      default: ''
+    }
+  },
+  data () {
+    return {
+      isShow: this.openModal, //  是否打开弹框
+      spinning: false, // 页面加载状态
+      formItemLayout: {// form表单中label设置
+        labelCol: { span: 5 },
+        wrapperCol: { span: 17 }
+      },
+      // 提交数据
+      form: {
+        ruleSn: undefined,
+        defaultFlag: 0,
+        dealerName: undefined,
+        ruleStartDate: undefined,
+        ruleTarget1: undefined,
+        ruleValue1: undefined,
+        ruleTarget2: undefined,
+        ruleValue2: undefined,
+        ruleTarget3: undefined,
+        ruleValue3: undefined
+      },
+      // 必填项判断
+      rules: {
+        ruleValue1: [{ required: true, message: '请输入服务费比例', trigger: 'blur' }],
+        ruleTarget1: [{ required: true, message: '增量补贴不能为空', trigger: 'blur' }]
+      }
+    }
+  },
+  methods: {
+    // 保存
+    handleSave () {
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          // 为空判断
+          if (_this.pageType === 'SUBSIDY_QUARTER_FEE' || _this.pageType === 'SUBSIDY_YEAR_FEE') {
+            const newForm = JSON.parse(JSON.stringify(_this.form))
+            delete newForm.ruleSn
+            delete newForm.defaultFlag
+            delete newForm.dealerName
+            delete newForm.ruleStartDate
+            const flag = _this.isValid(newForm)
+            if (!flag) {
+              _this.$message.error('季度增量补贴【条数】与【补贴】不符合填写规则!')
+              return
+            }
+          }
+          _this.form.ruleType = _this.pageType
+          _this.spinning = true
+          editSubsidyRule(this.form).then(res => {
+            if (res.status == 200) {
+              if (!res.data) {
+                _this.isShow = false
+                _this.$message.success(res.message)
+                _this.$emit('ok')
+              } else {
+                _this.openTip(res.data)
+              }
+            }
+            _this.spinning = false
+          })
+        } else {
+          console.log('error submit!!')
+          return false
+        }
+      })
+    },
+    // 为空判断
+    isValid (obj) {
+      const { ruleTarget1, ruleValue1, ruleTarget2, ruleValue2, ruleTarget3, ruleValue3 } = obj
+
+      // 检查第一阶梯是否填写
+      if (!ruleTarget1 || !ruleValue1) {
+        return false
+      }
+
+      // 如果第三阶梯存在,检查第二阶梯是否存在以及值是否正确
+      if (ruleTarget3 || ruleValue3) {
+        if ((!ruleTarget2 || !ruleValue2) || (!ruleTarget3 || !ruleValue3)) {
+          return false
+        } else {
+          if (ruleValue1 >= ruleValue2 || ruleValue2 >= ruleValue3 || ruleTarget1 >= ruleTarget2 || ruleTarget2 >= ruleTarget3) {
+            return false
+          }
+        }
+      }
+
+      // 如果只有第二阶梯存在(没有第三阶梯),检查值是否正确
+      if ((ruleTarget2 || ruleValue2) && (!ruleTarget3 && !ruleValue3)) {
+        if (!ruleTarget2 || !ruleValue2) {
+          return false
+        } else {
+          if (ruleValue1 >= ruleValue2 || ruleTarget1 >= ruleTarget2) {
+            return false
+          }
+        }
+      }
+      // 所有条件都满足,返回true
+      return true
+    },
+    // 错误提示语
+    openTip (code) {
+      const _this = this
+      this.$info({
+        title: '提示',
+        content: '当前规则不可操作,请刷新后重试',
+        centered: true,
+        onOk () {
+          console.log('知道了')
+        }
+      })
+    },
+    // 重置
+    resetFormData () {
+      this.form.defaultFlag = 0
+      this.form.ruleSn = undefined
+      this.form.dealerName = undefined
+      this.form.ruleStartDate = undefined
+      this.form.ruleTarget1 = undefined
+      this.form.ruleValue1 = undefined
+      this.form.ruleTarget2 = undefined
+      this.form.ruleValue2 = undefined
+      this.form.ruleTarget3 = undefined
+      this.form.ruleValue3 = undefined
+      this.$refs.ruleForm.resetFields()
+    },
+    // 获取编辑数据
+    getFormData (getData) {
+      this.form = getData
+    }
+  },
+  watch: {
+    //  父页面传过来的弹框状态
+    openModal (newValue, oldValue) {
+      this.isShow = newValue
+    },
+    //  重定义的弹框状态
+    isShow (newValue, oldValue) {
+      if (!newValue) {
+        this.$emit('close')
+        this.resetFormData()
+      }
+    }
+  }
+}
+</script>
+
+<style lang="less">
+  .editTireSetting-modal{
+    .ant-modal-body {
+      padding: 40px 40px 24px;
+    }
+    .btn-cont {
+      text-align: center;
+      margin: 35px 0 30px;
+    }
+  }
+</style>

+ 42 - 0
src/views/setting/tireSubsidySetting/index.vue

@@ -0,0 +1,42 @@
+<template>
+  <div class="tireSubsidySetting-mainBox">
+    <a-tabs default-active-key="SERVICE_FEE" v-model="tabVal" id="tireSubsidySetting-index" class="tireSubsidySetting-tabs">
+      <a-tab-pane key="SERVICE_FEE" tab="服务费">
+        <costCollectionList pageType="SERVICE_FEE"></costCollectionList>
+      </a-tab-pane>
+      <a-tab-pane key="SHIPPING_FEE" tab="运费补贴" force-render>
+        <costCollectionList pageType="SHIPPING_FEE"></costCollectionList>
+      </a-tab-pane>
+      <a-tab-pane key="SUBSIDY_QUARTER_FEE" tab="增量补贴(季度)" force-render>
+        <addSubsidyList pageType="SUBSIDY_QUARTER_FEE"></addSubsidyList>
+      </a-tab-pane>
+      <a-tab-pane key="SUBSIDY_YEAR_FEE" tab="增量补贴(年度)" force-render>
+        <addSubsidyList pageType="SUBSIDY_YEAR_FEE"></addSubsidyList>
+      </a-tab-pane>
+    </a-tabs>
+  </div>
+</template>
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import costCollectionList from './costCollectionList.vue'
+import addSubsidyList from './addSubsidyList.vue'
+
+export default {
+  name: 'TireSubsidySetting',
+  mixins: [commonMixin],
+  components: { costCollectionList, addSubsidyList },
+  data () {
+    return {
+      tabVal: 'SERVICE_FEE' // tab值  1轮胎月度费用报表 2轮胎季度费用报表 3轮胎年度费用报表 4轮胎费用明细报表
+    }
+  }
+}
+</script>
+<style lang="less" scoped>
+  .tireSubsidySetting-mainBox{
+    .tireSubsidySetting-tabs{
+      background:#ffffff;
+    }
+  }
+</style>

+ 2 - 2
vue.config.js

@@ -108,9 +108,9 @@ const vueConfig = {
     // If you want to turn on the proxy, please remosve the mockjs /src/main.jsL11
     proxy: {
       '/api': {
-        // target: 'http://192.168.2.10/ocs-admin',
+        target: 'http://192.168.2.10/ocs-admin',
         // target: 'https://t.ocs.360arrow.com/ocs-admin', //  练习
-        target: 'https://p.ocs.360arrow.com/ocs-admin', //  预发布
+        // target: 'https://p.ocs.360arrow.com/ocs-admin', //  预发布
         ws: false,
         changeOrigin: true,
         pathRewrite: {