|
@@ -175,7 +175,26 @@
|
|
</svg>
|
|
</svg>
|
|
<span v-show="sortActive !== '传播量'" style="display: inline-block; width: 14px; height: 14px;"></span>
|
|
<span v-show="sortActive !== '传播量'" style="display: inline-block; width: 14px; height: 14px;"></span>
|
|
</van-col>
|
|
</van-col>
|
|
- <van-col span="5" class="td"> 环比 </van-col>
|
|
|
|
|
|
+ <van-col span="5" class="td" @click="() => sortFunc('环比')">
|
|
|
|
+ 环比<svg
|
|
|
|
+ v-show="sortActive === '环比'"
|
|
|
|
+ t="1667611409259"
|
|
|
|
+ class="icon"
|
|
|
|
+ viewBox="0 0 1024 1024"
|
|
|
|
+ version="1.1"
|
|
|
|
+ xmlns="http://www.w3.org/2000/svg"
|
|
|
|
+ p-id="2536"
|
|
|
|
+ width="14"
|
|
|
|
+ height="14"
|
|
|
|
+ >
|
|
|
|
+ <path
|
|
|
|
+ d="M558.933333 853.333333V128h-42.666666v733.866667l-145.066667-145.066667-29.866667 29.866667 192 192 192-192-29.866666-29.866667-136.533334 136.533333z"
|
|
|
|
+ fill="#515151"
|
|
|
|
+ p-id="2537"
|
|
|
|
+ ></path>
|
|
|
|
+ </svg>
|
|
|
|
+ <span v-show="sortActive !== '环比'" style="display: inline-block; width: 14px; height: 14px;"></span>
|
|
|
|
+ </van-col>
|
|
</van-row>
|
|
</van-row>
|
|
<van-row
|
|
<van-row
|
|
class="item"
|
|
class="item"
|
|
@@ -343,7 +362,6 @@ export default {
|
|
"06fd56cdf5a6cfc3a2139cc8514d05aa0439ee8c1fb4d81145bc9647"
|
|
"06fd56cdf5a6cfc3a2139cc8514d05aa0439ee8c1fb4d81145bc9647"
|
|
)
|
|
)
|
|
return;
|
|
return;
|
|
- console.log(this.$route.params.date);
|
|
|
|
this.fontSize = (document.body.offsetWidth / 24).toFixed(2) - 0;
|
|
this.fontSize = (document.body.offsetWidth / 24).toFixed(2) - 0;
|
|
if (document.body.offsetWidth > 677) this.fontSize = 22;
|
|
if (document.body.offsetWidth > 677) this.fontSize = 22;
|
|
document.documentElement.style.fontSize = this.fontSize + "px";
|
|
document.documentElement.style.fontSize = this.fontSize + "px";
|
|
@@ -409,18 +427,27 @@ export default {
|
|
ratios.publish_count = publish_count;
|
|
ratios.publish_count = publish_count;
|
|
let read_count = this.timeFormat(ratios.read_count);
|
|
let read_count = this.timeFormat(ratios.read_count);
|
|
ratios.read_count = read_count;
|
|
ratios.read_count = read_count;
|
|
|
|
+ let key = "read_count"
|
|
|
|
+ switch (this.sortActive) {
|
|
|
|
+ case '发稿量':
|
|
|
|
+ key = 'publish_count'
|
|
|
|
+ break;
|
|
|
|
+ }
|
|
|
|
+ ratios.detail = ratios.detail.sort((newitem,olditem)=>olditem[key] - newitem[key])
|
|
this.ratios = ratios;
|
|
this.ratios = ratios;
|
|
this.$nextTick(() => {});
|
|
this.$nextTick(() => {});
|
|
},
|
|
},
|
|
sortFunc(text) {
|
|
sortFunc(text) {
|
|
if (text === this.sortActive) return;
|
|
if (text === this.sortActive) return;
|
|
this.sortActive = text;
|
|
this.sortActive = text;
|
|
- console.log(this.ratios);
|
|
|
|
let key = "read_count"
|
|
let key = "read_count"
|
|
switch (text) {
|
|
switch (text) {
|
|
- case '传播量':
|
|
|
|
|
|
+ case '发稿量':
|
|
key = 'publish_count'
|
|
key = 'publish_count'
|
|
break;
|
|
break;
|
|
|
|
+ case '环比':
|
|
|
|
+ key = 'read_huanbi'
|
|
|
|
+ break;
|
|
}
|
|
}
|
|
this.ratios.detail = this.ratios.detail.sort((newitem,olditem)=>olditem[key] - newitem[key])
|
|
this.ratios.detail = this.ratios.detail.sort((newitem,olditem)=>olditem[key] - newitem[key])
|
|
},
|
|
},
|