|
@ -57,7 +57,7 @@ const menuList = computed(() => { |
|
|
if (item.meta?.isDefault) { |
|
|
if (item.meta?.isDefault) { |
|
|
return true |
|
|
return true |
|
|
} |
|
|
} |
|
|
return !!(item.path === '/debug' && systemStore.isDebug) |
|
|
|
|
|
|
|
|
return (item.path === '/debug' && systemStore.isDebug) |
|
|
}) |
|
|
}) |
|
|
}) |
|
|
}) |
|
|
|
|
|
|
|
@ -75,6 +75,21 @@ const getSolution = async () => { |
|
|
const res = await getContainerList() |
|
|
const res = await getContainerList() |
|
|
containerList.value = res.filter(item => item.type === 0) |
|
|
containerList.value = res.filter(item => item.type === 0) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
const statusMap = { |
|
|
|
|
|
start: { |
|
|
|
|
|
type: 'primary', |
|
|
|
|
|
name: '指令开始执行', |
|
|
|
|
|
}, |
|
|
|
|
|
success: { |
|
|
|
|
|
type: 'success', |
|
|
|
|
|
name: '指令执行成功', |
|
|
|
|
|
}, |
|
|
|
|
|
fail: { |
|
|
|
|
|
type: 'error', |
|
|
|
|
|
name: '指令执行异常', |
|
|
|
|
|
}, |
|
|
|
|
|
} |
|
|
</script> |
|
|
</script> |
|
|
|
|
|
|
|
|
<template> |
|
|
<template> |
|
@ -152,7 +167,27 @@ const getSolution = async () => { |
|
|
<el-col :span="16"> |
|
|
<el-col :span="16"> |
|
|
<div class="footer-left"> |
|
|
<div class="footer-left"> |
|
|
<img src="../assets/images/run.svg" alt=""> |
|
|
<img src="../assets/images/run.svg" alt=""> |
|
|
<span class="text">机器运行状态</span> |
|
|
|
|
|
|
|
|
<span v-if="!systemStore.systemLogList.length" class="text">设备运行状态</span> |
|
|
|
|
|
<el-popover v-else width="auto" trigger="click" placement="top"> |
|
|
|
|
|
<template #reference> |
|
|
|
|
|
<el-tag style="width: 100%" :type="statusMap[systemStore.systemLogList[0]?.status as keyof typeof statusMap].type"> |
|
|
|
|
|
{{ systemStore.systemLogList[0]?.cmdName }}: {{ statusMap[systemStore.systemLogList[0]?.status as keyof typeof statusMap].name }} |
|
|
|
|
|
{{ systemStore.systemLogList[0]?.time }} |
|
|
|
|
|
</el-tag> |
|
|
|
|
|
</template> |
|
|
|
|
|
<template #default> |
|
|
|
|
|
<div class="log-box"> |
|
|
|
|
|
<el-tag |
|
|
|
|
|
v-for="(item, key) in systemStore.systemLogList" |
|
|
|
|
|
:key |
|
|
|
|
|
:type="statusMap[item?.status as keyof typeof statusMap].type" |
|
|
|
|
|
> |
|
|
|
|
|
{{ item.cmdName }}: {{ statusMap[item.status as keyof typeof statusMap].name }} |
|
|
|
|
|
{{ item.time }} |
|
|
|
|
|
</el-tag> |
|
|
|
|
|
</div> |
|
|
|
|
|
</template> |
|
|
|
|
|
</el-popover> |
|
|
</div> |
|
|
</div> |
|
|
</el-col> |
|
|
</el-col> |
|
|
|
|
|
|
|
@ -351,12 +386,17 @@ const getSolution = async () => { |
|
|
} |
|
|
} |
|
|
.footer-left { |
|
|
.footer-left { |
|
|
border-right: 5px solid #F6F6F6; |
|
|
border-right: 5px solid #F6F6F6; |
|
|
|
|
|
display: flex; |
|
|
|
|
|
align-items: center; |
|
|
|
|
|
justify-content: space-between; |
|
|
|
|
|
|
|
|
img { |
|
|
img { |
|
|
height: 60%; |
|
|
height: 60%; |
|
|
|
|
|
margin-right: 20px; |
|
|
} |
|
|
} |
|
|
.text { |
|
|
.text { |
|
|
color: #1C1C1C ; |
|
|
color: #1C1C1C ; |
|
|
margin-left: 10px; |
|
|
|
|
|
|
|
|
|
|
|
font-size: 14px; |
|
|
font-size: 14px; |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
@ -396,6 +436,16 @@ const getSolution = async () => { |
|
|
grid-gap: 10px; |
|
|
grid-gap: 10px; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.log-box { |
|
|
|
|
|
width: 500px; |
|
|
|
|
|
height: 400px; |
|
|
|
|
|
overflow: auto; |
|
|
|
|
|
.el-tag { |
|
|
|
|
|
margin: 5px 0; |
|
|
|
|
|
width: 100%; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
@keyframes swing { |
|
|
@keyframes swing { |
|
|
0% { |
|
|
0% { |
|
|
transform: rotate(0deg); |
|
|
transform: rotate(0deg); |
|
|