|
@@ -14,25 +14,37 @@
|
|
<div class="left-area">
|
|
<div class="left-area">
|
|
<!-- 采用定位方式以避免出现各个模块隐藏时其他模块下移的问题 -->
|
|
<!-- 采用定位方式以避免出现各个模块隐藏时其他模块下移的问题 -->
|
|
<template v-if="isOriginal">
|
|
<template v-if="isOriginal">
|
|
- <ModuleOriginal v-for="cfg in configsLeft" :key="cfg.deviceType" :show-style="cfg.showStyle"
|
|
|
|
- :module-data="cfg.moduleData" :module-name="cfg.moduleName" :device-type="cfg.deviceType" :data="data"
|
|
|
|
- :visible="true" />
|
|
|
|
|
|
+ <ModuleOriginal
|
|
|
|
+ v-for="cfg in configsLeft"
|
|
|
|
+ :key="cfg.deviceType"
|
|
|
|
+ :show-style="cfg.showStyle"
|
|
|
|
+ :module-data="cfg.moduleData"
|
|
|
|
+ :module-name="cfg.moduleName"
|
|
|
|
+ :device-type="cfg.deviceType"
|
|
|
|
+ :data="data"
|
|
|
|
+ :visible="true"
|
|
|
|
+ />
|
|
</template>
|
|
</template>
|
|
</div>
|
|
</div>
|
|
<div class="bottom-area">
|
|
<div class="bottom-area">
|
|
<!-- 采用定位方式以避免出现各个模块隐藏时其他模块下移的问题 -->
|
|
<!-- 采用定位方式以避免出现各个模块隐藏时其他模块下移的问题 -->
|
|
<template v-if="isOriginal">
|
|
<template v-if="isOriginal">
|
|
- <ModuleOriginal v-for="cfg in configsBottom" :key="cfg.deviceType" :show-style="cfg.showStyle"
|
|
|
|
- :module-data="cfg.moduleData" :module-name="cfg.moduleName" :device-type="cfg.deviceType" :data="data"
|
|
|
|
- :visible="true" />
|
|
|
|
|
|
+ <ModuleOriginal
|
|
|
|
+ v-for="cfg in configsBottom"
|
|
|
|
+ :key="cfg.deviceType"
|
|
|
|
+ :show-style="cfg.showStyle"
|
|
|
|
+ :module-data="cfg.moduleData"
|
|
|
|
+ :module-name="cfg.moduleName"
|
|
|
|
+ :device-type="cfg.deviceType"
|
|
|
|
+ :data="data"
|
|
|
|
+ :visible="true"
|
|
|
|
+ />
|
|
</template>
|
|
</template>
|
|
</div>
|
|
</div>
|
|
<div class="right-area">
|
|
<div class="right-area">
|
|
<greenRightTag></greenRightTag>
|
|
<greenRightTag></greenRightTag>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
-
|
|
|
|
-
|
|
|
|
<!-- <div
|
|
<!-- <div
|
|
v-if="sysDataType === 'all'"
|
|
v-if="sysDataType === 'all'"
|
|
:class="{ 'realtime-mode': isDataRealTime }"
|
|
:class="{ 'realtime-mode': isDataRealTime }"
|
|
@@ -42,7 +54,6 @@
|
|
></div> -->
|
|
></div> -->
|
|
<div class="switch-button icon-goto right-475px" @click="goMicroApp()"></div>
|
|
<div class="switch-button icon-goto right-475px" @click="goMicroApp()"></div>
|
|
</div>
|
|
</div>
|
|
-
|
|
|
|
</template>
|
|
</template>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
@@ -52,8 +63,8 @@ import { onMounted, onUnmounted, ref, watch, computed } from 'vue';
|
|
// import MonitorBar from './components/MonitorBar.vue';
|
|
// import MonitorBar from './components/MonitorBar.vue';
|
|
import { useInitConfigs, useInitPage } from './hooks/useInit';
|
|
import { useInitConfigs, useInitPage } from './hooks/useInit';
|
|
import ModuleOriginal from './components/ModuleOriginal-green.vue';
|
|
import ModuleOriginal from './components/ModuleOriginal-green.vue';
|
|
-import greenNav from './components/green-nav.vue'
|
|
|
|
-import greenRightTag from './components/green-right-tag.vue'
|
|
|
|
|
|
+import greenNav from './components/green-nav.vue';
|
|
|
|
+import greenRightTag from './components/green-right-tag.vue';
|
|
// import { useRoute } from 'vue-router';
|
|
// import { useRoute } from 'vue-router';
|
|
import VentModal from '/@/components/vent/micro/ventModal.vue';
|
|
import VentModal from '/@/components/vent/micro/ventModal.vue';
|
|
import { list } from './configurable.api';
|
|
import { list } from './configurable.api';
|
|
@@ -70,17 +81,17 @@ const router = useRouter();
|
|
const isDataRealTime = ref(sysDataType === 'monitor');
|
|
const isDataRealTime = ref(sysDataType === 'monitor');
|
|
// const showBar = ref(true);
|
|
// const showBar = ref(true);
|
|
let interval: number | undefined;
|
|
let interval: number | undefined;
|
|
-let configs = ref<any[]>([])
|
|
|
|
|
|
+let configs = ref<any[]>([]);
|
|
// function switchDataMode() {
|
|
// function switchDataMode() {
|
|
// isDataRealTime.value = !isDataRealTime.value;
|
|
// isDataRealTime.value = !isDataRealTime.value;
|
|
// refresh();
|
|
// refresh();
|
|
// }
|
|
// }
|
|
let configsLeft = computed(() => {
|
|
let configsLeft = computed(() => {
|
|
- return configs.value.filter(v => v.showStyle.position.includes('top'))
|
|
|
|
-})
|
|
|
|
|
|
+ return configs.value.filter((v) => v.showStyle.position.includes('top'));
|
|
|
|
+});
|
|
let configsBottom = computed(() => {
|
|
let configsBottom = computed(() => {
|
|
- return configs.value.filter(v => v.showStyle.position.includes('bottom'))
|
|
|
|
-})
|
|
|
|
|
|
+ return configs.value.filter((v) => v.showStyle.position.includes('bottom'));
|
|
|
|
+});
|
|
function refresh() {
|
|
function refresh() {
|
|
fetchConfigs(isDataRealTime.value ? 'vent_realtime' : 'vent').then(() => {
|
|
fetchConfigs(isDataRealTime.value ? 'vent_realtime' : 'vent').then(() => {
|
|
configs.value = isDataRealTime.value ? testConfigVentRealtime : testConfigVent;
|
|
configs.value = isDataRealTime.value ? testConfigVentRealtime : testConfigVent;
|
|
@@ -219,7 +230,7 @@ onUnmounted(() => {
|
|
background: url('../../../../assets/images/home-green/green-bd-left.png') no-repeat;
|
|
background: url('../../../../assets/images/home-green/green-bd-left.png') no-repeat;
|
|
background-size: 100% 100%;
|
|
background-size: 100% 100%;
|
|
box-sizing: border-box;
|
|
box-sizing: border-box;
|
|
- overflow-y: auto
|
|
|
|
|
|
+ overflow-y: auto;
|
|
}
|
|
}
|
|
|
|
|
|
.bottom-area {
|
|
.bottom-area {
|
|
@@ -233,12 +244,12 @@ onUnmounted(() => {
|
|
background-size: 100% 100%;
|
|
background-size: 100% 100%;
|
|
box-sizing: border-box;
|
|
box-sizing: border-box;
|
|
}
|
|
}
|
|
- .right-area{
|
|
|
|
- position:absolute;
|
|
|
|
- right:0px;
|
|
|
|
- top:0px;
|
|
|
|
- width:120px;
|
|
|
|
- height:calc(100% - 305px);
|
|
|
|
|
|
+ .right-area {
|
|
|
|
+ position: absolute;
|
|
|
|
+ right: 0px;
|
|
|
|
+ top: 0px;
|
|
|
|
+ width: 120px;
|
|
|
|
+ height: calc(100% - 305px);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|