修改机械分厂设备三级
This commit is contained in:
parent
71823c7879
commit
84428dba0a
@ -12,7 +12,11 @@
|
|||||||
<div>
|
<div>
|
||||||
<border6 ref="refborder6">
|
<border6 ref="refborder6">
|
||||||
<template v-slot>
|
<template v-slot>
|
||||||
<div ref="inguagu" class="box"></div>
|
<div ref="inguagu" class="box" v-show="handle == 't'"></div>
|
||||||
|
<div ref="inguagud" v-show="handle == 'f'" class="box empty">
|
||||||
|
<div class="empty-title">{{ props.title }}</div>
|
||||||
|
<el-empty :image-size="120" />
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</border6>
|
</border6>
|
||||||
</div>
|
</div>
|
||||||
@ -26,8 +30,10 @@ import { useI18n } from 'vue-i18n'
|
|||||||
let { t } = useI18n();
|
let { t } = useI18n();
|
||||||
let props = defineProps<{
|
let props = defineProps<{
|
||||||
title: string;
|
title: string;
|
||||||
|
handle: 't' | 'f'
|
||||||
}>();
|
}>();
|
||||||
let inguagu = ref();
|
let inguagu = ref();
|
||||||
|
let inguagud = ref();
|
||||||
|
|
||||||
let refborder6 = ref();
|
let refborder6 = ref();
|
||||||
|
|
||||||
@ -90,6 +96,9 @@ function setchartWH(width: any, height: any) {
|
|||||||
inguagu.value.style.height = height + "px";
|
inguagu.value.style.height = height + "px";
|
||||||
inguagu.value.style.width = width - 30 + "px";
|
inguagu.value.style.width = width - 30 + "px";
|
||||||
|
|
||||||
|
inguagud.value.style.height = height + "px";
|
||||||
|
inguagud.value.style.width = width - 30 + "px";
|
||||||
|
|
||||||
refborder6.value.resetWH();
|
refborder6.value.resetWH();
|
||||||
if (echartsData.inguagu.box) {
|
if (echartsData.inguagu.box) {
|
||||||
echartsData.inguagu.box.resize();
|
echartsData.inguagu.box.resize();
|
||||||
@ -110,5 +119,24 @@ defineExpose({
|
|||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.empty {
|
||||||
|
position: relative;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
.empty-title {
|
||||||
|
position: absolute;
|
||||||
|
top:10px;
|
||||||
|
left: 20px;
|
||||||
|
font-size: 22px;
|
||||||
|
font-weight: bolder;
|
||||||
|
color: white;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
|
|
@ -12,7 +12,8 @@
|
|||||||
<div class="header">
|
<div class="header">
|
||||||
<!-- <div class="title" @click="backrouter"> -->
|
<!-- <div class="title" @click="backrouter"> -->
|
||||||
<div class="title">
|
<div class="title">
|
||||||
<header2 :width="'100%'" :height="'100px'" :title="t('messages.machineryDevStatus')" :titleTip="[]" :typeFun="['comback','time']" :alarmType="['']"></header2>
|
<header2 :width="'100%'" :height="'100px'" :title="t('messages.machineryDevStatus')" :titleTip="[]"
|
||||||
|
:typeFun="['comback', 'time']" :alarmType="['']"></header2>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -32,7 +33,7 @@
|
|||||||
<MTTF ref="MTTFref" title="MTTF"></MTTF>
|
<MTTF ref="MTTFref" title="MTTF"></MTTF>
|
||||||
</div>
|
</div>
|
||||||
<div class="right ">
|
<div class="right ">
|
||||||
<timeguagu ref="timeguaguref" :title="t('messages.TimeUtilizationRate')"></timeguagu>
|
<timeguagu ref="timeguaguref" :title="t('messages.TimeUtilizationRate')" :handle="handle"></timeguagu>
|
||||||
<statuscontrast ref="contrastref" :title="t('messages.DevRunComparison')"></statuscontrast>
|
<statuscontrast ref="contrastref" :title="t('messages.DevRunComparison')"></statuscontrast>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -80,6 +81,8 @@ const router=useRouter()
|
|||||||
oWidth: 0,
|
oWidth: 0,
|
||||||
oHeight: 0
|
oHeight: 0
|
||||||
});
|
});
|
||||||
|
type handleType = 't' | 'f'
|
||||||
|
const handle = ref<handleType>('t');
|
||||||
function WH(div: HTMLElement) {
|
function WH(div: HTMLElement) {
|
||||||
let a = calcWH(div.offsetHeight, div.offsetWidth, 24, 24, 0)
|
let a = calcWH(div.offsetHeight, div.offsetWidth, 24, 24, 0)
|
||||||
size.oWidth = a.oWidth
|
size.oWidth = a.oWidth
|
||||||
@ -113,7 +116,7 @@ const router=useRouter()
|
|||||||
}
|
}
|
||||||
async function gatdeviceStatusInfoMFfun() {
|
async function gatdeviceStatusInfoMFfun() {
|
||||||
let result: any = await gatdeviceStatusInfoMF({ id: route.params.dev })
|
let result: any = await gatdeviceStatusInfoMF({ id: route.params.dev })
|
||||||
|
handle.value = result.data.handle
|
||||||
if (result.code == 200) {
|
if (result.code == 200) {
|
||||||
setdata(result.data)
|
setdata(result.data)
|
||||||
}
|
}
|
||||||
@ -167,7 +170,8 @@ let data={
|
|||||||
clearTimeout(time.value)
|
clearTimeout(time.value)
|
||||||
time.value = null
|
time.value = null
|
||||||
}
|
}
|
||||||
time.value = setTimeout(() => {WH(contentBox)
|
time.value = setTimeout(() => {
|
||||||
|
WH(contentBox)
|
||||||
}, 1000);
|
}, 1000);
|
||||||
})
|
})
|
||||||
gatdeviceStatusInfoMFfun()
|
gatdeviceStatusInfoMFfun()
|
||||||
@ -196,26 +200,31 @@ let data={
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
.title>h1 {
|
.title>h1 {
|
||||||
font-size: 30px;
|
font-size: 30px;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 10px;
|
top: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.header {
|
.header {
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
.header p {
|
.header p {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: 50px;
|
right: 50px;
|
||||||
bottom: 20px;
|
bottom: 20px;
|
||||||
font-size: 20px;
|
font-size: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.content {
|
.content {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
--header: 100px;
|
--header: 100px;
|
||||||
height: calc(1080px - var(--header));
|
height: calc(1080px - var(--header));
|
||||||
display: flex;
|
display: flex;
|
||||||
}
|
}
|
||||||
|
|
||||||
.center {
|
.center {
|
||||||
margin: 0 30px;
|
margin: 0 30px;
|
||||||
display: flex;
|
display: flex;
|
||||||
@ -223,6 +232,7 @@ let data={
|
|||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.left {
|
.left {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
@ -245,11 +255,13 @@ let data={
|
|||||||
|
|
||||||
/* --content:calc(100vh - var(--header)) */
|
/* --content:calc(100vh - var(--header)) */
|
||||||
overflow: hidden !important;
|
overflow: hidden !important;
|
||||||
-ms-overflow-style: none; /* IE + Edge */
|
-ms-overflow-style: none;
|
||||||
scrollbar-width: none; /* Firefox */
|
/* IE + Edge */
|
||||||
|
scrollbar-width: none;
|
||||||
|
/* Firefox */
|
||||||
}
|
}
|
||||||
|
|
||||||
::-webkit-scrollbar {
|
::-webkit-scrollbar {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}</style>
|
||||||
</style>
|
|
||||||
|
|
@ -171,7 +171,7 @@ async function reqDeviceTotelListMFfun() {
|
|||||||
item.name,
|
item.name,
|
||||||
item.dept,
|
item.dept,
|
||||||
compare[item.status] ? compare[item.status] : '停机',
|
compare[item.status] ? compare[item.status] : '停机',
|
||||||
item.activation + '%',
|
item.activation,
|
||||||
// item.failure + '%'
|
// item.failure + '%'
|
||||||
]
|
]
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user