chenrui hai 1 mes
pai
achega
88df3bc7e0

+ 25 - 21
src/views/reportData/billingStatistics/customerCountList.vue

@@ -56,7 +56,7 @@
               </a-col>
               <a-col :md="6" :sm="24">
                 <a-form-model-item label="客服">
-                  <customerService ref="customerName" id="customerCountList-customerName" v-model="queryParam.bizUserSn"></customerService>
+                  <customerService ref="customerName" id="customerCountList-customerName" v-model="queryParam.kfSn"></customerService>
                 </a-form-model-item>
               </a-col>
             </template>
@@ -150,19 +150,17 @@ export default {
         beginDate: moment().startOf('month').format('YYYY-MM-DD') + ' 00:00:00', // 月份开始时间
         endDate: moment().endOf('month').format('YYYY-MM-DD') + ' 23:59:59', // 月份结束时间
         dealerLevel: undefined, // 客户等级
-        customSn: undefined, // 客户sn
-        dealerEntity: {
-          dealerName: undefined, // 客户名称
-          provinceSn: undefined, // 省
-          citySn: undefined, // 市
-          districtSn: undefined // 区
-        },
+        dealerSn: undefined, // 客户sn
+        dealerName: undefined, // 客户名称
+        provinceSn: undefined, // 省
+        citySn: undefined, // 市
+        districtSn: undefined, // 区
         subareaArea: {
           subareaSn: '', // 区域
           subareaAreaSn: '', // 分区
           bizUserSn: undefined// 区域负责人
         },
-        bizUserSn: undefined// 客服
+        kfSn: undefined// 客服
       },
       columns: [], // 表格  列数据
       totalData: null, // 合计
@@ -236,14 +234,20 @@ export default {
       this.columns.unshift({ title: '序号', dataIndex: 'no', fixed: 'left', align: 'center' })
       this.countLabel = tableTitle.count
       this.columns.map(item => {
+        item.titleNum = item.title
         let mw = 20
         if (item.customRender == 'amount') {
           mw = 15
-          item.customRender = function (text) { return (text || text == 0) ? _this.toThousands(text) : '--' }
+          if (item.colour && item.colour === 'red') {
+            item.title = <span style="color:red;">{item.titleNum}</span>
+            item.customRender = (text) => { return <span style="color:red;">{(text || text == 0) ? _this.toThousands(text) : '--'}</span> }
+          } else {
+            item.customRender = function (text) { return (text || text == 0) ? _this.toThousands(text) : '--' }
+          }
         } else {
           item.customRender = function (text) { return text || '--' }
         }
-        const w = item.title.length * mw
+        const w = item.titleNum.length * mw
         const tw = w <= 80 ? mw * 5 : w
         item.width = tw + 'px'
         this.tableWidth = this.tableWidth + tw
@@ -264,8 +268,8 @@ export default {
     },
     // 客户名称 change
     custChange (val) {
-      this.queryParam.dealerEntity.dealerName = val.name
-      this.queryParam.customSn = val.key
+      this.queryParam.dealerName = val.name
+      this.queryParam.dealerSn = val.key
     },
     // 统计
     getCount (params) {
@@ -285,9 +289,9 @@ export default {
     },
     // 地区
     areaChange (val) {
-      this.queryParam.dealerEntity.provinceSn = val[0] ? val[0] : undefined
-      this.queryParam.dealerEntity.citySn = val[1] ? val[1] : undefined
-      this.queryParam.dealerEntity.districtSn = val[2] ? val[2] : undefined
+      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) {
@@ -299,11 +303,11 @@ export default {
       this.queryParam.beginDate = moment().startOf('month').format('YYYY-MM-DD') + ' 00:00:00'
       this.queryParam.endDate = moment().endOf('month').format('YYYY-MM-DD') + ' 23:59:59'
       this.monthVal = moment().format('YYYY-MM')
-      this.queryParam.dealerEntity.provinceSn = undefined
-      this.queryParam.dealerEntity.citySn = undefined
-      this.queryParam.dealerEntity.districtSn = undefined
-      this.queryParam.dealerEntity.dealerName = undefined
-      this.queryParam.customSn = undefined
+      this.queryParam.provinceSn = undefined
+      this.queryParam.citySn = undefined
+      this.queryParam.districtSn = undefined
+      this.queryParam.dealerName = undefined
+      this.queryParam.dealerSn = undefined
       this.queryParam.bizUserSn = undefined
       this.queryParam.subareaArea.subareaSn = ''
       this.queryParam.subareaArea.subareaAreaSn = ''

+ 8 - 2
src/views/reportData/billingStatistics/provinceCountList.vue

@@ -194,14 +194,20 @@ export default {
       this.columns.unshift({ title: '序号', dataIndex: 'no', fixed: 'left', align: 'center' })
       this.countLabel = tableTitle.count
       this.columns.map(item => {
+        item.titleNum = item.title
         let mw = 20
         if (item.customRender == 'amount') {
           mw = 15
-          item.customRender = function (text) { return (text || text == 0) ? _this.toThousands(text) : '--' }
+          if (item.colour && item.colour === 'red') {
+            item.title = <span style="color:red;">{item.titleNum}</span>
+            item.customRender = (text) => { return <span style="color:red;">{(text || text == 0) ? _this.toThousands(text) : '--'}</span> }
+          } else {
+            item.customRender = function (text) { return (text || text == 0) ? _this.toThousands(text) : '--' }
+          }
         } else {
           item.customRender = function (text) { return text || '--' }
         }
-        const w = item.title.length * mw
+        const w = item.titleNum.length * mw
         const tw = w <= 80 ? mw * 5 : w
         item.width = tw + 'px'
         this.tableWidth = this.tableWidth + tw

+ 9 - 7
src/views/reportData/promotionFeeReport/customerFeeList.vue

@@ -96,8 +96,7 @@
           class="sTable fixPagination"
           ref="table"
           size="small"
-          :rowKey="(record) => record.no"
-          rowKeyName="no"
+          :rowKey="(record) => record.id"
           :style="{ height: tableHeight+70+'px' }"
           :columns="columns"
           :data="loadData"
@@ -226,19 +225,22 @@ export default {
       const _this = this
       const tableTitle = await promoSalesExpenseTitle().then(res => res.data)
       this.columns = tableTitle.list
-      this.columns.unshift({ title: '序号', customRender: 'no', dataIndex: 'no', fixed: 'left', align: 'center' })
       this.countLabel = tableTitle.count
       this.columns.map(item => {
+        item.titleNum = item.title
         let mw = 20
         if (item.customRender == 'amount') {
           mw = 15
-          item.customRender = function (text) { return (text || text == 0) ? _this.toThousands(text) : '--' }
-        } else if (item.customRender == 'no') {
-          mw = 10
+          if (item.colour && item.colour === 'red') {
+            item.title = <span style="color:red;">{item.titleNum}</span>
+            item.customRender = (text) => { return <span style="color:red;">{(text || text == 0) ? _this.toThousands(text) : '--'}</span> }
+          } else {
+            item.customRender = function (text) { return (text || text == 0) ? _this.toThousands(text) : '--' }
+          }
         } else {
           item.customRender = function (text) { return text || '--' }
         }
-        const w = item.title.length * mw
+        const w = item.titleNum.length * mw
         const tw = w <= 80 ? mw * 5 : w
         item.width = tw + 'px'
         this.tableWidth = this.tableWidth + tw

+ 13 - 10
src/views/reportData/promotionFeeReport/promoFeeList.vue

@@ -101,8 +101,8 @@
           bordered>
           <template slot="footer" v-if="totalData&&totalData.length">
             <a-row :gutter="15">
-              <a-col span="2">合计:</a-col>
-              <a-col span="22">
+              <a-col span="24">合计:</a-col>
+              <a-col span="24">
                 <a-col span="4" v-for="item in totalData" :key="item.key">
                   {{ item.title }}:{{ item[item.key] ||item[item.key] ==0?toThousands(item[item.key]) :'--' }}
                 </a-col>
@@ -145,7 +145,7 @@ export default {
         beginDate: moment().startOf('month').format('YYYY-MM-DD') + ' 00:00:00', // 月份开始时间
         endDate: moment().endOf('month').format('YYYY-MM-DD') + ' 23:59:59', // 月份结束时间
         dealerLevel: undefined, // 客户级别
-        customSn: undefined, // 客户sn
+        dealerSn: undefined, // 客户sn
         dealerEntity: {
           dealerName: undefined, // 客户名称
           provinceSn: undefined, // 省
@@ -229,19 +229,22 @@ export default {
       const _this = this
       const tableTitle = await promoSalesExpenseTitle().then(res => res.data)
       this.columns = tableTitle.list
-      this.columns.unshift({ title: '序号', customRender: 'no', dataIndex: 'no', fixed: 'left', align: 'center' })
       this.countLabel = tableTitle.count
       this.columns.map(item => {
+        item.titleNum = item.title
         let mw = 20
         if (item.customRender == 'amount') {
           mw = 15
-          item.customRender = function (text) { return (text || text == 0) ? _this.toThousands(text) : '--' }
-        } else if (item.customRender == 'no') {
-          mw = 10
+          if (item.colour && item.colour === 'red') {
+            item.title = <span style="color:red;">{item.titleNum}</span>
+            item.customRender = (text) => { return <span style="color:red;">{(text || text == 0) ? _this.toThousands(text) : '--'}</span> }
+          } else {
+            item.customRender = function (text) { return (text || text == 0) ? _this.toThousands(text) : '--' }
+          }
         } else {
           item.customRender = function (text) { return text || '--' }
         }
-        const w = item.title.length * mw
+        const w = item.titleNum.length * mw
         const tw = w <= 80 ? mw * 5 : w
         item.width = tw + 'px'
         this.tableWidth = this.tableWidth + tw
@@ -263,7 +266,7 @@ export default {
     // 客户名称 change
     custChange (val) {
       this.queryParam.dealerEntity.dealerName = val.name
-      this.queryParam.customSn = val.key
+      this.queryParam.dealerSn = val.key
     },
     // 统计
     getCount (params) {
@@ -301,7 +304,7 @@ export default {
       this.queryParam.dealerEntity.citySn = undefined
       this.queryParam.dealerEntity.districtSn = undefined
       this.queryParam.dealerEntity.dealerName = undefined
-      this.queryParam.customSn = undefined
+      this.queryParam.dealerSn = undefined
       this.queryParam.subareaArea.subareaSn = ''
       this.queryParam.subareaArea.subareaAreaSn = ''
       this.queryParam.subareaArea.bizUserSn = undefined

+ 8 - 5
src/views/reportData/promotionFeeReport/provinceFeeList.vue

@@ -176,19 +176,22 @@ export default {
       const _this = this
       const tableTitle = await promoProvinceTableTitle().then(res => res.data)
       this.columns = tableTitle.list
-      this.columns.unshift({ title: '序号', customRender: 'no', dataIndex: 'no', fixed: 'left', align: 'center' })
       this.countLabel = tableTitle.count
       this.columns.map(item => {
+        item.titleNum = item.title
         let mw = 20
         if (item.customRender == 'amount') {
           mw = 15
-          item.customRender = function (text) { return (text || text == 0) ? _this.toThousands(text) : '--' }
-        } else if (item.customRender == 'no') {
-          mw = 10
+          if (item.colour && item.colour === 'red') {
+            item.title = <span style="color:red;">{item.titleNum}</span>
+            item.customRender = (text) => { return <span style="color:red;">{(text || text == 0) ? _this.toThousands(text) : '--'}</span> }
+          } else {
+            item.customRender = function (text) { return (text || text == 0) ? _this.toThousands(text) : '--' }
+          }
         } else {
           item.customRender = function (text) { return text || '--' }
         }
-        const w = item.title.length * mw
+        const w = item.titleNum.length * mw
         const tw = w <= 80 ? mw * 5 : w
         item.width = tw + 'px'
         this.tableWidth = this.tableWidth + tw