Procházet zdrojové kódy

销售盯盘封版

朱鑫波 před 3 roky
rodič
revize
5bead689bb
1 změnil soubory, kde provedl 20 přidání a 14 odebrání
  1. 20 14
      src/views/modules/Statistics/saleStatistics/index.vue

+ 20 - 14
src/views/modules/Statistics/saleStatistics/index.vue

@@ -80,7 +80,6 @@
                                 v-for="(item, index) in dataDimensionList"
                                 :key="index + 1"
                                 :value="item.companyId"
-                                :disabled="mediaDimension == 'a' && !item.ttDesignId"
                             >
                                 {{ item.companyName }}
                             </a-select-option>
@@ -119,9 +118,12 @@
                             </a-tooltip>
                         </span> -->
                         <div class="report-card-result">
-                            <div class="report-card-money">{{ accountIndexList.totalCharge | decimalsHandle }}</div>
+                            <div class="report-card-money" v-if="accountIndexList.totalCharge">
+                                {{ accountIndexList.totalCharge | decimalsHandle }}
+                            </div>
+                            <div v-else>-</div>
                             <div
-                                v-if="timeShowEchartsStatus"
+                                v-if="accountIndexList.totalCharge"
                                 class="accountIndexEchart"
                                 id="effectiveVideoEcharts"
                                 style="width: 100%; height: 50px; margin: 0 auto"
@@ -131,7 +133,7 @@
                         </div>
                         <div class="report-card-line"></div>
                         <div class="report-card-radio">
-                            <span>环比:{{ accountIndexList.chargeRoi }}</span>
+                            <span>环比:{{ accountIndexList.chargeRoi ? accountIndexList.chargeRoi : '-' }}</span>
                         </div>
                     </a-card>
                 </a-col>
@@ -144,11 +146,12 @@
                             </a-tooltip> -->
                         </span>
                         <div class="report-card-result">
-                            <div class="report-card-money">
+                            <div class="report-card-money" v-if="accountIndexList.platformCharge">
                                 {{ Number(accountIndexList.platformCharge) | decimalsHandle }}
                             </div>
+                            <div v-else>-</div>
                             <div
-                                v-if="timeShowEchartsStatus"
+                                v-if="accountIndexList.platformCharge"
                                 id="accountIndexEchart"
                                 class="accountIndexEchart"
                                 style="width: 100%; height: 50px; margin: 0 auto"
@@ -158,7 +161,7 @@
                         </div>
                         <div class="report-card-line"></div>
                         <div class="report-card-radio">
-                            <span>环比:{{ accountIndexList.platformChargeRoi }}</span>
+                            <span>环比:{{ accountIndexList.platformChargeRoi ? accountIndexList.platformChargeRoi : '-' }}</span>
                         </div>
                     </a-card>
                 </a-col>
@@ -373,7 +376,9 @@
             <a-col :xl="24">
                 <a-spin :spinning="signatureStatus">
                     <a-card title="项目消耗排行榜" style="width: 100%" :bordered="false">
-                        <a-button type="primary" @click="exportExcel" slot="extra" :loading="downloadLoading">下载</a-button>
+                        <a-button type="primary" @click="exportExcel" slot="extra" :loading="downloadLoading"
+                            >下载</a-button
+                        >
 
                         <a-table
                             bordered
@@ -475,7 +480,7 @@ export default {
                 },
             },
             accountList: [],
-            downloadLoading:false,
+            downloadLoading: false,
             active: 'cost',
             groupDisabled: false,
             timeShowEchartsStatus: true,
@@ -623,12 +628,11 @@ export default {
                 if (item.statDate) {
                     return item.statDate
                 } else {
-                    if(item.hour>10){
-                        return item.hour + ":00"
-                    }else{
-                        return "0"+item.hour + ":00"
+                    if (item.hour > 10) {
+                        return item.hour + ':00'
+                    } else {
+                        return '0' + item.hour + ':00'
                     }
-                    
                 }
             })
             let option = {
@@ -938,6 +942,8 @@ export default {
                             this.initEchart('effectiveVideoEcharts', this.handleEffectiveVideoEcharts(res.result.list))
                             resolve(res.result)
                         } else {
+                            this.$message.error(res.message)
+                            this.accountIndexList = {}
                             reject(res.message)
                         }
                     }