yuting.cui 3 年 前
コミット
360d6b5dd4

+ 1 - 0
wxVideo/project/src/assets/config/interface_api.js

@@ -81,6 +81,7 @@ var api = {
81 81
    labelEditDetail:'/wx_sph/api/sphUserLabel/labelEditDetail',//标签审核详情
82 82
    labelEditAudit:'/wx_sph/api/sphUserLabel/labelEditAudit',//标签审核
83 83
 
84
+   usage_report:'/wx_sph/api/sphLive/usage_report',
84 85
    // 订阅消息
85 86
    nFollowList:'/wx_sph/api/notice/followList',//消息列表
86 87
    nMsgList:'/wx_sph/api/notice/msgList',//消息列表

BIN
wxVideo/project/src/assets/img/liveMax.png


+ 5 - 0
wxVideo/project/src/components/Detail/WhDetail/liveData.vue

@@ -19,6 +19,11 @@
19 19
             </div>
20 20
         </div>
21 21
         <div class="moreBox clear">
22
+            <el-tooltip class="item" effect="dark" content="销售来源仅支持小商店,魔筷,有赞,拼多多,京喜" placement="bottom">
23
+                <el-button style="padding:0;border:none;background:transparent;vertical-align: text-bottom;">
24
+                    <img style="width:20px;height:20px" src="@/assets/img/topDesc.png" alt="">
25
+                </el-button>
26
+            </el-tooltip>
22 27
             <div class="moreTitle">已记录直播<span>{{liveObj.total.live_times?$NumberHandle(liveObj.total.live_times):'-'}}</span></div>
23 28
             <div class="moreTitle">场均观看人数<span>{{liveObj.total.avg_watching_count?$NumberHandle(liveObj.total.avg_watching_count):'-'}}</span></div>
24 29
             <div class="moreTitle">场均获赞<span>{{liveObj.total.avg_like?$NumberHandle(liveObj.total.avg_like):'-'}}</span></div>

+ 45 - 6
wxVideo/project/src/components/Detail/liveDetail/detail.vue

@@ -55,14 +55,26 @@
55 55
                         <li>
56 56
                             <img src="@/assets/new_img/sale.png" class="icon" alt="">
57 57
                             <div class="dataInfo">
58
-                                <p class="title">本场销量</p>
58
+                                <p class="title">本场销量
59
+                                    <el-tooltip class="item" effect="dark" content="直播销量根据直播过程中库存变化校准得来无法避免人工修改库存情况。仅供参考" placement="bottom">
60
+                                        <el-button style="padding:0;border:none;background:transparent;vertical-align: initial;">
61
+                                            <i class="el-icon-warning"></i>
62
+                                        </el-button>
63
+                                    </el-tooltip>
64
+                                </p>
59 65
                                 <p class="data">{{detailInfo.total_sales||detailInfo.total_sales==0?$NumberHandle(detailInfo.total_sales):"-"}}</p>
60 66
                             </div>
61 67
                         </li>
62 68
                         <li>
63 69
                             <img src="@/assets/new_img/money.png" class="icon" alt="">
64 70
                             <div class="dataInfo">
65
-                                <p class="title">本场销售额</p>
71
+                                <p class="title">本场销售额
72
+                                    <el-tooltip class="item" effect="dark" content="由于销量误差故销售额会略有误差。仅供参考" placement="bottom">
73
+                                        <el-button style="padding:0;border:none;background:transparent;vertical-align: initial;">
74
+                                            <i class="el-icon-warning"></i>
75
+                                        </el-button>
76
+                                    </el-tooltip>
77
+                                </p>
66 78
                                 <p class="data">{{detailInfo.total_sale_money||detailInfo.total_sale_money==0?$NumberHandle(detailInfo.total_sale_money):"-"}}</p>
67 79
                             </div>
68 80
                         </li>
@@ -210,7 +222,13 @@
210 222
             <div v-loading="loading">
211 223
                 <div class="uvBox clear">
212 224
                     <div class="left" style="margin-top:40px">
213
-                        <span style="color:#323232;font-size:16px;font-weight:bold">累计销售额</span>
225
+                        <div style="color:#323232;font-size:16px;font-weight:bold">累计销售额
226
+                            <el-tooltip class="item" effect="dark" content="由于销量误差所以销售额会略有误差,仅供参考" placement="bottom">
227
+                                <el-button style="padding:0;border:none;background:transparent;vertical-align: initial;">
228
+                                    <i class="el-icon-warning"></i>
229
+                                </el-button>
230
+                            </el-tooltip>
231
+                        </div>
214 232
                         <p class="uvData">{{detailInfo&&(detailInfo.total_sale_money||detailInfo.total_sale_money==0)?$NumberHandle(detailInfo.total_sale_money):'-'}}</p>
215 233
                         <p class="lookHint">用户平均价值{{detailInfo.per_vistor_transaction||detailInfo.per_vistor_transaction==0?$NumberHandle(detailInfo.per_vistor_transaction,2):'-'}}/人</p>
216 234
                     </div>
@@ -236,7 +254,13 @@
236 254
                 <ul class="data_info_ul">
237 255
                     <li>
238 256
                         <span class="data">{{detailInfo&&(detailInfo.total_sales||detailInfo.total_sales==0)?$NumberHandle(detailInfo.total_sales):'-'}}</span>
239
-                        <p class="dataTitle">累计销量</p>
257
+                        <p class="dataTitle">累计销量
258
+                            <el-tooltip class="item" effect="dark" content="直播销量根据直播过程中库存变化校准得来无法避免人工修改库存情况。仅供参考" placement="bottom">
259
+                                <el-button style="padding:0;border:none;background:transparent;vertical-align: initial;">
260
+                                    <i class="el-icon-warning"></i>
261
+                                </el-button>
262
+                            </el-tooltip>
263
+                        </p>
240 264
                     </li>
241 265
                     <li>
242 266
                         <span class="data">{{detailInfo&&(detailInfo.per_customer_transaction||detailInfo.per_customer_transaction==0)?$NumberHandle(detailInfo.per_customer_transaction):'-'}}</span>
@@ -333,12 +357,22 @@
333 357
                     </div>
334 358
                     <div class="goods_th_2">
335 359
                         <div :class="sort_type == 'sales' ? 'common_selected_down' : ''" @click="sortEvent('sales')">
360
+                            <el-tooltip class="item" effect="dark" content="直播销量根据直播过程中库存变化校准得来会有误差。仅供参考" placement="bottom">
361
+                                <el-button style="padding:0;border:none;background:transparent;vertical-align: initial;">
362
+                                    <i class="el-icon-warning"></i>
363
+                                </el-button>
364
+                            </el-tooltip>
336 365
                             预估销量
337 366
                             <i class="el-icon-caret-bottom"></i>
338 367
                         </div> 
339 368
                     </div>
340 369
                     <div class="goods_th_2">
341 370
                         <div :class="sort_type == 'sale_money' ? 'common_selected_down' : ''" @click="sortEvent('sale_money')">
371
+                            <el-tooltip class="item" effect="dark" content="由于销量误差故销售额会略有误差。仅供参考" placement="bottom">
372
+                                <el-button style="padding:0;border:none;background:transparent;vertical-align: initial;">
373
+                                    <i class="el-icon-warning"></i>
374
+                                </el-button>
375
+                            </el-tooltip>
342 376
                             预估销售额
343 377
                             <i class="el-icon-caret-bottom"></i>
344 378
                         </div> 
@@ -369,8 +403,12 @@
369 403
                             {{(item.min_price!=item.max_price)?'~':''}}
370 404
                             {{item.min_price!=item.max_price?$NumberHandle(item.max_price)+'元':''}}
371 405
                         </div>
372
-                        <div :class="['goods_th_2',sort_type == 'sales' ? 'common_selected' : '']">{{item.sales||item.sales==0?$NumberHandle(item.sales):'-'}}</div>
373
-                        <div :class="['goods_th_2',sort_type == 'sale_money' ? 'common_selected' : '']">{{item.sale_money||item.sale_money==0?$NumberHandle(item.sale_money):'-'}}</div>
406
+                        <div :class="['goods_th_2',sort_type == 'sales' ? 'common_selected' : '']">
407
+                            <span>{{item.sales?$NumberHandle(item.sales):(item.platform_name!='小商店'&&item.platform_name!='魔筷'&&item.platform_name!='有赞'&&item.platform_name!='拼多多'&&item.platform_name!='京喜'?('商品来源暂不支持'+item.platform_name):'0')}}</span>
408
+                        </div>
409
+                        <div :class="['goods_th_2',sort_type == 'sale_money' ? 'common_selected' : '']">
410
+                            <span>{{item.sale_money?$NumberHandle(item.sale_money):(item.platform_name!='小商店'&&item.platform_name!='魔筷'&&item.platform_name!='有赞'&&item.platform_name!='拼多多'&&item.platform_name!='京喜'?('商品来源暂不支持'+item.platform_name):'0')}}</span>
411
+                        </div>
374 412
                     </div>
375 413
                     <div v-if="!goodsLoading&&goodsList.length == 0" style="height:400px;padding-top:100px;">
376 414
                         <img src="@/assets/img/noData.png" style="width:200px;height:200px;margin:20px auto;" alt="">
@@ -1580,6 +1618,7 @@ export default {
1580 1618
             display: flex;
1581 1619
             align-items: center;
1582 1620
             margin: 21px 0;
1621
+            line-height: 20px;
1583 1622
             .goods_th_1{
1584 1623
                 display: flex;
1585 1624
                 align-items: center;

+ 129 - 4
wxVideo/project/src/components/workbench/monitor/liveMonitor/index.vue

@@ -122,6 +122,28 @@
122 122
                 </div>
123 123
             </div>
124 124
         </div>
125
+        <!-- 次数弹框 -->
126
+        <el-dialog class="diaMain" @click.stop :visible.sync="showMax" style="padding:0">
127
+            <div>
128
+                <div class="flex diaTop">
129
+                    <div>
130
+                        提示
131
+                    </div>
132
+                    <div style="overflow: hidden;">
133
+                        <i class="el-icon-close" style="cursor:pointer" @click="showMax=false;"></i>
134
+                    </div>
135
+                </div>
136
+                <div class="diaCon">
137
+                    <img src="@/assets/img/liveMax.png" alt="">
138
+                    <div>
139
+                        为保证监控效果,您当日直播监控次数已达上限(每日3次),请明日再添加
140
+                    </div>
141
+                </div>
142
+                <div class="diaBtn">
143
+                    <div class="button normal" @click.stop="showMax=false">确定</div>
144
+                </div>
145
+            </div>
146
+        </el-dialog>
125 147
         <monitor-history v-if="tab == 2"></monitor-history>
126 148
     </div>
127 149
 </template>
@@ -133,6 +155,8 @@ export default {
133 155
     },
134 156
     data(){
135 157
         return{
158
+            timeObj: {},
159
+            showMax: false,
136 160
             loadingList: false,
137 161
             tab:1,
138 162
             pickerTimes: {
@@ -171,6 +195,7 @@ export default {
171 195
             var myDate = new Date();
172 196
             this.date = myDate.getFullYear() + '-' + (myDate.getMonth() + 1) + '-' + myDate.getDate() +' '+ myDate.getHours() + ':' + myDate.getMinutes();
173 197
         }
198
+        this.getTime();
174 199
     },
175 200
     methods:{
176 201
         scrollBottom(e) {
@@ -204,6 +229,23 @@ export default {
204 229
         handleCurrentChange(val){
205 230
             this.init(val)
206 231
         },
232
+        getTime(){
233
+            this.$axios.get(this.URL.BASEURL + this.URL.usage_report).then((res) => {
234
+                var res=res.data
235
+                this.loadingList = false;
236
+                if(res&& res.errno == 0){
237
+                    var data=res.rst
238
+                    this.timeObj = data;
239
+                }else {
240
+                    this.$message({
241
+                        message: res.err,
242
+                        type:'warning'
243
+                    });
244
+                }
245
+            }).catch((err)=>{
246
+                this.loadingList = false;
247
+            })
248
+        },
207 249
         init(page){
208 250
             if(this.search_key_word == ''){
209 251
                 this.$message({
@@ -212,7 +254,11 @@ export default {
212 254
                 });
213 255
                 return;
214 256
             }
215
-            this.loadingList = true;
257
+            if(this.searchList.length==0) {
258
+                this.loading = true;
259
+            }else {
260
+                this.loadingList = true;
261
+            }
216 262
             this.isHaveUser = false;
217 263
             this.page = page;
218 264
             this.$axios.get(this.URL.BASEURL + this.URL.userIndex,{
@@ -223,7 +269,11 @@ export default {
223 269
                 }
224 270
             }).then((res) => {
225 271
                 var res=res.data
226
-                this.loadingList = false;
272
+                if(this.searchList.length==0) {
273
+                    this.loading = false;
274
+                }else {
275
+                    this.loadingList = false;
276
+                }
227 277
                 if(res&& res.errno == 0){
228 278
                     var data=res.rst
229 279
                     this.selectUser = {};
@@ -247,10 +297,18 @@ export default {
247 297
                     });
248 298
                 }
249 299
             }).catch((err)=>{
250
-                this.loadingList = false;
300
+                if(this.searchList.length==0) {
301
+                    this.loading = false;
302
+                }else {
303
+                    this.loadingList = false;
304
+                }
251 305
             })
252 306
         },
253 307
         addUser(){
308
+            if(this.timeObj.useful_times==0) {
309
+                this.showMax = true;
310
+                return;
311
+            }
254 312
             //添加视频监测
255 313
             if(!this.selectUser.id){
256 314
                 this.$message({
@@ -282,6 +340,7 @@ export default {
282 340
                 this.loading = false;
283 341
                 var res = res.data;
284 342
                 if(res && res.errno == 0){
343
+                    this.getTime();
285 344
                     this.$message({
286 345
                         message: "添加成功",
287 346
                         type: 'success'
@@ -314,6 +373,54 @@ export default {
314 373
 </script>
315 374
 <style lang="scss" scoped>
316 375
 @import '../index.scss';
376
+.monitorBox .diaMain {
377
+    .diaCon {
378
+        padding: 30px 0 50px;
379
+        text-align: center;
380
+        img {
381
+            display: block;
382
+            margin: 0 auto 30px;
383
+            width: 50px;
384
+            height: 50px;
385
+        }
386
+    }
387
+    .diaTop {
388
+        padding: 0 30px;
389
+        height: 70px;
390
+        line-height: 70px;
391
+        border-bottom: 1px solid #F8F9FB;
392
+        font-size: 18px;
393
+        color: #323232;
394
+        font-weight: bold;
395
+        display: flex;
396
+        justify-content: space-between;
397
+        align-items: center;
398
+    }
399
+    .diaBtn {
400
+        display: flex;
401
+        justify-content: center;
402
+        padding: 0 0 40px;
403
+    }
404
+    .diaBtn .button {
405
+        width: 120px;
406
+        height: 40px;
407
+        line-height: 40px;
408
+        border: 1px solid #979797;
409
+        background: #fff;
410
+        border-radius: 4px;
411
+        text-align: center;
412
+        color: #000;
413
+        cursor: pointer;
414
+        margin-right: 10px;
415
+    }
416
+    .diaBtn .normal {
417
+        background: #2661FF;
418
+        color: #fff;
419
+        border: none;
420
+        margin-right: 0;
421
+        margin-left: 10px;
422
+    }
423
+}
317 424
 .topTab {
318 425
     background: #F5F6F8;
319 426
     padding: 13px 0 20px;
@@ -371,7 +478,7 @@ export default {
371 478
         // width: 505px;
372 479
         width: 700px;
373 480
         position: relative;
374
-        z-index: 9;
481
+        z-index: 1;
375 482
         .banner {
376 483
             height: auto;
377 484
             background: transparent!important;
@@ -407,4 +514,22 @@ export default {
407 514
         }
408 515
     }
409 516
 }
517
+</style>
518
+<style lang="scss">
519
+.diaMain {
520
+    display: flex;
521
+    flex-flow: column;
522
+    justify-content: center;
523
+    .el-dialog {
524
+        width: 515px; 
525
+        margin: auto!important;
526
+        border-radius: 8px;
527
+    }
528
+    .el-dialog__header {
529
+        display: none;
530
+    }
531
+    .el-dialog__body {
532
+        padding: 0;
533
+    }
534
+}
410 535
 </style>