From 83a88a4606a9d6828533554acff60f76a48530a5 Mon Sep 17 00:00:00 2001 From: weiwei Date: Mon, 14 Apr 2025 20:26:06 +0800 Subject: [PATCH] 1 --- src/views/hard/hard-door-manager/index.vue | 92 ++++++++++++++++++---- 1 file changed, 77 insertions(+), 15 deletions(-) diff --git a/src/views/hard/hard-door-manager/index.vue b/src/views/hard/hard-door-manager/index.vue index 085aa9b..4407b23 100644 --- a/src/views/hard/hard-door-manager/index.vue +++ b/src/views/hard/hard-door-manager/index.vue @@ -14,9 +14,7 @@ {{}} {{ state.deviceDetail.deviceCode }} @@ -31,9 +29,7 @@ 在售 @@ -69,11 +65,43 @@ {{ state.deviceDetail.restartTime }} + + + + + + + {{ item.cabinetNo }} + + 正常 + 异常 + + + 正常 + 异常 + + + 正常 + 异常 + + + 在售 + 停售 + + + + + @@ -90,19 +118,36 @@
第 {{ floorIndex + 1 }} 层:
-
-
+
+
- 点击上架 + +
{{ v.spuDetail?.name }}
+
+
+ {{ displayPrice(v.spuDetail.price) }} + {{ v.spuDetail.specsCapacity }} +
+ +
+
+ 点击上架
-
{{ v.spuDetail?.name }}
@@ -129,6 +174,7 @@ import { displayPrice } from "/@/utils/formatMoney" import * as hardDoorManager from "/@/api/hard/hard-door-manager" import { ElMessageBox } from "element-plus" import { getByCabinetNo, unPutaway } from "/@/api/hard/hard-spu" +import { openAccess } from "/@/api/hard/hard-door-manager" const InfoSetting = defineAsyncComponent(() => import("./info-setting.vue")) const VolumeSetting = defineAsyncComponent(() => import("./volume-setting.vue")) @@ -143,6 +189,7 @@ const state = reactive({ hardId: "", deviceDetail: {}, cabinetData: [], + curActivedDoorTabIndex: 0, curActivedTabIndex: 0, }) @@ -196,7 +243,22 @@ const refreshVolume = (data: { hardId: string; mediaVolume: number; systemVolume state.deviceDetail.systemVolume = data.systemVolume } +// 检修开门 +const checkOpenAccess = async () => { + const res = await openAccess({ hardDoorId: "", cabinetNo: state.deviceDetail.cabinetList[state.curActivedDoorTabIndex].cabinetNo }) + if (res.code == 0) { + useMessage().success("操作成功") + return + } + useMessage().error(res.msg || "操作失败") +} + // 点击柜门tab +const doorTabClick = async (tab: any) => { + state.curActivedDoorTabIndex = tab.index +} + +// 点击柜门商品tab const tabClick = async (tab: any) => { state.curActivedTabIndex = tab.index await getCabinet(tab.index)