|
@@ -4,8 +4,10 @@
|
|
<img class="logo" src="@/assets/img/logo.png" alt="" />
|
|
<img class="logo" src="@/assets/img/logo.png" alt="" />
|
|
<span class="line"></span>
|
|
<span class="line"></span>
|
|
<div class="right">
|
|
<div class="right">
|
|
- <img src="@/assets/img/eye.png" alt="" />
|
|
|
|
- <span class="txt">{{ myMoods }} {{Mylangue?'访问量':'Viewers'}}</span>
|
|
|
|
|
|
+ <img src="@/assets/img/eye.png" alt="" />
|
|
|
|
+ <span class="txt"
|
|
|
|
+ >{{ myMoods }} {{ Mylangue ? "访问量" : "Viewers" }}</span
|
|
|
|
+ >
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@@ -31,12 +33,19 @@ export default {
|
|
created() {},
|
|
created() {},
|
|
//生命周期 - 挂载完成(可以访问DOM元素)
|
|
//生命周期 - 挂载完成(可以访问DOM元素)
|
|
mounted() {
|
|
mounted() {
|
|
- fetch("http://47.112.166.173:8109/api/count/saveVisit/" + 1171)
|
|
|
|
- .then((response) => response.json())
|
|
|
|
- .then((data) => {
|
|
|
|
- this.myMoods = data.data.visitSum;
|
|
|
|
- // console.log(data)
|
|
|
|
- });
|
|
|
|
|
|
+ if (window.number === "1171") {
|
|
|
|
+ fetch("http://47.112.166.173:8109/api/count/saveVisit/" + 1171)
|
|
|
|
+ .then((response) => response.json())
|
|
|
|
+ .then((data) => {
|
|
|
|
+ this.myMoods = data.data.visitSum;
|
|
|
|
+ });
|
|
|
|
+ } else {
|
|
|
|
+ fetch("http://47.112.166.173:8109/api/count/detail/" + 1171)
|
|
|
|
+ .then((response) => response.json())
|
|
|
|
+ .then((data) => {
|
|
|
|
+ this.myMoods = data.data.visitSum
|
|
|
|
+ });
|
|
|
|
+ }
|
|
},
|
|
},
|
|
beforeCreate() {}, //生命周期 - 创建之前
|
|
beforeCreate() {}, //生命周期 - 创建之前
|
|
beforeMount() {}, //生命周期 - 挂载之前
|
|
beforeMount() {}, //生命周期 - 挂载之前
|
|
@@ -83,7 +92,7 @@ export default {
|
|
.logo {
|
|
.logo {
|
|
width: 180px;
|
|
width: 180px;
|
|
}
|
|
}
|
|
- .right{
|
|
|
|
|
|
+ .right {
|
|
margin-top: 10px;
|
|
margin-top: 10px;
|
|
font-size: 12px;
|
|
font-size: 12px;
|
|
}
|
|
}
|