|
|
|
@ -12,6 +12,9 @@ Component({
|
|
|
|
|
weiyiTotal: pieOption(dColor,[]),
|
|
|
|
|
weiyiTotalData: [],
|
|
|
|
|
wyDataList: [],
|
|
|
|
|
//热门词云
|
|
|
|
|
wordCloudActive: 0,
|
|
|
|
|
wordCloudData: [],
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
getData() {
|
|
|
|
@ -74,6 +77,7 @@ Component({
|
|
|
|
|
};
|
|
|
|
|
this.setData({ weiyiTotal: pieOption(dColor,arr), weiyiTotalData: arr})
|
|
|
|
|
});
|
|
|
|
|
this.getWordCloud();
|
|
|
|
|
app.globalData.request({
|
|
|
|
|
action: 'getList0528', //尾翼信息列表
|
|
|
|
|
token: 't%2BrswgjvzGM=',
|
|
|
|
@ -88,6 +92,31 @@ Component({
|
|
|
|
|
this.setData({wyDataList: res})
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
getWordCloud() {
|
|
|
|
|
app.globalData.request({
|
|
|
|
|
action: this.data.wordCloudActive == 0?'getPositive':'getNegative', //正面词云 负面词云
|
|
|
|
|
token: 't%2BrswgjvzGM=',
|
|
|
|
|
sType: 'BrandWeiYi',
|
|
|
|
|
sTimeType: wx.getStorageSync('sTimeType') || 34,
|
|
|
|
|
sStartTime: wx.getStorageSync('sStartTime') || '',
|
|
|
|
|
sEndTime: wx.getStorageSync('sEndTime') || '',
|
|
|
|
|
sBrand: wx.getStorageSync('sBrand') || '',
|
|
|
|
|
}).then(res => {
|
|
|
|
|
let arr1 = [];
|
|
|
|
|
let skey = {
|
|
|
|
|
34: 6000,
|
|
|
|
|
3: 50000,
|
|
|
|
|
20: 180000,
|
|
|
|
|
23: 30000
|
|
|
|
|
};
|
|
|
|
|
Object.keys(res).forEach(key => {
|
|
|
|
|
let o = [key, res[key] / skey[wx.getStorageSync('sTimeType')]]
|
|
|
|
|
arr1.push(o)
|
|
|
|
|
});
|
|
|
|
|
const resArr = arr1.slice(0,50);
|
|
|
|
|
this.setData({wordCloudData: resArr})
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
toEventDetail(value) {
|
|
|
|
|
let id = value.currentTarget.dataset.id;
|
|
|
|
|
wx.setStorageSync('sRele', id);
|
|
|
|
@ -99,6 +128,10 @@ Component({
|
|
|
|
|
wx.navigateTo({
|
|
|
|
|
url: '/pages/insight/pages/brandInsight/tailDataList/index',
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
changeWordCloud(event) {
|
|
|
|
|
this.setData({wordCloudActive: event.detail.index});
|
|
|
|
|
this.getWordCloud()
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
lifetimes: {
|
|
|
|
|