阿丽 3 years ago
commit d9966f538b

@ -0,0 +1,66 @@
import httpService from "@/request"
// 品牌对比-品牌调性比例
export function getAffectionsC(params) {
let obj = Object.assign({action: 'getAffectionsC', sType: 'BrandOverview', iContrastType: 1}, params)
return httpService({
url: `/api/v6.ashx`,
method: 'post',
data: obj,
headers: {
'content-type': 'application/x-www-form-urlencoded'
}
})
}
// 品牌对比-信息量趋势
export function getCountTime0528C(params) {
let obj = Object.assign({action: 'getCountTime0528C', sType: 'BrandOverview', iContrastType: 1}, params)
return httpService({
url: `/api/v6.ashx`,
method: 'post',
data: obj,
headers: {
'content-type': 'application/x-www-form-urlencoded'
}
})
}
// 品牌对比-整体信息量
export function getContrastCount0528C(params) {
let obj = Object.assign({action: 'getContrastCount0528C', sType: 'BrandOverview', iContrastType: 1}, params)
return httpService({
url: `/api/v6.ashx`,
method: 'post',
data: obj,
headers: {
'content-type': 'application/x-www-form-urlencoded'
}
})
}
// 品牌对比-整体互动人数
export function getInteractCount0528C(params) {
let obj = Object.assign({action: 'getInteractCount0528C', sType: 'BrandOverview', iContrastType: 1}, params)
return httpService({
url: `/api/v6.ashx`,
method: 'post',
data: obj,
headers: {
'content-type': 'application/x-www-form-urlencoded'
}
})
}
// 品牌对比-渠道分布
export function getSourcetypeC(params) {
let obj = Object.assign({action: 'getSourcetypeC', sType: 'BrandOverview', iContrastType: 1}, params)
return httpService({
url: `/api/v6.ashx`,
method: 'post',
data: obj,
headers: {
'content-type': 'application/x-www-form-urlencoded'
}
})
}

@ -7,75 +7,120 @@
* @FilePath: /data-show/src/views/BrandComparison/brandTonalDistribution/index.vue * @FilePath: /data-show/src/views/BrandComparison/brandTonalDistribution/index.vue
--> -->
<template> <template>
<div class="bd-outter"> <div class="bd-outter">
<v-label-div title="品牌调性分布"> <v-label-div title="品牌调性分布"> </v-label-div>
</v-label-div> <div class="bd-d1">
<div class="bd-d1"> <div class="dd1" style="margin-left: 16px">
<div class="dd1" style="margin-left: 16px"><span class="s1"></span><span class="s2">正面</span></div> <span class="s1"></span><span class="s2">正面</span>
<div class="dd1" style="margin-left: 24px;"><span class="s1" :style="{background: '#54BF93'}"></span><span class="s2">中性</span></div> </div>
<div class="dd1" style="margin-left: 24px;"><span class="s1" :style="{background: '#CC9D12'}"></span><span class="s2">负面</span></div> <div class="dd1" style="margin-left: 24px">
</div> <span class="s1" :style="{ background: '#54BF93' }"></span
<div class="bd-inner"> ><span class="s2">中性</span>
<roundata title="奥迪" color="#3373CC" style="margin-left: 46px"></roundata> </div>
<roundata title="宝马" color="#63AECC" style="margin-left: 110px"></roundata> <div class="dd1" style="margin-left: 24px">
<roundata title="奔驰" color="#54BF93" style="margin-left: 110px"></roundata> <span class="s1" :style="{ background: '#CC9D12' }"></span
<roundata title="吉利" color="#CC9D12" style="margin-left: 110px"></roundata> ><span class="s2">负面</span>
<roundata title="大众" color="#CC7733" style="margin-left: 110px"></roundata> </div>
<roundata title="别克" color="#CC5B41" style="margin-left: 110px"></roundata>
</div>
</div> </div>
<div class="bd-inner">
<roundata
v-for="(item,index) in list"
:key="index"
:title="item.Name"
:color="colors[index]"
:style="index === 0 ? 'margin-left: 46px': 'margin-left: 110px'"
:data="item.Data"
></roundata>
</div>
</div>
</template> </template>
<script> <script>
import { getAffectionsC } from "@/api/BrandComparison";
import roundata from "./roundata"; import roundata from "./roundata";
export default { export default {
name: "brandTonalDistribution", name: "brandTonalDistribution",
components: { components: {
roundata, roundata,
},
data() {
return {
form: {
token: "",
sBrand: "",
},
colors: ['#3373CC', '#63AECC', '#54BF93', '#CC9D12', '#CC7733', '#CC5B41'],
list: [
]
};
},
created() {
this.initData();
},
methods: {
initData() {
this.form.token = this.getToken;
let arr = this.getBComparison;
let brands = [];
arr.forEach(ele => {
brands.push(ele.name)
});
this.form.sBrand = brands.toString();
this.getData();
}, },
data() { //
return { getData() {
opt: {}, return new Promise((resolve, reject) => {
}; let obj = Object.assign({}, this.getCtime2, this.form);
getAffectionsC(obj).then((res) => {
let data = res.data || [];
this.list = data;
resolve(data)
}).catch(() => {
reject(false)
});
});
}, },
},
}; };
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
.bd-outter { .bd-outter {
width: 100%;
height: 460px;
border: 2px solid #0f2a4d;
margin-top: 16px;
.bd-d1 {
width: 100%; width: 100%;
height: 460px; display: flex;
border: 2px solid #0f2a4d; height: 36px;
margin-top: 16px; justify-content: flex-start;
.bd-d1 { align-items: center;
width: 100%; .dd1 {
display: flex; display: flex;
height: 36px; justify-content: flex-start;
justify-content: flex-start; align-items: center;
align-items: center;
.dd1 {
display: flex;
justify-content: flex-start;
align-items: center;
}
.s1 {
display: inline-block;
width: 12px;
height: 12px;
background: #3373cc;
}
.s2 {
display: inline-block;
font-size: 12px;
color: #fff;
margin-left: 10px;
}
} }
.bd-inner { .s1 {
width: 100%; display: inline-block;
height: calc(100% - 48px); width: 12px;
display: flex; height: 12px;
justify-content: flex-start; background: #3373cc;
align-items: center;
} }
.s2 {
display: inline-block;
font-size: 12px;
color: #fff;
margin-left: 10px;
}
}
.bd-inner {
width: 100%;
height: calc(100% - 48px);
display: flex;
justify-content: flex-start;
align-items: center;
}
} }
</style> </style>

@ -9,7 +9,7 @@
<template> <template>
<div class="bd-item-round"> <div class="bd-item-round">
<div class="bd-item-r-cav"> <div class="bd-item-r-cav">
<v-echarts :opt="opt" @echarsUpdate="echarsFun"></v-echarts> <v-echarts :opt="opt"></v-echarts>
</div> </div>
<span class="bd-item-r-c-s1" :style="{color: color}">{{title}}</span> <span class="bd-item-r-c-s1" :style="{color: color}">{{title}}</span>
</div> </div>
@ -27,38 +27,26 @@ export default {
type: String, type: String,
default: "", default: "",
}, },
data: {
type: Object,
default: () => {}
}
},
watch: {
data: {
handler(val) {
this.opt = createOpt(val)
},
immediate: true
}
}, },
data() { data() {
return { return {
opt: createOpt(),
}; };
}, },
methods: { methods: {
echarsFun(myChart) {
let index = 0;
myChart.dispatchAction({
type: "highlight",
seriesIndex: 0,
dataIndex: 0,
});
myChart.on("mouseover", function (e) {
if (e.dataIndex != index) {
myChart.dispatchAction({
type: "downplay",
seriesIndex: 0,
dataIndex: index,
});
}
});
myChart.on("mouseout", function (e) {
index = e.dataIndex;
myChart.dispatchAction({
type: "highlight",
seriesIndex: 0,
dataIndex: e.dataIndex,
});
});
},
}, },
}; };
</script> </script>

@ -7,7 +7,40 @@
* @FilePath: /data-show/src/views/BrandInsight/weiboKol/opt.js * @FilePath: /data-show/src/views/BrandInsight/weiboKol/opt.js
*/ */
import * as echarts from "echarts"; import * as echarts from "echarts";
export default function createOpt() { function createData(obj = {}) {
if(JSON.stringify(obj) === '{}') {
return;
}
let arr = [];
for(let key in obj) {
let color = "";
if(key === '正面') {
color = "#3373CC"
} else if(key === '负面') {
color = "#b38b14"
} else {
color = "#54BF93"
}
let o = {
value: obj[key],
name: key,
itemStyle: {color: new echarts.graphic.LinearGradient(0, 1, 1, 0, [{
//给颜色设置渐变色 前面4个参数给第一个设置1第四个设置0 ,就是水平渐变
//给第一个设置0第四个设置1就是垂直渐变
offset: 0,
color: 'black'
}, {
offset: 1,
color: color
}])}
}
arr.push(o)
}
return arr
}
export default function createOpt(obj = {}) {
let data = createData(obj)
return { return {
series: [ series: [
{ {
@ -18,52 +51,23 @@ export default function createOpt() {
label: { label: {
show: false, show: false,
position: 'center', position: 'center',
lineHeight: 40 lineHeight: 28
}, },
emphasis: { emphasis: {
label: { label: {
show: true, show: true,
fontSize: '20', fontSize: '18',
color: "#ffff", color: "#ffff",
fontWeight: 'bold', fontWeight: 'bold',
formatter: function(p) { formatter: function(p) {
return `${p.data.name}\n25%\n${p.data.value}` return `${p.data.name}\n${p.percent}%\n${p.data.value}`
} }
} }
}, },
labelLine: { labelLine: {
show: false show: false
}, },
data: [ data: data
{ value: 2000, name: '正面', itemStyle: {color: new echarts.graphic.LinearGradient(0, 1, 1, 0, [{
//给颜色设置渐变色 前面4个参数给第一个设置1第四个设置0 ,就是水平渐变
//给第一个设置0第四个设置1就是垂直渐变
offset: 0,
color: 'black'
}, {
offset: 1,
color: '#3373CC'
}])} },
{ value: 1000, name: '中性', itemStyle: {color: new echarts.graphic.LinearGradient(0, 1, 1, 0, [{
//给颜色设置渐变色 前面4个参数给第一个设置1第四个设置0 ,就是水平渐变
//给第一个设置0第四个设置1就是垂直渐变
offset: 0,
color: 'black'
}, {
offset: 1,
color: '#54BF93'
}])} },
{ value: 1000, name: '负面', itemStyle: {color: new echarts.graphic.LinearGradient(0, 1, 1, 0, [{
//给颜色设置渐变色 前面4个参数给第一个设置1第四个设置0 ,就是水平渐变
//给第一个设置0第四个设置1就是垂直渐变
offset: 0,
color: 'black'
}, {
offset: 1,
color: '#b38b14'
}])} },
],
}, },
{ {
name: 'Access From1', name: 'Access From1',
@ -78,37 +82,7 @@ export default function createOpt() {
show: false show: false
}, },
center: ['50%', '50%'],//边框位置 center: ['50%', '50%'],//边框位置
data: [ data: data
{ value: 2000, name: '正面', itemStyle: {color: new echarts.graphic.LinearGradient(0, 1, 1, 0, [{
//给颜色设置渐变色 前面4个参数给第一个设置1第四个设置0 ,就是水平渐变
//给第一个设置0第四个设置1就是垂直渐变
offset: 0,
color: 'black'
}, {
offset: 1,
color: '#3373CC'
}])} },
{ value: 1000, name: '中性', itemStyle: {color: new echarts.graphic.LinearGradient(0, 1, 1, 0, [{
//给颜色设置渐变色 前面4个参数给第一个设置1第四个设置0 ,就是水平渐变
//给第一个设置0第四个设置1就是垂直渐变
offset: 0,
color: 'black'
}, {
offset: 1,
color: '#54BF93'
}])} },
{ value: 1000, name: '负面', itemStyle: {color: new echarts.graphic.LinearGradient(0, 1, 1, 0, [{
//给颜色设置渐变色 前面4个参数给第一个设置1第四个设置0 ,就是水平渐变
//给第一个设置0第四个设置1就是垂直渐变
offset: 0,
color: 'black'
}, {
offset: 1,
color: '#b38b14'
}])} },
],
} }
] ]
} }

@ -7,35 +7,72 @@
* @FilePath: /data-show/src/views/BrandComparison/channelDistribution/index.vue * @FilePath: /data-show/src/views/BrandComparison/channelDistribution/index.vue
--> -->
<template> <template>
<div class="cd-outter"> <div class="cd-outter">
<v-label-div title="渠道分布"> <v-label-div title="渠道分布"> </v-label-div>
</v-label-div> <div class="cd-inner">
<div class="cd-inner"> <v-echarts :opt="opt"></v-echarts>
<v-echarts :opt="opt"></v-echarts>
</div>
</div> </div>
</div>
</template> </template>
<script> <script>
import createOpt from "./opt" import { getSourcetypeC } from "@/api/BrandComparison";
import createOpt from "./opt";
export default { export default {
name: "channelDistribution", name: "channelDistribution",
data() { data() {
return { return {
opt: createOpt() form: {
} token: "",
} sBrand: "",
},
opt: {},
};
},
created() {
this.initData();
},
methods: {
initData() {
this.form.token = this.getToken;
let arr = this.getBComparison;
let brands = [];
arr.forEach((ele) => {
brands.push(ele.name);
});
this.form.sBrand = brands.toString();
this.getData();
},
getData() {
return new Promise((resolve, reject) => {
let obj = Object.assign({}, this.getCtime2, this.form);
getSourcetypeC(obj)
.then((res) => {
let data = res.data || [];
let brandList = [];
data.forEach(e => {
brandList.push(e.Name);
})
this.opt = createOpt(data,brandList);
resolve(data);
})
.catch(() => {
reject(false);
});
});
},
},
}; };
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
.cd-outter { .cd-outter {
width: 936px; width: 936px;
height: 460px; height: 460px;
border: 2px solid #0f2a4d; border: 2px solid #0f2a4d;
.cd-inner { .cd-inner {
width: 100%; width: 100%;
height: calc(100% - 48px); height: calc(100% - 48px);
} }
} }
</style> </style>

@ -6,8 +6,38 @@
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: /data-show/src/views/BrandComparison/channelDistribution/opt.js * @FilePath: /data-show/src/views/BrandComparison/channelDistribution/opt.js
*/ */
import { bigNumberTransform } from "@/utils/gol/dataTool"
let colors = ['#3373CC', '#63AECC', '#54BF93', '#CC9D12', '#CC7733', "#CC5B41", '#452b74', '#71686f'] let colors = ['#3373CC', '#63AECC', '#54BF93', '#CC9D12', '#CC7733', "#CC5B41", '#452b74', '#71686f']
export default function createOpt() { function createData(dataList = []) {
/*series: [
{
name: '奥迪',
type: 'bar',
barGap: 0,
barWidth: 16,
emphasis: {
focus: 'series'
},
data: [320, 332, 301, 334, 390, 400]
},*/
let arr = [];
dataList.forEach(e => {
let o = {
name: e.Name,
type: 'bar',
barGap: 0,
barWidth: 16,
emphasis: {
focus: 'series'
},
data: [e.Data.新闻,e.Data.论坛,e.Data.微信,e.Data.短视频,e.Data.微博,e.Data.其他]
};
arr.push(o)
})
return arr;
}
export default function createOpt(dataList = [],brandList = []) {
let info = createData(dataList);
return { return {
grid: { grid: {
top: "56px", top: "56px",
@ -18,7 +48,7 @@ export default function createOpt() {
}, },
color: colors, color: colors,
legend: { legend: {
data: ['奥迪', '宝马', '奔驰', '吉利', '大众', '别克'], data: brandList,
textStyle: { //图例文字的样式 textStyle: { //图例文字的样式
color: '#fff' color: '#fff'
}, },
@ -59,6 +89,12 @@ export default function createOpt() {
color: "#FFF", color: "#FFF",
}, },
}, },
axisLabel: {
formatter: (value) => {
let str = bigNumberTransform(value);
return str;
}
},
splitLine: { splitLine: {
lineStyle: { lineStyle: {
type: "dashed", // y轴分割线类型 type: "dashed", // y轴分割线类型
@ -67,62 +103,6 @@ export default function createOpt() {
}, },
} }
], ],
series: [ series: info
{
name: '奥迪',
type: 'bar',
barGap: 0,
barWidth: 16,
emphasis: {
focus: 'series'
},
data: [320, 332, 301, 334, 390, 400]
},
{
name: '宝马',
type: 'bar',
barWidth: 16,
emphasis: {
focus: 'series'
},
data: [220, 182, 191, 234, 290, 300]
},
{
name: '奔驰',
type: 'bar',
barWidth: 16,
emphasis: {
focus: 'series'
},
data: [150, 232, 201, 154, 190, 200]
},
{
name: '吉利',
type: 'bar',
barWidth: 16,
emphasis: {
focus: 'series'
},
data: [98, 77, 101, 99, 40, 44]
},
{
name: '大众',
type: 'bar',
barWidth: 16,
emphasis: {
focus: 'series'
},
data: [198, 177, 101, 199, 140, 145]
},
{
name: '别克',
type: 'bar',
barWidth: 16,
emphasis: {
focus: 'series'
},
data: [298, 277, 201, 299, 240, 250]
}
]
} }
} }

@ -7,34 +7,69 @@
* @FilePath: /data-show/src/views/BrandComparison/informationTrend/index.vue * @FilePath: /data-show/src/views/BrandComparison/informationTrend/index.vue
--> -->
<template> <template>
<div class="it-outter"> <div class="it-outter">
<v-label-div title="信息量趋势" ></v-label-div> <v-label-div title="信息量趋势"></v-label-div>
<div class="it-inner"> <div class="it-inner">
<v-echarts :opt="opt"></v-echarts> <v-echarts :opt="opt"></v-echarts>
</div>
</div> </div>
</div>
</template> </template>
<script> <script>
import createOpt from "./opt" import { getCountTime0528C } from "@/api/BrandComparison";
import createOpt from "./opt";
export default { export default {
name: "informationTrend", name: "informationTrend",
data() { data() {
return { return {
opt: createOpt() form: {
} token: "",
} sBrand: "",
} },
opt: {},
};
},
created() {
this.initData();
},
methods: {
initData() {
this.form.token = this.getToken;
let arr = this.getBComparison;
let brands = [];
arr.forEach((ele) => {
brands.push(ele.name);
});
this.form.sBrand = brands.toString();
this.getData();
},
getData() {
let obj = Object.assign({}, this.getCtime2, this.form);
getCountTime0528C(obj).then((res) => {
let data = res.data || [];
let dx = [];
let ds = [];
data.forEach(ele => {
let key = ele.key;
let value = ele.value;
dx.push(key);
ds.push(value);
});
this.opt = createOpt(dx, ds);
});
},
},
};
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
.it-outter { .it-outter {
width: 618px; width: 618px;
height: 460px; height: 460px;
border: 2px solid #0F2A4D; border: 2px solid #0f2a4d;
.it-inner { .it-inner {
width: 100%; width: 100%;
height: calc(100% - 48px); height: calc(100% - 48px);
} }
} }
</style> </style>

@ -6,7 +6,37 @@
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: /data-show/src/views/BrandInsight/titsopo/opt.js * @FilePath: /data-show/src/views/BrandInsight/titsopo/opt.js
*/ */
export default function createOpt() { import { bigNumberTransform } from "@/utils/gol/dataTool"
function createData(ds = []) {
let testData = {}
ds.forEach(item => {
item.forEach(val => {
if (testData[val.key] === undefined) {
testData[val.key] = {
name: val.key,
type: 'line',
symbol: 'none',
areaStyle: {
opacity: 0.2
},
emphasis: {
focus: 'series'
},
data: [val.value]
}
} else {
testData[val.key].data.push(val.value)
}
})
})
let arr = [];
for(let key in testData) {
arr.push(testData[key])
}
return arr
}
export default function createOpt(dx = [], ds = []) {
let data = createData(ds);
return { return {
grid: { grid: {
left: 16, left: 16,
@ -39,13 +69,19 @@ export default function createOpt() {
axisTick: { axisTick: {
show: false, show: false,
}, },
axisLabel: {
formatter: (value) => {
let str = value.substring(10, 16)
return str;
}
},
axisLine: { axisLine: {
show: false, show: false,
lineStyle: { lineStyle: {
color: "#fff", color: "#fff",
}, },
}, },
data: ['00:00', '04:00', '08:00', '12:00', '16:00', '20:00', '24:00'] data: dx
}, },
yAxis: { yAxis: {
type: 'value', type: 'value',
@ -55,6 +91,12 @@ export default function createOpt() {
color: "#fff", color: "#fff",
}, },
}, },
axisLabel: {
formatter: (value) => {
let str = bigNumberTransform(value);
return str;
}
},
splitLine: { splitLine: {
lineStyle: { lineStyle: {
type: "dashed", // y轴分割线类型 type: "dashed", // y轴分割线类型
@ -62,86 +104,6 @@ export default function createOpt() {
}, },
}, },
}, },
series: [ series: data
{
name: '奥迪',
type: 'line',
stack: 'Total',
symbol: 'none',
areaStyle: {
opacity: 0.4
},
emphasis: {
focus: 'series'
},
data: [2000, 1600, 1000, 2200, 2300, 2100, 1900]
},
{
name: '宝马',
type: 'line',
stack: 'Total',
symbol: 'none',
areaStyle: {
opacity: 0.4
},
emphasis: {
focus: 'series'
},
data: [1000, 1100, 1300, 2000, 1800, 2100, 1600]
},
{
name: '奔驰',
type: 'line',
stack: 'Total',
symbol: 'none',
areaStyle: {
opacity: 0.4
},
emphasis: {
focus: 'series'
},
data: [1200, 1200, 1400, 2100, 1400, 1900, 2000]
},
{
name: '吉利',
type: 'line',
stack: 'Total',
symbol: 'none',
areaStyle: {
opacity: 0.4
},
emphasis: {
focus: 'series'
},
data: [1200, 1200, 1350, 1550, 1750, 1900, 2000]
},
{
name: '大众',
type: 'line',
stack: 'Total',
symbol: 'none',
areaStyle: {
opacity: 0.4
},
emphasis: {
focus: 'series'
},
data: [1260, 1280, 1390, 1570, 1790, 1950, 2020]
},
{
name: '别克',
type: 'line',
stack: 'Total',
symbol: 'none',
areaStyle: {
opacity: 0.4
},
emphasis: {
focus: 'series'
},
data: [1260, 1280, 1390, 1570, 1790, 1950, 2020]
},
]
} }
} }

@ -16,12 +16,50 @@
</template> </template>
<script> <script>
import {getContrastCount0528C} from "@/api/BrandComparison"
import {createSingleColumnar} from "@/utils/gol/singleColumnar" import {createSingleColumnar} from "@/utils/gol/singleColumnar"
export default { export default {
name: "overallInformation", name: "overallInformation",
data() { data() {
return { return {
opt: createSingleColumnar(["奥迪", "宝马", "奔驰", "吉利", "大众", "别克"],[2200, 1900, 1800, 1600, 1400, 1500]) form: {
token: "",
sBrand: ""
},
opt: {}
}
},
created() {
this.initData();
},
methods: {
initData() {
this.form.token = this.getToken;
let arr = this.getBComparison;
let brands = [];
arr.forEach(ele => {
brands.push(ele.name)
});
this.form.sBrand = brands.toString();
this.getData();
},
getData() {
return new Promise((resolve, reject) => {
let obj = Object.assign({}, this.getCtime2, this.form);
getContrastCount0528C(obj).then((res) => {
let data = res.data || [];
let brandsList = [];
let infoList = [];
data.forEach(e => {
brandsList.push(e.key);
infoList.push(e.value);
})
this.opt = createSingleColumnar(brandsList, infoList);
resolve(data)
}).catch(() => {
reject(false)
});
});
} }
} }
}; };

@ -16,15 +16,53 @@
</template> </template>
<script> <script>
import {getInteractCount0528C} from "@/api/BrandComparison"
import {createSingleColumnar} from "@/utils/gol/singleColumnar" import {createSingleColumnar} from "@/utils/gol/singleColumnar"
export default { export default {
name: "overallNumberOfInteractions", name: "overallInformation",
data() { data() {
return { return {
opt: createSingleColumnar(["奥迪", "宝马", "奔驰", "吉利", "大众", "别克"],[2200, 1900, 1800, 1600, 1400, 1500], '#45a380') form: {
token: "",
sBrand: ""
},
opt: {}
}
},
created() {
this.initData();
},
methods: {
initData() {
this.form.token = this.getToken;
let arr = this.getBComparison;
let brands = [];
arr.forEach(ele => {
brands.push(ele.name)
});
this.form.sBrand = brands.toString();
this.getData();
},
getData() {
return new Promise((resolve, reject) => {
let obj = Object.assign({}, this.getCtime2, this.form);
getInteractCount0528C(obj).then((res) => {
let data = res.data || [];
let brandsList = [];
let infoList = [];
data.forEach(e => {
brandsList.push(e.key);
infoList.push(e.value);
})
this.opt = createSingleColumnar(brandsList, infoList);
resolve(data)
}).catch(() => {
reject(false)
});
});
} }
} }
} };
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>

@ -1,7 +1,7 @@
<!-- <!--
* @Author: your name * @Author: your name
* @Date: 2021-10-13 16:16:41 * @Date: 2021-10-13 16:16:41
* @LastEditTime: 2021-10-14 09:00:47 * @LastEditTime: 2021-11-08 17:28:58
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: 尾翼洞察详情 * @Description: 尾翼洞察详情
* @FilePath: /data-show/src/views/TailInsightDetails/index.vue * @FilePath: /data-show/src/views/TailInsightDetails/index.vue
@ -9,7 +9,7 @@
<template> <template>
<div class="d-container"> <div class="d-container">
<div class="tid-outter"> <div class="tid-outter">
<div class="tid-d1"> <div class="tid-d1" v-loading="load">
<v-label-div title="尾翼洞察详情"> <v-label-div title="尾翼洞察详情">
<v-btn @click="goback"></v-btn> <v-btn @click="goback"></v-btn>
</v-label-div> </v-label-div>
@ -51,6 +51,7 @@ export default {
}, },
data() { data() {
return { return {
load: false,
msg: "", msg: "",
form: { form: {
sBrand: "", sBrand: "",
@ -66,9 +67,11 @@ export default {
methods: { methods: {
getDdta(){ getDdta(){
let obj = Object.assign({}, this.getCtime2, this.form); let obj = Object.assign({}, this.getCtime2, this.form);
this.load = true;
getWeiYiInsightAnalysis(obj).then(res => { getWeiYiInsightAnalysis(obj).then(res => {
let data = res.msg; let data = res.msg;
this.msg = data; this.msg = data;
this.load = false;
}) })
}, },
goback() { goback() {

@ -1,13 +1,13 @@
<!-- <!--
* @Author: your name * @Author: your name
* @Date: 2021-10-13 16:54:12 * @Date: 2021-10-13 16:54:12
* @LastEditTime: 2021-10-13 17:40:37 * @LastEditTime: 2021-11-08 17:19:36
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: /data-show/src/views/TailInsightDetails/mediaDistribution/index.vue * @FilePath: /data-show/src/views/TailInsightDetails/mediaDistribution/index.vue
--> -->
<template> <template>
<div class="md-outter"> <div class="md-outter" v-loading="load">
<v-label-div title="媒体分布"></v-label-div> <v-label-div title="媒体分布"></v-label-div>
<div class="md-inner"> <div class="md-inner">
<v-echarts :opt="opt"></v-echarts> <v-echarts :opt="opt"></v-echarts>
@ -22,6 +22,7 @@ export default {
name: "mediaDistribution", name: "mediaDistribution",
data() { data() {
return { return {
load: false,
opt: {}, opt: {},
form: { form: {
sBrand: "", sBrand: "",
@ -59,10 +60,12 @@ export default {
methods: { methods: {
getDdta(){ getDdta(){
let obj = Object.assign({}, this.getCtime2, this.form); let obj = Object.assign({}, this.getCtime2, this.form);
this.load = true;
getSourcetype0528(obj).then(res => { getSourcetype0528(obj).then(res => {
let data = res.data || []; let data = res.data || [];
this.labelData = data; this.labelData = data;
this.opt = createOpt(data, this.colors); this.opt = createOpt(data, this.colors);
this.load = false;
}) })
}, },
}, },

@ -1,16 +1,16 @@
<!-- <!--
* @Author: your name * @Author: your name
* @Date: 2021-10-13 17:54:56 * @Date: 2021-10-13 17:54:56
* @LastEditTime: 2021-10-13 18:07:49 * @LastEditTime: 2021-11-08 17:26:04
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: /data-show/src/views/TailInsightDetails/popular-word-cloud/index.vue * @FilePath: /data-show/src/views/TailInsightDetails/popular-word-cloud/index.vue
--> -->
<template> <template>
<div class="pwc-outter"> <div class="pwc-outter" v-loading="load">
<v-label-div title="热门词云" :showLine="false" :eStyle="{'border-style': 'none'}"> <v-label-div title="热门词云" :showLine="false" :eStyle="{'border-style': 'none'}">
<v-tab-group :btns="['正面', '负面']" @change="handlerChange"></v-tab-group> <v-tab-group :btns="['正面', '负面']" @change="handlerChange"></v-tab-group>
</v-label-div> </v-label-div>
<div class="pwc-inner"> <div class="pwc-inner">
<v-echarts :opt="opt"></v-echarts> <v-echarts :opt="opt"></v-echarts>
</div> </div>
@ -18,51 +18,55 @@
</template> </template>
<script> <script>
import createWordCloud from "@/utils/gol/bubbleWord"; import createWordCloud from "@/utils/gol/bubbleWord";
import {getPositive,getNegative} from '@/api/TailInsightdetails' import { getPositive, getNegative } from "@/api/TailInsightdetails";
export default { export default {
name: "popular-word-cloud", name: "popular-word-cloud",
props: ["brand", "model"], props: ["brand", "model"],
data() { data() {
return { return {
load: false,
type: 0,
form: { form: {
sBrand: "", sBrand: "",
token: "", token: "",
}, },
opt: {} opt: {},
} };
}, },
created() { created() {
this.form.token = this.getToken; this.form.token = this.getToken;
this.form.sBrand = this.getBrand.brandname || '奥迪'; this.form.sBrand = this.getBrand.brandname || "奥迪";
this.getData1(); this.getData1();
this.getData2(); },
}, methods: {
methods: { handlerChange(n) {
handlerChange(n) {
this.type = n; this.type = n;
this.getData1(); if(n === 0) {
this.getData2(); this.getData1();
} else {
this.getData2();
}
}, },
getData1(){ getData1() {
this.load = true; this.load = true;
let obj = Object.assign({}, this.getCtime2, this.form); let obj = Object.assign({}, this.getCtime2, this.form);
getPositive(obj).then(res => { getPositive(obj).then((res) => {
let data = res.data; let data = res.data;
this.opt = createWordCloud(data); this.opt = createWordCloud(data);
this.load = false; this.load = false;
}); });
}, },
getData2(){ getData2() {
this.load = true; this.load = true;
let obj = Object.assign({}, this.getCtime2, this.form); let obj = Object.assign({}, this.getCtime2, this.form);
getNegative(obj).then(res => { getNegative(obj).then((res) => {
let data = res.data; let data = res.data;
this.opt = createWordCloud(data); this.opt = createWordCloud(data);
this.load = false; this.load = false;
}) });
}, },
}, },
} };
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>

@ -1,7 +1,7 @@
<!-- <!--
* @Author: your name * @Author: your name
* @Date: 2021-10-13 18:14:01 * @Date: 2021-10-13 18:14:01
* @LastEditTime: 2021-11-08 16:50:27 * @LastEditTime: 2021-11-08 17:19:08
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: /data-show/src/views/TailInsightDetails/rearWingInformationList/index.vue * @FilePath: /data-show/src/views/TailInsightDetails/rearWingInformationList/index.vue
@ -33,7 +33,7 @@
</a-form-item> </a-form-item>
</a-form> </a-form>
<div class="rwl-tb"> <div class="rwl-tb">
<v-table :columns="columns" :data="tdata" :pagination="pagination" @change="handlerPage"></v-table> <v-table :columns="columns" :loading="tableLoading" :data="tdata" :pagination="pagination" @change="handlerPage"></v-table>
</div> </div>
</div> </div>
</div> </div>
@ -47,6 +47,7 @@ export default {
data() { data() {
return { return {
load: false, load: false,
tableLoading: false,
form: { form: {
sSource: "", sSource: "",
token: "", token: "",
@ -133,6 +134,7 @@ export default {
// //
getData() { getData() {
let obj = Object.assign({}, this.getCtime2, this.form); let obj = Object.assign({}, this.getCtime2, this.form);
this.tableLoading = true;
getList0528(obj).then((res) => { getList0528(obj).then((res) => {
let data = res.data || []; let data = res.data || [];
let arr = []; let arr = [];
@ -151,8 +153,10 @@ export default {
this.tdata = arr; this.tdata = arr;
let totalNum = res.totalNum || 0; let totalNum = res.totalNum || 0;
this.pagination.total = totalNum; this.pagination.total = totalNum;
this.tableLoading = false;
}); });
}, },
//
handlerChangeModel() { handlerChangeModel() {
this.form.iPageIndex = 1; this.form.iPageIndex = 1;
this.pagination.current = 1; this.pagination.current = 1;

@ -1,13 +1,13 @@
<!-- <!--
* @Author: your name * @Author: your name
* @Date: 2021-10-13 16:45:48 * @Date: 2021-10-13 16:45:48
* @LastEditTime: 2021-10-13 16:52:57 * @LastEditTime: 2021-11-08 17:27:08
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: /data-show/src/views/TailInsightDetails/rearWingPropagationSituation/index.vue * @FilePath: /data-show/src/views/TailInsightDetails/rearWingPropagationSituation/index.vue
--> -->
<template> <template>
<div class="rwps-outter"> <div class="rwps-outter" v-loading="load">
<v-label-div title="尾翼传播态势"></v-label-div> <v-label-div title="尾翼传播态势"></v-label-div>
<div class="rwps-inner"> <div class="rwps-inner">
<v-echarts :opt="opt"></v-echarts> <v-echarts :opt="opt"></v-echarts>
@ -22,6 +22,7 @@ export default {
name: "rearWingPropagationSituation", name: "rearWingPropagationSituation",
data() { data() {
return { return {
load: false,
opt: {}, opt: {},
form: { form: {
sBrand: "", sBrand: "",
@ -37,6 +38,7 @@ export default {
methods: { methods: {
getDdta(){ getDdta(){
let obj = Object.assign({}, this.getCtime2, this.form); let obj = Object.assign({}, this.getCtime2, this.form);
this.load = true;
getWeiYiVolumeTime(obj).then(res => { getWeiYiVolumeTime(obj).then(res => {
let data = res.data || []; let data = res.data || [];
let dx = []; let dx = [];
@ -48,6 +50,7 @@ export default {
ds.push(value); ds.push(value);
}); });
this.opt = createOpt(dx, ds); this.opt = createOpt(dx, ds);
this.load = false;
}) })
}, },
} }

@ -1,13 +1,13 @@
<!-- <!--
* @Author: your name * @Author: your name
* @Date: 2021-10-13 17:42:57 * @Date: 2021-10-13 17:42:57
* @LastEditTime: 2021-10-13 17:52:09 * @LastEditTime: 2021-11-08 17:28:00
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: /data-show/src/views/TailInsightDetails/theOverallToneOfTheTail/index.vue * @FilePath: /data-show/src/views/TailInsightDetails/theOverallToneOfTheTail/index.vue
--> -->
<template> <template>
<div class="tot-outter"> <div class="tot-outter" v-loading="load">
<v-label-div title="尾翼整体调性"></v-label-div> <v-label-div title="尾翼整体调性"></v-label-div>
<div class="tot-inner"> <div class="tot-inner">
<v-echarts :opt="opt"></v-echarts> <v-echarts :opt="opt"></v-echarts>
@ -22,6 +22,7 @@ export default {
name: "theOverallToneOfTheTail", name: "theOverallToneOfTheTail",
data() { data() {
return { return {
load: false,
opt: {}, opt: {},
form: { form: {
sBrand: "", sBrand: "",
@ -37,6 +38,7 @@ export default {
methods: { methods: {
getDdta(){ getDdta(){
let obj = Object.assign({}, this.getCtime2, this.form); let obj = Object.assign({}, this.getCtime2, this.form);
this.load = true;
getAffections(obj).then(res => { getAffections(obj).then(res => {
let data = res.data || {}; let data = res.data || {};
let arr = []; let arr = [];
@ -48,6 +50,7 @@ export default {
arr.push(obj) arr.push(obj)
} }
this.opt = createOpt(arr); this.opt = createOpt(arr);
this.load = false;
}) })
}, },
} }

Loading…
Cancel
Save