From 87056890b08662d72f5078d6244e83fdf68113fc Mon Sep 17 00:00:00 2001 From: zx <604444282@qq.com> Date: Tue, 9 Aug 2022 16:26:08 +0800 Subject: [PATCH] zx --- .../keyCommunicationPositions/index.vue | 7 +- src/views/KeyMediaBrand/index.vue | 160 ++++-------- .../KeyMediaBrand/modelPopularity/index.vue | 183 -------------- .../modelPopularity/v-ranking-mpth/index.vue | 230 ------------------ .../modelPopularityStoken/index.vue | 39 --- .../negativeOpinionKOL/index.vue | 138 ----------- .../negativeOpinionKOLStoken/index.vue | 94 ------- .../KeyMediaBrand/positiveViewKOL/index.vue | 138 ----------- .../positiveViewKOLStoken/index.vue | 93 ------- .../KeyMediaBrand/spreadTOPmodels/index.vue | 82 +++++++ .../KeyMediaBrand/spreadTOPmodels/opt.js | 111 +++++++++ .../KeyMediaBrand/subscribeSeries/index.vue | 81 ++++++ .../KeyMediaBrand/subscribeSeries/opt.js | 111 +++++++++ .../KeyMediaBrand/weiboCharacters/index.vue | 68 +++--- .../KeyMediaBrand/weiboCharacters/opt.js | 4 +- .../weiboCommunicationTrend/index.vue | 97 +++----- .../weiboContentTOPVolume/index.vue | 18 +- .../KeyMediaBrand/weiboContentType/index.vue | 15 +- .../weiboSpreadFission/index.vue | 100 -------- .../KeyMediaBrand/weiboSpreadFission/opt.js | 82 ------- .../weiboSpreadFissionStoken/index.vue | 50 ---- .../weiboTonalDistribution/index.vue | 92 ------- .../weiboTonalDistribution/opt.js | 112 --------- .../weiboTonalDistributionStoken/index.vue | 51 ---- .../KeyMediaBrand/weiboWordCloud/index.vue | 59 ++--- 25 files changed, 564 insertions(+), 1651 deletions(-) delete mode 100644 src/views/KeyMediaBrand/modelPopularity/index.vue delete mode 100644 src/views/KeyMediaBrand/modelPopularity/v-ranking-mpth/index.vue delete mode 100644 src/views/KeyMediaBrand/modelPopularityStoken/index.vue delete mode 100644 src/views/KeyMediaBrand/negativeOpinionKOL/index.vue delete mode 100644 src/views/KeyMediaBrand/negativeOpinionKOLStoken/index.vue delete mode 100644 src/views/KeyMediaBrand/positiveViewKOL/index.vue delete mode 100644 src/views/KeyMediaBrand/positiveViewKOLStoken/index.vue create mode 100644 src/views/KeyMediaBrand/spreadTOPmodels/index.vue create mode 100644 src/views/KeyMediaBrand/spreadTOPmodels/opt.js create mode 100644 src/views/KeyMediaBrand/subscribeSeries/index.vue create mode 100644 src/views/KeyMediaBrand/subscribeSeries/opt.js delete mode 100644 src/views/KeyMediaBrand/weiboSpreadFission/index.vue delete mode 100644 src/views/KeyMediaBrand/weiboSpreadFission/opt.js delete mode 100644 src/views/KeyMediaBrand/weiboSpreadFissionStoken/index.vue delete mode 100644 src/views/KeyMediaBrand/weiboTonalDistribution/index.vue delete mode 100644 src/views/KeyMediaBrand/weiboTonalDistribution/opt.js delete mode 100644 src/views/KeyMediaBrand/weiboTonalDistributionStoken/index.vue diff --git a/src/views/BrandInsight/keyCommunicationPositions/index.vue b/src/views/BrandInsight/keyCommunicationPositions/index.vue index 11a159f..8957256 100644 --- a/src/views/BrandInsight/keyCommunicationPositions/index.vue +++ b/src/views/BrandInsight/keyCommunicationPositions/index.vue @@ -75,7 +75,12 @@ export default { }); }, goKeyMedia(item) { - console.log(item.label) + this.$router.push({ + path: '/keyMediaBrand', + query: { + source: item.label + } + }) } }, }; diff --git a/src/views/KeyMediaBrand/index.vue b/src/views/KeyMediaBrand/index.vue index 14ae446..ff2bfad 100644 --- a/src/views/KeyMediaBrand/index.vue +++ b/src/views/KeyMediaBrand/index.vue @@ -14,44 +14,30 @@ 返回品牌洞察
-
- {{ form.sBrand }} -
+
{{ form.sSource }}
- +
- {{ countObj.count }} + {{ total }} 信息总量
- +
- {{ countObj.vCount }} - 参与大V数量 + {{ totalRep }} + 评论总数
-
- +
- +
- - - + + +
@@ -91,50 +62,32 @@ - - - - - - + +
-
+ +
+ +
- - - - - - - - - - - - - - + + -
-
- - + + - - + +
@@ -147,26 +100,17 @@ import weiboContentType from "./weiboContentType"; import weiboCharacters from "./weiboCharacters"; import weiboUserActiveArea from "./weiboUserActiveArea"; import weiboContentTOPVolume from "./weiboContentTOPVolume"; -import modelPopularity from "./modelPopularity"; import weiboWordCloud from "./weiboWordCloud"; -import weiboSpreadFission from "./weiboSpreadFission"; -import weiboTonalDistribution from "./weiboTonalDistribution"; -import positiveViewKOL from "./positiveViewKOL"; -import negativeOpinionKOL from "./negativeOpinionKOL"; +import spreadTOPmodels from "./spreadTOPmodels"; +import subscribeSeries from "./subscribeSeries"; //骨架屏 import weiboCommunicationTrendStoken from "./weiboCommunicationTrendStoken"; import weiboContentTypeStoken from "./weiboContentTypeStoken"; import weiboCharactersStoken from "./weiboCharactersStoken"; import weiboUserActiveAreaStoken from "./weiboUserActiveAreaStoken"; import weiboContentTOPVolumeStoken from "./weiboContentTOPVolumeStoken"; -import modelPopularityStoken from "./modelPopularityStoken"; import weiboWordCloudStoken from "./weiboWordCloudStoken"; -import weiboSpreadFissionStoken from "./weiboSpreadFissionStoken"; -import weiboTonalDistributionStoken from "./weiboTonalDistributionStoken"; -import positiveViewKOLStoken from "./positiveViewKOLStoken"; -import negativeOpinionKOLStoken from "./negativeOpinionKOLStoken"; -import { getBrandWeiBoCount0528 } from "@/api/WeiboDetails/index.js"; -import { getAffections } from "@/api/WeiboDetails/index.js"; +import {getCountAndaffections} from "@/api/KeyMediaBrand/index.js" export default { name: "WeiboDetails", components: { @@ -175,24 +119,16 @@ export default { weiboCharacters, // 微博人物画像 weiboUserActiveArea, // 微博用户活跃地区 weiboContentTOPVolume, // 微博内容TOP声量 - modelPopularity, // 车型热度 weiboWordCloud, // 词云分布 - weiboSpreadFission, // 微博传播裂变 - weiboTonalDistribution, // 调性分布 - positiveViewKOL, // 正面观点KOL - negativeOpinionKOL, // 负面观点KOL + spreadTOPmodels, // 传播TOP车型 + subscribeSeries, // 关注TOP车型 //骨架屏 weiboCommunicationTrendStoken, // 微博传播趋势 weiboContentTypeStoken, // 微博内容类型 weiboCharactersStoken, // 微博人物画像 weiboUserActiveAreaStoken, // 微博用户活跃地区 weiboContentTOPVolumeStoken, // 微博内容TOP声量 - modelPopularityStoken, // 车型热度 weiboWordCloudStoken, // 词云分布 - weiboSpreadFissionStoken, // 微博传播裂变 - weiboTonalDistributionStoken, // 调性分布 - positiveViewKOLStoken, // 正面观点KOL - negativeOpinionKOLStoken, // 负面观点KOL }, data() { return { @@ -200,6 +136,8 @@ export default { form: { token: "", sBrand: "", + sSource: '', + ilimitType: 0, }, countObj: { carseriesCount: 0, @@ -213,11 +151,18 @@ export default { 负面: 0, }, total: 0, + totalRep: 0, }; }, created() { this.form.token = this.getToken; this.form.sBrand = this.getBrand.brandname || "奥迪"; + this.form.sSource = this.$route.query.source || "抖音"; + if(this.form.sSource == '汽车之家') { + this.form.ilimitType = 1; + } else if (this.form.sSource == '懂车帝') { + this.form.ilimitType = 2; + } this.getData(); }, methods: { @@ -226,19 +171,20 @@ export default { }, getData() { let obj = Object.assign({}, this.getCtime2, this.form); - getBrandWeiBoCount0528(obj).then((res) => { - let data = res.data; - this.countObj = Object.assign(this.countObj, data); - }); - getAffections(obj).then((res) => { - let data = res.data || {}; - let total = 0; - for (let key in data) { - total += data[key] * 1; + // getBrandWeiBoCount0528(obj).then((res) => { + // let data = res.data; + // this.countObj = Object.assign(this.countObj, data); + // }); + getCountAndaffections(obj).then(res => { + let data = res.data.Affections || {}; + this.total = res.data.Count; + this.totalRep = res.data.ReplyCount; + this.countObj2 = { + 正面: data[0].Value, + 中性: data[1].Value, + 负面: data[2].Value, } - this.countObj2 = Object.assign(this.countObj2, data); - this.total = total; - }); + }) }, }, }; diff --git a/src/views/KeyMediaBrand/modelPopularity/index.vue b/src/views/KeyMediaBrand/modelPopularity/index.vue deleted file mode 100644 index c335a40..0000000 --- a/src/views/KeyMediaBrand/modelPopularity/index.vue +++ /dev/null @@ -1,183 +0,0 @@ - - - - - - - diff --git a/src/views/KeyMediaBrand/modelPopularity/v-ranking-mpth/index.vue b/src/views/KeyMediaBrand/modelPopularity/v-ranking-mpth/index.vue deleted file mode 100644 index fb825e2..0000000 --- a/src/views/KeyMediaBrand/modelPopularity/v-ranking-mpth/index.vue +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - diff --git a/src/views/KeyMediaBrand/modelPopularityStoken/index.vue b/src/views/KeyMediaBrand/modelPopularityStoken/index.vue deleted file mode 100644 index fe0b33a..0000000 --- a/src/views/KeyMediaBrand/modelPopularityStoken/index.vue +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - diff --git a/src/views/KeyMediaBrand/negativeOpinionKOL/index.vue b/src/views/KeyMediaBrand/negativeOpinionKOL/index.vue deleted file mode 100644 index e96eefe..0000000 --- a/src/views/KeyMediaBrand/negativeOpinionKOL/index.vue +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - diff --git a/src/views/KeyMediaBrand/negativeOpinionKOLStoken/index.vue b/src/views/KeyMediaBrand/negativeOpinionKOLStoken/index.vue deleted file mode 100644 index f2fb98a..0000000 --- a/src/views/KeyMediaBrand/negativeOpinionKOLStoken/index.vue +++ /dev/null @@ -1,94 +0,0 @@ - - - - - - diff --git a/src/views/KeyMediaBrand/positiveViewKOL/index.vue b/src/views/KeyMediaBrand/positiveViewKOL/index.vue deleted file mode 100644 index 8a2ad49..0000000 --- a/src/views/KeyMediaBrand/positiveViewKOL/index.vue +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - diff --git a/src/views/KeyMediaBrand/positiveViewKOLStoken/index.vue b/src/views/KeyMediaBrand/positiveViewKOLStoken/index.vue deleted file mode 100644 index 9fce34f..0000000 --- a/src/views/KeyMediaBrand/positiveViewKOLStoken/index.vue +++ /dev/null @@ -1,93 +0,0 @@ - - - - - - diff --git a/src/views/KeyMediaBrand/spreadTOPmodels/index.vue b/src/views/KeyMediaBrand/spreadTOPmodels/index.vue new file mode 100644 index 0000000..1485ba5 --- /dev/null +++ b/src/views/KeyMediaBrand/spreadTOPmodels/index.vue @@ -0,0 +1,82 @@ + + + + + diff --git a/src/views/KeyMediaBrand/spreadTOPmodels/opt.js b/src/views/KeyMediaBrand/spreadTOPmodels/opt.js new file mode 100644 index 0000000..8aaaa5f --- /dev/null +++ b/src/views/KeyMediaBrand/spreadTOPmodels/opt.js @@ -0,0 +1,111 @@ +/* + * @Author: your name + * @Date: 2021-10-12 18:23:25 + * @LastEditTime: 2021-10-12 18:31:20 + * @LastEditors: Please set LastEditors + * @Description: In User Settings Edit + * @FilePath: /data-show/src/views/BrandInsight/spreadTOPmodels/opt.js + */ +import * as echarts from "echarts"; +import { bigNumberTransform } from "@/utils/gol/dataTool" +export default function createOpt(dx,ds) { + return { + grid: { + top: "10%", + left: "16px", + right: "5%", + bottom: "16px", + containLabel: true, + }, + tooltip: { + trigger: "axis", + backgroundColor: "#08182F", + color: "#fff", + borderColor: "#3373CC", + textStyle: { + color: "#fff", //设置文字颜色 + }, + extraCssText: "box-shadow: 0px 0px 10px 0px #3373CC;", + formatter: function (params) { + var result = ""; + var dotHtml = + ''; + params.forEach(function (item) { + result += item.axisValue + "
" + dotHtml + item.data; + }); + return result; + }, + }, + xAxis: { + type: "category", + axisTick: { + show: false, + }, + axisLine: { + show: false, + lineStyle: { + color: "#fff", + }, + }, + data: dx, + }, + yAxis: { + type: "value", + axisLine: { + show: false, + lineStyle: { + color: "#FFF", + }, + }, + axisLabel: { + formatter: (value) => { + let str = bigNumberTransform(value); + return str; + } + }, + splitLine: { + lineStyle: { + type: "dashed", // y轴分割线类型 + color: "#012b4b", + }, + }, + }, + series: [ + { + name: "2001", + data: ds, + type: "bar", + barWidth: 24, + itemStyle: { + normal: { + label: { + show: true, //开启显示 + position: 'top', //在上方显示 + textStyle: { //数值样式 + color: '#fff', + fontSize: 14 + } + }, + color: new echarts.graphic.LinearGradient( + 0, + 1, + 0, + 0, + [ + { + offset: 0, + color: "rgba(99,187,143,0.4)", // 0% 处的颜色 + }, + { + offset: 1, + color: "#51bc8f", // 100% 处的颜色#3373CC + }, + ], + false + ), + }, + }, + }, + ], + } +} diff --git a/src/views/KeyMediaBrand/subscribeSeries/index.vue b/src/views/KeyMediaBrand/subscribeSeries/index.vue new file mode 100644 index 0000000..aac77e1 --- /dev/null +++ b/src/views/KeyMediaBrand/subscribeSeries/index.vue @@ -0,0 +1,81 @@ + + + + + diff --git a/src/views/KeyMediaBrand/subscribeSeries/opt.js b/src/views/KeyMediaBrand/subscribeSeries/opt.js new file mode 100644 index 0000000..878e67a --- /dev/null +++ b/src/views/KeyMediaBrand/subscribeSeries/opt.js @@ -0,0 +1,111 @@ +/* + * @Author: your name + * @Date: 2021-10-12 18:23:25 + * @LastEditTime: 2021-10-12 18:31:20 + * @LastEditors: Please set LastEditors + * @Description: In User Settings Edit + * @FilePath: /data-show/src/views/BrandInsight/spreadTOPmodels/opt.js + */ +import * as echarts from "echarts"; +import { bigNumberTransform } from "@/utils/gol/dataTool" +export default function createOpt(dx,ds) { + return { + grid: { + top: "10%", + left: "16px", + right: "5%", + bottom: "16px", + containLabel: true, + }, + tooltip: { + trigger: "axis", + backgroundColor: "#08182F", + color: "#fff", + borderColor: "#3373CC", + textStyle: { + color: "#fff", //设置文字颜色 + }, + extraCssText: "box-shadow: 0px 0px 10px 0px #3373CC;", + formatter: function (params) { + var result = ""; + var dotHtml = + ''; + params.forEach(function (item) { + result += item.axisValue + "
" + dotHtml + item.data; + }); + return result; + }, + }, + xAxis: { + type: "category", + axisTick: { + show: false, + }, + axisLine: { + show: false, + lineStyle: { + color: "#fff", + }, + }, + data: dx, + }, + yAxis: { + type: "value", + axisLine: { + show: false, + lineStyle: { + color: "#FFF", + }, + }, + axisLabel: { + formatter: (value) => { + let str = bigNumberTransform(value); + return str; + } + }, + splitLine: { + lineStyle: { + type: "dashed", // y轴分割线类型 + color: "#012b4b", + }, + }, + }, + series: [ + { + name: "2001", + data: ds, + type: "bar", + barWidth: 24, + itemStyle: { + normal: { + label: { + show: true, //开启显示 + position: 'top', //在上方显示 + textStyle: { //数值样式 + color: '#fff', + fontSize: 14 + } + }, + color: new echarts.graphic.LinearGradient( + 0, + 1, + 0, + 0, + [ + { + offset: 0, + color: "#CC9D1240", // 0% 处的颜色 + }, + { + offset: 1, + color: "#CC9D12", // 100% 处的颜色#3373CC + }, + ], + false + ), + }, + }, + }, + ], + } +} diff --git a/src/views/KeyMediaBrand/weiboCharacters/index.vue b/src/views/KeyMediaBrand/weiboCharacters/index.vue index 16dce28..017ea5b 100644 --- a/src/views/KeyMediaBrand/weiboCharacters/index.vue +++ b/src/views/KeyMediaBrand/weiboCharacters/index.vue @@ -8,10 +8,10 @@ -->