CzRger месяцев назад: 2
Родитель
Сommit
5e76c03e9f
38 измененных файлов с 219 добавлено и 727 удалено
  1. 1 1
      .env.development
  2. 1 1
      .env.production
  3. 1 1
      index.html
  4. BIN
      src/assets/images/bg.png
  5. BIN
      src/assets/images/logo.png
  6. 47 7
      src/layout/top-left/head/index.vue
  7. 4 4
      src/layout/top-left/index.vue
  8. 0 4
      src/out/config.js
  9. 10 4
      src/router/index.ts
  10. 44 0
      src/router/modules/big-model.ts
  11. 2 2
      src/style/czr.scss
  12. BIN
      src/style/font/Alimama.ttf
  13. BIN
      src/style/font/PingFang Regular.ttf
  14. 9 0
      src/style/font/font.scss
  15. 1 0
      src/style/index.scss
  16. 0 291
      src/views/draw/chart/index.vue
  17. 0 25
      src/views/draw/config/config.ts
  18. 0 15
      src/views/draw/config/types.ts
  19. 0 23
      src/views/draw/draw.vue
  20. 0 19
      src/views/draw/index.vue
  21. 0 47
      src/views/draw/node/component/if/index.vue
  22. 0 18
      src/views/draw/node/component/if/type.ts
  23. 0 32
      src/views/draw/node/component/node-operation.vue
  24. 0 113
      src/views/draw/node/index.vue
  25. 24 0
      src/views/global/login/index.vue
  26. 15 0
      src/views/manage/app/index.vue
  27. 15 0
      src/views/manage/center/index.vue
  28. 15 0
      src/views/manage/home/index.vue
  29. 15 0
      src/views/manage/knowledge/index.vue
  30. 15 0
      src/views/manage/model/index.vue
  31. 0 15
      src/views/menu/menu1.vue
  32. 0 15
      src/views/menu/menu2-1.vue
  33. 0 15
      src/views/menu/menu2-2.vue
  34. 0 15
      src/views/menu/menu2-3-1-1.vue
  35. 0 15
      src/views/menu/menu2-3-1-2.vue
  36. 0 15
      src/views/menu/menu2-3-2.vue
  37. 0 15
      src/views/menu/menu3.vue
  38. 0 15
      src/views/menu/menu4.vue

+ 1 - 1
.env.development

@@ -2,7 +2,7 @@
 NODE_ENV = development
 
 # 标题
-VITE_TITLE = 大模型
+VITE_TITLE = 大模型智能应用开发及监测平台
 
 # 基础路径
 VITE_BASE = 'big-model-web'

+ 1 - 1
.env.production

@@ -2,7 +2,7 @@
 NODE_ENV = production
 
 # 标题
-VITE_TITLE = 大模型
+VITE_TITLE = 大模型智能应用开发及监测平台
 
 # 基础路径
 VITE_BASE = 'big-model-web'

+ 1 - 1
index.html

@@ -3,7 +3,7 @@
 <head>
   <meta charset="UTF-8"/>
   <title><{VITE_TITLE}></title>
-  <link rel="icon" type="image/png" id="logo" href="/src/assets/images/global/logo.png">
+  <link rel="icon" type="image/png" id="logo" href="/src/assets/images/logo.png">
   <script src="/config.js"></script>
 </head>
 <body>

BIN
src/assets/images/bg.png


BIN
src/assets/images/logo.png


+ 47 - 7
src/layout/top-left/head/index.vue

@@ -1,26 +1,66 @@
 <template>
   <div class="head-com">
-    <template v-for="item in MenuStore.menus">
-      <el-button
-        :type="$route.matched.some(v => v.path === item.path) ? 'success' : 'info'"
-        @click="$router.push(item.path)"
-      >{{item.meta.title}}</el-button>
-    </template>
+    <div class="logo">
+      <img src="@/assets/images/logo.png"/>
+    </div>
+    <div class="title">{{titleCpt}}</div>
+    <div class="menus">
+      <template v-for="item in menusCpt.children">
+        <div class="menu-item __hover" :class="{active: $route.matched.some(v => v.path === item.path)}" @click="$router.push(item.path)">
+          {{item.meta.title}}
+        </div>
+      </template>
+    </div>
   </div>
 </template>
 
 <script setup lang="ts">
-import {getCurrentInstance, reactive} from "vue";
+import {computed, getCurrentInstance, reactive} from "vue";
 import {useMenuStore} from "@/stores";
+import {useRoute, useRouter} from "vue-router";
 
 const MenuStore = useMenuStore()
+const router = useRouter()
+const route = useRoute()
 const {proxy} = getCurrentInstance()
 const state: any = reactive({})
+const titleCpt =  computed(() => import.meta.env.VITE_TITLE)
+const menusCpt: any = computed(() => router.options.routes.filter(v => v.name === 'root')[0])
+console.log(menusCpt)
+console.log(route)
 </script>
 
 <style lang="scss" scoped>
 .head-com {
+  width: 100%;
+  height: 100%;
   display: flex;
   align-items: center;
+  .logo {
+    margin-left: 1.5rem;
+  }
+  .title {
+    margin-left: 0.75rem;
+    font-weight: bold;
+    font-size: 1.38rem;
+    background: linear-gradient(180deg, #3DC8FE 0%, #2D6BD0 46%, #6255F6 100%);
+    color: transparent;
+    background-clip: text;
+    font-family: Alimama;
+  }
+  .menus {
+    margin-left: 5rem;
+    display: flex;
+    align-items: center;
+    gap: 3.13rem;
+    .menu-item {
+      font-weight: bold;
+      font-size: 1.13rem;
+      color: #303133;
+      &.active {
+        color: var(--czr-main-color)
+      }
+    }
+  }
 }
 </style>

+ 4 - 4
src/layout/top-left/index.vue

@@ -32,10 +32,12 @@ const state: any = reactive({})
   height: 100%;
   display: flex;
   flex-direction: column;
+  background-image: url("@/assets/images/bg.png");
+  background-size: 100% 100%;
+  background-repeat: no-repeat;
   .top-left-layout-head {
     width: 100%;
-    height: 60px;
-    background-color: #22a5fe;
+    height: 4.25rem;
   }
   .top-left-layout-center {
     flex: 1;
@@ -43,11 +45,9 @@ const state: any = reactive({})
     .top-left-layout-center-sub-menu {
       width: 300px;
       height: 100%;
-      background-color: #0B46C9;
     }
     .top-left-layout-center-content {
       flex: 1;
-      background-color: #666666;
       display: flex;
       flex-direction: column;
       .top-left-layout-center-content {

+ 0 - 4
src/out/config.js

@@ -1,7 +1,3 @@
 window.czrConfig = {
   menuLayout: 'top-left', //  'left'-左侧,'top-left'-顶部左侧
-  dify: {
-    // appId: '86945884-adf3-4e22-91b2-e48c38b44e9e'
-    appId: 'b9aca5c8-f0bb-4313-965f-3375d7a55579'
-  }
 }

+ 10 - 4
src/router/index.ts

@@ -1,5 +1,6 @@
 import {createRouter, createWebHistory} from 'vue-router'
 import demoRouter from './modules/demo'
+import bigModelRouter from './modules/big-model'
 import Temp404 from '@/views/global/temp/404.vue'
 import RouterView from '@/layout/router-view.vue'
 // @ts-ignore
@@ -12,14 +13,15 @@ const routes = [
         name: 'root',
         path: '/',
         component: Layout,
-        redirect: '/workflow',
+        redirect: '/knowledge',
         children: [
+          ...bigModelRouter
         ]
     },
     {
-        name: 'draw',
-        path: '/draw',
-        component: () => import('@/views/draw/index.vue'),
+        name: 'login',
+        path: '/login',
+        component: () => import('@/views/global/login/index.vue'),
         meta: {
             noLoading: true
         }
@@ -56,6 +58,10 @@ router.beforeEach((to, from , next) => {
 //     })
 // }
 export const beforeInit = () => {
+    const l = document.getElementById('loader')
+    if (l) {
+        l.style.display = 'none'
+    }
     // if (location.pathname === (import.meta as any).env.BASE_URL + 'assistant') {
     //     document.title = "“i口岸”通关小助理";
     //     let link: any = document.querySelector("link[rel*='icon']") || document.createElement('link');

+ 44 - 0
src/router/modules/big-model.ts

@@ -0,0 +1,44 @@
+const BigModelRouter = [
+  {
+    path: '/home',
+    name: '4806d051-e037-4d9d-99a0-78aa2f2f362b',
+    component: () => import('@/views/manage/home/index.vue'),
+    meta: {
+      title: '首页',
+    },
+  },
+  {
+    path: '/model',
+    name: '86e9f5e8-285d-4038-abc2-a39b2ad7fcd1',
+    component: () => import('@/views/manage/model/index.vue'),
+    meta: {
+      title: '模型纳管',
+    },
+  },
+  {
+    path: '/app',
+    name: 'd446bfb3-4605-477f-a0f4-b7a0a1aa78fe',
+    component: () => import('@/views/manage/app/index.vue'),
+    meta: {
+      title: '应用中心',
+    },
+  },
+  {
+    path: '/knowledge',
+    name: '4342bfff-1ea8-4f4c-b562-3cdc1fde116f',
+    component: () => import('@/views/manage/knowledge/index.vue'),
+    meta: {
+      title: '知识库',
+    },
+  },
+  {
+    path: '/center',
+    name: '3b046708-5a14-450f-9dcd-9d869e336ed7',
+    component: () => import('@/views/manage/center/index.vue'),
+    meta: {
+      title: '管理中心',
+    },
+  },
+]
+
+export default BigModelRouter

+ 2 - 2
src/style/czr.scss

@@ -1,6 +1,6 @@
 :root {
-  --czr-main-color: rgba(21, 90, 239, 1);
-  --czr-main-color-rgb: 21, 90, 239;
+  --czr-main-color: rgba(47, 130, 255, 1);
+  --czr-main-color-rgb: 47, 130, 255;
 }
 
 .__disabled {

BIN
src/style/font/Alimama.ttf


BIN
src/style/font/PingFang Regular.ttf


+ 9 - 0
src/style/font/font.scss

@@ -0,0 +1,9 @@
+@font-face {
+  font-family: "PingFang SC";
+  src: url("@/style/font/PingFang Regular.ttf");
+}
+
+@font-face {
+  font-family: "Alimama";
+  src: url("@/style/font/Alimama.ttf");
+}

+ 1 - 0
src/style/index.scss

@@ -1,5 +1,6 @@
 @use './webkit-scrollbar';
 @use './czr';
+@use './font/font';
 
 * {
   outline: none;  // dom元素选中带边框

+ 0 - 291
src/views/draw/chart/index.vue

@@ -1,291 +0,0 @@
-<template>
-  <div class="chart"
-    @mousedown="moveStart"
-    @mousemove="move"
-    @mouseup="moveEnd"
-    @mouseleave="moveEnd"
-  >
-    <div class="chart-block" ref="ref_chart">
-      <template v-for="n in state.nodes">
-        <node
-          :item="n"
-          :type="n.type"
-          v-model:x="n.x"
-          v-model:y="n.y"
-          v-model:w="n.w"
-          v-model:h="n.h"
-        />
-      </template>
-      <svg class="lines" :style="{width: offsetStyleCpt.width + 'px', height: offsetStyleCpt.height + 'px', left: offsetStyleCpt.left + 'px', top: offsetStyleCpt.top + 'px'}">
-        <defs>
-          <marker
-            id="arrow"
-            :viewBox="`0 0 ${markerStyle.width} ${markerStyle.width}`"
-            :refX="0"
-            :refY="markerStyle.height"
-            :markerWidth="markerStyle.width"
-            :markerHeight="markerStyle.height"
-            orient="auto-start-reverse"
-          >
-            <path :d="`M 0 0 L ${markerStyle.width} ${markerStyle.height} L 0 ${markerStyle.width} z`" fill="#d0d5dc" />
-          </marker>
-        </defs>
-        <!-- 绘制曲线连线 -->
-        <path
-          v-for="(line, index) in state.lines"
-          :key="index"
-          :d="getPath(line)"
-          stroke="#d0d5dc"
-          stroke-width="2"
-          fill="none"
-          marker-end="url(#arrow)"
-        />
-      </svg>
-    </div>
-  </div>
-</template>
-
-<script setup lang="ts">
-import {computed, getCurrentInstance, onMounted, reactive, ref} from "vue";
-import node from '../node/index.vue'
-import {LineDef, NodeDef} from "@/views/draw/config/types";
-import {nodeStyleConfig} from "@/views/draw/config/config";
-import {IfLevelsCondition} from "@/views/draw/node/component/if/type";
-
-
-const {proxy} = getCurrentInstance()
-const markerStyle = {
-  width: 10,
-  height: 5,
-}
-const state: any = reactive({
-  moving: false,
-  nodes: [
-    {
-      id: '8facce0d-c5ff-42ba-b6a0-6a920510c794',
-      type: 'NodeRoot',
-      x: 0,
-      y: 0,
-    },
-    {
-      id: 'f001c786-c4a0-402f-a79d-19456f9346a6',
-      type: 'NodeIf',
-      x: 300,
-      y: 0,
-      data: {
-        title: '条件分支1',
-        levels: [
-          {
-            id: '418af28e-8799-45f3-8c26-29bbbad37cbf',
-            method: 'AND',
-            conditions: [
-              {
-                source: 'asd',
-                to: 'zxc',
-                target: 'qwe',
-                targetType: 'value'
-              },
-              {
-                source: 'asd',
-                to: 'zxc',
-                target: 'qwe',
-                targetType: 'value'
-              },
-              {
-                source: 'asd',
-                to: 'zxc',
-                target: 'qwe',
-                targetType: 'value'
-              },
-            ]
-          },
-          {
-            id: 'b812382b-f1bd-4539-a8a3-0efc875107f9',
-            method: 'OR',
-            conditions: [
-              {
-                source: 'asd',
-                to: 'zxc',
-                target: 'qwe',
-                targetType: 'value'
-              },
-              {
-                source: 'asd',
-                to: 'zxc',
-                target: 'qwe',
-                targetType: 'value'
-              },
-              {
-                source: 'asd',
-                to: 'zxc',
-                target: 'qwe',
-                targetType: 'value'
-              },
-            ]
-          },
-          {
-            id: '883881a6-d993-4f5f-ba4f-f382cda4395c',
-            method: 'AND',
-            conditions: [
-              {
-                source: 'asd',
-                to: 'zxc',
-                target: 'qwe',
-                targetType: 'value'
-              },
-              {
-                source: 'asd',
-                to: 'zxc',
-                target: 'qwe',
-                targetType: 'value'
-              },
-              {
-                source: 'asd',
-                to: 'zxc',
-                target: 'qwe',
-                targetType: 'value'
-              },
-            ]
-          }
-        ]
-      }
-    },
-    {
-      id: 'e7dacb7d-8505-4bf7-abae-91e81d27106e',
-      type: 'NodeSwitch',
-      x: 300,
-      y: 200,
-    },
-    {
-      id: '329dd688-461d-4dec-af1e-80685b135e27',
-      type: 'NodeFor',
-      x: 600,
-      y: 200,
-    },
-    {
-      id: 'e3c9c844-4333-4d0d-9fad-b952f7f04496',
-      type: 'NodeFor',
-      x: 600,
-      y: 400,
-    }
-  ] as NodeDef[],
-  lines: [
-    {source: '8facce0d-c5ff-42ba-b6a0-6a920510c794', target: 'f001c786-c4a0-402f-a79d-19456f9346a6', type: 'NODE'},
-    {source: '8facce0d-c5ff-42ba-b6a0-6a920510c794', target: 'e7dacb7d-8505-4bf7-abae-91e81d27106e', type: 'NODE'},
-    {source: 'e7dacb7d-8505-4bf7-abae-91e81d27106e', target: '329dd688-461d-4dec-af1e-80685b135e27', type: 'NODE'},
-    {source: 'b812382b-f1bd-4539-a8a3-0efc875107f9', target: 'e3c9c844-4333-4d0d-9fad-b952f7f04496', type: 'LEVEL'},
-  ] as LineDef[]
-})
-const ref_chart = ref()
-const offsetStyleCpt = computed(() => {
-  try {
-    let maxW = 0
-    let minW = 0
-    let maxH = 0
-    let minH = 0
-    const chart = ref_chart.value
-    if (chart) {
-      state.nodes.forEach((v: NodeDef) => {
-        const dom = chart.querySelector(`#NODE_${v.id}`)
-        if (v.x < minW) {
-          minW = v.x
-        }
-        if (v.x + dom.clientWidth > maxW) {
-          maxW = v.x + dom.clientWidth
-        }
-        if (v.y < minH) {
-          minH = v.y
-        }
-        if (v.y + dom.clientHeight > maxH) {
-          maxH = v.y + dom.clientHeight
-        }
-      })
-    }
-    return {
-      width: maxW - minW - 40,
-      height: maxH - minH,
-      left: minW - 40,
-      top: minH
-    }
-  } catch (e) {
-     console.log(e)
-  }
-  return {
-    width: 0,
-    height: 0,
-    left: 0,
-    top: 0
-  }
-})
-const moveStart = (e) => {
-  state.moving = true
-}
-const move = (e) => {
-  if (state.moving) {
-    const chart = ref_chart.value
-    const x = chart.style.left ? Number(chart.style.left.replace('px', '')) : 0
-    const y = chart.style.top ? Number(chart.style.top.replace('px', '')) : 0
-    chart.style.left = `${x + e.movementX}px`
-    chart.style.top = `${y + e.movementY}px`
-  }
-}
-const moveEnd = (e) => {
-  state.moving = false
-}
-// 计算连线路径
-const getPath = (line) => {
-  const chart = ref_chart.value
-  if (chart) {
-    const sourceNode = chart.querySelector(`#${line.type}_${line.source}`)
-    const targetNode = chart.querySelector(`#NODE_${line.target}`)
-    let startX
-    let startY
-    if (line.type === 'NODE') {
-      startX = Number(sourceNode.getAttribute('x')) + sourceNode.clientWidth - offsetStyleCpt.value.left + nodeStyleConfig.nodeBorderWidth
-      startY = Number(sourceNode.getAttribute('y')) + nodeStyleConfig.titleHeight / 2 - offsetStyleCpt.value.top + nodeStyleConfig.nodeBorderWidth
-    } else if (line.type === 'LEVEL') {
-      const node = chart.querySelector(`#NODE_${sourceNode.getAttribute('node-id')}`)
-      startX = Number(node.getAttribute('x')) + node.clientWidth - offsetStyleCpt.value.left + nodeStyleConfig.nodeBorderWidth
-      startY = Number(node.getAttribute('y')) + sourceNode.offsetTop + nodeStyleConfig.nodeBorderWidth + nodeStyleConfig.lineOperationRadius + 2
-    }
-    const endX = Number(targetNode.getAttribute('x')) - offsetStyleCpt.value.left - markerStyle.width;
-    const endY = Number(targetNode.getAttribute('y')) - offsetStyleCpt.value.top + nodeStyleConfig.titleHeight / 2 + nodeStyleConfig.nodeBorderWidth
-    // 调整控制点位置,让连线起点和终点保持距离再弯曲
-    const offset = 50
-    const controlX1 = startX + offset
-    const controlY1 = startY
-    const controlX2 = endX - offset
-    const controlY2 = endY
-    return `M ${startX} ${startY} C ${controlX1} ${controlY1} ${controlX2} ${controlY2} ${endX} ${endY}`
-  }
-  return ''
-};
-
-onMounted(() => {
-})
-</script>
-
-<style lang="scss" scoped>
-.chart {
-  position: relative;
-  width: 1400px;
-  height: 800px;
-  overflow: hidden;
-  background-color: #f2f4f7;
-  .chart-block {
-    position: absolute;
-  }
-}
-.lines {
-  position: absolute;
-  top: 0;
-  left: 0;
-  width: 100%;
-  height: 100%;
-  pointer-events: none;
-  z-index: 0;
-  marker {
-
-  }
-}
-</style>

+ 0 - 25
src/views/draw/config/config.ts

@@ -1,25 +0,0 @@
-import {NodeData} from "./types";
-import {NodeIf} from "@/views/draw/node/component/if/type";
-export const nodeTypeConfig = {
-  NodeRoot: <NodeData>{
-    title: '开始'
-  },
-  NodeIf: <NodeIf>{
-    title: '条件分支',
-    levels: [
-      {}
-    ]
-  },
-  NodeFor: <NodeData>{
-    title: '循环'
-  },
-  NodeSwitch: <NodeData>{
-    title: '分类处理'
-  }
-}
-
-export const nodeStyleConfig = {
-  nodeBorderWidth: 2,
-  titleHeight: 50,
-  lineOperationRadius: 8
-}

+ 0 - 15
src/views/draw/config/types.ts

@@ -1,15 +0,0 @@
-export type NodeDef = {
-  id: string
-  type: string
-  x: number
-  y: number
-  data: NodeData
-}
-export type LineDef = {
-  source: string
-  target: string
-  type: 'NODE' | 'LEVEL'
-}
-export type NodeData = {
-  title: string
-}

+ 0 - 23
src/views/draw/draw.vue

@@ -1,23 +0,0 @@
-<template>
-  <div class="draw">
-    <chart/>
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive} from "vue";
-import chart from './chart/index.vue'
-
-const {proxy} = getCurrentInstance()
-const state: any = reactive({})
-</script>
-
-<style lang="scss" scoped>
-.draw {
-  width: 100%;
-  height: 100%;
-  display: flex;
-  align-items: center;
-  justify-content: center;
-}
-</style>

+ 0 - 19
src/views/draw/index.vue

@@ -1,19 +0,0 @@
-<template>
-  <div class="main">
-    <draw/>
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive} from "vue";
-import draw from './draw.vue'
-const {proxy} = getCurrentInstance()
-const state: any = reactive({})
-</script>
-
-<style lang="scss" scoped>
-.main {
-  width: 100%;
-  height: 100%;
-}
-</style>

+ 0 - 47
src/views/draw/node/component/if/index.vue

@@ -1,47 +0,0 @@
-<template>
-  <div class="node-if">
-    <template v-for="(level, levelIndex) in data.levels">
-      <div class="node-if-level">
-        <div class="node-if-level-title" :node-id="nodeId" :id="'LEVEL_' + level.id">
-          <div>
-            CASE
-          </div>
-          <div>{{levelIndex === 0 ? 'IF' : levelIndex === data.levels.length - 1 ? 'ELSE' : 'ELIF'}}</div>
-        </div>
-        <div class="node-if-level-content">
-
-        </div>
-      </div>
-    </template>
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive, ref} from "vue";
-import {NodeIf} from "@/views/draw/node/component/if/type";
-const props = defineProps({
-  data: {default: <NodeIf>{}},
-  nodeId: {}
-})
-const {proxy} = getCurrentInstance()
-const state: any = reactive({
-})
-</script>
-
-<style lang="scss" scoped>
-.node-if {
-  font-size: 14px;
-  display: flex;
-  flex-direction: column;
-  gap: 4px;
-  .node-if-level-title {
-    display: flex;
-    justify-content: space-between;
-    align-items: center;
-    >div:nth-child(1) {
-      font-size: 12px;
-      color: #333333;
-    }
-  }
-}
-</style>

+ 0 - 18
src/views/draw/node/component/if/type.ts

@@ -1,18 +0,0 @@
-import {NodeData} from "@/views/draw/config/types";
-
-export type NodeIf = NodeData & {
-  levels: IfLevel[]
-}
-
-export type IfLevel = {
-  id: string
-  method: 'AND' | 'OR',
-  conditions: IfLevelsCondition[]
-}
-
-export type IfLevelsCondition = {
-  source: string
-  to: string
-  target: string
-  targetType: 'value' | 'param'
-}

+ 0 - 32
src/views/draw/node/component/node-operation.vue

@@ -1,32 +0,0 @@
-<template>
-  <div class="node-operation" :style="{top: top + 'px'}">
-    <SvgIcon name="czr_add" color="#ffffff" size="12"/>
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive, ref} from "vue";
-
-const emits = defineEmits([])
-const props = defineProps({
-  top: {default: 0},
-  addRadius: {default: 0}
-})
-const addRadiusPx = props.addRadius + 'px'
-const {proxy}: any = getCurrentInstance()
-const state: any = reactive({})
-</script>
-
-<style lang="scss" scoped>
-.node-operation {
-  background-color: #286bfb;
-  width: calc(v-bind(addRadiusPx) * 2);
-  height: calc(v-bind(addRadiusPx) * 2);
-  border-radius: 50%;
-  display: flex;
-  align-items: center;
-  justify-content: center;
-  position: absolute;
-  right: calc(v-bind(addRadiusPx) * -1);
-}
-</style>

+ 0 - 113
src/views/draw/node/index.vue

@@ -1,113 +0,0 @@
-<template>
-  <div
-    :id="'NODE_' + item.id"
-    class="node"
-    ref="ref_node"
-    :style="{
-      left: x + 'px',
-      top: y + 'px',
-      borderWidth: nodeStyleConfig.nodeBorderWidth + 'px',
-    }"
-    :x="x"
-    :y="y"
-    @mousedown.stop="moveStart"
-    @mousemove.stop="move"
-    @mouseup.stop="moveEnd"
-    @mouseleave.stop="moveEnd"
-    @mouseenter="state.hover = true"
-  >
-    <div class="node-title" :style="{height: nodeStyleConfig.titleHeight + 'px'}">
-      {{item.data?.title || nodeTypeConfig[type].title}}
-    </div>
-    <div class="node-content" :class="`node-content_${type}`" v-if="type !== 'NodeRoot'">
-      <template v-if="type === 'NodeIf'">
-        <nodeIf :data="item.data" :nodeId="item.id"/>
-      </template>
-    </div>
-    <template v-if="state.active || state.hover">
-      <template v-if="item.data?.levels?.length > 0">
-        <template v-for="level in item.data.levels">
-          <nodeOperation :top="getLevelTop(level)" :add-radius="addRadius"/>
-        </template>
-      </template>
-      <template v-else>
-        <nodeOperation :top="nodeStyleConfig.titleHeight / 2 - addRadius" :add-radius="addRadius"/>
-      </template>
-    </template>
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive, ref} from "vue";
-import {nodeStyleConfig, nodeTypeConfig} from '@/views/draw/config/config'
-import nodeIf from '@/views/draw/node/component/if/index.vue'
-import nodeOperation from '@/views/draw/node/component/node-operation.vue'
-import {IfLevel} from "@/views/draw/node/component/if/type";
-
-const emits = defineEmits(['update:x', 'update:y', 'update:w', 'update:h'])
-const props = defineProps({
-  item: {default: <any>{}},
-  type: {default: 'root'},
-  x: {default: 0},
-  y: {default: 0},
-})
-const {proxy} = getCurrentInstance()
-const state: any = reactive({
-  moving: false,
-  active: false,
-  hover: false,
-})
-const addRadius = nodeStyleConfig.lineOperationRadius
-const ref_node = ref()
-const moveStart = (e) => {
-  state.moving = true
-}
-const move = (e) => {
-  if (state.moving) {
-    emits('update:x', proxy.x + e.movementX)
-    emits('update:y', proxy.y + e.movementY)
-  }
-}
-const moveEnd = (e) => {
-  state.moving = false
-  state.hover = false
-}
-const getLevelTop = (level: IfLevel) => {
-  let top = 0
-  const node = ref_node.value
-  if (node) {
-    const dom = node.querySelector(`#LEVEL_${level.id}`)
-    top = dom.offsetTop + 2
-  }
-  return top
-}
-</script>
-
-<style lang="scss" scoped>
-.node {
-  z-index: 10;
-  border-style: solid;
-  border-color: rgba(0, 0, 0, 0.1);
-  border-radius: 10px;
-  background-color: #ffffff;
-  position: absolute;
-  min-width: 240px;
-  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
-  &:hover {
-    border-color: #286bfb;
-    cursor: pointer;
-  }
-  .node-title {
-    width: 100%;
-    display: flex;
-    align-items: center;
-    padding: 8px 12px;
-    font-size: 14px;
-    font-weight: bold;
-  }
-  .node-content {
-    padding: 0px 12px;
-    margin-bottom: 8px;
-  }
-}
-</style>

+ 24 - 0
src/views/global/login/index.vue

@@ -0,0 +1,24 @@
+<template>
+  <div class="login">
+    <div class="login-main">
+
+    </div>
+  </div>
+</template>
+
+<script setup lang="ts">
+import {getCurrentInstance, reactive, ref} from "vue";
+
+const emits = defineEmits([])
+const props = defineProps({})
+const {proxy}: any = getCurrentInstance()
+const state: any = reactive({})
+</script>
+
+<style lang="scss" scoped>
+.login {
+  width: 100%;
+  height: 100vh;
+  background-color: red;
+}
+</style>

+ 15 - 0
src/views/manage/app/index.vue

@@ -0,0 +1,15 @@
+<template>
+  应用中心
+</template>
+
+<script setup lang="ts">
+import {getCurrentInstance, reactive, ref} from "vue";
+
+const emits = defineEmits([])
+const props = defineProps({})
+const {proxy}: any = getCurrentInstance()
+const state: any = reactive({})
+</script>
+
+<style lang="scss" scoped>
+</style>

+ 15 - 0
src/views/manage/center/index.vue

@@ -0,0 +1,15 @@
+<template>
+  管理中心
+</template>
+
+<script setup lang="ts">
+import {getCurrentInstance, reactive, ref} from "vue";
+
+const emits = defineEmits([])
+const props = defineProps({})
+const {proxy}: any = getCurrentInstance()
+const state: any = reactive({})
+</script>
+
+<style lang="scss" scoped>
+</style>

+ 15 - 0
src/views/manage/home/index.vue

@@ -0,0 +1,15 @@
+<template>
+  首页
+</template>
+
+<script setup lang="ts">
+import {getCurrentInstance, reactive, ref} from "vue";
+
+const emits = defineEmits([])
+const props = defineProps({})
+const {proxy}: any = getCurrentInstance()
+const state: any = reactive({})
+</script>
+
+<style lang="scss" scoped>
+</style>

+ 15 - 0
src/views/manage/knowledge/index.vue

@@ -0,0 +1,15 @@
+<template>
+  知识库
+</template>
+
+<script setup lang="ts">
+import {getCurrentInstance, reactive, ref} from "vue";
+
+const emits = defineEmits([])
+const props = defineProps({})
+const {proxy}: any = getCurrentInstance()
+const state: any = reactive({})
+</script>
+
+<style lang="scss" scoped>
+</style>

+ 15 - 0
src/views/manage/model/index.vue

@@ -0,0 +1,15 @@
+<template>
+  模型纳管
+</template>
+
+<script setup lang="ts">
+import {getCurrentInstance, reactive, ref} from "vue";
+
+const emits = defineEmits([])
+const props = defineProps({})
+const {proxy}: any = getCurrentInstance()
+const state: any = reactive({})
+</script>
+
+<style lang="scss" scoped>
+</style>

+ 0 - 15
src/views/menu/menu1.vue

@@ -1,15 +0,0 @@
-<template>
-  <div>
-    菜单1
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive} from "vue";
-
-const {proxy} = getCurrentInstance()
-const state: any = reactive({})
-</script>
-
-<style lang="scss" scoped>
-</style>

+ 0 - 15
src/views/menu/menu2-1.vue

@@ -1,15 +0,0 @@
-<template>
-  <div>
-    菜单2-1
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive} from "vue";
-
-const {proxy} = getCurrentInstance()
-const state: any = reactive({})
-</script>
-
-<style lang="scss" scoped>
-</style>

+ 0 - 15
src/views/menu/menu2-2.vue

@@ -1,15 +0,0 @@
-<template>
-  <div>
-    菜单2-2
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive} from "vue";
-
-const {proxy} = getCurrentInstance()
-const state: any = reactive({})
-</script>
-
-<style lang="scss" scoped>
-</style>

+ 0 - 15
src/views/menu/menu2-3-1-1.vue

@@ -1,15 +0,0 @@
-<template>
-  <div>
-    菜单2-3-1-1
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive} from "vue";
-
-const {proxy} = getCurrentInstance()
-const state: any = reactive({})
-</script>
-
-<style lang="scss" scoped>
-</style>

+ 0 - 15
src/views/menu/menu2-3-1-2.vue

@@ -1,15 +0,0 @@
-<template>
-  <div>
-    菜单2-3-1-2
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive} from "vue";
-
-const {proxy} = getCurrentInstance()
-const state: any = reactive({})
-</script>
-
-<style lang="scss" scoped>
-</style>

+ 0 - 15
src/views/menu/menu2-3-2.vue

@@ -1,15 +0,0 @@
-<template>
-  <div>
-    菜单2-3-2
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive} from "vue";
-
-const {proxy} = getCurrentInstance()
-const state: any = reactive({})
-</script>
-
-<style lang="scss" scoped>
-</style>

+ 0 - 15
src/views/menu/menu3.vue

@@ -1,15 +0,0 @@
-<template>
-  <div>
-    菜单3
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive} from "vue";
-
-const {proxy} = getCurrentInstance()
-const state: any = reactive({})
-</script>
-
-<style lang="scss" scoped>
-</style>

+ 0 - 15
src/views/menu/menu4.vue

@@ -1,15 +0,0 @@
-<template>
-  <div>
-    菜单4
-  </div>
-</template>
-
-<script setup lang="ts">
-import {getCurrentInstance, reactive} from "vue";
-
-const {proxy} = getCurrentInstance()
-const state: any = reactive({})
-</script>
-
-<style lang="scss" scoped>
-</style>