|
@@ -3,7 +3,7 @@
|
|
|
<div style="display: flex;justify-content: space-between">
|
|
|
<div></div>
|
|
|
<div class="time-style">
|
|
|
- {{nowTime}}
|
|
|
+
|
|
|
</div>
|
|
|
</div>
|
|
|
<fullScreen ref="fullRef" class="inline-16" domId="fullScreen" v-show="false" @backFull="backFull"></fullScreen>
|
|
@@ -18,7 +18,9 @@ export default {
|
|
|
data(){
|
|
|
return {
|
|
|
timer: "", // 定义一个定时器
|
|
|
- nowTime: ""
|
|
|
+ nowTime: "",
|
|
|
+ ymd:"",
|
|
|
+ week:""
|
|
|
}
|
|
|
},
|
|
|
mounted() {
|
|
@@ -53,7 +55,10 @@ export default {
|
|
|
];
|
|
|
|
|
|
// 将获取的时间信息赋值给nowTime
|
|
|
- this.nowTime = `${year}-${mounth}-${day} ${weekArr[week]} ${hours}:${minutes}:${seconds}`;
|
|
|
+ // this.nowTime = `${year}-${mounth}-${day} ${weekArr[week]} ${hours}:${minutes}:${seconds}`;
|
|
|
+ this.ymd = `${year}年${mounth}月${day}日`
|
|
|
+ this.week = `${weekArr[week]}`
|
|
|
+ this.nowTime = `${hours}:${minutes}:${seconds}`
|
|
|
}, 1000); // 每隔一秒更新时间
|
|
|
},
|
|
|
backFull(){
|
|
@@ -91,4 +96,7 @@ export default {
|
|
|
text-transform: none;
|
|
|
margin: 18px 20px 0 0 ;
|
|
|
}
|
|
|
+.time-style .span {
|
|
|
+ margin-right: 20px;
|
|
|
+}
|
|
|
</style>
|