diff --git a/src/components/home/AddLiquid/index.vue b/src/components/home/AddLiquid/index.vue index 0a75083..5f161b5 100644 --- a/src/components/home/AddLiquid/index.vue +++ b/src/components/home/AddLiquid/index.vue @@ -1,10 +1,9 @@ + + + + + + + + + + + + + + mousedownHandle(item)" + @touch.prevent="() => mousedownHandle(item)" + > + + + + { .el-tag { margin-right: 5px; } + +.tube-item { + padding: 5px; + background: #384D5D; + border-radius: 10px; + display: grid; + grid-template-columns: repeat(5, 1fr); + grid-template-rows: repeat(1, 1fr); + grid-gap: 5px; + position: relative; + .tube-line { + display: flex; + flex-direction: column; + .tube-line-inner { + display: inline-block; + width: 25px; + height: 25px; + border-radius: 50%; + background: #fff; + margin: 2px; + transition: background 0.5s; + } + } + .tube-line-disable { + .tube-line-inner { + background: #C6C6C6; + } + } + .tube-line-active { + .tube-line-inner { + background: #26D574; + } + } + +} diff --git a/src/views/home/index.vue b/src/views/home/index.vue index a9b112e..bbd72d2 100644 --- a/src/views/home/index.vue +++ b/src/views/home/index.vue @@ -10,6 +10,7 @@ import StartClean from 'components/home/StartClean/index.vue' import StartExperiment from 'components/home/StartExperiment/index.vue' import Tube from 'components/home/Tube/index.vue' +import { ElMessageBox } from 'element-plus' import { FtMessage } from 'libs/message' import { socket } from 'libs/socket' import { cmdNameMap, formatDateTime } from 'libs/utils' @@ -133,6 +134,63 @@ const commandHandle = async (command: string, params?: unknown) => { } await homeStore.sendControl(data) } + +const move_to_liquid_area = async () => { + if (!selectedHeatArea.value?.value) { + await ElMessageBox.confirm( + '是否要将上料区托盘移至加液位? ', + '提示', + { + confirmButtonText: '确认', + showClose: false, + showCancelButton: false, + closeOnClickModal: false, + closeOnPressEscape: false, + type: 'warning', + customClass: 'init-message', + }, + ) + } + await commandHandle('move_to_liquid_area', { heatModuleCode: selectedHeatArea.value?.value }) +} + +const move_to_feed_area = async () => { + if (!selectedHeatArea.value?.value) { + await ElMessageBox.confirm( + '是否要将加液位托盘移至上料区? ', + '提示', + { + confirmButtonText: '确认', + showClose: false, + showCancelButton: false, + closeOnClickModal: false, + closeOnPressEscape: false, + type: 'warning', + customClass: 'init-message', + }, + ) + } + await commandHandle('move_to_feed_area', { heatModuleCode: selectedHeatArea.value?.value }) +} + +const move_to_anneal_area = async () => { + if (!selectedHeatArea.value?.value) { + await ElMessageBox.confirm( + '是否要将加液位或上料区的托盘移至退火区? ', + '提示', + { + confirmButtonText: '确认', + showClose: false, + showCancelButton: false, + closeOnClickModal: false, + closeOnPressEscape: false, + type: 'warning', + customClass: 'init-message', + }, + ) + } + await commandHandle('move_to_anneal_area', { heatModuleCode: selectedHeatArea.value?.value }) +} @@ -156,13 +214,13 @@ const commandHandle = async (command: string, params?: unknown) => { 移至加热位 - - 移至加/排液位 + + 移至加液位 - - 移至上/下料区 + + 移至上料区 - + 移至退火位 @@ -240,16 +298,14 @@ const commandHandle = async (command: string, params?: unknown) => { - - x轴回原点 + + 加液臂回原点 - z轴回原点 - - - 加液臂回原点 + + x轴回原点