From 0f71d72c2e55e39193262b8da994bd36e3cb6fdc Mon Sep 17 00:00:00 2001 From: zx <604444282@qq.com> Date: Tue, 6 Sep 2022 15:43:29 +0800 Subject: [PATCH] zx --- components/option/multiColumnsOption.js | 6 +-- pages/insight/modalChild/index.wxss | 3 +- .../pages/eventInsight/evTailwing/index.wxml | 4 +- .../pages/eventInsight/evTailwing/index.wxss | 4 +- .../pages/eventInsight/evTotal/index.js | 50 ++++++++++--------- .../pages/eventInsight/evTotal/index.wxml | 19 +++++-- .../pages/eventInsight/evTotal/index.wxss | 6 ++- .../pages/eventInsight/evWeibo/index.wxss | 5 +- pages/insight/pages/eventInsight/index.wxss | 2 +- .../pages/modalInsight/TutorInsight/index.js | 11 +++- .../modalInsight/TutorInsight/index.wxml | 24 +++++++-- pages/insight/pages/modalInsight/index.js | 4 +- .../pages/modalInsight/weiboInsight/index.js | 6 +++ pages/insight/pages/themeBoard/index.js | 31 ++++++++++-- pages/insight/pages/themeList/index.js | 4 +- pages/insight/themeChild/index.js | 9 +++- pages/insight/themeChild/index.wxml | 3 +- 17 files changed, 135 insertions(+), 56 deletions(-) diff --git a/components/option/multiColumnsOption.js b/components/option/multiColumnsOption.js index f95cf8b..4397811 100644 --- a/components/option/multiColumnsOption.js +++ b/components/option/multiColumnsOption.js @@ -28,9 +28,9 @@ export default function multiColumnsOption(dx=[], dValue=[], dName=[]) { xAxis: { type: 'category', data: dx, - axisLabel: { - interval: 0, - } + // axisLabel: { + // interval: 0, + // } }, yAxis: { type: 'value' diff --git a/pages/insight/modalChild/index.wxss b/pages/insight/modalChild/index.wxss index 03585fe..1bb97a5 100644 --- a/pages/insight/modalChild/index.wxss +++ b/pages/insight/modalChild/index.wxss @@ -100,7 +100,7 @@ display: flex; } .bs-tab-sv-item { - width: 20%; + /* width: 20%; */ height: 100rpx; text-align: center; display: inline-block; @@ -112,5 +112,6 @@ } .bs-tab-title{ font-size: 27rpx; + margin: 0 0rpx 0 24rpx; } \ No newline at end of file diff --git a/pages/insight/pages/eventInsight/evTailwing/index.wxml b/pages/insight/pages/eventInsight/evTailwing/index.wxml index d8b3171..00df880 100644 --- a/pages/insight/pages/eventInsight/evTailwing/index.wxml +++ b/pages/insight/pages/eventInsight/evTailwing/index.wxml @@ -13,8 +13,8 @@ - 热门词云 - + 热门词云 + diff --git a/pages/insight/pages/eventInsight/evTailwing/index.wxss b/pages/insight/pages/eventInsight/evTailwing/index.wxss index 6acdc78..257948c 100644 --- a/pages/insight/pages/eventInsight/evTailwing/index.wxss +++ b/pages/insight/pages/eventInsight/evTailwing/index.wxss @@ -84,9 +84,9 @@ margin-top: 12rpx; } .evtw-area-title { - width: 100%; + width: 95%; font-size: 18px; - padding-left: 32rpx; + /* padding-left: 32rpx; */ font-weight: 600; color: #333333; display: flex; diff --git a/pages/insight/pages/eventInsight/evTotal/index.js b/pages/insight/pages/eventInsight/evTotal/index.js index acc716d..4bec533 100644 --- a/pages/insight/pages/eventInsight/evTotal/index.js +++ b/pages/insight/pages/eventInsight/evTotal/index.js @@ -26,6 +26,7 @@ Component({ wordCloudActive: 0, wordCloudData: [], eventTransActive: 0, + affActive: 0, }, methods: { getData() { @@ -46,27 +47,7 @@ Component({ }; this.setData({ transRankList: arr }); }); - app.globalData.request({ - action: 'getAffectionsTime', //调性分布态势 - token: 't%2BrswgjvzGM=', - sType: 'HotEvent', - sTimeType: wx.getStorageSync('sTimeType') || 34, - sStartTime: wx.getStorageSync('sStartTime') || '', - sEndTime: wx.getStorageSync('sEndTime') || '', - sRele: wx.getStorageSync('sRele') || '', - }).then(res => { - let dx = []; let dAff = ['正面','中性','负面']; - let dValue = [[],[],[]]; - res.forEach(ele => { - dx.push(ele.Time) - for(let i=0;i { let dx = []; @@ -122,6 +101,27 @@ Component({ }) }); }, + getAff() { + app.globalData.request({ + action: 'getAffectionsTime', //调性分布态势 + token: 't%2BrswgjvzGM=', + sType: 'HotEvent', + sTimeType: this.data.affActive == 0 ? '34' : '20', + sRele: wx.getStorageSync('sRele') || '', + }).then(res => { + let dx = []; let dAff = ['正面','中性','负面']; + let dValue = [[],[],[]]; + res.forEach(ele => { + dx.push(ele.Time) + for(let i=0;i - - 事件传播态势 - + + 事件传播态势 + @@ -35,7 +35,16 @@ - 调性分布态势 + + + 调性分布态势 + + + + + + + @@ -61,7 +70,7 @@ - + 热门词云 diff --git a/pages/insight/pages/eventInsight/evTotal/index.wxss b/pages/insight/pages/eventInsight/evTotal/index.wxss index dc04f44..d74a739 100644 --- a/pages/insight/pages/eventInsight/evTotal/index.wxss +++ b/pages/insight/pages/eventInsight/evTotal/index.wxss @@ -11,10 +11,14 @@ border-radius: 8rpx; } .evt-chart-title { + width: 95%; font-size: 18px; - padding-left: 32rpx; + /* padding-left: 32rpx; */ + margin-left: 32rpx; font-weight: 600; color: #333333; + display: flex; + justify-content: flex-start; } .evt-chart-subTitle { font-size: 12px; diff --git a/pages/insight/pages/eventInsight/evWeibo/index.wxss b/pages/insight/pages/eventInsight/evWeibo/index.wxss index 6393169..f4012f7 100644 --- a/pages/insight/pages/eventInsight/evWeibo/index.wxss +++ b/pages/insight/pages/eventInsight/evWeibo/index.wxss @@ -84,9 +84,10 @@ margin-top: 12rpx; } .evw-area-title { - width: 100%; + width: 95%; font-size: 18px; - padding-left: 32rpx; + /* padding-left: 32rpx; */ + margin-left: 32rpx; font-weight: 600; color: #333333; display: flex; diff --git a/pages/insight/pages/eventInsight/index.wxss b/pages/insight/pages/eventInsight/index.wxss index 270d38b..e76c78a 100644 --- a/pages/insight/pages/eventInsight/index.wxss +++ b/pages/insight/pages/eventInsight/index.wxss @@ -60,7 +60,7 @@ .view-tabs .van-tab--active{ color: #0084FF; /* 字体颜色 */ - font-size: 19px; + font-size: 16px; font-weight: 600; } .view-tabs .van-tabs__line { diff --git a/pages/insight/pages/modalInsight/TutorInsight/index.js b/pages/insight/pages/modalInsight/TutorInsight/index.js index 8e760a8..a69bb78 100644 --- a/pages/insight/pages/modalInsight/TutorInsight/index.js +++ b/pages/insight/pages/modalInsight/TutorInsight/index.js @@ -55,6 +55,8 @@ Component({ 'background: rgb(75,203,100)', 'background: rgb(75,214,213)', ], + infoShow1: false, + infoShow2: false, }, methods: { getData() { @@ -80,7 +82,8 @@ Component({ sBrand: wx.getStorageSync('sBrand') || '', sSeriesName: wx.getStorageSync('sSeriesName') || '', }).then(res => { - let total = res.正面*1 + res.中性*1 + res.负面*1 + let total = res.正面*1 + res.中性*1 + res.负面*1; + if(total == 0) {total = 1}; let obj = { positive: (res.正面/total*100).toFixed(0), middle: (res.中性/total*100).toFixed(0), @@ -344,6 +347,12 @@ Component({ suChange(event) { this.setData({suActive: event.detail.index}); this.getSubUserAnalize() + }, + info1() { + this.setData({infoShow1: true}) + }, + info2() { + this.setData({infoShow2: true}) } }, lifetimes: { diff --git a/pages/insight/pages/modalInsight/TutorInsight/index.wxml b/pages/insight/pages/modalInsight/TutorInsight/index.wxml index 6d1593a..45ff743 100644 --- a/pages/insight/pages/modalInsight/TutorInsight/index.wxml +++ b/pages/insight/pages/modalInsight/TutorInsight/index.wxml @@ -8,9 +8,9 @@ {{detailData.Count}} - 品牌千人发帖量 + 车型千人发帖量 {{detailData.qrCount}} - 品牌千人评论量 + 车型千人评论量 {{detailData.replyCount}} @@ -21,10 +21,10 @@ 量差 - ?⃝ - {{detailData.Count}} + ?⃝ + {{detailData.qrCount - detailData.hyqrCount}} 量差 - ?⃝ + ?⃝ {{detailData.replyCountDifference}} @@ -239,4 +239,18 @@ + + + 行业千人发帖量=【(行业所有车型主贴量×1000)÷所有阅读量】÷车型数量 + 千人发帖量=(车型主贴量×1000)÷阅读量 + 千人发帖量量差=品牌千人发帖量-行业千人发帖量 + + + + + 行业千人评论量=【(行业所有车型评论量×1000)÷所有阅读量】÷车型数量 + 千人评论量=(车型评论量×1000)÷阅读量 + 千人评论量量差=品牌千人评论量-行业千人评论量 + + \ No newline at end of file diff --git a/pages/insight/pages/modalInsight/index.js b/pages/insight/pages/modalInsight/index.js index 971ab32..7ad60b0 100644 --- a/pages/insight/pages/modalInsight/index.js +++ b/pages/insight/pages/modalInsight/index.js @@ -69,12 +69,12 @@ Page({ createReport() { app.globalData.request({ action: 'getToPptTask', - sType: 'ToBrandPptV6', + sType: 'ToSeriesPptV6', token: 't%2BrswgjvzGM=', sTimeType: wx.getStorageSync('sTimeType') || 34, sStartTime: wx.getStorageSync('sStartTime') || '', sEndTime: wx.getStorageSync('sEndTime') || '', - sBrand: this.currentBrand, + sBrand: this.data.currentBrand, sSeriesName: wx.getStorageSync('sSeriesName') || '', }).then(res => { wx.showModal({ diff --git a/pages/insight/pages/modalInsight/weiboInsight/index.js b/pages/insight/pages/modalInsight/weiboInsight/index.js index 6284b68..e9a3f8a 100644 --- a/pages/insight/pages/modalInsight/weiboInsight/index.js +++ b/pages/insight/pages/modalInsight/weiboInsight/index.js @@ -94,6 +94,7 @@ Component({ sSeriesName: wx.getStorageSync('sSeriesName') || '', }).then(res => { let total = res.正面*1 + res.中性*1 + res.负面*1 + if(total == 0) { total = 1 } let obj = { positive: (res.正面/total*100).toFixed(0), middle: (res.中性/total*100).toFixed(0), @@ -134,6 +135,7 @@ Component({ res.forEach(ele => { total = total + ele.value*1 }); + if(total == 0) { total = 1 } let arr = []; res.forEach(ele => { let obj = {value: ele.value, name: ele.key, percent: (ele.value*100/total).toFixed(0)}; @@ -155,6 +157,7 @@ Component({ res.forEach(ele => { total = total + ele.value*1 }); + if(total == 0) { total = 1 } let arr = []; res.forEach(ele => { let obj = {value: ele.value, name: ele.key, percent: (ele.value*100/total).toFixed(0)}; @@ -266,6 +269,7 @@ Component({ for(let key in res.sex) { sexTotal = sexTotal + res.sex[key]*1; }; + if(sexTotal == 0) {sexTotal = 1} for(let key in res.sex) { let obj = { value: res.sex[key], @@ -278,6 +282,7 @@ Component({ for(let key in res.attestation) { sexTotal = sexTotal + res.attestation[key]*1; }; + if(sexTotal == 0) {sexTotal = 1} for(let key in res.attestation) { let obj = { value: res.attestation[key], @@ -290,6 +295,7 @@ Component({ for(let key in res.RegionWeiBo) { sexTotal = sexTotal + res.RegionWeiBo[key]*1; }; + if(sexTotal == 0) {sexTotal = 1} for(let key in res.RegionWeiBo) { let obj = { value: res.RegionWeiBo[key], diff --git a/pages/insight/pages/themeBoard/index.js b/pages/insight/pages/themeBoard/index.js index 32cf010..0d1e721 100644 --- a/pages/insight/pages/themeBoard/index.js +++ b/pages/insight/pages/themeBoard/index.js @@ -15,6 +15,8 @@ Page({ sTitle: '', sGuid: '', website: '', + sStartTime: '', + sEndTime: '', //顶部信息 affData: {}, //Affections, AffectionsMsg, Summarize affPercent: pieOption(dColor2,[]), @@ -64,7 +66,9 @@ Page({ sQingGan: option.sQingGan, sTitle: option.sTitle, sGuid: option.Guid, - website: option.website + website: option.website, + sStartTime: option.sStartTime, + sEndTime: option.sEndTime, }) }, onShow() { @@ -73,9 +77,9 @@ Page({ getData() { let obj = { token: 't%2BrswgjvzGM=', - sTimeType: wx.getStorageSync('sTimeType') || 34, - sStartTime: wx.getStorageSync('sStartTime') || '', - sEndTime: wx.getStorageSync('sEndTime') || '', + sTimeType: 4, + sStartTime: this.data.sStartTime, + sEndTime: this.data.sEndTime, sQuDao: this.data.sQuDao, sQingGan: this.data.sQingGan, sTitle: this.data.sTitle, @@ -234,7 +238,24 @@ Page({ }) }, createReport() { - + app.globalData.request({ + action: 'getToPptTask', + sType: 'ToZhuTiPptV6', + token: 't%2BrswgjvzGM=', + sTimeType: 4, + sStartTime: this.data.sStartTime, + sEndTime: this.data.sEndTime, + sQuDao: this.data.sQuDao, + sQingGan: this.data.sQingGan, + sTitle: this.data.sTitle, + sGuid: this.data.sGuid, + website: this.data.website, + }).then(res => { + wx.showModal({ + title: '数据生成中,请前往”我的“查看生成进度', + showCancel: false + }) + }); }, getUserChar() { let obj = { diff --git a/pages/insight/pages/themeList/index.js b/pages/insight/pages/themeList/index.js index ed7a3f5..8787aae 100644 --- a/pages/insight/pages/themeList/index.js +++ b/pages/insight/pages/themeList/index.js @@ -169,9 +169,11 @@ Page({ let qingGan = (this.data.sQingGan).join(',') || '-1'; let title = this.data.sTitle; let website = this.data.website; + let sStartTime = this.data.sStartTime; + let sEndTime= this.data.sEndTime; wx.navigateTo({ url: '/pages/insight/pages/themeBoard/index'+'?Guid=' + Guid - +'&sQuDao='+quDao+'&sQingGan='+qingGan+'&sTitle='+title+'&website='+website, + +'&sQuDao='+quDao+'&sQingGan='+qingGan+'&sTitle='+title+'&website='+website+'&sStartTime='+sStartTime+'&sEndTime='+sEndTime, }) }, openReport() { diff --git a/pages/insight/themeChild/index.js b/pages/insight/themeChild/index.js index 242a344..37639e3 100644 --- a/pages/insight/themeChild/index.js +++ b/pages/insight/themeChild/index.js @@ -48,7 +48,14 @@ Component({ pageSize: 100, sType: this.data.tabActive == 0 ? 'now' : 'former' }).then(res => { - this.setData({themeData: res}) + let data = res; + let nd = new Date().valueOf(); + data.forEach(ele => { + if(new Date(ele.EndTime).valueOf() < nd) { + ele.Classify = 1 + } + }) + this.setData({themeData: data}) }); }, toThemeDataList(event) { diff --git a/pages/insight/themeChild/index.wxml b/pages/insight/themeChild/index.wxml index e2ffa84..1b8bb73 100644 --- a/pages/insight/themeChild/index.wxml +++ b/pages/insight/themeChild/index.wxml @@ -15,7 +15,8 @@ {{item.AddTime}} - {{item.Classify == 0? '进行中':'已完成'}} + 进行中 + 已完成 {{item.Name}}