修改界面显示

master
夜笙歌 12 months ago
parent 5aa886bd76
commit 26f99d8c0a

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 MiB

After

Width:  |  Height:  |  Size: 695 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 646 KiB

After

Width:  |  Height:  |  Size: 606 KiB

@ -10,6 +10,7 @@
{{ i }} {{ i }}
</div> </div>
<div class="meter">平均节拍{{ meter }} /</div> <div class="meter">平均节拍{{ meter }} /</div>
<div class="centerBg"></div>
<div class="scrollTable"> <div class="scrollTable">
<div style="background-color: #094170"> <div style="background-color: #094170">
@ -756,4 +757,15 @@ export default {
font-size: 0.9vw; font-size: 0.9vw;
color: #fff; color: #fff;
} }
.centerBg {
background-image: url("../../../assets/board/model2.png");
background-repeat: no-repeat;
background-size: 100% 100%;
position: absolute;
transform: translate(-50%, -50%);
top: 54.5%;
left: 49%;
width: 90%;
height: 22%;
}
</style> </style>

@ -558,10 +558,10 @@ export default {
background-size: 100% 100%; background-size: 100% 100%;
position: absolute; position: absolute;
transform: translate(-50%, -50%); transform: translate(-50%, -50%);
top: 56%; top: 54.5%;
left: 49%; left: 49%;
width: 98%; width: 90%;
height: 57%; height: 22%;
} }
.headTitle { .headTitle {

@ -63,9 +63,21 @@ export default {
this.setOptions(this.chartData) this.setOptions(this.chartData)
}, },
setOptions({expectedData, actualData} = {}) { setOptions({expectedData, actualData} = {}) {
const week = () =>{
let today = new Date();
let firstDayOfYear = new Date(today.getFullYear(), 0, 1);
let dayOfWeek = firstDayOfYear.getDay();
let spendDay = 1;
if (dayOfWeek != 0) {
spendDay = 7 - dayOfWeek + 1;
}
firstDayOfYear = new Date(today.getFullYear(), 0, spendDay);
let d = Math.ceil((today.valueOf() - firstDayOfYear.valueOf()) / 86400000);
return Math.ceil((d / 7) + 1)
}
this.chart.setOption({ this.chart.setOption({
title: { title: {
text: '标题1 ', text: `${week()}`,
textStyle: { textStyle: {
align: 'center', align: 'center',
color: '#000', color: '#000',
@ -85,7 +97,7 @@ export default {
left: 10, left: 10,
right: 10, right: 10,
bottom: 20, bottom: 20,
top: 30, top: 50,
containLabel: true containLabel: true
}, },
tooltip: { tooltip: {

@ -62,9 +62,21 @@ export default {
this.setOptions(this.chartData) this.setOptions(this.chartData)
}, },
setOptions({ expectedData, actualData } = {}) { setOptions({ expectedData, actualData } = {}) {
const week = () =>{
let today = new Date();
let firstDayOfYear = new Date(today.getFullYear(), 0, 1);
let dayOfWeek = firstDayOfYear.getDay();
let spendDay = 1;
if (dayOfWeek != 0) {
spendDay = 7 - dayOfWeek + 1;
}
firstDayOfYear = new Date(today.getFullYear(), 0, spendDay);
let d = Math.ceil((today.valueOf() - firstDayOfYear.valueOf()) / 86400000);
return Math.ceil((d / 7) + 1)
}
this.chart.setOption({ this.chart.setOption({
title: { title: {
text: '标题1 ', text: `${week()}`,
textStyle: { textStyle: {
align: 'center', align: 'center',
color: '#000', color: '#000',

@ -44,9 +44,21 @@ export default {
initChart() { initChart() {
this.chart = echarts.init(this.$el, 'macarons') this.chart = echarts.init(this.$el, 'macarons')
const week = () =>{
let today = new Date();
let firstDayOfYear = new Date(today.getFullYear(), 0, 1);
let dayOfWeek = firstDayOfYear.getDay();
let spendDay = 1;
if (dayOfWeek != 0) {
spendDay = 7 - dayOfWeek + 1;
}
firstDayOfYear = new Date(today.getFullYear(), 0, spendDay);
let d = Math.ceil((today.valueOf() - firstDayOfYear.valueOf()) / 86400000);
return Math.ceil((d / 7) + 1)
}
this.chart.setOption({ this.chart.setOption({
title: { title: {
text: '标题1 ', text: `${week()}`,
textStyle: { textStyle: {
align: 'center', align: 'center',
color: '#000', color: '#000',

Loading…
Cancel
Save