From 1d3f8dc16ca98b14a40da8c70a405793295faa78 Mon Sep 17 00:00:00 2001
From: wangfei <3597712270@qq.com>
Date: 星期三, 23 四月 2025 13:47:45 +0800
Subject: [PATCH] 系统配置页面修改bug,上片新增页面
---
UI-Project/src/views/hollow/hellowquiphistory.vue | 498 ++++++++++++++++++++++++++++++++++++++++++++++++++++--
1 files changed, 473 insertions(+), 25 deletions(-)
diff --git a/UI-Project/src/views/hollow/hellowquiphistory.vue b/UI-Project/src/views/hollow/hellowquiphistory.vue
index 3181d22..fd2d995 100644
--- a/UI-Project/src/views/hollow/hellowquiphistory.vue
+++ b/UI-Project/src/views/hollow/hellowquiphistory.vue
@@ -1,6 +1,6 @@
<template>
<div>
-<div style="display: flex;width: 1770px;">
+<div style="display: flex;width: 1780px;">
<el-input v-model="flowCardId" clearable style="margin-left: 10px;margin-bottom: 10px;width: 200px;" :placeholder="$t('searchOrder.processcards')" />
<el-select v-model="selectValuesa[0]" filterable :placeholder="$t('hellow.isForceList')" clearable
style="width: 200px;margin-left: 10px;">
@@ -13,20 +13,25 @@
<el-option :label="$t('basicData.stop')" value="2"></el-option>
<el-option :label="$t('sorter.endingtask')" value="3"></el-option>
</el-select>
- <el-date-picker v-model="timeRange" type="datetimerange" range-separator="鑷�" :start-placeholder="$t('reportmanage.starttime')"
- style="margin-left: 15px;" value-format = "YYYY-MM-DD hh:mm:ss"
- :end-placeholder="$t('reportmanage.endtime')">
- </el-date-picker>
+ <el-date-picker
+ style="margin-left: 15px;"
+ v-model="timeRange"
+ type="datetimerange"
+ :shortcuts="shortcuts"
+ range-separator="鑷�"
+ :start-placeholder="$t('reportmanage.starttime')"
+ :end-placeholder="$t('reportmanage.endtime')"
+ />
<el-button type="primary" style="margin-left: 10px;margin-bottom: 10px;" @click="sethistorical()">{{$t('reportmanage.inquire')}}</el-button>
</div>
- <el-table ref="table" style="margin-top: 20px;height: 580px;width: 1770px;" :data="tableDatax" :header-cell-style="{background:'#F2F3F5 ',color:'#1D2129'}">
- <el-table-column prop="flowCardId" align="center" :label="$t('searchOrder.processcards')" min-width="80" />
- <el-table-column prop="totalLayer" align="center" :label="$t('hellow.totalLayer')" min-width="80" />
- <el-table-column prop="totalPairQuantity" align="center" :label="$t('hellow.totalPairQuantity')" min-width="80" />
+ <el-table ref="table" style="margin-top: 20px;height: 580px;width: 99%;" :data="tableDatax" :header-cell-style="{background:'#F2F3F5 ',color:'#1D2129'}">
+ <el-table-column prop="flowCardId" align="center" :label="$t('searchOrder.processcards')" min-width="50" />
+ <el-table-column prop="totalLayer" align="center" :label="$t('hellow.totalLayer')" min-width="20" />
+ <el-table-column prop="totalPairQuantity" align="center" :label="$t('hellow.totalPairQuantity')" min-width="50" />
<el-table-column
align="center"
:label="$t('hellow.isForceList')"
- min-width="80"
+ min-width="50"
prop="isForce"
>
<template #default="scope">
@@ -38,7 +43,7 @@
<el-table-column
align="center"
:label="$t('searchOrder.state')"
- min-width="80"
+ min-width="50"
prop="state"
>
<template #default="scope">
@@ -47,8 +52,14 @@
</el-tag>
</template>
</el-table-column>
- <el-table-column prop="formattedCreateTime" align="center" :label="$t('reportmanage.starttime')" min-width="100" />
- <el-table-column prop="formattedUpdateTime" align="center" :label="$t('reportmanage.endtime')" min-width="100" />
+ <el-table-column prop="formattedCreateTime" align="center" :label="$t('reportmanage.starttime')" min-width="50" />
+ <el-table-column prop="formattedUpdateTime" align="center" :label="$t('reportmanage.endtime')" min-width="50" />
+ <el-table-column fixed="right" :label="$t('film.operate')" align="center">
+ <template #default="scope">
+ <el-button type="text" plain @click="handleptask(scope.row)">{{ $t('hellow.listFormula') }}</el-button>
+ <el-button type="text" plain @click="handlecagedetails(scope.row)">{{ $t('hellow.HollowGlass') }}</el-button>
+ </template>
+ </el-table-column>
</el-table>
<div style="margin-top: 20px;margin-left: 40%;">
<el-pagination
@@ -62,6 +73,273 @@
style="margin-top: 10px;"
/>
</div>
+ <el-dialog v-model="dialogFormVisiblef" top="5vh" width="65%" :title="$t('hellow.HollowGlass')">
+ <el-table ref="table" style="margin-top: 20px;height: 450px;"
+ :data="tableDatacagedetails" :header-cell-style="{background:'#F2F3F5 ',color:'#1D2129'}">
+ <el-table-column prop="flowCardId" :label="$t('hellow.flowCardId')" align="center" width="140"/>
+ <el-table-column prop="glassId" :label="$t('searchOrder.glassID')" align="center" width="140"/>
+ <el-table-column prop="hollowSequence" :label="$t('hellow.order')" align="center"/>
+ <el-table-column prop="thickness" :label="$t('hellow.thickness')" align="center"/>
+ <el-table-column prop="layer" :label="$t('hellow.layer')" align="center"/>
+ <el-table-column prop="filmsId" :label="$t('hellow.coatingtypes')" align="center"/>
+ <el-table-column prop="height" :label="$t('hellow.height')" align="center"/>
+ <el-table-column prop="width" :label="$t('hellow.width')" align="center"/>
+ <el-table-column prop="state" :label="$t('hellow.state')" align="center">
+ <template #default="scope">
+ {{ scope.row.state == -1 ? $t('hellow.waitingout') : $t('hellow.finishout') }}
+ </template>
+ </el-table-column>
+ </el-table>
+</el-dialog>
+<el-dialog v-model="dialogFormVisiblea" top="10vh" width="90%" :title="$t('hellow.listFormula')">
+ <div style="margin-left: 50px;margin-top: 10px;margin-bottom: 10px;">
+ <el-form label-width="150px" label-position="right">
+ <!-- 绗竴琛岋細3涓厓绱� -->
+ <el-row style="margin-top: 20px;">
+ <el-col :span="8">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.formulaName')" style="width: 90%;">
+ <el-input disabled v-model="formulaName" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="8">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('Mounting.removalmethoda')" style="width: 90%;">
+ <el-select v-model="filmRemove" clearable style="width: 100%" disabled placeholder=" ">
+ <el-option :label="$t('Mounting.removal')" value="1"></el-option>
+ <el-option :label="$t('Mounting.noremoval')" value="0"></el-option>
+ </el-select>
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="8">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.sealInsertb')" style="width: 90%;">
+ <el-input disabled v-model="sealInsert" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ </el-row>
+
+ <!-- 绗簩琛岋細4涓厓绱� -->
+ <el-row style="margin-top: 20px;">
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.topRemove')" style="width: 90%;">
+ <el-input disabled v-model="topRemove" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.bottomRemove')" style="width: 90%;">
+ <el-input disabled v-model="bottomRemove" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.leftRemove')" style="width: 90%;">
+ <el-input disabled v-model="leftRemove" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.rightRemove')" style="width: 90%;">
+ <el-input disabled v-model="rightRemove" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ </el-row>
+
+ <!-- 绗笁琛岋細4涓厓绱� -->
+ <el-row style="margin-top: 20px;">
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.casOneb')" style="width: 90%;">
+ <el-select v-model="casOne" clearable disabled style="width: 100%" placeholder=" ">
+ <el-option :label="$t('hellow.F')" value="0"></el-option>
+ <el-option :label="$t('hellow.Y')" value="1"></el-option>
+ </el-select>
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.casTwob')" style="width: 90%;">
+ <el-select v-model="casTwo" clearable disabled style="width: 100%" placeholder=" ">
+ <el-option :label="$t('hellow.F')" value="0"></el-option>
+ <el-option :label="$t('hellow.Y')" value="1"></el-option>
+ </el-select>
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.casThreeb')" style="width: 90%;">
+ <el-select v-model="casThree" clearable disabled style="width: 100%" placeholder=" ">
+ <el-option :label="$t('hellow.F')" value="0"></el-option>
+ <el-option :label="$t('hellow.Y')" value="1"></el-option>
+ </el-select>
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.casFourb')" style="width: 90%;">
+ <el-select v-model="casFour" clearable disabled style="width: 100%" placeholder=" ">
+ <el-option :label="$t('hellow.F')" value="0"></el-option>
+ <el-option :label="$t('hellow.Y')" value="1"></el-option>
+ </el-select>
+ </el-form-item>
+ </div>
+ </el-col>
+ </el-row>
+
+ <!-- 绗洓琛岋細4涓厓绱� -->
+ <el-row style="margin-top: 20px;">
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.frameOneb')" style="width: 90%;">
+ <el-input disabled v-model="frameOne" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.frameTwob')" style="width: 90%;">
+ <el-input disabled v-model="frameTwo" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.frameThreeb')" style="width: 90%;">
+ <el-input disabled v-model="frameThree" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.frameFourb')" style="width: 90%;">
+ <el-input disabled v-model="frameFour" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ </el-row>
+
+ <!-- 绗簲琛岋細4涓厓绱� -->
+ <el-row style="margin-top: 20px;">
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.intervalFrameHeightbOne')" style="width: 90%;">
+ <el-input disabled v-model="intervalFrameHeightOne" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.intervalFrameHeightbTwo')" style="width: 90%;">
+ <el-input disabled v-model="intervalFrameHeightTwo" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.intervalFrameHeightbThree')" style="width: 90%;">
+ <el-input disabled v-model="intervalFrameHeightThree" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.intervalFrameHeightbFour')" style="width: 90%;">
+ <el-input disabled v-model="intervalFrameHeightFour" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ </el-row>
+
+ <!-- 绗叚琛岋細4涓厓绱� -->
+ <el-row style="margin-top: 20px;">
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.intervalFrameWidthbOne')" style="width: 90%;">
+ <el-input disabled v-model="intervalFrameWidthOne" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.intervalFrameWidthbTwo')" style="width: 90%;">
+ <el-input disabled v-model="intervalFrameWidthTwo" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.intervalFrameWidthbThree')" style="width: 90%;">
+ <el-input disabled v-model="intervalFrameWidthThree" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.intervalFrameWidthbFour')" style="width: 90%;">
+ <el-input disabled v-model="intervalFrameWidthFour" autocomplete="off" />
+ </el-form-item>
+ </div>
+ </el-col>
+ </el-row>
+
+ <!-- 绗竷琛岋細4涓厓绱� -->
+ <el-row style="margin-top: 20px;">
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.intervalFrameTypedOne')" style="width: 90%;">
+ <el-select v-model="intervalFrameTypeOne" clearable style="width: 100%" disabled placeholder=" ">
+ <el-option :label="$t('hellow.intervalFrameTypeb')" value="1"></el-option>
+ <el-option :label="$t('hellow.intervalFrameTypea')" value="5"></el-option>
+ </el-select>
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.intervalFrameTypedTwo')" style="width: 90%;">
+ <el-select v-model="intervalFrameTypeTwo" clearable style="width: 100%" disabled placeholder=" ">
+ <el-option :label="$t('hellow.intervalFrameTypeb')" value="1"></el-option>
+ <el-option :label="$t('hellow.intervalFrameTypea')" value="5"></el-option>
+ </el-select>
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.intervalFrameTypedThree')" style="width: 90%;">
+ <el-select v-model="intervalFrameTypeThree" clearable style="width: 100%" disabled placeholder=" ">
+ <el-option :label="$t('hellow.intervalFrameTypeb')" value="1"></el-option>
+ <el-option :label="$t('hellow.intervalFrameTypea')" value="5"></el-option>
+ </el-select>
+ </el-form-item>
+ </div>
+ </el-col>
+ <el-col :span="6">
+ <div style="font-size: 15px;">
+ <el-form-item :label="$t('hellow.intervalFrameTypedFour')" style="width: 90%;">
+ <el-select v-model="intervalFrameTypeFour" clearable style="width: 100%" disabled placeholder=" ">
+ <el-option :label="$t('hellow.intervalFrameTypeb')" value="1"></el-option>
+ <el-option :label="$t('hellow.intervalFrameTypea')" value="5"></el-option>
+ </el-select>
+ </el-form-item>
+ </div>
+ </el-col>
+ </el-row>
+ </el-form>
+ </div>
+</el-dialog>
</div>
</template>
<script lang="ts" setup>
@@ -87,6 +365,39 @@
const flowCardId = ref('');
const rawGlassfilmsId = ref('');
const slot = ref('');
+const formattedCreate = ref('')
+const formulaName = ref('')
+const filmRemove = ref('')
+const topRemove = ref('')
+const bottomRemove = ref('')
+const leftRemove = ref('')
+const rightRemove = ref('')
+const frameOne = ref('')
+const frameTwo = ref('')
+const frameThree = ref('')
+const frameFour = ref('')
+const sealInsert = ref('')
+const casOne = ref('')
+const casTwo = ref('')
+const casThree = ref('')
+const casFour = ref('')
+const intervalFrameTypeOne = ref('')
+const intervalFrameWidthOne = ref('')
+const intervalFrameHeightOne = ref('')
+const intervalFrameTypeTwo = ref('')
+const intervalFrameWidthTwo = ref('')
+const intervalFrameHeightTwo = ref('')
+const intervalFrameTypeThree = ref('')
+const intervalFrameWidthThree = ref('')
+const intervalFrameHeightThre = ref('')
+const intervalFrameTypeFour = ref('')
+const intervalFrameWidthFour = ref('')
+const intervalFrameHeightFour = ref('')
+const createTime = ref('')
+const updateTime = ref('')
+const tableDatacagedetails = ref([])
+const dialogFormVisiblea = ref(false)
+const dialogFormVisiblef = ref(false)
let getglobalDate = window.localStorage.getItem('getglobalDate')
const historical = async () => {
try {
@@ -109,19 +420,16 @@
formattedUpdateTime: formatTimestamp(record.updateTime),
}));
tableDatax.value = formattedData;
- console.log(response.data.pages);
totalRecords.value = response.data.total/2 || 0
} else {
ElMessage.error(response.message);
}
}
catch (error) {
- console.error(error);
}
}
const handlePageChange2 = (newPage) => {
currentPage2.value = newPage;
-console.log(currentPage2.value);
window.localStorage.setItem('pagenumber', currentPage2.value)
historicala(currentPage2.value);
};
@@ -148,8 +456,8 @@
flowCardId: flowCardId.value,
isForceList: celllist,
stateList: stateList,
- beginDate: (timeRange.value && timeRange.value[0]) || '',
- endDate: (timeRange.value && timeRange.value[1]) || '',
+ beginDate: (formatTimestamp(timeRange.value) && formatTimestamp(timeRange.value[0])) || '',
+ endDate: (formatTimestamp(timeRange.value) && formatTimestamp(timeRange.value[1])) || '',
})
if (response.code == 200) {
ElMessage.success(response.message);
@@ -165,7 +473,6 @@
}
}
catch (error) {
- console.error(error);
}
}
// 鍘嗗彶鏌ヨ鐐瑰嚮
@@ -192,8 +499,8 @@
flowCardId: flowCardId.value,
isForceList: celllist,
stateList: stateList,
- beginDate: (timeRange.value && timeRange.value[0]) || '',
- endDate: (timeRange.value && timeRange.value[1]) || '',
+ beginDate: (formatTimestamp(timeRange.value) && formatTimestamp(timeRange.value[0])) || '',
+ endDate: (formatTimestamp(timeRange.value) && formatTimestamp(timeRange.value[1])) || '',
})
if (response.code == 200) {
currentPage2.value = 1
@@ -211,8 +518,81 @@
}
}
catch (error) {
- console.error(error);
}
+}
+// 閰嶆柟淇℃伅
+const handleptask = (row) => {
+ fetchcagedl(row);
+ dialogFormVisiblea.value = true;
+};
+const removalMethodMap = {
+ 1: t('Mounting.removal'),
+ 0: t('Mounting.noremoval')
+};
+const fetchcagedl = async (row) => {
+ try {
+ var url="/hollowGlass/hollowFormulaDetails/getFormulaDetailsById?id="+ row.formulaId;
+ const response = await request.get(url)
+ if (response.code == 200) {
+ ElMessage.success(response.message);
+ formulaName.value = response.data.formulaName
+ filmRemove.value = removalMethodMap[response.data.filmRemove];
+ topRemove.value = response.data.topRemove
+ bottomRemove.value = response.data.bottomRemove
+ leftRemove.value = response.data.leftRemove
+ rightRemove.value = response.data.rightRemove
+ frameOne.value = response.data.frameOne
+ frameTwo.value = response.data.frameTwo
+ frameThree.value = response.data.frameThree
+ frameFour.value = response.data.frameFour
+ sealInsert.value = response.data.sealInsert
+ casOne.value = response.data.casOne
+ casTwo.value = response.data.casTwo
+ casThree.value = response.data.casThree
+ casFour.value = response.data.casFour
+ intervalFrameTypeOne.value = response.data.intervalFrameTypeOne
+ intervalFrameWidthOne.value = response.data.intervalFrameWidthOne
+ intervalFrameHeightOne.value = response.data.intervalFrameHeightOne
+ intervalFrameTypeTwo.value = response.data.intervalFrameTypeTwo
+ intervalFrameWidthTwo.value = response.data.intervalFrameWidthTwo
+ intervalFrameHeightTwo.value = response.data.intervalFrameHeightTwo
+ intervalFrameTypeThree.value = response.data.intervalFrameTypeThree
+ intervalFrameWidthThree.value = response.data.intervalFrameWidthThree
+ intervalFrameHeightThre.value = response.data.intervalFrameHeightThre
+ intervalFrameTypeFour.value = response.data.intervalFrameTypeFour
+ intervalFrameWidthFour.value = response.data.intervalFrameWidthFour
+ intervalFrameHeightFour.value = response.data.intervalFrameHeightFour
+ } else {
+ ElMessage.error(response.message);
+ }
+}
+catch (error) {
+ }
+}
+// 闃熷垪淇℃伅
+const handlecagedetails = (row) => {
+ const { id } = row;
+ fetchcagedetails(id);
+ dialogFormVisiblef.value = true;
+};
+const fetchcagedetails = async (id) => {
+ try {
+ var url="/hollowGlass/hollowGlassQueueInfo/queryHollowGlassQueueInfoByTask?taskId="+ id;
+ const response = await request.post(url)
+ if (response.code == 200) {
+ ElMessage.success(response.message);
+ const formattedData = response.data.map(record => ({
+ ...record,
+ formaCreateTime: formatTimestamp(record.createTime),
+ formaUpdateTime: formatTimestamp(record.updateTime),
+ }));
+ tableDatacagedetails.value = formattedData;
+ } else {
+ ElMessage.error(response.message);
+ }
+}
+catch (error) {
+ }
}
// 鏍煎紡鍖栨椂闂存埑涓哄勾鏈堟棩鏃堕棿瀛楃涓茬殑鍑芥暟
function formatTimestamp(timestamp) {
@@ -225,13 +605,47 @@
const seconds = String(date.getSeconds()).padStart(2, '0'); // 琛ラ浂锛堝鏋滈渶瑕佹樉绀烘椂闂达級
return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`;
}
+const shortcuts = [
+ {
+ text: '鏈�杩戜竴鍛�',
+ value: () => {
+ const backendTime = new Date(getglobalDate)
+ const oneWeekAgo = new Date(getglobalDate)
+ oneWeekAgo.setHours(0, 0, 0, 0);
+ oneWeekAgo.setDate(oneWeekAgo.getDate() - 7)
+ timeRange.value = [formatTimestamp(oneWeekAgo), formatTimestamp(backendTime)]
+ window.localStorage.setItem('startTime', formatTimestamp(oneWeekAgo))
+ },
+ },
+ {
+ text: '鏈�杩戜竴涓湀',
+ value: () => {
+ const backendTime = new Date(getglobalDate)
+ const oneWeekAgo = new Date(getglobalDate)
+ oneWeekAgo.setHours(0, 0, 0, 0);
+ oneWeekAgo.setMonth(oneWeekAgo.getMonth() - 1)
+ timeRange.value = [formatTimestamp(oneWeekAgo), formatTimestamp(backendTime)]
+ window.localStorage.setItem('startTime', formatTimestamp(oneWeekAgo))
+ },
+ },
+ {
+ text: '鏈�杩戜笁涓湀',
+ value: () => {
+ const backendTime = new Date(getglobalDate)
+ const oneWeekAgo = new Date(getglobalDate)
+ oneWeekAgo.setHours(0, 0, 0, 0);
+ oneWeekAgo.setMonth(oneWeekAgo.getMonth() - 3)
+ timeRange.value = [formatTimestamp(oneWeekAgo), formatTimestamp(backendTime)]
+ window.localStorage.setItem('startTime', formatTimestamp(oneWeekAgo))
+},
+ },
+]
// 鏍煎紡鍖栧悗绔椂闂村苟璁$畻涓�鍛ㄥ墠鐨勬椂闂�
const defaultTime = ref<[Date, Date]>([new Date(), new Date()]);
function parseAndSetTime() {
const backendTime = new Date(getglobalDate);
const oneWeekAgo = new Date(backendTime.getTime() - 7 * 24 * 60 * 60 * 1000); // 鍑忓幓7澶�
-console.log(formatTimestamp(oneWeekAgo));
-console.log(oneWeekAgo);
+ oneWeekAgo.setHours(0, 0, 0, 0);
timeRange.value = [formatTimestamp(oneWeekAgo), formatTimestamp(backendTime)];
window.localStorage.setItem('startTime', formatTimestamp(oneWeekAgo))
}
@@ -265,10 +679,42 @@
}
function getStatusTexta(isForce: number) {
switch (isForce) {
+ case 0:
+ return t('hellow.noisForceList');
+ case 1:
+ return t('hellow.yesisForceList');
+}
+}
+function getStatustate(state: number) {
+switch (state) {
+ case 0:
+ return 'primary';
+ case 1:
+ return 'success';
+}
+}
+function getStatustatet(state: number) {
+switch (state) {
case 0:
return t('hellow.noisForceList');
case 1:
return t('hellow.yesisForceList');
+}
+}
+function getisPairstate(isPair: number) {
+switch (isPair) {
+ case 0:
+ return 'info';
+ case 1:
+ return 'success';
+}
+}
+function getisPairstatet(isPair: number) {
+switch (isPair) {
+ case 1:
+ return t('sorter.yes');
+ case 0:
+ return t('hellow.no');
}
}
onMounted(() => {
@@ -276,5 +722,7 @@
historical();
});
</script>
-<style scoped>
+<style scoped>
+#dt { display:block; float:left;line-height: 20px;margin-left: 100px;}
+#dta { display:block; float:left;line-height: 20px;margin-left: 80%;}
</style>
\ No newline at end of file
--
Gitblit v1.8.0