|
@@ -34,7 +34,8 @@
|
|
|
|
|
|
<a-card class="card-content echarts-card" style="margin-bottom: 20px;">
|
|
|
<div slot="title">
|
|
|
- <span style="font-weight: bolder;">数据趋势</span> <span style="font-size: 12px;">更新时间:{{updateTime | formatDate}}</span>
|
|
|
+ <span style="font-weight: bolder;">数据趋势</span>
|
|
|
+ <!-- <span style="font-size: 12px;">更新时间:{{updateTime | formatDate}}</span> -->
|
|
|
</div>
|
|
|
<div class="person-content-title" slot="extra">
|
|
|
<div class="content-title-acount"></div>
|
|
@@ -91,11 +92,19 @@
|
|
|
id="outTable"
|
|
|
:pagination="false"
|
|
|
:loading="echartsLoading"
|
|
|
- :scroll="{ x: scrollX }"
|
|
|
ref="accountTable"
|
|
|
+ :scroll="{ x: scrollX }"
|
|
|
>
|
|
|
- <span slot="unitStatus" slot-scope="text, record">
|
|
|
- <a-switch :checked="text === 0" />
|
|
|
+ <!-- <span slot="status" slot-scope="text, record">
|
|
|
+ <a-switch :checked="text == 1" @change="switchChange(text,record)"/>
|
|
|
+ </span> -->
|
|
|
+ <span slot="status" slot-scope="text,record">
|
|
|
+ <a-spin :spinning="record.spin" size="small" >
|
|
|
+ <div class="spin-content">
|
|
|
+ <a-switch size="default" :checked='text==1' @change="switchChange(text,record)"/>
|
|
|
+ </div>
|
|
|
+ </a-spin>
|
|
|
+
|
|
|
</span>
|
|
|
<span slot="operator" slot-scope="text,record">
|
|
|
<a-popover v-model="record.visible" trigger="click" placement="topLeft" @visibleChange='visibleChange'>
|
|
@@ -149,7 +158,8 @@
|
|
|
|
|
|
<a-card class="card-content echarts-card" style="margin-bottom: 20px;">
|
|
|
<div slot="title">
|
|
|
- <span style="font-weight:bolder">素材相关</span> <span style="font-size: 12px;">更新时间:{{updateRelated | formatDate}}</span>
|
|
|
+ <span style="font-weight:bolder">素材相关</span>
|
|
|
+ <!-- <span style="font-size: 12px;">更新时间:{{updateRelated | formatDate}}</span> -->
|
|
|
</div>
|
|
|
<div class="person-content-title" slot="extra">
|
|
|
<div class="content-title-acount"></div>
|
|
@@ -305,8 +315,8 @@
|
|
|
targetVisible:false,
|
|
|
listNum:[],
|
|
|
visible:false,
|
|
|
- scrollX: 1500,
|
|
|
- columnsFixd:keepPersonData.setNoDeleteColumns(),
|
|
|
+ scrollX:1500,
|
|
|
+ columnsFixd:keepPersonData.groupDelivery(),
|
|
|
valueBtn:['花费'],
|
|
|
plainOptions:[
|
|
|
{label:'花费',value:'花费'},
|
|
@@ -330,13 +340,14 @@
|
|
|
dataIndex: 'status',
|
|
|
key: 'status',
|
|
|
align: 'center',
|
|
|
- scopedSlots: { customRender: 'unitStatus' },
|
|
|
+ scopedSlots: { customRender: 'status' },
|
|
|
},
|
|
|
{
|
|
|
title: '组名称',
|
|
|
dataIndex: 'unitName',
|
|
|
key: 'unitName',
|
|
|
align: 'center',
|
|
|
+ width:300,
|
|
|
},{
|
|
|
title: '花费',
|
|
|
dataIndex: 'charge',
|
|
@@ -366,13 +377,13 @@
|
|
|
dataIndex: 'operationAgree',
|
|
|
key: 'operationAgree',
|
|
|
align: 'center',
|
|
|
+
|
|
|
},{
|
|
|
title: '操作',
|
|
|
dataIndex: 'operator',
|
|
|
key: 'operator',
|
|
|
align: 'center',
|
|
|
scopedSlots: { customRender: 'operator' },
|
|
|
- width:150
|
|
|
},
|
|
|
],
|
|
|
sourceMaterial:[
|
|
@@ -484,6 +495,7 @@
|
|
|
}
|
|
|
},
|
|
|
mounted() {
|
|
|
+ this.showColumn();
|
|
|
// 获取折线图
|
|
|
this.getQueryNewlyData();
|
|
|
// 第一个饼图
|
|
@@ -493,10 +505,36 @@
|
|
|
this.getAccountNameData();
|
|
|
this.getGroupLaunchData();
|
|
|
this.getEchartOnePieData();
|
|
|
- this.showColumn();
|
|
|
+
|
|
|
},
|
|
|
|
|
|
methods: {
|
|
|
+ //状态改变
|
|
|
+ switchChange(text,record){
|
|
|
+ // this.spinning=true;
|
|
|
+ // console.log(res);(text,record)
|
|
|
+ record.spin=true;
|
|
|
+
|
|
|
+
|
|
|
+ let putStatus=text==1?2:1;
|
|
|
+ postAction(`/kuaishou/batch/batchUpdateUnitStatus`,{
|
|
|
+ accountId:this.accountId,
|
|
|
+ unitIds:[record.unit_id],
|
|
|
+ id:record.id,
|
|
|
+ putStatus
|
|
|
+ }).then((res)=>{
|
|
|
+
|
|
|
+ record.spin=false;
|
|
|
+ if(res.success){
|
|
|
+ this.getGroupDataList()
|
|
|
+ this.$message.success(res.message)
|
|
|
+ }else{
|
|
|
+ this.$message.error(res.message)
|
|
|
+ }
|
|
|
+ })
|
|
|
+
|
|
|
+
|
|
|
+ },
|
|
|
// 自定义列
|
|
|
customColumn(){
|
|
|
this.visible = true;
|
|
@@ -508,7 +546,7 @@
|
|
|
},
|
|
|
showColumn() {
|
|
|
this.postDataAction('/toutiao/videoReportDaily/getColumnJson', {
|
|
|
- columnType: 102,
|
|
|
+ columnType: 103,
|
|
|
}).then((res) => {
|
|
|
// console.log(res)
|
|
|
if (res.success) {
|
|
@@ -530,7 +568,7 @@
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- this.changeColumn(this.columns)
|
|
|
+ // this.changeColumn(this.columns)
|
|
|
}
|
|
|
})
|
|
|
},
|
|
@@ -543,7 +581,7 @@
|
|
|
|
|
|
element.width = 'auto'
|
|
|
element.fixed = false
|
|
|
-
|
|
|
+ element.visible = false
|
|
|
}
|
|
|
})
|
|
|
|
|
@@ -552,8 +590,11 @@
|
|
|
else if (this.columns.length >= 8) {
|
|
|
this.columns.forEach((element, index) => {
|
|
|
if (index < this.columnsFixd.length) {
|
|
|
- element.width = 150
|
|
|
- element.fixed = 'left'
|
|
|
+
|
|
|
+ element.width = 180
|
|
|
+ element.fixed = 'left'
|
|
|
+ element.visible = false
|
|
|
+
|
|
|
}
|
|
|
})
|
|
|
|
|
@@ -565,14 +606,14 @@
|
|
|
|
|
|
element.width = 'auto'
|
|
|
element.fixed = false
|
|
|
-
|
|
|
+ element.visible = false
|
|
|
})
|
|
|
}
|
|
|
|
|
|
let arr = JSON.stringify(this.columns)
|
|
|
this.postDataAction('/toutiao/videoReportDaily/saveOrUpdateColumnJson', {
|
|
|
json: arr,
|
|
|
- columnType: 102,
|
|
|
+ columnType: 103,
|
|
|
}).then((res) => {
|
|
|
// console.log(res)
|
|
|
})
|
|
@@ -783,8 +824,14 @@
|
|
|
pageNum:this.tablePag.pageNum,
|
|
|
pageSize:this.tablePag.pageSize
|
|
|
}
|
|
|
- getAction('/kuaishou/realTime/getUnitDateInfo',params).then(res=>{
|
|
|
+ getAction('http://139.186.29.76:8804/jeecg-boot/kuaishou/realTime/getUnitDateInfo',params).then(res=>{
|
|
|
if (res.code == 200) {
|
|
|
+ res.result.forEach((item)=>{
|
|
|
+ // item.key=item.id;
|
|
|
+ // item.show=false;
|
|
|
+ item.visible=false;
|
|
|
+ item.spin=false;
|
|
|
+ })
|
|
|
this.updateTimeGroup = res.timestamp;
|
|
|
this.echartsData = res.result
|
|
|
this.totalAll = res.result[0].totalCount
|
|
@@ -818,14 +865,14 @@
|
|
|
getAction('/kuaishou/dingpan/updateBid',{
|
|
|
accountId:record.accountId,
|
|
|
bid:this.newBid*1000,
|
|
|
- unitId:record.unitId,
|
|
|
+ unitId:record.unit_id,
|
|
|
bidType:record.bidType
|
|
|
}).then(res=>{
|
|
|
// console.log(res);(res)
|
|
|
if(res.code==0){
|
|
|
this.$message.success(res.message)
|
|
|
this.newBid=undefined;
|
|
|
- this.getLaunchData()
|
|
|
+ this.getGroupDataList()
|
|
|
}
|
|
|
|
|
|
})
|
|
@@ -860,7 +907,7 @@
|
|
|
this.targetVisible=false;
|
|
|
getAction('/kuaishou/dingpan/updateTemplate',{
|
|
|
accountId:this.accountId,
|
|
|
- unitId:this.currentUnit.unitId,
|
|
|
+ unitId:this.currentUnit.unit_id,
|
|
|
templateId:this.selectDirectionalId
|
|
|
}).then(res=>{
|
|
|
|
|
@@ -878,7 +925,7 @@
|
|
|
this.linkVisible=true;
|
|
|
getAction('/kuaishou/dingpan/getClickTrackUrlByUnitId',{
|
|
|
accountId:this.accountId,
|
|
|
- unitId:record.unitId
|
|
|
+ unitId:record.unit_id
|
|
|
}).then(res=>{
|
|
|
// console.log(res);(res);
|
|
|
if(res.result){
|
|
@@ -892,7 +939,7 @@
|
|
|
this.linkVisible=false;
|
|
|
getAction('/kuaishou/dingpan/updateClickTrackUrlByUnitId',{
|
|
|
accountId:this.accountId,
|
|
|
- unitId:this.currentUnit.unitId,
|
|
|
+ unitId:this.currentUnit.unit_id,
|
|
|
clickTrackUr:this.newLink
|
|
|
}).then(res=>{
|
|
|
// console.log(res);(res)
|
|
@@ -932,11 +979,11 @@
|
|
|
today.data = res.result.map(itemprice=>{
|
|
|
return itemprice.tCost
|
|
|
});
|
|
|
- today.name = '花费(today)'
|
|
|
+ today.name = '花费(今天)'
|
|
|
yesterday.data = res.result.map(itemyes=>{
|
|
|
return itemyes.yCost
|
|
|
});
|
|
|
- yesterday.name = '花费(yesterday)'
|
|
|
+ yesterday.name = '花费(昨天)'
|
|
|
}else{
|
|
|
today.data = [];
|
|
|
today.name = '';
|
|
@@ -949,12 +996,12 @@
|
|
|
activation.data = res.result.map(itemprice=>{
|
|
|
return itemprice.tActivationPrice
|
|
|
});
|
|
|
- activation.name = '激活成本(today)'
|
|
|
+ activation.name = '激活成本(今天)'
|
|
|
|
|
|
activationyes.data = res.result.map(itemyes=>{
|
|
|
return itemyes.yActivationPrice
|
|
|
});
|
|
|
- activationyes.name = '激活成本(yesterday)'
|
|
|
+ activationyes.name = '激活成本(昨天)'
|
|
|
}else{
|
|
|
activation.data = [];
|
|
|
activation.name = '';
|
|
@@ -967,12 +1014,12 @@
|
|
|
pay.data = res.result.map(itemprice=>{
|
|
|
return itemprice.tEventNewUserPayCost
|
|
|
});
|
|
|
- pay.name = '新增付费成本(today)'
|
|
|
+ pay.name = '新增付费成本(今天)'
|
|
|
|
|
|
payyes.data = res.result.map(itemyes=>{
|
|
|
return itemyes.yEventNewUserPayCost
|
|
|
});
|
|
|
- payyes.name = '新增付费成本(yesterday)'
|
|
|
+ payyes.name = '新增付费成本(昨天)'
|
|
|
}else{
|
|
|
pay.data = [];
|
|
|
pay.name = '';
|
|
@@ -985,12 +1032,12 @@
|
|
|
Secondary.data = res.result.map(itemprice=>{
|
|
|
return itemprice.tLeave
|
|
|
});
|
|
|
- Secondary.name = '次留率(today)'
|
|
|
+ Secondary.name = '次留率(今天)'
|
|
|
|
|
|
Secondaryyes.data = res.result.map(itemyes=>{
|
|
|
return itemyes.yLeave
|
|
|
});
|
|
|
- Secondaryyes.name = '次留率(yesterday)'
|
|
|
+ Secondaryyes.name = '次留率(昨天)'
|
|
|
}else{
|
|
|
Secondary.data = [];
|
|
|
Secondary.name = '';
|