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

Merge branch 'master' of http://47.94.222.6:3003/lizuo/VentSystem_2.0_front

lxh пре 1 година
родитељ
комит
0d22612704

+ 2 - 2
src/components/Table/src/components/editable/EditableCell.vue

@@ -112,8 +112,8 @@
 
         return {
           size: 'small',
-          getPopupContainer: () => unref(table?.wrapRef.value) ?? document.body,
-          getCalendarContainer: () => unref(table?.wrapRef.value) ?? document.body,
+          // getPopupContainer: () => unref(table?.wrapRef.value) ?? document.body,
+          // getCalendarContainer: () => unref(table?.wrapRef.value) ?? document.body,
           placeholder: createPlaceholderMessage(unref(getComponent)),
           ...apiSelectProps,
           ...omit(compProps, 'onChange'),

+ 1 - 1
src/layouts/default/header/index.vue

@@ -38,7 +38,7 @@
       </div>
     </div>
   </Header>
-  <div v-else-if="currentRoute.path !== '/micro-vent-3dModal/dashboard/analysis'" :class="`${prefixCls}-action`"  style="position: fixed; top: 30px; right: 20px; z-index: 999;">
+  <div v-else-if="currentRoute.path !== '/micro-vent-3dModal/dashboard/analysis' && !currentRoute.path.startsWith('micro-need-air')" :class="`${prefixCls}-action`"  style="position: fixed; top: 30px; right: 20px; z-index: 999;">
     <div class="right-position">
       <UserDropDown :theme="getHeaderTheme" />
     </div>

+ 1 - 1
src/views/vent/comment/EditRowTable.vue

@@ -12,7 +12,7 @@
   </div>
 </template>
 <script lang="ts">
-  import { defineComponent, ref, nextTick, onMounted } from 'vue';
+  import { defineComponent, ref, nextTick } from 'vue';
   import { BasicTable, useTable, TableAction, BasicColumn, ActionItem, EditRecordRow } from '/@/components/Table';
   import { useMessage } from '/@/hooks/web/useMessage';
   // import { nextTick } from 'process';

+ 11 - 9
src/views/vent/deviceManager/comment/NormalTable.vue

@@ -1,11 +1,11 @@
 <template>
-  <div>
+  <div style="position: fixed;">
     <BasicTable @register="registerTable" :rowSelection="rowSelection">
       <template #tableTitle>
         <a-button preIcon="ant-design:plus-outlined" type="primary" @click="handleAdd">新增</a-button>
         <a-button type="primary" preIcon="ant-design:export-outlined" @click="onExportXls"> 导出</a-button>
         <j-upload-button type="primary" preIcon="ant-design:import-outlined" @click="onImportXls">导入</j-upload-button>
-        <a-dropdown v-if="selectedRowKeys.length > 0">
+        <a-dropdown v-if="selectedRowKeys.length > 0" :getPopupContainer="getPopupContainer">
           <template #overlay>
             <a-menu>
               <a-menu-item key="1" @click="batchHandleDelete">
@@ -20,8 +20,8 @@
           </a-button>
         </a-dropdown>
       </template>
-      <template #action="{ record }">
-        <TableAction :actions="getActions(record)" :dropDownActions="getDropDownAction(record)" />
+      <template #action="{ record, column }">
+        <TableAction :actions="getActions(record, column)" />
       </template>
       <template #bodyCell="{ column, record }">
         <slot name="filterCell" v-bind="{ column, record }"></slot>
@@ -34,13 +34,14 @@
 <script lang="ts" name="system-user" setup>
   //ts语法
   import { ref, provide, reactive, toRaw, defineExpose } from 'vue';
-  import { BasicTable, TableAction } from '/@/components/Table';
+  import { BasicTable, TableAction, ActionItem, EditRecordRow, BasicColumn } from '/@/components/Table';
   import { useModal } from '/@/components/Modal';
   import DeviceModal from './DeviceModal.vue';
   // import { getToken } from '/@/utils/auth';
   // import { useGlobSetting } from '/@/hooks/setting';
   import { getTableHeaderColumns } from '/@/hooks/web/useWebColumns';
   import { useListPage } from '/@/hooks/system/useListPage';
+  import { getPopupContainer } from '/@/utils';
 
   const props = defineProps({
     columnsType: {
@@ -212,21 +213,21 @@
    * 操作列定义
    * @param record
    */
-  function getActions(record) {
+  function getActions(record: EditRecordRow, column: BasicColumn): ActionItem[]  {
     return [
       {
         label: '编辑',
-        onClick: handleEdit.bind(null, record),
+        onClick: handleEdit.bind(null, record, column),
       },
       {
         label: '删除',
         popConfirm: {
           title: '是否确认删除',
-          confirm: handleDelete.bind(null, record),
+          confirm: handleDelete.bind(null, record, column),
         },
       },
       // {
-      //   label: '查看',
+      //   label: '查看',wss
       //   onClick: handleDetail.bind(null, record),
       // },
     ];
@@ -249,6 +250,7 @@
       // },
     ];
   }
+
   defineExpose({
     doRequest,
   });

+ 3 - 0
src/views/vent/monitorManager/deviceMonitor/device.api.ts

@@ -4,6 +4,7 @@ enum Api {
   list = '/monitor/device',
   baseList = '/safety/ventanalyDeviceInfo/list',
   deviceTypeList = '/safety/ventanalyDeviceInfo/DeviceKind/query',
+  itemList = '/sys/dictItem/list',
 }
 /**
  * 列表接口
@@ -18,3 +19,5 @@ export const list = (params) => defHttp.post({ url: Api.list, params });
 export const getDeviceList = (params) => defHttp.get({ url: Api.baseList, params });
 
 export const getDeviceTypeList = (params) => defHttp.get({ url: Api.deviceTypeList, params });
+
+export const itemList = (params) => defHttp.get({ url: Api.itemList, params });

+ 32 - 14
src/views/vent/monitorManager/deviceMonitor/index.vue

@@ -2,26 +2,26 @@
   <div class="scene-box" v-if="routerParam !== 'home'">
     <!-- <div class="scene-box"> -->
     <div class="device-header">智能通风管控系统</div>
-    <div class="select-node" :class="{ 'node-select-show': !treeShow, 'node-select-hide': treeShow, }">
-      <SvgIcon class="is-expansion-icon put-away-icon" size="38" name="expansion" @click="showTree('treeShow', true)" />
+    <div class="select-node" :class="{ 'node-select-show': !treeShow, 'node-select-hide': treeShow, }" @click="showTree('treeShow', true)">
+      <SvgIcon class="is-expansion-icon put-away-icon" size="38" name="expansion"  />
       <span class="title">{{ treeNodeTitle }}</span>
     </div>
-    <div class="device-select" :class="{ 'device-select-show': treeShow, 'device-select-hide': !treeShow, }">
-      <SvgIcon class="is-expansion-icon expansion-icon" size="28" name="put-away" @click="showTree('treeShow', false)" />
+    <div class="device-select" :class="{ 'device-select-show': treeShow, 'device-select-hide': !treeShow, }" >
+      <SvgIcon class="is-expansion-icon expansion-icon" size="28" name="put-away"  @click="showTree('treeShow', false)"/>
       <div class="device-select-box">
         <a-tree :show-line="true" :tree-data="treeData" v-model:selectedKeys="selectedKeys"
           v-model:expandedKeys="expandedKeys" @select="onSelect">
         </a-tree>
       </div>
     </div>
-    <div class="location-icon" :class="{  'location-btn-show': !locationSettingShow, 'location-btn-hide': locationSettingShow, }">
-      <SvgIcon size="18" name="put-away" @click="showTree('location', true)" />
+    <div class="location-icon" :class="{  'location-btn-show': !locationSettingShow, 'location-btn-hide': locationSettingShow, }" @click="showTree('location', true)" >
+      <SvgIcon size="18" name="put-away" />
       <span class="location-text">定位图标显示</span>
     </div>
     <div class="location-select" :class="{ 'location-select-show': locationSettingShow, 'location-select-hide': !locationSettingShow, }">
       <div class="location-select-box">
-        <div class="location-top-title" >
-          <SvgIcon class="is-expansion-icon location-expansion-icon" size="28" name="expansion" @click="showTree('location', false)" />
+        <div class="location-top-title" @click="showTree('location', false)">
+          <SvgIcon class="is-expansion-icon location-expansion-icon" size="28" name="expansion"  />
           <div class="title">定位图标显示</div>
         </div>
         <div class="location-container">
@@ -107,7 +107,7 @@
 import { ref, onMounted, onUnmounted, ComponentOptions, shallowRef, nextTick } from 'vue'
 import { SendOutlined } from '@ant-design/icons-vue';
 import { list, getDeviceList, getDeviceTypeList } from './device.api'
-import { locationList } from './device.data'
+// import { locationList } from './device.data'
 import AlarmHistoryTable from '../comment/AlarmHistoryTable.vue';
 import HistoryTable from '../comment/HistoryTable.vue';
 import HandlerHistoryTable from '../comment/HandlerHistoryTable.vue';
@@ -120,6 +120,7 @@ import DustModal from './modal/dust.modal.vue'
 import { SvgIcon } from '/@/components/Icon';
 import { getActions } from '/@/qiankun/state';
 import { useRouter } from 'vue-router';
+import { initDictOptions } from '/@/utils/dict/index';
 
 
 type DeviceType = { deviceType: string, deviceName: string, datalist: any[] };
@@ -135,6 +136,7 @@ const alarmHistoryTable = ref()
 const handlerHistoryTable = ref()
 
 const routerParam = ref('home') // 默认进来时首页
+
 // 模态框
 const currentModal = shallowRef<Nullable<ComponentOptions>>(null); //模态框
 const modalVisible = ref<Boolean>(false); // 模态框是否可见
@@ -145,6 +147,7 @@ const treeShow = ref(true) //是否显示树形菜单
 const locationSettingShow = ref(false) //是否显示树形菜单
 const treeNodeTitle = ref('') // 选中的树形标题
 
+const locationList = ref([])
 const deviceList = ref<DeviceType[]>([])
 const deviceActive = ref('')
 const activeKey = ref('1'); // tab key
@@ -335,6 +338,18 @@ function goDetail(record?) {
     } else if (deviceType.value.indexOf("fanlocal") != -1) {
       const newPage = router.resolve({ path: '/monitorChannel/monitor-fan-local' })
       window.open(newPage.href, '_blank')
+    } else if (deviceType.value.indexOf("nitrogen") != -1) {
+      const newPage = router.resolve({ path: '/compressor-home' })
+      window.open(newPage.href, '_blank')
+    } else if (deviceType.value.indexOf("pulping") != -1) {
+      const newPage = router.resolve({ path: '/grout-home' })
+      window.open(newPage.href, '_blank')
+    } else if (deviceType.value.indexOf("pressurefan") != -1) {
+      const newPage = router.resolve({ path: '/nitrogen/home' })
+      window.open(newPage.href, '_blank')
+    } else if (deviceType.value.indexOf("chamber") != -1) {
+      const newPage = router.resolve({ path: '/chamber-home' })
+      window.open(newPage.href, '_blank')
     } else {
       message.info('待开发。。。')
     }
@@ -425,6 +440,8 @@ onMounted(async () => {
     }
   })
   await getDeviceType()
+  locationList.value = await initDictOptions('devPosVisible')
+  console.log('定位列表------------>', locationList.value)
   // getMonitor()
 })
 onUnmounted(() => {
@@ -435,6 +452,7 @@ onUnmounted(() => {
 })
 
 </script>
+
 <style lang="less" scoped >
 @import '/@/design/vent/modal.less';
 @ventSpace: zxm;
@@ -730,15 +748,15 @@ onUnmounted(() => {
     background: url('/@/assets/images/vent/home/tosmall.png') no-repeat center;
     background-size: auto;
     position: absolute;
-    top: -65px;
-    right: 30px;
+    top: -62px;
+    right: 36px;
     border-radius: 10px;
     padding: 8px;
     backdrop-filter: blur(10px);
-    background-color: rgba(0, 58, 128, 0.418);
+    background-color: rgba(45, 86, 137, 0.418);
 
     &:hover {
-      background-color: rgba(42, 85, 138, 0.418);
+      background-color: rgba(79, 104, 134, 0.418);
     }
   }
 
@@ -815,7 +833,7 @@ onUnmounted(() => {
     cursor: pointer;
     position: absolute;
     right: 120px;
-    top: -10px;
+    top: -6px;
     padding: 5px;
     // border: 1px transparent solid;
     border-radius: 5px;

+ 3 - 5
src/views/vent/monitorManager/windowMonitor/index.vue

@@ -252,7 +252,6 @@
 
   // 判断前后窗的面积是否发生改变,如果改变则开启动画
   const playAnimation = (data, maxarea = 90, isFirst = false) => {
-    maxarea = 90
     rotationParam.frontDeg0 = (90 / maxarea) * Number(isFirst ? 0 : selectData.forntArea);
     rotationParam.backDeg0 = (90 / maxarea) * Number(isFirst ? 0 : selectData.rearArea);
     rotationParam.frontDeg1 = (90 / maxarea) * Number(data.forntArea) || 0;
@@ -260,7 +259,7 @@
     if (isFirst) {
       console.log('最大面积---->', maxarea, '前窗实际面积---->', selectData.forntArea, '后窗实际面积---->', selectData.rearArea, '计算的值---->', rotationParam);
     }
-
+    console.log('最大面积---->', maxarea, '前窗实际面积---->', selectData.forntArea, '后窗实际面积---->', selectData.rearArea, '计算的值---->', rotationParam);
     if (!rotationParam.frontDeg1 && !rotationParam.backDeg1) {
       // 当返回值有误时默认关闭
       play(rotationParam, 0);
@@ -303,9 +302,8 @@
       value: windowAngle.value,
     };
     deviceControlApi(data)
-      .then((res) => {
-        if (res.success) {
-        }
+      .then(() => {
+        message.success('设置成功')
       })
       .finally(() => {
         handleCancel();

+ 1 - 1
src/views/vent/performance/comment/DeviceModal.vue

@@ -49,7 +49,7 @@
       {
         type: 'desktop',
         width: '100%',
-        height: '500px',
+        height: '100%',
         document: {
           title: '文档管理',
           url: 'http://47.94.222.6:9999/ventanaly-sharefile/fileServer/onlyOffice/read?id=' + props.editID, //id表示文件id,后端接口用这个id来加载文件

+ 56 - 11
src/views/vent/performance/fileDetail/index.vue

@@ -1,5 +1,6 @@
 <template>
   <div class="file-details">
+    <customHeader >文件共享中心</customHeader>
     <div class="content">
       <div class="left-box">
         <!-- 左侧树菜单 -->
@@ -41,14 +42,14 @@
     </div>
     <!-- 上传谈弹窗 -->
     <a-modal v-model:visible="visible" centered :width="600" title="上传文件" @ok="handleOk" @cancel="handleCancel">
-      <a-form :model="formState" labelAlign="right" :label-col="{ span: 6 }" :wrapper-col="{ span: 18 }">
+      <a-form :model="formState" labelAlign="right" :label-col="{ span: 6 }" :wrapper-col="{ span: 16 }">
         <a-form-item label="是否审批">
           <a-radio-group v-model:value="formState.isApprove">
             <a-radio :value="true">是</a-radio>
             <a-radio :value="false">否</a-radio>
           </a-radio-group>
         </a-form-item>
-        <a-form-item label="文件类型">
+        <a-form-item label="文件类型" >
           <JDictSelectTag v-model:value="formState.fileType" placeholder="请选择文件类型" dictCode="file_type"
             style="width: 500px;" />
         </a-form-item>
@@ -62,10 +63,10 @@
   </div>
 </template>
 <script lang="ts" setup name="system-user">
+import customHeader from '/@/views/vent/comment/components/customHeader.vue';
 import { useRouter } from 'vue-router';
 import { useMessage } from '/@/hooks/web/useMessage';
 import fileSystem from './commen/fileSystem.vue';
-import icon from './commen/Icon/index.vue';
 import { SvgIcon } from '/@/components/Icon';
 import treeIcon from './commen/Icon/treeIcon.vue';
 import { ref, onMounted, reactive, nextTick, watch } from 'vue';
@@ -191,11 +192,12 @@ const onClick = (node) => {
 //   console.log(node);
 // };
 //添加文件
-let onAddNode = async (node) => {
+const onAddNode = async (node) => {
   let data = await createFile({ fileName: node.newName, type: 'FOL', parentId: node.id });
   console.log(data, '新增文件返回');
   getTreeList();
 };
+
 //  修改名字
 const onChangeName = (node) => {
   console.log(node, '修改菜单名称');
@@ -261,25 +263,40 @@ let handleRemove = (file) => {
   newFileList.splice(index, 1);
   fileList = newFileList;
 };
-watch(() => router.currentRoute.value, (val) => {
-  console.log('各矿传参', val)
+watch(()=>router.currentRoute.value,(val)=>{
+  console.log('各矿传参',val)
   selfParam.bpmStatus = val.query.bpmStatus
   selfParam.sysOrgCode = val.query.sysOrgCode
   selfParam.flag = val.query.flag
-}, { immediate: true })
+},{immediate:true})
 onMounted(() => {
   getTreeList();
 });
 </script>
 
 <style lang="less" scoped>
+@ventSpace: zxm;
+
 .file-details {
-  width: 100%;
-  height: 100%;
+  width: calc(100% - 10px);
+  height: calc(100% - 100px);
   padding: 15px;
   position: relative;
+  margin-top: 100px;
   // background: url(../../../../assets/images/files/homes/bd.png) no-repeat center;
-
+  // background-size: contain;
+  
+  &::after{
+    display: block;
+    content: '';
+    height: 200px;
+    width: 100%;
+    position: absolute;
+    background-image: linear-gradient(  #2eb2ff05, #2EA2FF00);
+    border-top: 1px solid #2eb2ff20;
+    top: 0px;
+    left: 0px;
+  }
   .content {
     width: 100%;
     height: calc(100% - 30px);
@@ -287,6 +304,8 @@ onMounted(() => {
     flex-direction: row;
     justify-content: space-between;
     align-items: flex-start;
+    position: relative;
+    z-index: 999;
 
     .left-box {
       // width: 15%;
@@ -302,7 +321,7 @@ onMounted(() => {
       margin-bottom: 20px;
       padding: 20px;
       border: 1px solid #99e8ff66;
-      background: #27546e4a;
+      background: #27546e1a;
       box-shadow: 0px 0px 20px 7px rgba(145, 233, 254, 0.7) inset;
       -moz-box-shadow: 0px 0px 20px 7px rgba(145, 233, 254, 0.7) inset;
       -webkit-box-shadow: 0px 0px 50px 1px rgb(149 235 255 / 5%) inset;
@@ -405,6 +424,32 @@ onMounted(() => {
   color: #000;
 }
 
+:deep(.@{ventSpace}-table-cell-row-hover) {
+  background: #264d8833 !important;
+}
+:deep(.@{ventSpace}-table-row-selected) {
+  background: #268bc522 !important;
+}
+:deep(.@{ventSpace}-select-dropdown) {
+  border: 1px solid #ececec66;
+  background: #004362 !important;
+  left: 0px !important;
+  backdrop-filter: blur(50px);
+
+  .@{ventSpace}-select-item {
+    color: #fff !important;
+  }
+
+  .@{ventSpace}-select-item-option-selected,
+  .@{ventSpace}-select-item-option-active {
+    background-color: #00678b66 !important;
+  }
+  .@{ventSpace}-select-item:hover {
+    background-color: #008fc366 !important;
+  }
+}
+
+
 ::v-deep .zxm-form-item-control-input {
   width: 90%;
 }

+ 5 - 1
src/views/vent/performance/fileIndex/index.vue

@@ -1,5 +1,6 @@
 <template>
   <div class="performance">
+    <customHeader >文件共享中心</customHeader>
     <div class="main-container">
       <div class="card" v-for="(item, index) in titleList" :class="index === active ? 'actived' : 'isActived'"
         :key="index" @click="getDetails(index)">
@@ -17,10 +18,12 @@
 </template>
 <script lang="ts" setup>
 import { reactive, ref, onMounted } from 'vue';
+
 import { useRouter } from 'vue-router';
 import leftImg from '../../../../assets/images/files/homes/file.svg';
 import rightImg from '../../../../assets/images/files/homes/sp.svg';
 import { list } from './fileIndex.api';
+import customHeader from '/@/views/vent/comment/components/customHeader.vue';
 let router = useRouter(); //路由
 let active = ref(); //当前选中项
 let titleList = reactive<any[]>([]);
@@ -206,4 +209,5 @@ onMounted(() => {
       background-size: 100% 100%;
     }
   }
-}</style>
+}
+</style>