Преглед изворни кода

1. 公司端解决轮播时个别数据定位错位
2. 局部风机根据定频、变频将个别按钮隐藏
3. 滚动条加宽

hongrunxia пре 9 месеци
родитељ
комит
61ec6ab375

+ 1 - 1
src/design/public.less

@@ -9,7 +9,7 @@
 // =================================
 
 ::-webkit-scrollbar {
-  width: 2px;
+  width: 7px !important;
   height: 4px;
 }
 

+ 2 - 1
src/views/vent/home/billboard/components/GasStatus.vue

@@ -52,7 +52,8 @@
     };
     headerData.value = {
       gasWarnLevel: riskTrans[get(info, 'gasWarnLevel', 0)],
-      gasJudgeLevel: '低风险',
+      // gasJudgeLevel: '低风险',
+      gasJudgeLevel: props.data.orgcode == 'sdmtjtbdmk' ? '高瓦斯' : '低瓦斯',
     };
     tableData.value = get(info, 'gasTypeList', []).map((e) => {
       return {

+ 8 - 8
src/views/vent/home/clique/components/scene-key.vue

@@ -186,6 +186,7 @@
           height: 32px;
           background: url('../../../../../assets/images/company/fxfx.png') no-repeat center;
           background-size: 100% 100%;
+          display: flex;
 
           .box-icon {
             position: absolute;
@@ -195,22 +196,21 @@
           }
 
           .box-label {
-            position: absolute;
-            left: 56px;
-            top: 50%;
-            transform: translate(0, -50%);
+            margin-left: 56px;
+            width: 50px;
+            display: block;
             color: #fff;
             font-size: 14px;
+            line-height: 32px;
           }
 
           .box-value {
-            position: absolute;
-            right: 96px;
-            top: 50%;
-            transform: translate(0, -48%);
+            width: 130px;
             font-family: 'douyuFont';
             font-size: 14px;
             color: #31fbcc;
+            line-height: 32px;
+            text-align: end;
           }
 
           .box-img {

+ 1 - 1
src/views/vent/monitorManager/deviceMonitor/components/device/device.data.ts

@@ -46,7 +46,7 @@ export const locationList = [
 ];
 
 export function getMonitorComponent() {
-  let { sysOrgCode } = useGlobSetting();
+  const { sysOrgCode } = useGlobSetting();
   // sysOrgCode = 'sdmtjtbdmk';
   let FiberModal;
   switch (sysOrgCode) {

+ 5 - 3
src/views/vent/monitorManager/deviceMonitor/components/device/index.vue

@@ -436,7 +436,7 @@ const systemID = ref('') // 系统监测时,系统id
 const selectedKeys = ref<string[]>([]);
 const expandedKeys = ref<string[]>([]);
 const scroll = reactive({
-  y: 210
+  y: 180
 })
 const treeData = ref<TreeProps['treeData']>([]);
 let departmentInfo: Null | Object = null
@@ -464,12 +464,11 @@ const onSelect: TreeProps['onSelect'] = (keys, e) => {
   if (startMonitorTimer) {
     clearTimeout(startMonitorTimer)
   }
+  dataSource.value = []
   startMonitorTimer = setTimeout(() => {
     expandedKeys.value = keys
     selectedKeys.value = keys
     treeNodeTitle.value = e.node.title
-    console.log('树选择器--------------->', selectedKeys.value, treeNodeTitle.value, e)
-    dataSource.value = []
     activeKey.value = '1'
     timer = null
     if (e.node.children?.length < 1) {
@@ -700,6 +699,7 @@ function goDetail(record?) {
       modalVisible.value = true;
     } else if (deviceType.value.startsWith('bundletube')) {
       currentModal.value = BundleModal
+      // currentModal.value = BallvalveModal
       modalVisible.value = true;
     } else if (deviceType.value.startsWith('ballvalve')) {
       currentModal.value = BallvalveModal
@@ -926,6 +926,8 @@ onMounted(async () => {
   } else {
     locationList.value = await devPosition({})
   }
+  
+
   // safetyOption.value = await safetyDeviceList(null, { devicetype: 'safetymonitor', code: 'dataTypeName' })
 })
 

+ 42 - 10
src/views/vent/monitorManager/deviceMonitor/components/device/modal/ballvalve.modal.vue

@@ -1,5 +1,5 @@
 <template>
-  <BasicModal v-bind="$attrs" @register="register" :title="`束管监测详情    ${currentTime}`" width="1200px" @ok="handleOk" @cancel="handleCancel">
+  <BasicModal v-bind="$attrs" @register="register" :title="`光纤测温监测详情    ${currentTime}`" width="1200px" @ok="handleOk" @cancel="handleCancel">
     <div class="fiber-modal">
       <div class="modal-left">
         <div
@@ -212,8 +212,20 @@
           </div>
         </div>
         <div class="right-bottom">
-          <span class="base-title">设备监测曲线</span>
-          <a-table size="small" :columns="ballvalveColumns" :data-source="[]" :pagination="false" :scroll="{ y: 300 }" />
+          <span class="base-title">设备监测</span>
+          <!-- <a-table size="small" :columns="ballvalveColumns" :data-source="historyList" :pagination="false" :scroll="{ y: 300 }" /> -->
+          <div class="echarts-box">
+            <BarAndLine
+              class="echarts-line"
+              xAxisPropType="time"
+              :dataSource="historyList"
+              height="100%"
+              width="100%"
+              :chartsColumns="chartsColumns"
+              :option="echatsOption"
+              chartsType="listMonitor"
+            />
+          </div>
         </div>
       </div>
     </div>
@@ -224,9 +236,11 @@
   import { BasicModal, useModalInner } from '/@/components/Modal';
   import BarAndLine from '/@/components/chart/BarAndLine.vue';
   import { SvgIcon } from '/@/components/Icon';
+  import { chartsColumnList } from '../device.data';
   import { Decoration7 as DvDecoration7, ScrollBoard as DvScrollBoard } from '@kjgl77/datav-vue3';
   import dayjs from 'dayjs';
   import { ballvalveColumns } from '../device.data';
+  import { getTableHeaderColumns } from '/@/hooks/web/useWebColumns';
 
   export default defineComponent({
     components: { BasicModal, BarAndLine, SvgIcon, DvScrollBoard, DvDecoration7 },
@@ -243,6 +257,20 @@
       const historyList = ref<any[]>([]);
       const posList = ref<any[]>([]);
       const posMonitor = shallowRef({});
+      const chartsColumnArr = getTableHeaderColumns('ballvalve_chart');
+      const chartsColumns = chartsColumnArr.length > 0 ? chartsColumnArr : chartsColumnList;
+      const echatsOption = {
+        grid: {
+          top: '20%',
+          left: '-5',
+          right: '45',
+          bottom: '0',
+          containLabel: true,
+        },
+        toolbox: {
+          feature: {},
+        },
+      };
 
       const [register, { setModalProps, closeModal }] = useModalInner();
 
@@ -308,6 +336,9 @@
         historyList,
         activeDeviceID,
         posMonitor,
+        echatsOption,
+        chartsColumnList,
+        chartsColumns,
       };
     },
   });
@@ -399,7 +430,8 @@
             width: 120px;
           }
           .value {
-            width: 100px;
+            width: 150px;
+            text-overflow: ellipsis;
           }
         }
       }
@@ -472,19 +504,19 @@
         }
         .item-data {
           position: relative;
-          height: 130px;
+          height: 120px;
           padding-top: 0;
           .icon {
             position: absolute;
             left: 20px;
-            top: 30px;
+            top: 25px;
             // margin-right: 30px;
             // margin-top: 25px;
           }
           .item-container {
             width: 140px;
             position: absolute;
-            padding-top: 18px;
+            padding-top: 15px;
             justify-content: flex-start;
             right: 0;
             .value {
@@ -553,7 +585,7 @@
             :deep(.dv-scroll-board) {
               .row-item {
                 height: 40px !important;
-                line-height: 40px !important;
+                line-height: 35px !important;
               }
 
               .header-item {
@@ -566,11 +598,11 @@
       }
 
       .right-bottom {
-        margin-top: 20px;
+        margin-top: 10px;
 
         .echarts-box {
           width: 100%;
-          height: 320px;
+          height: 180px;
           position: relative;
 
           .echarts-line {

+ 0 - 1
src/views/vent/monitorManager/deviceMonitor/index.vue

@@ -53,7 +53,6 @@
   );
 
   onMounted(() => {
-    debugger;
     const { type, deviceType, topage } = route.query;
     deviceKind.value = deviceType as string;
     if (!topage) {

+ 16 - 6
src/views/vent/monitorManager/fanLocalMonitor/index.vue

@@ -94,16 +94,25 @@
         </div>
         <!-- fanlocal_systeml_zj 模拟局部风机,不显示操作按钮 -->
         <template v-for="(item, index) in modalTypeArr.leftBtnArr" :key="index">
-          <div v-if="hasPermission(item.permission)" :class="{ 'button-box': btnClick, 'button-disable': !btnClick }" @click="showModal(item)">{{
-            item.value
-          }}</div>
+          <div
+            v-if="!(selectData.fanFrequencyType == 'fandp' && item.permission.startsWith('btn:frequency')) && hasPermission(item.permission)"
+            :class="{ 'button-box': btnClick, 'button-disable': !btnClick }"
+            @click="showModal(item)"
+            >{{ item.value }}</div
+          >
         </template>
       </div>
       <div class="top-right row">
         <template v-for="(item, index) in modalTypeArr.rightBtnArr" :key="index">
-          <div v-if="hasPermission(item.permission)" :class="{ 'button-box': btnClick, 'button-disable': !btnClick }" @click="showModal(item)">{{
-            item.value
-          }}</div>
+          <div
+            v-if="
+              !(selectData.fanFrequencyType == 'fandp' && (item.permission === 'fanLocal:gasAlarmSet' || item.permission === 'fanLocal:kkjc')) &&
+              hasPermission(item.permission)
+            "
+            :class="{ 'button-box': btnClick, 'button-disable': !btnClick }"
+            @click="showModal(item)"
+            >{{ item.value }}</div
+          >
         </template>
       </div>
     </div>
@@ -692,6 +701,7 @@
     netStatus: '0', //通信状态
     warnLevel_str: '',
     stationname: '',
+    fanFrequencyType: '',
   };
   const frequencyVal = ref(0);
   const dataSource = ref([]);