libushang пре 3 месеци
родитељ
комит
2b244d79c8

+ 0 - 1
src/types/auto-imports.d.ts

@@ -43,7 +43,6 @@ declare global {
   const getCurrentInstance: typeof import('vue')['getCurrentInstance']
   const getCurrentScope: typeof import('vue')['getCurrentScope']
   const h: typeof import('vue')['h']
-  const iconFeature: typeof import('~icons/fe/ature')['default']
   const ignorableWatch: typeof import('@vueuse/core')['ignorableWatch']
   const inject: typeof import('vue')['inject']
   const injectLocal: typeof import('@vueuse/core')['injectLocal']

+ 17 - 1
src/types/components.d.ts

@@ -21,6 +21,7 @@ declare module 'vue' {
     ElBreadcrumb: typeof import('element-plus/es')['ElBreadcrumb']
     ElBreadcrumbItem: typeof import('element-plus/es')['ElBreadcrumbItem']
     ElButton: typeof import('element-plus/es')['ElButton']
+    ElCard: typeof import('element-plus/es')['ElCard']
     ElCheckbox: typeof import('element-plus/es')['ElCheckbox']
     ElCol: typeof import('element-plus/es')['ElCol']
     ElColorPicker: typeof import('element-plus/es')['ElColorPicker']
@@ -37,22 +38,34 @@ declare module 'vue' {
     ElIcon: typeof import('element-plus/es')['ElIcon']
     ElImage: typeof import('element-plus/es')['ElImage']
     ElInput: typeof import('element-plus/es')['ElInput']
+    ElLink: typeof import('element-plus/es')['ElLink']
     ElMenu: typeof import('element-plus/es')['ElMenu']
     ElMenuItem: typeof import('element-plus/es')['ElMenuItem']
     ElOption: typeof import('element-plus/es')['ElOption']
     ElPagination: typeof import('element-plus/es')['ElPagination']
+    ElPopover: typeof import('element-plus/es')['ElPopover']
+    ElRadio: typeof import('element-plus/es')['ElRadio']
+    ElRadioGroup: typeof import('element-plus/es')['ElRadioGroup']
     ElRow: typeof import('element-plus/es')['ElRow']
     ElScrollbar: typeof import('element-plus/es')['ElScrollbar']
     ElSelect: typeof import('element-plus/es')['ElSelect']
     ElSkeleton: typeof import('element-plus/es')['ElSkeleton']
     ElSkeletonItem: typeof import('element-plus/es')['ElSkeletonItem']
     ElSlider: typeof import('element-plus/es')['ElSlider']
+    ElStep: typeof import('element-plus/es')['ElStep']
+    ElSteps: typeof import('element-plus/es')['ElSteps']
     ElSubMenu: typeof import('element-plus/es')['ElSubMenu']
     ElSwitch: typeof import('element-plus/es')['ElSwitch']
+    ElTable: typeof import('element-plus/es')['ElTable']
+    ElTableColumn: typeof import('element-plus/es')['ElTableColumn']
+    ElTabPane: typeof import('element-plus/es')['ElTabPane']
+    ElTabs: typeof import('element-plus/es')['ElTabs']
     ElText: typeof import('element-plus/es')['ElText']
     ElTimeline: typeof import('element-plus/es')['ElTimeline']
     ElTimelineItem: typeof import('element-plus/es')['ElTimelineItem']
+    ElTooltip: typeof import('element-plus/es')['ElTooltip']
     ElTree: typeof import('element-plus/es')['ElTree']
+    ElTreeSelect: typeof import('element-plus/es')['ElTreeSelect']
     ElUpload: typeof import('element-plus/es')['ElUpload']
     FileUpload: typeof import('./../components/FileUpload/index.vue')['default']
     FooterSection: typeof import('./../components/FooterSection/index.vue')['default']
@@ -63,6 +76,7 @@ declare module 'vue' {
     HikvisionPlayer: typeof import('./../components/HKVideo/hikvision-player.vue')['default']
     HKVideo: typeof import('./../components/HKVideo/index.vue')['default']
     IconSelect: typeof import('./../components/IconSelect/index.vue')['default']
+    IEpUploadFilled: typeof import('~icons/ep/upload-filled')['default']
     IFrame: typeof import('./../components/iFrame/index.vue')['default']
     ImagePreview: typeof import('./../components/ImagePreview/index.vue')['default']
     ImageUpload: typeof import('./../components/ImageUpload/index.vue')['default']
@@ -99,7 +113,9 @@ declare module 'vue' {
     VideoContainer2: typeof import('./../components/HKVideo/video-container2.vue')['default']
     VideoTagEdit: typeof import('./../components/VideoTagEdit/index.vue')['default']
     YMap: typeof import('./../components/Map/YMap.vue')['default']
-    YMapold: typeof import('./../components/Map/YMapold.vue')['default']
     YztMap: typeof import('./../components/Map/YztMap/index.vue')['default']
   }
+  export interface ComponentCustomProperties {
+    vLoading: typeof import('element-plus/es')['ElLoadingDirective']
+  }
 }

+ 81 - 32
src/views/emergencyCommandMap/LeftSection/Communication.vue

@@ -91,7 +91,7 @@
           <div class="icon2"></div>
           <div class="text">电话呼叫</div>
         </div>
-        <div class="btn" @click="handleStartMeeting">
+        <div class="btn" @click="handleOpenMeeting">
           <div class="icon3"></div>
           <div class="text">发起会议</div>
         </div>
@@ -102,6 +102,19 @@
     
     <IndividualEquipment v-show="activeIndex === 2"></IndividualEquipment>
 
+    <Dialog v-if="showOpenMeeting" custom-show type="xs" height="660px" title="发起会议" @confirm="handleStartMeeting" @close="closeOpenDialog">
+      <el-form ref="form2Ref" :model="openMeetingForm" :rules="rules2">
+        
+        <el-form-item label="账号" label-width="200px" prop="username">
+          <el-input v-model="openMeetingForm.username" class="custom-input2" clearable placeholder="请输入设备账号" />
+        </el-form-item>
+
+        <el-form-item label="密码" label-width="200px" prop="userpass">
+          <el-input v-model="openMeetingForm.userpass" type="password" class="custom-input2" clearable placeholder="请输入设备密码" />
+        </el-form-item>
+      </el-form>
+    </Dialog>
+
     <Dialog v-if="showJoinMeeting" custom-show type="xs" height="760px" title="加入会议" @confirm="handleJoinMeeting" @close="closeDialog">
       <el-form ref="formRef" :model="meetingForm" :rules="rules">
         
@@ -114,7 +127,7 @@
         </el-form-item>
 
         <el-form-item label="密码" label-width="200px" prop="userpass">
-          <el-input v-model="meetingForm.userpass" class="custom-input2" clearable placeholder="请输入设备密码" />
+          <el-input v-model="meetingForm.userpass" type="password" class="custom-input2" clearable placeholder="请输入设备密码" />
         </el-form-item>
       </el-form>
     </Dialog>
@@ -242,6 +255,7 @@ const rules = reactive({
   username: [{ required: true, message: '会议账号不能为空', trigger: 'blur' }],
   userpass: [{ required: true, message: '会议密码不能为空', trigger: 'blur' }]
 });
+
 // 点击会议号入会
 const showJoinMeetingDialog = () => {
   showJoinMeeting.value = true;
@@ -250,6 +264,24 @@ const closeDialog = () => {
   showJoinMeeting.value = false;
   meetingForm.roomcode = '';
 };
+///////////////////
+let form2Ref = ref();
+let showOpenMeeting = ref(false);
+let openMeetingForm = reactive({
+  username: '',
+  userpass: ''
+});
+const rules2 = reactive({
+  username: [{ required: true, message: '会议账号不能为空', trigger: 'blur' }],
+  userpass: [{ required: true, message: '会议密码不能为空', trigger: 'blur' }]
+});
+const handleOpenMeeting = () => {
+  showOpenMeeting.value = true;
+};
+const closeOpenDialog = () => {
+  showOpenMeeting.value = false;
+};
+
 // 会议号入会
 const handleJoinMeeting = () => {
   formRef.value?.validate((valid) => {
@@ -270,8 +302,9 @@ const handleJoinMeeting = () => {
         // 触发点击事件
         a.click();
 
-        // 保存账号和密码,待加入相关代码
-        // ....
+        // 保存账号和密码
+        localStorage.setItem('meeting_username', meetingForm.username)
+        localStorage.setItem('meeting_userpass', meetingForm.userpass)
       });
       closeDialog();
     }
@@ -313,37 +346,53 @@ const handleStartCall = () => {
 
 // 发起会议
 const handleStartMeeting = () => {
-  let dev_list = [];
-  userList.value.forEach((item) => {
-    if (item.checked && item.mobile != '') {
-      dev_list.push({ id: item.mobile, avtype: 'av' }); // a 音频 v 视频 默认 av
-    }
-  });
-  if (dev_list.length == 0) {
-    proxy?.$modal.msgError('请勾选人员');
-    return false;
-  }
-  const screenWidth = window.screen.width * window.devicePixelRatio;
-  const screenHeight = window.screen.height * window.devicePixelRatio;
-  const data = {
-    'userid': 'mmyj0009', // 空表示后台获取当前用户对应融合通信dev_id
-    'password': '',
-    windowpos: { 'x': 0, 'y': 0, 'width': screenWidth, 'height': screenHeight, 'top': true },
-    members: {
-      num: dev_list.length + 2, // 配置多少个座位,一般就是邀请人多少个就多少个
-      'dev-list': dev_list
+  form2Ref.value?.validate((valid) => {
+    if (valid) {
+      let dev_list = [];
+      userList.value.forEach((item) => {
+        if (item.checked && item.mobile != '') {
+          dev_list.push({ id: item.mobile, avtype: 'av' }); // a 音频 v 视频 默认 av
+        }
+      });
+      if (dev_list.length == 0) {
+        proxy?.$modal.msgError('请勾选人员');
+        return false;
+      }
+      const screenWidth = window.screen.width * window.devicePixelRatio;
+      const screenHeight = window.screen.height * window.devicePixelRatio;
+      const data = {
+        'userid': openMeetingForm.username, // 空表示后台获取当前用户对应融合通信dev_id
+        'password': openMeetingForm.userpass,
+        windowpos: { 'x': 0, 'y': 0, 'width': screenWidth, 'height': screenHeight, 'top': true },
+        members: {
+          num: dev_list.length + 2, // 配置多少个座位,一般就是邀请人多少个就多少个
+          'dev-list': dev_list
+        }
+      };
+      getStartMiniParam(data).then((res) => {
+        // 创建一个a标签元素
+        const a = document.createElement('a');
+        // 设置a标签的href属性
+        a.href = res.data;
+        // 触发点击事件
+        a.click();
+        
+        // 保存账号和密码
+        localStorage.setItem('meeting_username', openMeetingForm.username)
+        localStorage.setItem('meeting_userpass', openMeetingForm.userpass)
+      });
+      closeOpenDialog();
     }
-  };
-  getStartMiniParam(data).then((res) => {
-    // 创建一个a标签元素
-    const a = document.createElement('a');
-    // 设置a标签的href属性
-    a.href = res.data;
-    // 触发点击事件
-    a.click();
-  });
+  })
 };
 onMounted(() => {
+  const meeting_username = localStorage.getItem('meeting_username') || "";
+  const meeting_userpass = localStorage.getItem('meeting_userpass') || "";
+  meetingForm.username = meeting_username;
+  meetingForm.userpass = meeting_userpass;
+  openMeetingForm.username = meeting_username;
+  openMeetingForm.userpass = meeting_userpass;
+
   getTree();
 });
 </script>

+ 1 - 1
src/views/emergencyCommandMap/LeftSection/Drone.vue

@@ -29,7 +29,7 @@ interface QueryParams {
   equipment: string;
 }
 const queryParams = reactive<QueryParams>({
-  equipment: ''
+  equipment: '无人机'
 });
 const getTree = () => {
   getDroneTree(queryParams).then((res) => {

+ 2 - 2
src/views/emergencyCommandMap/LeftSection/IndividualEquipment.vue

@@ -24,13 +24,13 @@
 
 <script setup lang="ts">
 import { Search } from '@element-plus/icons-vue';
-import { getAvconDeptTree } from '@/api/emergencyCommandMap/communication';
+// import { getAvconDeptTree } from '@/api/emergencyCommandMap/communication';
 import { getDroneTree } from '@/api/emergencyCommandMap/Drone';
 interface QueryParams {
   equipment: string;
 }
 const queryParams = reactive<QueryParams>({
-  equipment: ''
+  equipment: '单兵设备'
 });
 
 const treeData = ref([]);