|
@@ -1,5 +1,13 @@
|
|
<template>
|
|
<template>
|
|
<div class="vsummary">
|
|
<div class="vsummary">
|
|
|
|
+ <div class="xiangmuxuanze">
|
|
|
|
+ <span>项目选择:</span>
|
|
|
|
+ <a-select default-value="" style="width: 500px" @change="selectChange" placeholder="请选择项目账户">
|
|
|
|
+ <a-select-option v-for="(item,index) in projectArr" :key="index" :value='item.id'>
|
|
|
|
+ {{ item }}
|
|
|
|
+ </a-select-option>
|
|
|
|
+ </a-select>
|
|
|
|
+ </div>
|
|
<div class="timeDiv">
|
|
<div class="timeDiv">
|
|
<div>
|
|
<div>
|
|
<span>时间范围:</span>
|
|
<span>时间范围:</span>
|
|
@@ -345,7 +353,9 @@ let detailConsum = [
|
|
export default {
|
|
export default {
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
-
|
|
|
|
|
|
+ //下拉选择框的数据
|
|
|
|
+ projectArr:[],
|
|
|
|
+ selectValue:'',
|
|
//gudinglie
|
|
//gudinglie
|
|
columnsFixd:columnsFixd,
|
|
columnsFixd:columnsFixd,
|
|
|
|
|
|
@@ -401,6 +411,10 @@ export default {
|
|
mixins: [JeecgListMixin],
|
|
mixins: [JeecgListMixin],
|
|
methods: {
|
|
methods: {
|
|
moment,
|
|
moment,
|
|
|
|
+ //select切换---项目
|
|
|
|
+ selectChange(key){
|
|
|
|
+ this.selectValue=key;
|
|
|
|
+ },
|
|
//打开视频
|
|
//打开视频
|
|
openVideo(val){
|
|
openVideo(val){
|
|
this.Videovisible=true;
|
|
this.Videovisible=true;
|
|
@@ -432,34 +446,16 @@ export default {
|
|
this.totalSelect = (this.dateRange[1]._d - this.dateRange[0]._d) / (24 * 60 * 60 * 1000) + 1;
|
|
this.totalSelect = (this.dateRange[1]._d - this.dateRange[0]._d) / (24 * 60 * 60 * 1000) + 1;
|
|
this.timedata=[this.dateRange[0]._i,this.dateRange[1]._i]
|
|
this.timedata=[this.dateRange[0]._i,this.dateRange[1]._i]
|
|
this.daysFlag = true
|
|
this.daysFlag = true
|
|
- postAction('/toutiao/videoReportDaily/bytedanceVideoInfoListMonth', {
|
|
|
|
- startDate: this.timedata[0],
|
|
|
|
- endDate: this.timedata[1],
|
|
|
|
- cost: this.consumeValue,
|
|
|
|
- signature: this.videoID
|
|
|
|
- }).then(res => {
|
|
|
|
- let resArr = []
|
|
|
|
- this.loading = false
|
|
|
|
- console.log(res)
|
|
|
|
- if (res.success) {
|
|
|
|
- let result = res.result
|
|
|
|
- this.data.push({ ...result, key: 1 })
|
|
|
|
- result.map((item, index) => {
|
|
|
|
- item.key = index
|
|
|
|
- })
|
|
|
|
- this.data = result;
|
|
|
|
-
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
|
|
+ this.HttpPost();
|
|
|
|
|
|
},
|
|
},
|
|
|
|
|
|
consumeOnChange() {},
|
|
consumeOnChange() {},
|
|
- //查询按钮
|
|
|
|
- searchRes() {
|
|
|
|
- this.date = []
|
|
|
|
- this.loading = true
|
|
|
|
- postAction('/toutiao/videoReportDaily/bytedanceVideoInfoListMonth', {
|
|
|
|
|
|
+ //获取table数据请求
|
|
|
|
+ HttpPost(){
|
|
|
|
+ this.loading=true;
|
|
|
|
+ this.date=[];
|
|
|
|
+ postAction('/toutiao/videoReportDaily/bytedanceVideoInfoListMonth', {
|
|
startDate: this.timedata[0],
|
|
startDate: this.timedata[0],
|
|
endDate: this.timedata[1],
|
|
endDate: this.timedata[1],
|
|
cost: this.consumeValue,
|
|
cost: this.consumeValue,
|
|
@@ -479,6 +475,10 @@ export default {
|
|
}
|
|
}
|
|
})
|
|
})
|
|
},
|
|
},
|
|
|
|
+ //查询按钮
|
|
|
|
+ searchRes() {
|
|
|
|
+ this.HttpPost();
|
|
|
|
+ },
|
|
|
|
|
|
//导出报表
|
|
//导出报表
|
|
exportExcel() {
|
|
exportExcel() {
|
|
@@ -718,7 +718,24 @@ export default {
|
|
tofixed(val){
|
|
tofixed(val){
|
|
return Number(val).toFixed(2)
|
|
return Number(val).toFixed(2)
|
|
}
|
|
}
|
|
- }
|
|
|
|
|
|
+ },
|
|
|
|
+ mounted() {
|
|
|
|
+ let lastStart =
|
|
|
|
+ moment()
|
|
|
|
+ .subtract(1, 'months')
|
|
|
|
+ .format('YYYY-MM-DD')
|
|
|
|
+ let lastEnd = moment()
|
|
|
|
+ .subtract(1, 'days')
|
|
|
|
+ .format('YYYY-MM-DD')
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ this.dateRange=[moment(lastStart),moment(lastEnd)]
|
|
|
|
+ // console.log(this.dateRange)
|
|
|
|
+ this.totalSelect = (this.dateRange[1]._d - this.dateRange[0]._d) / (24 * 60 * 60 * 1000) + 1;
|
|
|
|
+ this.timedata=[this.dateRange[0]._i,this.dateRange[1]._i]
|
|
|
|
+ this.daysFlag = true
|
|
|
|
+ this.HttpPost();
|
|
|
|
+ },
|
|
}
|
|
}
|
|
</script>
|
|
</script>
|
|
<style lang="less">
|
|
<style lang="less">
|
|
@@ -737,6 +754,9 @@ export default {
|
|
width: 100%;
|
|
width: 100%;
|
|
height: 100%;
|
|
height: 100%;
|
|
}
|
|
}
|
|
|
|
+.xiangmuxuanze{
|
|
|
|
+ margin-bottom: 20px;;
|
|
|
|
+}
|
|
.timeDiv {
|
|
.timeDiv {
|
|
display: flex;
|
|
display: flex;
|
|
justify-content: space-between;
|
|
justify-content: space-between;
|