diff --git a/src/components/home/LineChart.vue b/src/components/home/LineChart.vue index 74a679c..b8aff26 100644 --- a/src/components/home/LineChart.vue +++ b/src/components/home/LineChart.vue @@ -75,7 +75,7 @@ watch( xAxis: { type: 'category', boundaryGap: false, - data: newValue.data?.map(item => formatDateTime('HH:mm:ss', item.timestamp)), + data: newValue.data?.map(item => formatDateTime('HH:mm:ss', item.timestamp + 8 * 60 * 60 * 1000)), }, yAxis: { type: 'value', diff --git a/src/components/setting/SystemDate.vue b/src/components/setting/SystemDate.vue index 7ce7e29..e04bcc7 100644 --- a/src/components/setting/SystemDate.vue +++ b/src/components/setting/SystemDate.vue @@ -25,7 +25,7 @@ const onChangeDate = async (value: string) => { day, }, } - syncSendCmd(dateParams) + await syncSendCmd(dateParams) const HMS = splitDate[1].split(':') // 更新时分秒 @@ -65,7 +65,7 @@ onMounted(() => { :key="systemTime" v-model="systemTime" format="YYYY-MM-DD HH:mm:ss" - @change="(val) => onChangeDate(val)" + @change="val => onChangeDate(val)" /> @@ -73,11 +73,11 @@ onMounted(() => {