lxh hace 9 meses
padre
commit
d05ae6aa06

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

@@ -75,7 +75,7 @@ export const chartsColumnList = [
   {
     legend: '一氧化碳',
     seriesName: '(ppm)',
-    ymax: 10,
+    ymax: 30,
     yname: 'ppm',
     linetype: 'line',
     yaxispos: 'left',
@@ -87,7 +87,7 @@ export const chartsColumnList = [
   {
     legend: '乙炔',
     seriesName: '',
-    ymax: 10,
+    ymax: 30,
     yname: 'ppm',
     linetype: 'line',
     yaxispos: 'left',
@@ -99,7 +99,7 @@ export const chartsColumnList = [
   {
     legend: '乙烯',
     seriesName: '',
-    ymax: 10,
+    ymax: 30,
     yname: 'ppm',
     linetype: 'line',
     yaxispos: 'left',
@@ -111,7 +111,7 @@ export const chartsColumnList = [
   {
     legend: '二氧化碳',
     seriesName: '(%)',
-    ymax: 20,
+    ymax: 30,
     yname: '%',
     linetype: 'line',
     yaxispos: 'right',
@@ -123,7 +123,7 @@ export const chartsColumnList = [
   {
     legend: '甲烷',
     seriesName: '',
-    ymax: 20,
+    ymax: 30,
     yname: '%',
     linetype: 'line',
     yaxispos: 'right',

+ 9 - 6
src/views/vent/monitorManager/deviceMonitor/components/device/modal/bundle.modal.vue

@@ -165,9 +165,9 @@ export default defineComponent({
     }
 
     // 选择监测
-    function selectDevice(id) {
+    function selectDevice() {
       loading.value = true;
-      getListdays(id);
+      getListdays();
       setModalProps({ loading: true, confirmLoading: true });
       setTimeout(() => {
         loading.value = false;
@@ -187,7 +187,7 @@ export default defineComponent({
     }
 
     //获取历史数据
-    async function getListdays(id) {
+    async function getListdays() {
       if (posMonitor.value.stationtype != 'redis') {
         const ttime_begin = dayjs(new Date().getTime() - 3 * 24 * 60 * 60 * 1000).format('YYYY-MM-DD hh:mm:ss');
         const ttime_end = dayjs(new Date().getTime()).format('YYYY-MM-DD hh:mm:ss');
@@ -195,7 +195,7 @@ export default defineComponent({
         const pageSize = 100;
         const skip = 8;
         const strtype = 'bundletube_auto';
-        let res = await listdays({ ttime_begin, ttime_end, pageNo, pageSize, skip, strtype, gdeviceid: id });
+        let res = await listdays({ ttime_begin, ttime_end, pageNo, pageSize, skip, strtype, gdeviceid: activeDeviceID.value });
         console.log(res, '束管历史数据');
         let data = res.datalist.records;
         if (data.length != 0) {
@@ -210,7 +210,7 @@ export default defineComponent({
           pageSize: 100,
           startTime: dayjs(new Date().getTime() - 3 * 24 * 60 * 60 * 1000).format('YYYY-MM-DD hh:mm:ss'),
           endTime: dayjs(new Date().getTime()).format('YYYY-MM-DD hh:mm:ss'),
-          deviceId: id,
+          deviceId: activeDeviceID.value,
           interval: '1h',
           isEmployee: true,
         };
@@ -239,12 +239,15 @@ export default defineComponent({
         if ((!activeDeviceID.value && index == 0) || item.deviceID === activeDeviceID.value) {
           // activeDeviceID.value = item.deviceID;
           posMonitor.value = Object.assign(item, item.readData);
-          getListdays(activeDeviceID.value);
+         
         }
         item.readTime = item.readTime?.substring(11);
         return item;
       });
     });
+    onMounted(()=>{
+      getListdays();
+    })
     return {
       register,
       model: modelRef,