Browse Source

fix: 时间自动加8小时取消

master
guoapeng 2 weeks ago
parent
commit
238f1fa12e
  1. 2
      src/components/home/LineChart.vue
  2. 2
      src/stores/systemStore.ts
  3. 17
      src/views/seal/index.vue

2
src/components/home/LineChart.vue

@ -75,7 +75,7 @@ watch(
xAxis: { xAxis: {
type: 'category', type: 'category',
boundaryGap: false, boundaryGap: false,
data: newValue.data?.map(item => formatDateTime('HH:mm:ss', item.timestamp + 8 * 60 * 60 * 1000)),
data: newValue.data?.map(item => formatDateTime('HH:mm:ss', item.timestamp)),
}, },
yAxis: { yAxis: {
type: 'value', type: 'value',

2
src/stores/systemStore.ts

@ -138,7 +138,7 @@ export const useSystemStore = defineStore(
fnName: 'getTime', fnName: 'getTime',
} }
const res = await sendCmd(timeParams) const res = await sendCmd(timeParams)
systemTime.value = res.time + 8 * 60 * 60 * 1000
systemTime.value = res.time
} }
return { return {

17
src/views/seal/index.vue

@ -138,7 +138,6 @@ function handleConfirm(value: string) {
</div> </div>
</div> </div>
<div class="seal-right"> <div class="seal-right">
<div class="left-title">
<div class="title-text-test"> <div class="title-text-test">
<img :src="SealInstrumentSvg" alt="仪表盘"> <img :src="SealInstrumentSvg" alt="仪表盘">
<div class="title-text"> <div class="title-text">
@ -149,10 +148,6 @@ function handleConfirm(value: string) {
<span class="title-kpa-pl">Kpa</span> <span class="title-kpa-pl">Kpa</span>
</div> </div>
</div> </div>
</div>
<div class="seal-right-btn">
<div>
<div class="seal-add-btn">
<bt-button <bt-button
button-text="启动测试" button-text="启动测试"
bg-color="#31CB7A" bg-color="#31CB7A"
@ -169,8 +164,6 @@ function handleConfirm(value: string) {
<img :src="homeStart" alt=""> <img :src="homeStart" alt="">
</template> </template>
</bt-button> </bt-button>
</div>
<div class="seal-add-btn">
<bt-button <bt-button
:button-text="stopText" :button-text="stopText"
bg-color="#FF6767" bg-color="#FF6767"
@ -188,9 +181,6 @@ function handleConfirm(value: string) {
</template> </template>
</bt-button> </bt-button>
</div> </div>
</div>
</div>
</div>
</main> </main>
<SoftKeyboard <SoftKeyboard
ref="softKeyboardRef" ref="softKeyboardRef"
@ -236,7 +226,7 @@ function handleConfirm(value: string) {
//width: 16rem; //width: 16rem;
height: 5rem; height: 5rem;
border-radius: 15px; border-radius: 15px;
padding: 0 2 0px;
padding: 0 2px 0;
} }
.seal-time-text { .seal-time-text {
font-size: 1.5rem; font-size: 1.5rem;
@ -273,7 +263,8 @@ function handleConfirm(value: string) {
.seal-right { .seal-right {
background: $gradient-color; background: $gradient-color;
display: grid; display: grid;
grid-template-rows: repeat(2, 1fr);
grid-template-rows: repeat(3, 1fr);
gap: 20px;
.left-title { .left-title {
//padding-top: 3.5vw; //padding-top: 3.5vw;
padding-left: 2.5vw; padding-left: 2.5vw;
@ -296,7 +287,7 @@ function handleConfirm(value: string) {
} }
} }
.seal-right-btn { .seal-right-btn {
height: 30vh;
//height: 30vh;
grid-row: 2 / 4; grid-row: 2 / 4;
margin-top: -6rem; margin-top: -6rem;
display: flex; display: flex;

Loading…
Cancel
Save