Browse Source

[Mod 0000] 给天气气压功能添加权限; 新增准东二矿带风窗的风门控制风窗功能;

hongrunxia 5 ngày trước cách đây
mục cha
commit
1bdedb7043

+ 216 - 216
src/layouts/default/header/components/weatherBroadcast.vue

@@ -54,246 +54,246 @@
   </div>
 </template>
 <script lang="ts">
-import BarAndLine from '/@/components/chart/BarAndLine.vue';
-import { Tooltip, Badge } from 'ant-design-vue';
-import { SoundOutlined, ClearOutlined, FileSearchOutlined, WarningOutlined } from '@ant-design/icons-vue';
-import Icon from '/@/components/Icon';
-import { defineComponent, ref, onMounted, nextTick } from 'vue';
-import { defHttp } from '/@/utils/http/axios';
-import { useDrag } from '@/hooks/event/useDrag';
+  import BarAndLine from '/@/components/chart/BarAndLine.vue';
+  import { Tooltip, Badge } from 'ant-design-vue';
+  import { SoundOutlined, ClearOutlined, FileSearchOutlined, WarningOutlined } from '@ant-design/icons-vue';
+  import Icon from '/@/components/Icon';
+  import { defineComponent, ref, onMounted, nextTick } from 'vue';
+  import { defHttp } from '/@/utils/http/axios';
+  import { useDrag } from '@/hooks/event/useDrag';
 
-export default defineComponent({
-  name: 'VoiceBroadcast',
-  components: { Icon, Tooltip, Badge, SoundOutlined, ClearOutlined, FileSearchOutlined, WarningOutlined, BarAndLine },
+  export default defineComponent({
+    name: 'VoiceBroadcast',
+    components: { Icon, Tooltip, Badge, SoundOutlined, ClearOutlined, FileSearchOutlined, WarningOutlined, BarAndLine },
 
-  setup() {
-    const getWeather = () => defHttp.post({ url: '/safety/ventanalyDevice/getWeatherData' });
-    const activeKey = ref(0);
-    const isShowWeatherBroad = ref(false);
-    const monitorData = ref<any[]>([]);
+    setup() {
+      const getWeather = () => defHttp.post({ url: '/safety/ventanalyDevice/getWeatherData' });
+      const activeKey = ref(0);
+      const isShowWeatherBroad = ref(false);
+      const monitorData = ref<any[]>([]);
 
-    const ChartsColumnsWD = [
-      {
-        legend: '温度',
-        seriesName: '(℃)',
-        ymax: 0.8,
-        yname: '℃',
-        linetype: 'line',
-        yaxispos: 'left',
-        color: '#00FFA8',
-        sort: 1,
-        xRotate: 0,
-        dataIndex: 'temp',
-      },
-    ];
-    const ChartsColumnsQY = [
-      {
-        legend: '气压',
-        seriesName: '(hPa)',
-        ymax: 0.8,
-        yname: 'hPa',
-        linetype: 'line',
-        yaxispos: 'left',
-        color: '#00FFA8',
-        sort: 1,
-        xRotate: 0,
-        dataIndex: 'pressure',
-      },
-    ];
-    const ChartsColumnsFL = [
-      {
-        legend: '风力',
-        seriesName: '(等级)',
-        ymax: 0.8,
-        yname: '等级',
-        linetype: 'line',
-        yaxispos: 'left',
-        color: '#00FFA8',
-        sort: 1,
-        xRotate: 0,
-        dataIndex: 'widnScale',
-      },
-    ];
+      const ChartsColumnsWD = [
+        {
+          legend: '温度',
+          seriesName: '(℃)',
+          ymax: 0.8,
+          yname: '℃',
+          linetype: 'line',
+          yaxispos: 'left',
+          color: '#00FFA8',
+          sort: 1,
+          xRotate: 0,
+          dataIndex: 'temp',
+        },
+      ];
+      const ChartsColumnsQY = [
+        {
+          legend: '气压',
+          seriesName: '(hPa)',
+          ymax: 0.8,
+          yname: 'hPa',
+          linetype: 'line',
+          yaxispos: 'left',
+          color: '#00FFA8',
+          sort: 1,
+          xRotate: 0,
+          dataIndex: 'pressure',
+        },
+      ];
+      const ChartsColumnsFL = [
+        {
+          legend: '风力',
+          seriesName: '(等级)',
+          ymax: 0.8,
+          yname: '等级',
+          linetype: 'line',
+          yaxispos: 'left',
+          color: '#00FFA8',
+          sort: 1,
+          xRotate: 0,
+          dataIndex: 'widnScale',
+        },
+      ];
 
-    const Option = {
-      grid: {
-        top: '20%',
-        left: '5%',
-        right: '5%',
-        bottom: '3%',
-        containLabel: true,
-      },
-      toolbox: {
-        feature: null,
-      },
-    };
-    const weatherObj = ref({
-      cloud: '',
-      dew: '',
-      fxTime: '',
-      humidity: '',
-      icon: '',
-      pop: '',
-      precip: '',
-      pressure: '',
-      temp: '',
-      text: '',
-      wind360: '',
-      windDir: '',
-      windScale: '',
-      windSpeed: '',
-    });
+      const Option = {
+        grid: {
+          top: '20%',
+          left: '5%',
+          right: '5%',
+          bottom: '3%',
+          containLabel: true,
+        },
+        toolbox: {
+          feature: null,
+        },
+      };
+      const weatherObj = ref({
+        cloud: '',
+        dew: '',
+        fxTime: '',
+        humidity: '',
+        icon: '',
+        pop: '',
+        precip: '',
+        pressure: '',
+        temp: '',
+        text: '',
+        wind360: '',
+        windDir: '',
+        windScale: '',
+        windSpeed: '',
+      });
 
-    const iconMap = {
-      晴: new URL('/src/assets/icons/sun.svg', import.meta.url).href,
-      雨: new URL('/src/assets/icons/rain.svg', import.meta.url).href,
-      雪: new URL('/src/assets/icons/snow.svg', import.meta.url).href,
-      多云: new URL('/src/assets/icons/clound.svg', import.meta.url).href,
-      风: new URL('/src/assets/icons/wind.svg', import.meta.url).href,
-    };
+      const iconMap = {
+        晴: new URL('/src/assets/icons/sun.svg', import.meta.url).href,
+        雨: new URL('/src/assets/icons/rain.svg', import.meta.url).href,
+        雪: new URL('/src/assets/icons/snow.svg', import.meta.url).href,
+        多云: new URL('/src/assets/icons/clound.svg', import.meta.url).href,
+        风: new URL('/src/assets/icons/wind.svg', import.meta.url).href,
+      };
 
-    function parseWeatherData(res) {
-      return iconMap[res] || new URL('/src/assets/icons/sun.svg', import.meta.url).href;
-    }
-    function showWarningBroad() {
-      isShowWeatherBroad.value = !isShowWeatherBroad.value;
-      if (isShowWeatherBroad.value) {
-        toSelectList(0);
+      function parseWeatherData(res) {
+        return iconMap[res] || new URL('/src/assets/icons/sun.svg', import.meta.url).href;
+      }
+      function showWarningBroad() {
+        isShowWeatherBroad.value = !isShowWeatherBroad.value;
+        if (isShowWeatherBroad.value) {
+          toSelectList(0);
 
-        nextTick(() => {
-          const dom = document.getElementById('VoiceBroadcast');
-          if (dom) useDrag(dom);
-        });
+          nextTick(() => {
+            const dom = document.getElementById('VoiceBroadcast');
+            if (dom) useDrag(dom);
+          });
+        }
       }
-    }
-    async function toSelectList(key) {
-      activeKey.value = key;
-    }
-    async function getWeatherInfo() {
-      const res = await getWeather();
+      async function toSelectList(key) {
+        activeKey.value = key;
+      }
+      async function getWeatherInfo() {
+        const res = await getWeather();
 
-      weatherObj.value = JSON.parse(res.weatherDataNow);
-      monitorData.value = JSON.parse(res.weatherData);
-    }
-    onMounted(() => {
-      nextTick(async () => {
-        await getWeatherInfo();
+        weatherObj.value = JSON.parse(res.weatherDataNow);
+        monitorData.value = JSON.parse(res.weatherData);
+      }
+      onMounted(() => {
+        nextTick(async () => {
+          await getWeatherInfo();
+        });
       });
-    });
 
-    return {
-      showWarningBroad,
-      isShowWeatherBroad,
-      activeKey,
-      weatherObj,
-      parseWeatherData,
-      toSelectList,
-      monitorData,
-      ChartsColumnsWD,
-      ChartsColumnsQY,
-      ChartsColumnsFL,
-      Option,
-    };
-  },
-});
+      return {
+        showWarningBroad,
+        isShowWeatherBroad,
+        activeKey,
+        weatherObj,
+        parseWeatherData,
+        toSelectList,
+        monitorData,
+        ChartsColumnsWD,
+        ChartsColumnsQY,
+        ChartsColumnsFL,
+        Option,
+      };
+    },
+  });
 </script>
 <style lang="less" scoped>
-.unit {
-  font-size: 15px;
-  line-height: 47px;
-  color: #fff;
-}
-.btn {
-  line-height: 30px;
-  cursor: pointer;
-  display: flex;
-}
-.btn-header {
-  width: 130px;
-  height: 50px;
-}
-.weather-icon {
-  width: 20px;
-  height: 20px;
-  margin-top: 14px;
-  margin-right: 10px;
-}
-.broadcast {
-  width: 500px;
-  height: 350px;
-  border-radius: 4px;
-  position: fixed;
-  top: 50px;
-  right: 20px;
-  background-color: rgb(255, 255, 255);
-  background: url('../../../../assets/images/warn-dialog-bg.png') no-repeat center;
-  background-size: 100% 100%;
-  z-index: 9999999;
-  color: #fff;
+  .unit {
+    font-size: 15px;
+    line-height: 47px;
+    color: #fff;
+  }
+  .btn {
+    line-height: 30px;
+    cursor: pointer;
+    display: flex;
+  }
+  .btn-header {
+    width: 130px;
+    height: 50px;
+  }
+  .weather-icon {
+    width: 20px;
+    height: 20px;
+    margin-top: 14px;
+    margin-right: 10px;
+  }
+  .broadcast {
+    width: 500px;
+    height: 350px;
+    border-radius: 4px;
+    position: fixed;
+    top: 50px;
+    right: 20px;
+    background-color: rgb(255, 255, 255);
+    background: url('../../../../assets/images/warn-dialog-bg.png') no-repeat center;
+    background-size: 100% 100%;
+    z-index: 9999999;
+    color: #fff;
 
-  .title {
-    text-align: center;
-    padding: 0 20px;
+    .title {
+      text-align: center;
+      padding: 0 20px;
 
-    :deep(.ant-badge:not(.ant-badge-status)) {
-      margin-right: 40px !important;
-    }
-    display: flex;
-    align-items: center;
-    justify-content: center;
-    .message-title {
-      font-size: 16px;
-      color: #fff;
-      font-weight: 600;
-      line-height: 50px;
-      flex: 1;
-    }
-    .badge-box {
+      :deep(.ant-badge:not(.ant-badge-status)) {
+        margin-right: 40px !important;
+      }
       display: flex;
       align-items: center;
-      padding-top: 10px;
-      .badge-title {
-        display: inline-block;
-        width: 62px;
-        line-height: 32px;
-        background-color: #2174f0;
-        border-radius: 26px;
-        text-align: center;
+      justify-content: center;
+      .message-title {
+        font-size: 16px;
         color: #fff;
-        padding-bottom: 2px;
+        font-weight: 600;
+        line-height: 50px;
+        flex: 1;
+      }
+      .badge-box {
+        display: flex;
+        align-items: center;
+        padding-top: 10px;
+        .badge-title {
+          display: inline-block;
+          width: 62px;
+          line-height: 32px;
+          background-color: #2174f0;
+          border-radius: 26px;
+          text-align: center;
+          color: #fff;
+          padding-bottom: 2px;
+        }
       }
     }
-  }
 
-  .broadcast-context {
-    .context-tab {
-      display: flex;
-      .context-tab-item {
-        line-height: 24px;
-        background: url('../../../../assets/images/tab-1.png') no-repeat center;
-        border-radius: 24px;
-        text-align: center;
-        color: #fff;
-        cursor: pointer;
-        font-size: 14px;
-        width: 80px;
+    .broadcast-context {
+      .context-tab {
+        display: flex;
+        .context-tab-item {
+          line-height: 24px;
+          background: url('../../../../assets/images/tab-1.png') no-repeat center;
+          border-radius: 24px;
+          text-align: center;
+          color: #fff;
+          cursor: pointer;
+          font-size: 14px;
+          width: 80px;
+        }
+        .context-tab-item-active {
+          background: url('../../../../assets/images/tab-2.png') no-repeat center;
+        }
       }
-      .context-tab-item-active {
-        background: url('../../../../assets/images/tab-2.png') no-repeat center;
-      }
-    }
-    .context-box {
-      width: 100%;
-      height: calc(100% - 32px);
-      .echarts-box {
+      .context-box {
         width: 100%;
-        height: 500px;
+        height: calc(100% - 32px);
+        .echarts-box {
+          width: 100%;
+          height: 500px;
+        }
       }
     }
   }
-}
-:deep(.zxm-badge-count) {
-  width: 0px;
-  height: 0px;
-}
+  :deep(.zxm-badge-count) {
+    width: 0px;
+    height: 0px;
+  }
 </style>

+ 252 - 249
src/layouts/default/header/index.vue

@@ -57,7 +57,7 @@
   <div :class="`${prefixCls}-action`" style="position: fixed; top: 30px; right: 20px; z-index: 999999">
     <div class="right-position">
       <!-- 公司端不显示语音播报功能 weatherBroadcast.vue-->
-      <WeatherBroadcast v-if="sysOrgCode != 'sdmtjtgsd'" />
+      <WeatherBroadcast v-if="sysOrgCode != 'sdmtjtgsd' && hasPermission('btn:weatherBroadcast')" />
       <VoiceBroadcast v-if="sysOrgCode != 'sdmtjtgsd'" />
       <VoiceBroadcastGsd v-if="sysOrgCode == 'sdmtjtgsd'" />
       <UserDropDown v-if="showUserDropdown" :theme="getHeaderTheme" />
@@ -66,269 +66,272 @@
   </div>
 </template>
 <script lang="ts">
-import { defineComponent, unref, computed, ref, onMounted, toRaw } from 'vue';
-import { useGlobSetting } from '/@/hooks/setting';
-import { propTypes } from '/@/utils/propTypes';
-
-import { Layout } from 'ant-design-vue';
-import { AppLogo } from '/@/components/Application';
-import LayoutMenu from '../menu/index.vue';
-import LayoutTrigger from '../trigger/index.vue';
-
-import { AppSearch } from '/@/components/Application';
-
-import { useHeaderSetting } from '/@/hooks/setting/useHeaderSetting';
-import { useMenuSetting } from '/@/hooks/setting/useMenuSetting';
-import { useRootSetting } from '/@/hooks/setting/useRootSetting';
-
-import { MenuModeEnum, MenuSplitTyeEnum } from '/@/enums/menuEnum';
-import { SettingButtonPositionEnum } from '/@/enums/appEnum';
-import { AppLocalePicker } from '/@/components/Application';
-
-import { UserDropDown, LayoutBreadcrumb, FullScreen, Notify, ErrorAction, LockScreen } from './components';
-import { useAppInject } from '/@/hooks/web/useAppInject';
-import { useDesign } from '/@/hooks/web/useDesign';
-
-import { createAsyncComponent } from '/@/utils/factory/createAsyncComponent';
-import { useLocale } from '/@/locales/useLocale';
-
-import WeatherBroadcast from './components/weatherBroadcast.vue';
-import VoiceBroadcast from './components/VoiceBroadcast.vue';
-import VoiceBroadcastGsd from './components/VoiceBroadcastGsd.vue';
-
-import LoginSelect from '/@/views/sys/login/LoginSelect.vue';
-import { useUserStore } from '/@/store/modules/user';
-import { useRouter } from 'vue-router';
-
-import { noHeadeLink } from '../layout.data';
-
-export default defineComponent({
-  name: 'LayoutHeader',
-  components: {
-    Header: Layout.Header,
-    AppLogo,
-    LayoutTrigger,
-    LayoutBreadcrumb,
-    LayoutMenu,
-    UserDropDown,
-    AppLocalePicker,
-    FullScreen,
-    Notify,
-    AppSearch,
-    ErrorAction,
-    LockScreen,
-    LoginSelect,
-    VoiceBroadcast,
-    VoiceBroadcastGsd,
-    WeatherBroadcast,
-    SettingDrawer: createAsyncComponent(() => import('/@/layouts/default/setting/index.vue'), {
-      loading: true,
-    }),
-  },
-  props: {
-    fixed: propTypes.bool,
-  },
-  setup(props) {
-    const { prefixCls } = useDesign('layout-header');
-    const userStore = useUserStore();
-    const { currentRoute } = useRouter();
-    console.log(currentRoute);
-
-    const { getShowTopMenu, getShowHeaderTrigger, getSplit, getIsMixMode, getMenuWidth, getIsMixSidebar } = useMenuSetting();
-    const { getUseErrorHandle, getShowSettingButton, getSettingButtonPosition } = useRootSetting();
-    const { title, sysOrgCode, homePath } = useGlobSetting();
-    const {
-      getHeaderTheme,
-      getShowFullScreen,
-      getShowNotice,
-      getShowContent,
-      getShowBread,
-      getShowHeaderLogo,
-      getShowHeader,
-      getShowSearch,
-      getUseLockPage,
-      getShowBreadTitle,
-      getShowFullHeaderRef,
-    } = useHeaderSetting();
-
-    const { getShowLocalePicker } = useLocale();
-
-    const { getIsMobile } = useAppInject();
-
-    const getHeaderClass = computed(() => {
-      const theme = unref(getHeaderTheme);
-      return [
-        prefixCls,
-        {
-          [`${prefixCls}--fixed`]: props.fixed,
-          [`${prefixCls}--mobile`]: unref(getIsMobile),
-          [`${prefixCls}--${theme}`]: theme,
-        },
-      ];
-    });
-
-    const getShowFullHeader = computed(() => {
-      const route = unref(currentRoute);
-      return getShowFullHeaderRef && route.path.startsWith('/micro-');
-    });
-
-    const getShowSetting = computed(() => {
-      if (!unref(getShowSettingButton)) {
-        return false;
+  import { defineComponent, unref, computed, ref, onMounted, toRaw } from 'vue';
+  import { useGlobSetting } from '/@/hooks/setting';
+  import { propTypes } from '/@/utils/propTypes';
+
+  import { Layout } from 'ant-design-vue';
+  import { AppLogo } from '/@/components/Application';
+  import LayoutMenu from '../menu/index.vue';
+  import LayoutTrigger from '../trigger/index.vue';
+
+  import { AppSearch } from '/@/components/Application';
+
+  import { useHeaderSetting } from '/@/hooks/setting/useHeaderSetting';
+  import { useMenuSetting } from '/@/hooks/setting/useMenuSetting';
+  import { useRootSetting } from '/@/hooks/setting/useRootSetting';
+
+  import { MenuModeEnum, MenuSplitTyeEnum } from '/@/enums/menuEnum';
+  import { SettingButtonPositionEnum } from '/@/enums/appEnum';
+  import { AppLocalePicker } from '/@/components/Application';
+
+  import { UserDropDown, LayoutBreadcrumb, FullScreen, Notify, ErrorAction, LockScreen } from './components';
+  import { useAppInject } from '/@/hooks/web/useAppInject';
+  import { useDesign } from '/@/hooks/web/useDesign';
+
+  import { createAsyncComponent } from '/@/utils/factory/createAsyncComponent';
+  import { useLocale } from '/@/locales/useLocale';
+
+  import WeatherBroadcast from './components/weatherBroadcast.vue';
+  import VoiceBroadcast from './components/VoiceBroadcast.vue';
+  import VoiceBroadcastGsd from './components/VoiceBroadcastGsd.vue';
+
+  import LoginSelect from '/@/views/sys/login/LoginSelect.vue';
+  import { useUserStore } from '/@/store/modules/user';
+  import { useRouter } from 'vue-router';
+
+  import { noHeadeLink } from '../layout.data';
+  import { usePermission } from '/@/hooks/web/usePermission';
+
+  export default defineComponent({
+    name: 'LayoutHeader',
+    components: {
+      Header: Layout.Header,
+      AppLogo,
+      LayoutTrigger,
+      LayoutBreadcrumb,
+      LayoutMenu,
+      UserDropDown,
+      AppLocalePicker,
+      FullScreen,
+      Notify,
+      AppSearch,
+      ErrorAction,
+      LockScreen,
+      LoginSelect,
+      VoiceBroadcast,
+      VoiceBroadcastGsd,
+      WeatherBroadcast,
+      SettingDrawer: createAsyncComponent(() => import('/@/layouts/default/setting/index.vue'), {
+        loading: true,
+      }),
+    },
+    props: {
+      fixed: propTypes.bool,
+    },
+    setup(props) {
+      const { prefixCls } = useDesign('layout-header');
+      const userStore = useUserStore();
+      const { currentRoute } = useRouter();
+      console.log(currentRoute);
+      const { hasPermission } = usePermission();
+
+      const { getShowTopMenu, getShowHeaderTrigger, getSplit, getIsMixMode, getMenuWidth, getIsMixSidebar } = useMenuSetting();
+      const { getUseErrorHandle, getShowSettingButton, getSettingButtonPosition } = useRootSetting();
+      const { title, sysOrgCode, homePath } = useGlobSetting();
+      const {
+        getHeaderTheme,
+        getShowFullScreen,
+        getShowNotice,
+        getShowContent,
+        getShowBread,
+        getShowHeaderLogo,
+        getShowHeader,
+        getShowSearch,
+        getUseLockPage,
+        getShowBreadTitle,
+        getShowFullHeaderRef,
+      } = useHeaderSetting();
+
+      const { getShowLocalePicker } = useLocale();
+
+      const { getIsMobile } = useAppInject();
+
+      const getHeaderClass = computed(() => {
+        const theme = unref(getHeaderTheme);
+        return [
+          prefixCls,
+          {
+            [`${prefixCls}--fixed`]: props.fixed,
+            [`${prefixCls}--mobile`]: unref(getIsMobile),
+            [`${prefixCls}--${theme}`]: theme,
+          },
+        ];
+      });
+
+      const getShowFullHeader = computed(() => {
+        const route = unref(currentRoute);
+        return getShowFullHeaderRef && route.path.startsWith('/micro-');
+      });
+
+      const getShowSetting = computed(() => {
+        if (!unref(getShowSettingButton)) {
+          return false;
+        }
+        const settingButtonPosition = unref(getSettingButtonPosition);
+
+        if (settingButtonPosition === SettingButtonPositionEnum.AUTO) {
+          return unref(getShowHeader);
+        }
+        return settingButtonPosition === SettingButtonPositionEnum.HEADER;
+      });
+
+      const getLogoWidth = computed(() => {
+        if (!unref(getIsMixMode) || unref(getIsMobile)) {
+          return {};
+        }
+        const width = unref(getMenuWidth) < 180 ? 180 : unref(getMenuWidth);
+        return { width: `${width}px` };
+      });
+
+      const getSplitType = computed(() => {
+        return unref(getSplit) ? MenuSplitTyeEnum.TOP : MenuSplitTyeEnum.NONE;
+      });
+
+      const getMenuMode = computed(() => {
+        return unref(getSplit) ? MenuModeEnum.HORIZONTAL : null;
+      });
+
+      // /**
+      //  * 首页多租户部门弹窗逻辑
+      //  */
+      const loginSelectRef = ref();
+
+      function showLoginSelect() {
+        //update-begin---author:liusq  Date:20220101  for:判断登录进来是否需要弹窗选择租户----
+        //判断是否是登陆进来
+        const loginInfo = toRaw(userStore.getLoginInfo) || {};
+        if (!!loginInfo.isLogin) {
+          loginSelectRef.value.show(loginInfo);
+        }
+        //update-end---author:liusq  Date:20220101  for:判断登录进来是否需要弹窗选择租户----
       }
-      const settingButtonPosition = unref(getSettingButtonPosition);
 
-      if (settingButtonPosition === SettingButtonPositionEnum.AUTO) {
-        return unref(getShowHeader);
+      function loginSelectOk() {
+        console.log('成功。。。。。');
       }
-      return settingButtonPosition === SettingButtonPositionEnum.HEADER;
-    });
 
-    const getLogoWidth = computed(() => {
-      if (!unref(getIsMixMode) || unref(getIsMobile)) {
-        return {};
-      }
-      const width = unref(getMenuWidth) < 180 ? 180 : unref(getMenuWidth);
-      return { width: `${width}px` };
-    });
-
-    const getSplitType = computed(() => {
-      return unref(getSplit) ? MenuSplitTyeEnum.TOP : MenuSplitTyeEnum.NONE;
-    });
-
-    const getMenuMode = computed(() => {
-      return unref(getSplit) ? MenuModeEnum.HORIZONTAL : null;
-    });
-
-    // /**
-    //  * 首页多租户部门弹窗逻辑
-    //  */
-    const loginSelectRef = ref();
-
-    function showLoginSelect() {
-      //update-begin---author:liusq  Date:20220101  for:判断登录进来是否需要弹窗选择租户----
-      //判断是否是登陆进来
-      const loginInfo = toRaw(userStore.getLoginInfo) || {};
-      if (!!loginInfo.isLogin) {
-        loginSelectRef.value.show(loginInfo);
-      }
-      //update-end---author:liusq  Date:20220101  for:判断登录进来是否需要弹窗选择租户----
-    }
+      // 用户下拉框应该在以下情况中隐藏:
+      // 1. 本页面是由其他页面的 iframe 嵌入的页面
+      const showUserDropdown = computed(() => {
+        return window.self === window.top;
+      });
 
-    function loginSelectOk() {
-      console.log('成功。。。。。');
-    }
+      onMounted(() => {
+        showLoginSelect();
+      });
 
-    // 用户下拉框应该在以下情况中隐藏:
-    // 1. 本页面是由其他页面的 iframe 嵌入的页面
-    const showUserDropdown = computed(() => {
-      return window.self === window.top;
-    });
-
-    onMounted(() => {
-      showLoginSelect();
-    });
-
-    return {
-      prefixCls,
-      getHeaderClass,
-      getShowHeaderLogo,
-      getHeaderTheme,
-      getShowHeaderTrigger,
-      getIsMobile,
-      getShowBreadTitle,
-      getShowBread,
-      getShowContent,
-      getSplitType,
-      getSplit,
-      getMenuMode,
-      getShowTopMenu,
-      getShowLocalePicker,
-      getShowFullScreen,
-      getShowNotice,
-      getUseErrorHandle,
-      getLogoWidth,
-      getIsMixSidebar,
-      getShowSettingButton,
-      getShowSetting,
-      getShowSearch,
-      getUseLockPage,
-      loginSelectOk,
-      loginSelectRef,
-      currentRoute,
-      title,
-      getShowFullHeader,
-      noHeadeLink,
-      showUserDropdown,
-      sysOrgCode,
-      homePath,
-    };
-  },
-});
+      return {
+        prefixCls,
+        getHeaderClass,
+        getShowHeaderLogo,
+        getHeaderTheme,
+        getShowHeaderTrigger,
+        getIsMobile,
+        getShowBreadTitle,
+        getShowBread,
+        getShowContent,
+        getSplitType,
+        getSplit,
+        getMenuMode,
+        getShowTopMenu,
+        getShowLocalePicker,
+        getShowFullScreen,
+        getShowNotice,
+        getUseErrorHandle,
+        getLogoWidth,
+        getIsMixSidebar,
+        getShowSettingButton,
+        getShowSetting,
+        getShowSearch,
+        getUseLockPage,
+        loginSelectOk,
+        loginSelectRef,
+        currentRoute,
+        title,
+        getShowFullHeader,
+        noHeadeLink,
+        showUserDropdown,
+        sysOrgCode,
+        homePath,
+        hasPermission,
+      };
+    },
+  });
 </script>
 <style lang="less">
-@import './index.less';
-//update-begin---author:scott ---date:2022-09-30  for:默认隐藏顶部菜单面包屑-----------
-//顶部欢迎语展示样式
-@prefix-cls: ~'@{namespace}-layout-header';
-
-.@{prefix-cls} {
-  display: flex;
-  padding: 0 8px;
-  // align-items: center;
-
-  .headerIntroductionClass {
-    margin-right: 4px;
-    margin-bottom: 2px;
-    border-bottom: 0px;
-    border-left: 0px;
-  }
+  @import './index.less';
+  //update-begin---author:scott ---date:2022-09-30  for:默认隐藏顶部菜单面包屑-----------
+  //顶部欢迎语展示样式
+  @prefix-cls: ~'@{namespace}-layout-header';
+
+  .@{prefix-cls} {
+    display: flex;
+    padding: 0 8px;
+    // align-items: center;
 
-  &--light {
     .headerIntroductionClass {
-      color: @breadcrumb-item-normal-color;
+      margin-right: 4px;
+      margin-bottom: 2px;
+      border-bottom: 0px;
+      border-left: 0px;
     }
-  }
 
-  &--dark {
-    .headerIntroductionClass {
-      color: rgba(255, 255, 255, 0.6);
+    &--light {
+      .headerIntroductionClass {
+        color: @breadcrumb-item-normal-color;
+      }
     }
 
-    .anticon {
-      color: rgba(255, 255, 255, 0.8);
+    &--dark {
+      .headerIntroductionClass {
+        color: rgba(255, 255, 255, 0.6);
+      }
+
+      .anticon {
+        color: rgba(255, 255, 255, 0.8);
+      }
     }
+
+    //update-end---author:scott ---date::2022-09-30  for:默认隐藏顶部菜单面包屑--------------
   }
 
-  //update-end---author:scott ---date::2022-09-30  for:默认隐藏顶部菜单面包屑--------------
-}
-
-// background: linear-gradient(#003f77, #0a134c);
-//   // background: linear-gradient(#02050c 0%, #03114c 100%);
-//   // border: none;
-//   border-bottom: 1px solid #81aabf01;
-//   padding-bottom: 2px;
-//   box-shadow: 0 0 20px #44caff55 inset;
-.normal-header {
-  height: 52px !important;
-  line-height: 52px !important;
-  background: var(--vent-header-bg-color) !important;
-  // background: linear-gradient(#005177,#0a344c) !important;
-  border-bottom: 1px solid #81aabf01 !important;
-  padding-bottom: 2px !important;
-  box-shadow: 0 0 20px #44caff55 inset !important;
-  padding: 0 8px !important;
-}
-
-.no-header {
-  height: 0px !important;
-  display: none !important;
-}
-
-.header-nav-title {
-  background-image: linear-gradient(#ffffff 50%, #60f4ff);
-  -webkit-background-clip: text;
-  color: transparent;
-  font-weight: 600;
-}
+  // background: linear-gradient(#003f77, #0a134c);
+  //   // background: linear-gradient(#02050c 0%, #03114c 100%);
+  //   // border: none;
+  //   border-bottom: 1px solid #81aabf01;
+  //   padding-bottom: 2px;
+  //   box-shadow: 0 0 20px #44caff55 inset;
+  .normal-header {
+    height: 52px !important;
+    line-height: 52px !important;
+    background: var(--vent-header-bg-color) !important;
+    // background: linear-gradient(#005177,#0a344c) !important;
+    border-bottom: 1px solid #81aabf01 !important;
+    padding-bottom: 2px !important;
+    box-shadow: 0 0 20px #44caff55 inset !important;
+    padding: 0 8px !important;
+  }
+
+  .no-header {
+    height: 0px !important;
+    display: none !important;
+  }
+
+  .header-nav-title {
+    background-image: linear-gradient(#ffffff 50%, #60f4ff);
+    -webkit-background-clip: text;
+    color: transparent;
+    font-weight: 600;
+  }
 </style>

+ 1 - 1
src/utils/http/axios/index.ts

@@ -46,7 +46,7 @@ const transform: AxiosTransform = {
     const { data } = res;
     if (!data) {
       // return '[HTTP] Request has no return value';
-      throw new Error(t('sys.api.apiRequestFailed'));
+      // throw new Error(t('sys.api.apiRequestFailed'));
     }
     //  这里 code,result,message为 后台统一的字段,需要在 types.ts内修改为项目自己的接口返回格式
     if (data.result) {

+ 1 - 1
src/views/vent/monitorManager/gateMonitor/modal.vue

@@ -5,7 +5,7 @@
         <ExclamationCircleFilled style="color: #ffb700; font-size: 30px" />
         <div class="warning-text">您是否要进行{{ title }}操作?</div>
       </div>
-      <div v-if="type == '10'">
+      <div v-if="type == '10' || type == '11'">
         <div class="vent-flex-row input-box">
           <div class="label">风窗开启角度:</div>
           <a-input-number size="small" placeholder="0" :min="0" v-model:value="value" />

+ 5 - 5
src/views/vent/monitorManager/windowMonitor/components/modal.vue

@@ -5,15 +5,15 @@
         <ExclamationCircleFilled style="color: #ffb700; font-size: 30px" />
         <div class="warning-text">您是否要进行{{ title }}操作?</div>
       </div>
-      <template
+      <!-- <template
         v-if="type == '1' || type == '2' || type.startsWith('sameSetValue') || type.startsWith('middleSetValue') || type.startsWith('rearSetValue')"
       >
         <div class="vent-flex-row input-box">
           <div class="label">{{ title.includes('角度') ? '风窗角度:' : '风窗面积:' }}</div>
           <a-input-number size="small" placeholder="0" :min="0" v-model:value="data" />
         </div>
-      </template>
-      <template v-else-if="type == '7'">
+      </template> -->
+      <template v-if="type == '7'">
         <div class="vent-flex-row input-box">
           <div class="label">风窗目标风量(m³/min):</div>
           <a-input-number size="small" placeholder="0" :min="0" v-model:value="data" />
@@ -31,12 +31,12 @@
           <a-input-number size="small" placeholder="0" :min="0" v-model:value="data" />
         </div>
       </template>
-      <template v-else-if="type.startsWith('frontSetValue')">
+      <!-- <template v-else-if="type.startsWith('frontSetValue')">
         <div class="vent-flex-row input-box">
           <div class="label">风窗角度:</div>
           <a-input-number size="small" placeholder="0" :min="0" v-model:value="data" />
         </div>
-      </template>
+      </template> -->
       <template v-else-if="type.startsWith('air')">
         <div class="vent-flex-row input-box">
           <div class="label">风窗过风量(m³/min):</div>

+ 2 - 2
src/views/vent/monitorManager/windowMonitor/shuangdaoFcHj.threejs.ts

@@ -177,8 +177,8 @@ class sdFc_4 {
       const meshArr04: THREE.Mesh[] = [JuanLian4];
       this.windowsActionArr.frontWindow1 = meshArr01;
       this.windowsActionArr.frontWindow2 = meshArr02;
-      this.windowsActionArr.backWindow1 = meshArr03;
-      this.windowsActionArr.backWindow2 = meshArr04;
+      this.windowsActionArr.backWindow1 = meshArr04;
+      this.windowsActionArr.backWindow2 = meshArr03;
     }
   }