Parcourir la source

地图资源浏览页面

sujunling il y a 2 ans
Parent
commit
d159cee0ae

+ 1 - 1
.env.development

@@ -11,7 +11,7 @@ VITE_GLOB_PUBLIC_PATH = /
 # VITE_PROXY = [["/api","http://192.168.2.225/api"]]
 
 # 线上演示环境
-VITE_PROXY = [["/api","http://117.174.10.73:19200"],["/agent","http://117.174.10.73:31895"]]
+VITE_PROXY = [["/api","http://117.174.10.73:19200"],["/agent","http://117.174.10.73:31895"],["/iserver","http://221.182.8.141:15000/iserver"]]
                                                               
 # 线上测试环境
 # VITE_PROXY = [["/api","http://localhost:8080/api"],["/thingskit-drawio","http://localhost:3000/"]]

+ 2 - 1
.env.production

@@ -18,7 +18,8 @@ VITE_GLOB_DROP_CONSOLE = true
 # Whether to enable gzip or brotli compression
 # Optional: gzip | brotli | none
 # If you need multiple forms, you can use `,` to separate
-VITE_GLOB_BUILD_COMPRESS = 'gzip'
+# VITE_GLOB_BUILD_COMPRESS = 'gzip'
+VITE_GLOB_BUILD_COMPRESS = ''
 
 # Whether to delete origin files when using compress, default false
 VITE_GLOB_BUILD_COMPRESS_DELETE_ORIGIN_FILE = false

+ 166 - 174
index.html

@@ -1,177 +1,169 @@
 <!DOCTYPE html>
 <html lang="en" id="htmlRoot">
-  <head>
-    <meta charset="UTF-8" />
-    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
-    <meta name="renderer" content="webkit" />
-    <meta name="keywords" content="GIS数据支撑系统" />
-    <meta name="description" content="GIS数据支撑系统" />
-    <meta http-equiv="Expires" content="0" />
-    <meta http-equiv="Cache-control" content="no-cache" />
-    <meta http-equiv="Cache" content="no-cache" />
-    <meta
-      name="viewport"
-      content="width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,user-scalable=0"
-    />
-    <title>GIS数据支撑系统</title>
-    <link rel="icon" href="/favicon.ico" />
-    <script src="http://127.0.0.1:8080/onemapV5.0/plugin/jquery/jquery-1.11.3.js"></script>
-  </head>
-
-  <body>
-    <script>
-      (() => {
-        var htmlRoot = document.getElementById('htmlRoot');
-        var theme = window.localStorage.getItem('__APP__DARK__MODE__');
-        if (htmlRoot && theme) {
-          htmlRoot.setAttribute('data-theme', theme);
-          theme = htmlRoot = null;
-        }
-      })();
-    </script>
-    <div id="app">
-      <style>
-        html[data-theme='dark'] .app-loading {
-          background-color: #2c344a;
-        }
 
-        html[data-theme='dark'] .app-loading .app-loading-title {
-          color: rgba(255, 255, 255, 0.85);
-        }
-
-        .app-loading {
-          display: flex;
-          width: 100%;
-          height: 100%;
-          justify-content: center;
-          align-items: center;
-          flex-direction: column;
-          background-color: #f4f7f9;
-        }
-
-        .app-loading .app-loading-wrap {
-          position: absolute;
-          top: 50%;
-          left: 50%;
-          display: flex;
-          -webkit-transform: translate3d(-50%, -50%, 0);
-          transform: translate3d(-50%, -50%, 0);
-          justify-content: center;
-          align-items: center;
-          flex-direction: column;
-        }
-
-        .app-loading .dots {
-          display: flex;
-          padding: 98px;
-          justify-content: center;
-          align-items: center;
-        }
-
-        .app-loading .app-loading-title {
-          display: flex;
-          margin-top: 30px;
-          font-size: 30px;
-          color: rgba(0, 0, 0, 0.85);
-          justify-content: center;
-          align-items: center;
-        }
-
-        .app-loading .app-loading-logo {
-          display: block;
-          width: 90px;
-          margin: 0 auto;
-          margin-bottom: 20px;
-        }
-
-        .dot {
-          position: relative;
-          display: inline-block;
-          width: 48px;
-          height: 48px;
-          margin-top: 30px;
-          font-size: 32px;
-          transform: rotate(45deg);
-          box-sizing: border-box;
-          animation: antRotate 1.2s infinite linear;
-        }
-
-        .dot i {
-          position: absolute;
-          display: block;
-          width: 20px;
-          height: 20px;
-          background-color: #0065cc;
-          border-radius: 100%;
-          opacity: 0.3;
-          transform: scale(0.75);
-          animation: antSpinMove 1s infinite linear alternate;
-          transform-origin: 50% 50%;
-        }
-
-        .dot i:nth-child(1) {
-          top: 0;
-          left: 0;
-        }
-
-        .dot i:nth-child(2) {
-          top: 0;
-          right: 0;
-          -webkit-animation-delay: 0.4s;
-          animation-delay: 0.4s;
-        }
-
-        .dot i:nth-child(3) {
-          right: 0;
-          bottom: 0;
-          -webkit-animation-delay: 0.8s;
-          animation-delay: 0.8s;
-        }
-
-        .dot i:nth-child(4) {
-          bottom: 0;
-          left: 0;
-          -webkit-animation-delay: 1.2s;
-          animation-delay: 1.2s;
-        }
-
-        @keyframes antRotate {
-          to {
-            -webkit-transform: rotate(405deg);
-            transform: rotate(405deg);
-          }
-        }
-
-        @-webkit-keyframes antRotate {
-          to {
-            -webkit-transform: rotate(405deg);
-            transform: rotate(405deg);
-          }
-        }
-
-        @keyframes antSpinMove {
-          to {
-            opacity: 1;
-          }
-        }
-
-        @-webkit-keyframes antSpinMove {
-          to {
-            opacity: 1;
-          }
-        }
-      </style>
-      <!-- <div id="first-screen-loading" class="app-loading">
-        <div class="app-loading-wrap"> -->
-          <!-- <img src="/resource/img/logo.png" class="app-loading-logo" alt="Logo" /> -->
-          <!-- <div class="app-loading-dots">
-            <span class="dot dot-spin"><i></i><i></i><i></i><i></i></span>
-          </div> -->
-          <!-- <div class="app-loading-title"><%= title %></div> -->
-        <!-- </div>
-      </div> -->
-    </div>
-
-    <script type="module" src="/src/main.ts"></script>
-  </body>
-</html>
+<head>
+  <meta charset="UTF-8" />
+  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
+  <meta name="renderer" content="webkit" />
+  <meta name="keywords" content="GIS数据支撑系统" />
+  <meta name="description" content="GIS数据支撑系统" />
+  <meta http-equiv="Expires" content="0" />
+  <meta http-equiv="Cache-control" content="no-cache" />
+  <meta http-equiv="Cache" content="no-cache" />
+  <meta name="viewport"
+    content="width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,user-scalable=0" />
+  <title>GIS数据支撑系统</title>
+  <link rel="icon" href="/favicon.ico" />
+  <link rel="stylesheet" href="./static/css/portal.css">
+  <link rel="stylesheet" href="./static/css/boot.min.css">
+
+</head>
+
+<body>
+  <script>
+    (() => {
+      var htmlRoot = document.getElementById('htmlRoot');
+      var theme = window.localStorage.getItem('__APP__DARK__MODE__');
+      if (htmlRoot && theme) {
+        htmlRoot.setAttribute('data-theme', theme);
+        theme = htmlRoot = null;
+      }
+    })();
+  </script>
+  <div id="app">
+    <style>
+      html[data-theme='dark'] .app-loading {
+        background-color: #2c344a;
+      }
+
+      html[data-theme='dark'] .app-loading .app-loading-title {
+        color: rgba(255, 255, 255, 0.85);
+      }
+
+      .app-loading {
+        display: flex;
+        width: 100%;
+        height: 100%;
+        justify-content: center;
+        align-items: center;
+        flex-direction: column;
+        background-color: #f4f7f9;
+      }
+
+      .app-loading .app-loading-wrap {
+        position: absolute;
+        top: 50%;
+        left: 50%;
+        display: flex;
+        -webkit-transform: translate3d(-50%, -50%, 0);
+        transform: translate3d(-50%, -50%, 0);
+        justify-content: center;
+        align-items: center;
+        flex-direction: column;
+      }
+
+      .app-loading .dots {
+        display: flex;
+        padding: 98px;
+        justify-content: center;
+        align-items: center;
+      }
+
+      .app-loading .app-loading-title {
+        display: flex;
+        margin-top: 30px;
+        font-size: 30px;
+        color: rgba(0, 0, 0, 0.85);
+        justify-content: center;
+        align-items: center;
+      }
+
+      .app-loading .app-loading-logo {
+        display: block;
+        width: 90px;
+        margin: 0 auto;
+        margin-bottom: 20px;
+      }
+
+      .dot {
+        position: relative;
+        display: inline-block;
+        width: 48px;
+        height: 48px;
+        margin-top: 30px;
+        font-size: 32px;
+        transform: rotate(45deg);
+        box-sizing: border-box;
+        animation: antRotate 1.2s infinite linear;
+      }
+
+      .dot i {
+        position: absolute;
+        display: block;
+        width: 20px;
+        height: 20px;
+        background-color: #0065cc;
+        border-radius: 100%;
+        opacity: 0.3;
+        transform: scale(0.75);
+        animation: antSpinMove 1s infinite linear alternate;
+        transform-origin: 50% 50%;
+      }
+
+      .dot i:nth-child(1) {
+        top: 0;
+        left: 0;
+      }
+
+      .dot i:nth-child(2) {
+        top: 0;
+        right: 0;
+        -webkit-animation-delay: 0.4s;
+        animation-delay: 0.4s;
+      }
+
+      .dot i:nth-child(3) {
+        right: 0;
+        bottom: 0;
+        -webkit-animation-delay: 0.8s;
+        animation-delay: 0.8s;
+      }
+
+      .dot i:nth-child(4) {
+        bottom: 0;
+        left: 0;
+        -webkit-animation-delay: 1.2s;
+        animation-delay: 1.2s;
+      }
+
+      @keyframes antRotate {
+        to {
+          -webkit-transform: rotate(405deg);
+          transform: rotate(405deg);
+        }
+      }
+
+      @-webkit-keyframes antRotate {
+        to {
+          -webkit-transform: rotate(405deg);
+          transform: rotate(405deg);
+        }
+      }
+
+      @keyframes antSpinMove {
+        to {
+          opacity: 1;
+        }
+      }
+
+      @-webkit-keyframes antSpinMove {
+        to {
+          opacity: 1;
+        }
+      }
+    </style>
+  </div>
+  <script type="module" src="/src/main.ts"></script>
+</body>
+
+</html>

+ 45 - 0
public/mapview.html

@@ -0,0 +1,45 @@
+<!DOCTYPE html>
+<html lang="en" id="htmlRoot">
+
+<head>
+    <meta charset="UTF-8" />
+    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
+    <meta name="renderer" content="webkit" />
+    <meta name="keywords" content="GIS数据支撑系统" />
+    <meta name="description" content="GIS数据支撑系统" />
+    <meta http-equiv="Expires" content="0" />
+    <meta http-equiv="Cache-control" content="no-cache" />
+    <meta http-equiv="Cache" content="no-cache" />
+    <title>GIS数据支撑系统</title>
+    <link rel="icon" href="/favicon.ico" />
+    <style>
+        body {
+            margin: 0;
+            padding: 0;
+            overflow: hidden;
+            -ms-overflow-style: none;
+            scrollbar-width: none;
+        }
+
+        body::-webkit-scrollbar {
+            display: none;
+        }
+    </style>
+</head>
+
+<body>
+    <script>
+        window.onload = function () {
+            var arr = window.location.href.split("?")
+            if (arr.length && arr[1]) {
+                const iframe = document.createElement('iframe');
+                iframe.style.width = '100vw';
+                iframe.style.height = '100vh';
+                iframe.src = arr[1];
+                document.body.appendChild(iframe);
+            }
+        }
+    </script>
+</body>
+
+</html>

Fichier diff supprimé car celui-ci est trop grand
+ 7060 - 0
public/static/css/boot.min.css


Fichier diff supprimé car celui-ci est trop grand
+ 3776 - 0
public/static/css/portal.css


Fichier diff supprimé car celui-ci est trop grand
+ 72 - 1
src/api/resource/plat.ts


+ 44 - 12
src/views/resource/plat/index.vue

@@ -4,12 +4,20 @@
       <div class="page-name">
         <p>数据目录</p>
       </div>
-      <div class="ztree-container">111</div>
+      <div class="ztree-container">
+        <a-directory-tree :tree-data="treeData" v-model:expandedKeys="expandedKeys" v-model:selectedKeys="selectedKeys"
+          :replace-fields="{ children: 'child', key: 'id', value: 'name', title: 'name' }" v-if="treeData.length"
+          defaultExpandAll="true" v-model:checkedKeys="checkedKeys">
+          <template #title0010><span style="color: #1890ff">sss</span></template>
+        </a-directory-tree>
+      </div>
     </div>
     <Tabs>
-      <template v-for="item in achieveList" :key="item.key">
-        <TabPane :tab="item.name">
-          <component :is="item.component" />
+      <template v-for="item in  achieveList " :key="item.type">
+        <TabPane :tab="[`${item.typeName}成果(${item.count})`]">
+          <component :is="item.type == 'MR'?'MapData':'FileData'" :listData="item.items" :numb="1" />
+          <!-- <MapData v-if="item.type == 'MR'" :listData="item.items" /> -->
+          <!-- <FileData v-if="item.type == 'DR'" :listData="item.items" /> -->
         </TabPane>
       </template>
     </Tabs>
@@ -18,12 +26,11 @@
 
 <script lang="ts">
 import { Tabs } from 'ant-design-vue';
-import { defineComponent } from 'vue';
-import SmsLog from './item/SmsLog.vue';
-import EmailLog from './item/EmailLog.vue';
-import { achieveList } from './data';
+import { defineComponent, ref, watch } from 'vue';
+import MapData from './item/MapData.vue';
+import FileData from './item/FileData.vue';
 import { onMounted } from 'vue';
-import { platList } from '/@/api/resource/plat';
+import { directoryTree, platList } from '/@/api/resource/plat';
 
 const prefixCls = 'account-center-bottom'
 
@@ -31,16 +38,35 @@ export default defineComponent({
   components: {
     Tabs,
     TabPane: Tabs.TabPane,
-    SmsLog,
-    EmailLog,
+    MapData,
+    FileData,
   },
   setup() {
+    const treeData = ref([]);
+    const expandedKeys = ref([]);
+    const selectedKeys = ref([]);
+    const checkedKeys = ref([]);
+    const achieveList = ref([]);
+    watch(expandedKeys, () => {
+      console.log('expandedKeys', expandedKeys);
+    });
+    watch(selectedKeys, () => {
+      console.log('selectedKeys', selectedKeys);
+    });
+    watch(checkedKeys, () => {
+      console.log('checkedKeys', checkedKeys);
+    });
 
     onMounted(() => {
-      platList();
+      directoryTree().then((r) => { if (r) treeData.value = r });
+      platList().then((r) => { if (r) console.log(r), achieveList.value = r });
     });
 
     return {
+      treeData,
+      expandedKeys,
+      selectedKeys,
+      checkedKeys,
       prefixCls: 'account-center',
       achieveList,
     };
@@ -48,6 +74,12 @@ export default defineComponent({
 });
 </script>
 <style lang="less" scoped>
+.account-center-bottom {
+  background: #fff;
+  height: calc(100vh - 110px);
+  overflow: hidden;
+}
+
 .ztree-container {
   float: left;
   overflow: auto;

src/views/resource/plat/item/EmailLog.vue → src/views/resource/plat/item/FileData.vue


+ 271 - 0
src/views/resource/plat/item/MapData.vue

@@ -0,0 +1,271 @@
+<template>
+  <div style="background-color: #f0f2f5" class="dark:bg-dark-900">
+    <div class="datacenter-right">
+      <div class="resource_list" id="map_list">
+        <div v-for="(i, n) in list" v-if="list.length" :key="n" data-permission="true" class="resource_item"
+          data-checking="false" data-searching="1" data-ispub="1">
+          <div class="mapItem-top-box">
+            <div class="item-top">
+              <div class="img_container" data-num="1">
+                <img class="tab-list-icon-img-MR00001936 img_mr MR00001936"
+                  :src="i.info && i.info.length && i.info[0].thumbnail" alt="">
+              </div>
+            </div>
+            <div class="item-title">
+              <span class="r_name">{{ i.SERVICENAME }}</span>
+              <span class="r-number" data-num="1" title="编目1次">1</span>
+            </div>
+            <div class="item-msg">
+              <div class="item-msg-val" style="font-weight:bold;font-size:12px;color: #000;">坐标系:{{ i.CRS }}</div>
+              <div class="item-msg-val">适用流程:国家秘密和工作秘密数据成果申请,</div>
+              <div class="item-msg-val">关键字:测试数据</div>
+              <div class="item-msg-val">服务类型:{{ i.TYPENAME }}</div>
+            </div>
+          </div>
+          <div class="operation-box">
+            <div class="operation-item browse-item-btn browse-item-MR00001936">
+              <a target="_blank" :href="`../../mapview.html?/iserver/services/map-16/rest/maps/LZS16envi1%4016.ijs`"
+                style="border-right: 1px #ccc solid;">
+                <span>浏览</span>
+              </a>
+            </div>
+
+            <div class="operation-item alone-apply-btn alone-apply-btn-MR00001936">
+              <span style="border-right: 1px #ccc solid;" onclick="cardApplyItem('mr')">
+                <span>申请</span>
+              </span>
+            </div>
+            <!-- <div class="user-apply-btn user-apply-btn-MR00001936"
+              onclick="addApplyBank(this,'MR00001936','行政区域','1','测试数据','mr','2000坐标系4490')">
+              <span>加入申请库</span>
+            </div>
+            <div class="dis-apply-btn dis-apply-btn-MR00001936">
+              <span>已加入申请库</span>
+            </div> -->
+            <div class="operation-item" @click="handleQuery(i)">
+              <a href="javascript:void(0)" class="">
+                <span>详细</span>
+              </a>
+            </div>
+          </div>
+        </div>
+      </div>
+    </div>
+
+    <!-- <BasicTable @register="registerTable" class="dark:bg-dark-900">
+      <template #toolbar>
+        <Authority value="api:yt:smsLog:delete">
+          <Popconfirm title="您确定要批量删除数据" ok-text="确定" cancel-text="取消" @confirm="handleDeleteOrBatchDelete(null)">
+            <a-button type="primary" color="error" :disabled="hasBatchDelete"> 批量删除 </a-button>
+          </Popconfirm>
+        </Authority>
+      </template>
+      <template #remark="{ record }">
+        <Tooltip :title="record.remark">
+          <div class="truncate w-full">{{ record.remark }}</div>
+        </Tooltip>
+      </template>
+      <template #action="{ record }">
+        <TableAction :actions="[
+          {
+            label: '查看',
+            auth: 'api:yt:smsLog:get',
+            icon: 'ant-design:fund-view-outlined',
+            onClick: handleQuery.bind(null, record),
+          },
+          {
+            label: '删除',
+            auth: 'api:yt:smsLog:delete',
+            icon: 'ant-design:delete-outlined',
+            color: 'error',
+            popConfirm: {
+              title: '是否确认删除',
+              confirm: handleDeleteOrBatchDelete.bind(null, record),
+            },
+          },
+        ]" />
+      </template>
+    </BasicTable> -->
+    <!-- 弹出框 -->
+    <MapDrawer @register="registerModal" />
+  </div>
+</template>
+<script lang="ts">
+import { defineComponent, nextTick, onMounted, ref, defineProps, watch } from 'vue';
+import { BasicTable, useTable, TableAction } from '/@/components/Table';
+import { columns, searchFormSchema } from './sms.data';
+import { Popconfirm, Tooltip } from 'ant-design-vue';
+import { Authority } from '/@/components/Authority';
+import { platList, img } from '/@/api/resource/plat';
+// 加载自定义侧边弹出框 组件
+import { useDrawer } from '/@/components/Drawer';
+// 导入子页面【新增、修改】
+import MapDrawer from './MapDrawer.vue';
+
+
+export default defineComponent({
+  name: 'SmsLog',
+  components: { BasicTable, TableAction, Authority, Popconfirm, Tooltip, MapDrawer },
+  setup() {
+    const [registerModal, { openDrawer }] = useDrawer(); //使用右侧弹出框
+    const list = ref([]);
+    const props = defineProps({
+      listData: {
+        type: Array,
+        default: () => [],
+      }
+    })
+
+    // setInterval(() => {
+    //   console.log(props)
+    // }, 2000)
+    onMounted(() => {
+      platList().then((r) => {
+        if (r) {
+          list.value = r[0].items;
+          list.value.map(async (i) => i.info = await img(i.SERVICEID))
+        }
+      });
+    });
+
+    function handleQuery(record: Recordable) {
+      console.log("11111:", record)
+      openDrawer(true, {
+        record,
+      });
+    }
+
+    return {
+      registerModal,
+      list,
+      handleQuery,
+    };
+  },
+});
+</script>
+
+<style scoped>
+.datacenter-right .resource_list .item-title .r_name {
+  color: #5e5d5e;
+  display: inline-block;
+  width: 190px;
+  overflow: hidden;
+  text-overflow: ellipsis;
+  white-space: nowrap;
+}
+
+.datacenter-right .resource_list {
+  box-sizing: border-box;
+  width: 100%;
+  float: left;
+  clear: both;
+  display: flex;
+  flex-wrap: wrap;
+  align-items: center;
+}
+
+.datacenter-right .resource_list>div:not(:nth-of-type(4n + 4)) {
+  margin-right: 7px;
+}
+
+.resource_item {
+  height: 318px;
+  width: 224px;
+  margin-bottom: 14px;
+  border: 2px dashed transparent;
+}
+
+.mapItem-top-box {
+  height: 278px;
+  border: 1px solid #dfdfdf;
+  border-bottom: none;
+}
+
+.datacenter-right .resource_list .operation-box {
+  height: 42px;
+  border: 1px solid #dfdfdf;
+  display: flex;
+  margin-bottom: 10px;
+}
+
+.datacenter-right .resource_list .item-top {
+  padding: 13px;
+}
+
+.datacenter-right .resource_list .item-top img {
+  width: 198px;
+  height: 124px;
+}
+
+.datacenter-right .resource_list .item-title {
+  font-size: 14px;
+  font-family: PingFang SC;
+  font-weight: bold;
+  color: #5e5d5e;
+  line-height: 16px;
+  padding: 0 0 0 14px;
+  overflow: hidden;
+  text-overflow: ellipsis;
+  white-space: nowrap;
+}
+
+.datacenter-right .resource_list .item-msg {
+  padding: 0 13px 13px;
+}
+
+.img_container {
+  text-align: center;
+}
+
+.img_container {
+  width: 100%;
+  height: 100%;
+  background: #b7bed3;
+  border-radius: 4px;
+}
+
+.datacenter-right .resource_list .item-msg-val {
+  font-size: 12px;
+  font-family: PingFang SC;
+  font-weight: bold;
+  color: #5e5d5e;
+  line-height: 22px;
+  opacity: 0.5;
+  overflow: hidden;
+  text-overflow: ellipsis;
+  white-space: nowrap;
+}
+
+.datacenter-right .resource_list .operation-item {
+  width: 50%;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.datacenter-right .resource_list .operation-item.alone-apply-btn {
+  display: none;
+}
+
+.datacenter-right .resource_list .operation-item {
+  width: 50%;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.datacenter-right .resource_list .operation-item {
+  width: 50%;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.datacenter-right .resource_list .operation-item a {
+  font-size: 12px;
+  width: 100%;
+  text-align: center;
+  color: #5e5d5e;
+  background-color: #ffffff;
+}
+</style>

Fichier diff supprimé car celui-ci est trop grand
+ 530 - 0
src/views/resource/plat/item/MapDrawer.vue


+ 0 - 117
src/views/resource/plat/item/SmsLog.vue

@@ -1,117 +0,0 @@
-<template>
-  <div style="background-color: #f0f2f5" class="dark:bg-dark-900">
-    <BasicTable @register="registerTable" class="dark:bg-dark-900">
-      <template #toolbar>
-        <!-- <Authority value="api:yt:smsLog:export">
-          <a-button type="primary" @click="handleExport"> 导出 </a-button>
-        </Authority> -->
-        <Authority value="api:yt:smsLog:delete">
-          <Popconfirm
-            title="您确定要批量删除数据"
-            ok-text="确定"
-            cancel-text="取消"
-            @confirm="handleDeleteOrBatchDelete(null)"
-          >
-            <a-button type="primary" color="error" :disabled="hasBatchDelete"> 批量删除 </a-button>
-          </Popconfirm>
-        </Authority>
-      </template>
-      <template #remark="{ record }">
-        <Tooltip :title="record.remark">
-          <div class="truncate w-full">{{ record.remark }}</div>
-        </Tooltip>
-      </template>
-      <template #action="{ record }">
-        <TableAction
-          :actions="[
-            {
-              label: '查看',
-              auth: 'api:yt:smsLog:get',
-              icon: 'ant-design:fund-view-outlined',
-              onClick: handleQuery.bind(null, record),
-            },
-            {
-              label: '删除',
-              auth: 'api:yt:smsLog:delete',
-              icon: 'ant-design:delete-outlined',
-              color: 'error',
-              popConfirm: {
-                title: '是否确认删除',
-                confirm: handleDeleteOrBatchDelete.bind(null, record),
-              },
-            },
-          ]"
-        />
-      </template>
-    </BasicTable>
-  </div>
-</template>
-<script lang="ts">
-  import { defineComponent, h, nextTick } from 'vue';
-  import { BasicTable, useTable, TableAction } from '/@/components/Table';
-  import { columns, searchFormSchema } from './sms.data';
-  import { Modal, Popconfirm, Tooltip } from 'ant-design-vue';
-  import { smsLogPage, deleteSmsLog } from '/@/api/message/records';
-  import { JsonPreview } from '/@/components/CodeEditor';
-  import { useBatchDelete } from '/@/hooks/web/useBatchDelete';
-  import { Authority } from '/@/components/Authority';
-
-  export default defineComponent({
-    name: 'SmsLog',
-    components: { BasicTable, TableAction, Authority, Popconfirm, Tooltip },
-    setup() {
-      const [registerTable, { reload, setProps }] = useTable({
-        title: '短信发送列表',
-        api: smsLogPage,
-        columns,
-        formConfig: {
-          labelWidth: 120,
-          schemas: searchFormSchema,
-          fieldMapToTime: [['sendTime', ['startTime', 'endTime'], 'YYYY-MM-DD HH:mm:ss']],
-        },
-        useSearchForm: true,
-        showTableSetting: true,
-        bordered: true,
-        showIndexColumn: false,
-        actionColumn: {
-          width: 200,
-          title: '操作',
-          dataIndex: 'action',
-          slots: { customRender: 'action' },
-          fixed: 'right',
-        },
-      });
-      const { hasBatchDelete, handleDeleteOrBatchDelete, selectionOptions } = useBatchDelete(
-        deleteSmsLog,
-        handleSuccess,
-        setProps
-      );
-      nextTick(() => {
-        setProps(selectionOptions);
-      });
-      function handleQuery(record: Recordable) {
-        Modal.info({
-          title: '消息内容',
-          width: 480,
-          centered: true,
-          maskClosable: true,
-          content: h(JsonPreview, { data: JSON.parse(JSON.stringify(record.templateParam)) }),
-        });
-      }
-      // 导出 TODO:待做
-      const handleExport = () => {};
-      // 刷新表格
-      function handleSuccess() {
-        reload();
-      }
-
-      return {
-        hasBatchDelete,
-        registerTable,
-        handleExport,
-        handleQuery,
-        handleDeleteOrBatchDelete,
-      };
-    },
-  });
-</script>

+ 221 - 0
src/views/resource/plat/item/map.data.ts

@@ -0,0 +1,221 @@
+import { BasicColumn } from '/@/components/Table';
+import { FormSchema } from '/@/components/Table';
+import { h } from 'vue';
+import { Tag } from 'ant-design-vue';
+import { Icon } from '/@/components/Icon';
+import { useI18n } from '/@/hooks/web/useI18n';
+const { t } = useI18n();
+
+//菜单管理页,所需的列 配置
+export const columns: BasicColumn[] = [
+  {
+    title: t('routes.common.system.tableTitleSystemMenuName'), //菜单名称
+    // title:'菜单名称',
+    dataIndex: 'meta.title',
+    width: 180,
+    align: 'left',
+    customRender: ({ record }) => {
+      record = t(record.title); //国际化处理
+      return record;
+    },
+  },
+  {
+    title: t('routes.common.system.tableTitleSystemPermissionTag'), //权限标识
+    // title:'权限标识',
+    dataIndex: 'permission',
+    width: 220,
+  },
+  {
+    title: t('routes.common.system.tableTitleSystemComponents'), //'组件'
+    // title:'组件',
+    width: 120,
+    // dataIndex: 'component',
+    dataIndex: 'url',
+  },
+  {
+    title: t('routes.common.system.tableTitleSystemSort'), //'排序'
+    // title:'排序',
+    dataIndex: 'sort',
+    width: 50,
+  },
+
+];
+
+const isDir = (type: string) => type === '0';
+const isMenu = (type: string) => type === '1';
+const isButton = (type: string) => type === '2';
+
+//----------------------------------新增、编辑----------------------------------------------------------
+export const formSchema: FormSchema[] = [
+  {
+    field: 'menuType',
+    label: t('routes.common.system.menuEditPagesMenuType'), //菜单类型
+    component: 'RadioButtonGroup',
+    defaultValue: '0',
+    componentProps: {
+      options: [
+        { label: t('routes.common.system.menuEditPagesDirectory'), value: '0' }, //目录
+        { label: t('routes.common.system.menuEditPagesMenu'), value: '1' }, //菜单
+        { label: t('routes.common.system.menuEditPagesButton'), value: '2' }, //按钮
+      ],
+    },
+    colProps: { lg: 24, md: 24 },
+  },
+  {
+    field: 'title',
+    label: t('routes.common.system.tableTitleSystemMenuName'), //菜单名称
+    component: 'Input',
+    required: true,
+    componentProps: {
+      maxLength: 255,
+    },
+  },
+
+  {
+    field: 'parentId',
+    label: t('routes.common.system.menuEditPagesParentMenu'), //上级菜单
+    component: 'TreeSelect',
+    componentProps: {
+      replaceFields: {
+        title: 'menuName',
+        key: 'id',
+        value: 'id',
+      },
+      getPopupContainer: () => document.body,
+    },
+  },
+
+  {
+    field: 'sort',
+    label: t('routes.common.system.tableTitleSystemSort'), //排序
+    component: 'InputNumber',
+    required: true,
+    componentProps: {
+      maxLength: 32,
+    },
+  },
+  {
+    field: 'icon',
+    label: t('routes.common.system.tableTitleSystemIcon'), //图标
+    component: 'IconPicker',
+    required: true,
+    ifShow: ({ values }) => !isButton(Reflect.get(values, 'menuType')),
+  },
+
+  {
+    field: 'path',
+    label: t('routes.common.system.menuEditPagesRouterAddress'), //路由地址
+    component: 'Input',
+    required: true,
+    ifShow: ({ values }) => !isButton(Reflect.get(values, 'menuType')),
+    componentProps: {
+      maxLength: 255,
+    },
+  },
+  {
+    field: 'permission',
+    label: '权限标识', //路由地址
+    component: 'Input',
+    // required: true,//是否必须
+    componentProps: {
+      maxLength: 255,
+    },
+  },
+  {
+    field: 'component',
+    label: t('routes.common.system.menuEditPagesComponentsPath'), //组件路径
+    component: 'Input',
+    ifShow: ({ values }) => isMenu(Reflect.get(values, 'menuType')),
+    componentProps: {
+      maxLength: 100,
+    },
+    dynamicRules: () => {
+      return [
+        {
+          required: false,
+          validator: (_, value) => {
+            if (String(value).length > 100) {
+              return Promise.reject('字数不超过100个字');
+            }
+            return Promise.resolve();
+          },
+        },
+      ];
+    },
+  },
+  {
+    field: 'permission',
+    label: t('routes.common.system.tableTitleSystemPermissionTag'), //权限标识
+    component: 'Input',
+    ifShow: ({ values }) => !isDir(Reflect.get(values, 'menuType')),
+    componentProps: {
+      maxLength: 100,
+    },
+    dynamicRules: () => {
+      return [
+        {
+          required: false,
+          validator: (_, value) => {
+            if (String(value).length > 100) {
+              return Promise.reject('字数不超过100个字');
+            }
+            return Promise.resolve();
+          },
+        },
+      ];
+    },
+  },
+  {
+    field: 'status',
+    label: t('routes.common.system.tableTitleSystemStatus'), //状态
+    component: 'RadioButtonGroup',
+    defaultValue: '0',
+    componentProps: {
+      options: [
+        { label: t('routes.common.system.tableTitleSystemEnable'), value: '0' }, //启用
+        { label: t('routes.common.system.tableTitleSystemStop'), value: '1' }, //禁用
+      ],
+    },
+  },
+  {
+    field: 'isLink',
+    label: t('routes.common.system.menuEditPagesIsExt'), //是否外链
+    component: 'RadioButtonGroup',
+    defaultValue: false,
+    componentProps: {
+      options: [
+        { label: t('routes.common.system.menuEditPagesYes'), value: true }, //是
+        { label: t('routes.common.system.menuEditPagesNo'), value: false }, //否
+      ],
+    },
+    ifShow: ({ values }) => !isButton(Reflect.get(values, 'menuType')),
+  },
+
+  {
+    field: 'ignoreKeepAlive',
+    label: t('routes.common.system.menuEditPagesIsKeepAlive'), //是否缓存
+    component: 'RadioButtonGroup',
+    defaultValue: false,
+    componentProps: {
+      options: [
+        { label: t('routes.common.system.menuEditPagesYes'), value: true }, //是
+        { label: t('routes.common.system.menuEditPagesNo'), value: false }, //否
+      ],
+    },
+    ifShow: ({ values }) => isMenu(Reflect.get(values, 'menuType')),
+  },
+
+  {
+    field: 'hideMenu',
+    label: t('routes.common.system.menuEditPagesIsHide'), //是否隐藏
+    component: 'RadioButtonGroup',
+    defaultValue: false,
+    componentProps: {
+      options: [
+        { label: t('routes.common.system.menuEditPagesYes'), value: true }, //是
+        { label: t('routes.common.system.menuEditPagesNo'), value: false }, //否
+      ],
+    },
+    ifShow: ({ values }) => !isButton(Reflect.get(values, 'menuType')),
+  },
+];

+ 3 - 3
src/views/systemAdmin/system/account/AccountDetail.vue

@@ -11,10 +11,10 @@
   import { useRoute } from 'vue-router';
   import { PageWrapper } from '/@/components/Page';
   import { useGo } from '/@/hooks/web/usePage';
-  import { Description } from '../../../components/Description';
-  import { getAccountInfo } from '../../../api/system/system';
+  import { Description } from '/@/components/Description';
+  import { getAccountInfo } from '/@/api/system/system';
   import { accountSchema } from './account.detail.data';
-  import { useDescription } from '../../../components/Description';
+  import { useDescription } from '/@/components/Description';
   import { useTabs } from '/@/hooks/web/useTabs';
   const accountData = {};
   export default defineComponent({

+ 0 - 1
target/dist/assets/SiteAnalysis.a5cf3f89.css

@@ -1 +0,0 @@
-.center{display:flex;justify-content:center;font-size:16px}.active{color:#0960bd;font-weight:500}.extra-date{display:flex;align-items:center;justify-content:space-between}.extra-date span{margin-right:20px;cursor:pointer}

Fichier diff supprimé car celui-ci est trop grand
+ 1 - 1
target/dist/assets/app-antd-dark-theme-style.e3b0c442.css


Fichier diff supprimé car celui-ci est trop grand
+ 2 - 2
target/dist/index.html