Browse Source

设置应用菜单

v8_master
超级管理员 2 years ago
parent
commit
5bf6449ac3
  1. 112
      src/api/date/type.ts
  2. 1
      src/assets/icons/chaoSongWoDe.svg
  3. 1
      src/assets/icons/daiWoCuLi.svg
  4. 1
      src/assets/icons/fenZhu.svg
  5. 1
      src/assets/icons/liuChengBiaoDan.svg
  6. 1
      src/assets/icons/puTongBiaoDan.svg
  7. 1
      src/assets/icons/woChuangJianDe.svg
  8. 1
      src/assets/icons/woYiChuLi.svg
  9. BIN
      src/assets/images/13.png
  10. BIN
      src/assets/images/3.png
  11. 82
      src/components/IconSelect/appMenuSvgPage.vue
  12. 87
      src/components/IconSelect/svgPage.vue
  13. 2
      src/components/SvgIcon/index.vue
  14. 29
      src/types/components.d.ts
  15. 62
      src/views/sysworkflow/codepage/page.vue
  16. 114
      src/views/sysworkflow/lowcodepage/appPage/appMenus.vue
  17. 221
      src/views/sysworkflow/lowcodepage/appPage/index.vue
  18. 5
      src/views/sysworkflow/lowcodepage/workFlow.vue

112
src/api/date/type.ts

@ -65,3 +65,115 @@ export interface dataBaseStruct {
id?: string;
redashDatasourceId?: number;
}
/**
@ 作者: 秦东
@ 时间: 2024-04-22 11:43:21
@ 功能: 自建应用菜单树结构
*/
export interface appMenuTreeInfo {
id:string; //节点唯一识别符
label:string; //节点名称
type:number; //节点类型 1:目录;2:菜单;3:必定存在
svg?:string; //图标
pcIsShow:number; //pc端显示与隐藏
wapIsShow:number; //移动端显示与隐藏
isLock:number;
children?:appMenuTreeInfo[]; //子级
}
/**
@ 作者: 秦东
@ 时间: 2024-04-22 08:31:22
@ 功能: 实验拖拽树
*/
export let threeShiyanData = [
{
id:"1",
svg:"chaoSongWoDe",
label:"Hr管理",
type:1,
children:[
{
id:"2",
svg:"chaoSongWoDe",
label:"Hr看板",
type:2,
children:[]
},
{
id:"3",
svg:"chaoSongWoDe",
label:"员工档案",
type:2,
children:[]
},
{
id:"4",
svg:"chaoSongWoDe",
label:"绩效考核",
type:1,
children:[
{
id:"5",
svg:"chaoSongWoDe",
label:"统计分析",
type:1,
children:[
{
id:"6",
svg:"chaoSongWoDe",
label:"综合成绩",
type:2,
children:[]
},
{
id:"7",
svg:"chaoSongWoDe",
label:"指标分析",
type:2,
children:[]
}
]
},
{
id:"8",
svg:"chaoSongWoDe",
label:"考核方案",
type:1,
children:[
{
id:"9",
svg:"chaoSongWoDe",
label:"方案生成",
type:2,
children:[]
}
]
}
]
},
{
id:"10",
svg:"chaoSongWoDe",
label:"考勤管理",
type:2,
children:[]
},
]
},
{
id:"11",
svg:"chaoSongWoDe",
label:"应用管理",
type:1,
children:[
{
id:"",
svg:"chaoSongWoDe",
label:"应用中心",
type:2,
children:[]
},
]
}
];

1
src/assets/icons/chaoSongWoDe.svg

@ -0,0 +1 @@
<svg t="1713594202430" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="12832" width="200" height="200"><path d="M536.539429 565.357714a102.144 102.144 0 0 1 16.036571-67.547428l4.205714-5.485715a356.205714 356.205714 0 0 0 95.652572-231.990857c-1.92-123.501714-77.074286-198.052571-182.857143-198.052571-106.624 0-180.571429 72.740571-180.571429 195.2a347.245714 347.245714 0 0 0 95.250286 234.422857l4.608 4.681143 2.377143 6.217143c25.362286 66.358857-6.930286 117.266286-44.946286 126.555428-98.742857 40.027429-168.777143 84.114286-209.718857 131.364572a126.171429 126.171429 0 0 0-30.665143 82.651428v39.350857a49.974857 49.974857 0 0 0 49.371429 50.541715h335.908571a300.544 300.544 0 0 0 47.670857 62.171428H155.190857A111.542857 111.542857 0 0 1 45.129143 882.651429v-39.350858a189.44 189.44 0 0 1 46.006857-123.977142c48.237714-55.625143 125.878857-104.612571 236.763429-149.193143 8.082286-2.029714 16.457143-14.409143 8.740571-39.094857a410.934857 410.934857 0 0 1-108.397714-273.627429C228.242286 100.004571 329.965714 0 469.613714 0c138.733714 0 241.206857 101.613714 243.638857 259.657143a418.468571 418.468571 0 0 1-83.657142 241.371428 295.515429 295.515429 0 0 0-92.909715 64.347429zM737.298286 1024a246.326857 246.326857 0 0 1-0.164572-492.525714h0.164572a246.326857 246.326857 0 0 1 0 492.525714z m0-51.858286a194.468571 194.468571 0 1 0-189.769143-194.413714A192.128 192.128 0 0 0 737.298286 972.068571z m-73.142857-209.645714c-30.72-59.465143-9.142857-81.92 49.371428-49.682286l105.325714 58.221715c58.002286 32.054857 51.620571 52.534857-13.513142 45.714285l-44.544-4.553143 4.516571 46.957715c6.473143 67.2-13.165714 73.563429-43.885714 14.006857l-57.179429-110.738286z" fill="currentColor" p-id="12833"></path></svg>

After

Width:  |  Height:  |  Size: 1.7 KiB

1
src/assets/icons/daiWoCuLi.svg

@ -0,0 +1 @@
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1713593859030" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="817" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M443.890033 1023.9995H196.927154c-89.934956 0-162.542921-70.688965-162.542921-157.385923V157.385923C34.385233 70.509966 107.412198 0 196.928154 0H801.769859c89.934956 0 162.601921 70.748965 162.60192 157.385923v294.267856a33.455984 33.455984 0 0 1-66.851967 0V157.385923a94.431954 94.431954 0 0 0-95.929953-92.692955H196.928154a94.431954 94.431954 0 0 0-95.930953 92.692955v709.047654a94.431954 94.431954 0 0 0 95.929953 92.692955H443.710033a32.436984 32.436984 0 1 1 0 64.872968z" p-id="818"></path><path d="M249.090128 247.919879h447.336782q32.315984 0 32.315984 32.316984v0.06q0 32.316984-32.315984 32.316984H249.090128q-32.316984 0-32.316984-32.316984v-0.06q0-32.315984 32.316984-32.315984zM253.647126 495.841758h281.915862q32.316984 0 32.316985 32.315984v0.06q0 32.316984-32.316985 32.316984H253.647126q-32.316984 0-32.316984-32.316984v-0.06q0-32.315984 32.316984-32.315984zM869.461825 806.176606a22.063989 22.063989 0 0 1-22.003989 22.00499H759.859879a22.003989 22.003989 0 0 1-21.883989-22.00499v-87.595957a21.883989 21.883989 0 0 1 43.767978 0v65.951968h65.951968a21.883989 21.883989 0 0 1 22.004989 21.883989z" p-id="819"></path><path d="M773.769872 560.054727A215.843895 215.843895 0 1 0 989.615767 775.899621 215.843895 215.843895 0 0 0 773.769872 560.054727z m0 380.724814A164.879919 164.879919 0 1 1 938.652792 775.899621 164.879919 164.879919 0 0 1 773.769872 940.779541z" p-id="820"></path></svg>

After

Width:  |  Height:  |  Size: 1.7 KiB

1
src/assets/icons/fenZhu.svg

@ -0,0 +1 @@
<svg t="1713757185363" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="9936" width="200" height="200"><path d="M256 512 256 448l384 0 0 64L332.8 512 256 512zM320 832l64 0 0 64L320 896 281.6 896 256 896 39.488 896C14.72 896 0 899.008 0 874.24L0 423.68 0 384 0 320 0 259.84 0 134.4C0 108.288 15.872 64 42.048 64l353.28 0C421.44 64 448 108.288 448 134.4L448 192l461.888 0C934.592 192 960 235.136 960 259.84L960 384l-64 0-128 0L64 384l0 39.68L64 832l192 0L320 832zM64 320l832 0L896 256 442.688 256 384 256 384 215.04 384 128 64 128l0 131.84L64 320zM832 640 832 576l-64 0 0 320 64 0 0-64 192 0 0 192-192 0 0-64-128 0 0-64 0-128-64 0 0 128L448 896 448 576l192 0 0 128 64 0L704 576 704 512l64 0 64 0L832 448l192 0 0 192L832 640zM896 576l64 0L960 512l-64 0L896 576zM576 640 512 640l0 192 64 0L576 640zM896 960l64 0 0-64-64 0L896 960z" p-id="9937"></path></svg>

After

Width:  |  Height:  |  Size: 897 B

1
src/assets/icons/liuChengBiaoDan.svg

@ -0,0 +1 @@
<svg t="1713756956200" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="7983" width="200" height="200"><path d="M451.168317 1024h-364.990099A25.346535 25.346535 0 0 1 60.831683 998.653465v-892.198019A25.346535 25.346535 0 0 1 86.178218 81.108911h114.870495a25.346535 25.346535 0 0 1 0 50.693069H111.524752v841.504951h339.643565a25.346535 25.346535 0 0 1 0 50.693069zM897.267327 537.346535a25.346535 25.346535 0 0 1-25.346535-25.346535V131.80198h-92.362772a25.346535 25.346535 0 0 1 0-50.693069H897.267327a25.346535 25.346535 0 0 1 25.346534 25.346535v405.544554a25.346535 25.346535 0 0 1-25.346534 25.346535z" p-id="7984"></path><path d="M775.60396 212.910891h-567.762376a25.346535 25.346535 0 0 1-25.346534-25.346535v-162.217821A25.346535 25.346535 0 0 1 207.841584 0h567.762376A25.346535 25.346535 0 0 1 800.950495 25.346535v162.217821a25.346535 25.346535 0 0 1-25.346535 25.346535zM233.188119 162.217822h517.069307V50.693069H233.188119zM735.049505 375.128713h-486.653465a25.346535 25.346535 0 0 1 0-50.693069h486.653465a25.346535 25.346535 0 0 1 0 50.693069zM410.613861 598.178218h-162.217821a25.346535 25.346535 0 0 1 0-50.693069h162.217821a25.346535 25.346535 0 0 1 0 50.693069zM329.50495 821.227723h-81.10891a25.346535 25.346535 0 0 1 0-50.69307h81.10891a25.346535 25.346535 0 0 1 0 50.69307zM775.60396 699.564356h-202.772277a65.90099 65.90099 0 0 1 0-131.80198h202.772277a65.90099 65.90099 0 0 1 0 131.80198z m-202.772277-81.10891a15.207921 15.207921 0 0 0 0 30.415841h202.772277a15.207921 15.207921 0 0 0 0-30.415841zM775.60396 861.782178h-202.772277a65.90099 65.90099 0 0 1 0-131.80198h202.772277a65.90099 65.90099 0 0 1 0 131.80198z m-202.772277-81.108911a15.207921 15.207921 0 0 0 0 30.415842h202.772277a15.207921 15.207921 0 0 0 0-30.415842zM775.60396 1024h-202.772277a65.90099 65.90099 0 0 1 0-131.80198h202.772277a65.90099 65.90099 0 0 1 0 131.80198z m-202.772277-81.108911a15.207921 15.207921 0 0 0 0 30.415842h202.772277a15.207921 15.207921 0 0 0 0-30.415842z" p-id="7985"></path><path d="M532.277228 821.227723C449.850297 821.227723 385.267327 774.488713 385.267327 714.772277S449.850297 608.316832 532.277228 608.316832a25.346535 25.346535 0 0 1 0 50.693069c-56.776238 0-96.316832 29.40198-96.316832 55.762376s39.540594 55.762376 96.316832 55.762376a25.346535 25.346535 0 0 1 0 50.69307zM816.158416 983.445545a25.346535 25.346535 0 0 1 0-50.69307c56.776238 0 96.316832-29.40198 96.316832-55.762376S872.934653 821.227723 816.158416 821.227723a25.346535 25.346535 0 0 1 0-50.69307C898.585347 770.534653 963.168317 817.273663 963.168317 876.990099S898.585347 983.445545 816.158416 983.445545z" p-id="7986"></path></svg>

After

Width:  |  Height:  |  Size: 2.6 KiB

1
src/assets/icons/puTongBiaoDan.svg

@ -0,0 +1 @@
<svg t="1713756831580" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="6930" width="200" height="200"><path d="M288 512l256 0C561.92 512 576 497.92 576 480 576 462.08 561.92 448 544 448l-256 0C270.08 448 256 462.08 256 480 256 497.92 270.08 512 288 512zM768 64 192 64C121.6 64 64 121.6 64 192l0 576c0 70.4 57.6 128 128 128l576 0c70.4 0 128-57.6 128-128L896 192C896 121.6 838.4 64 768 64zM832 768c0 35.2-28.8 64-64 64L192 832c-35.2 0-64-28.8-64-64L128 192c0-35.2 28.8-64 64-64l576 0c35.2 0 64 28.8 64 64L832 768zM672 256l-384 0C270.08 256 256 270.08 256 288 256 305.92 270.08 320 288 320l384 0C689.92 320 704 305.92 704 288 704 270.08 689.92 256 672 256zM608 640l-320 0C270.08 640 256 654.08 256 672l0 0C256 689.92 270.08 704 288 704l320 0c17.92 0 32-14.08 32-32l0 0C640 654.08 625.92 640 608 640z" p-id="6931"></path></svg>

After

Width:  |  Height:  |  Size: 867 B

1
src/assets/icons/woChuangJianDe.svg

@ -0,0 +1 @@
<svg t="1713594317729" class="icon" viewBox="0 0 1099 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="19212" width="200" height="200"><path d="M222.42623 268.590164H125.17141C107.03318 268.590164 92.327869 285.502951 92.327869 306.360656s14.705311 37.770492 32.843541 37.770492H222.42623v97.254819c0 18.13823 16.912787 32.843541 37.770491 32.843541s37.770492-14.705311 37.770492-32.843541V344.131148h97.25482C413.360262 344.131148 428.065574 327.218361 428.065574 306.360656S413.360262 268.590164 395.222033 268.590164H297.967213V171.335344c0-18.13823-16.912787-32.843541-37.770492-32.843541s-37.770492 14.705311-37.770491 32.843541V268.590164z m616.918032-59.442361c-21.571148-5.036066-44.048787-7.70518-67.147541-7.70518-162.245246 0-293.770492 131.525246-293.770491 293.770492 0 78.780852 31.01377 150.326557 81.500327 203.079344C454.446164 763.803279 381.456787 876.695082 370.688 1007.213115H83.934426c-46.356984 0-83.934426-37.577443-83.934426-83.934426V83.934426C0 37.577443 37.577443 0 83.934426 0h671.47541c46.356984 0 83.934426 37.577443 83.934426 83.934426v125.213377zM772.196721 713.442623c-120.529836 0-218.229508-97.699672-218.229508-218.229508s97.699672-218.229508 218.229508-218.229508 218.229508 97.699672 218.229509 218.229508-97.699672 218.229508-218.229509 218.229508z m-327.344262 307.426623C454.756721 890.686951 540.789508 781.79882 658.549508 738.622951a276.009967 276.009967 0 0 0 112.690361 23.887738c40.137443 0 78.277246-8.536131 112.698754-23.887738 117.751607 43.175869 203.792787 152.072393 213.697049 282.246295H444.852459z" fill="currentColor" p-id="19213"></path></svg>

After

Width:  |  Height:  |  Size: 1.6 KiB

1
src/assets/icons/woYiChuLi.svg

@ -0,0 +1 @@
<svg t="1713593953149" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="3009" width="200" height="200"><path d="M631.249893 1022.319395H248.948766a105.512773 105.512773 0 0 1-39.311546-7.306979 102.078493 102.078493 0 0 1-33.319823-21.190238 97.182817 97.182817 0 0 1-22.140146-31.931497A93.821607 93.821607 0 0 1 146.651063 924.33281V97.913515c0-25.939775 10.814329-50.929642 29.958613-69.270158C195.82703 10.22977 221.912944 0 248.948766 0h599.172256c27.035821 0 53.121735 10.30284 72.339089 28.716426 19.144284 18.340517 29.958613 43.330384 29.958613 69.270159v519.306979a30.90852 30.90852 0 0 1-4.530327 13.66405 32.516055 32.516055 0 0 1-10.375909 10.37591 32.954474 32.954474 0 0 1-31.2008 0 230.09676 230.09676 0 0 0-84.030255-16.221493 225.858713 225.858713 0 0 0-83.664907 16.294562c-26.451263 10.668189-50.491223 26.232054-70.658484 45.814757a207.810475 207.810475 0 0 0-46.764664 68.466391c-10.814329 25.501356-16.075353 52.829456-15.783074 80.376766 0 49.395176 18.852005 97.182817 52.902526 134.302269a31.200799 31.200799 0 0 1 5.041815 34.050521 32.296846 32.296846 0 0 1-12.202654 13.517911 34.3428 34.3428 0 0 1-17.902098 5.041815v-0.657628zM248.948766 64.301413a36.607963 36.607963 0 0 0-25.428286 9.718282 33.685172 33.685172 0 0 0-10.52205 24.113029V924.33281c0 9.133723 3.799629 17.829028 10.52205 24.332239a36.754103 36.754103 0 0 0 25.428286 10.083631h319.168831a262.758955 262.758955 0 0 1 29.008705-290.671614 284.387612 284.387612 0 0 1 128.456686-89.29128 296.590267 296.590267 0 0 1 158.34223-9.499073V97.913515a32.589125 32.589125 0 0 0-10.52205-24.11303A35.365777 35.365777 0 0 0 848.121022 64.301413H248.948766z" fill="currentColor" p-id="3010"></path><path d="M756.856857 906.649922a29.958613 29.958613 0 0 1-22.359355-9.572143l-63.936063-63.936064a31.346939 31.346939 0 0 1 22.359354-53.340944c8.403026 0 16.440702 3.36121 22.359355 9.206793l44.134152 44.134151 93.383188-93.383188a30.689311 30.689311 0 0 1 44.71871 0 31.346939 31.346939 0 0 1 0 44.134152l-118.299986 111.285286a31.346939 31.346939 0 0 1-22.359355 11.471957zM448.063936 527.125446H290.744684a31.931497 31.931497 0 1 1 0-63.936064h157.319252a31.931497 31.931497 0 1 1 0 63.936064z m296.663337-265.974026H290.744684a32.004567 32.004567 0 0 1 0-63.936064h453.982589a32.004567 32.004567 0 0 1 0 63.936064z m0 120.857428H290.744684a32.004567 32.004567 0 0 1 0-63.936064h453.982589a32.004567 32.004567 0 0 1 0 63.936064z" fill="currentColor" p-id="3011"></path></svg>

After

Width:  |  Height:  |  Size: 2.4 KiB

BIN
src/assets/images/13.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.8 KiB

BIN
src/assets/images/3.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.8 KiB

After

Width:  |  Height:  |  Size: 55 KiB

82
src/components/IconSelect/appMenuSvgPage.vue

@ -0,0 +1,82 @@
<!--
@ 作者: 秦东
@ 时间: 2024-04-22 14:39:07
@ 备注: 选择图标弹窗
-->
<script lang='ts' setup>
import SvgIcon from "@/components/SvgIcon/index.vue";
import SvgPage from "@/components/IconSelect/svgPage.vue";
const props = defineProps({
isShow:{
type: Boolean,
default: false,
},
svgName:{
type:String,
require: false,
default:""
},
iconList:{
type:Object,
default(){
return {}
}
}
});
const visible = ref(false); //
const iconSelectorRef = ref();
const iconSelectorDialogRef = ref();
const emits = defineEmits(["update:isShow","update:svgName"]);
const filterIconNames = ref<string[]>([]);
//
onClickOutside(iconSelectorRef, () => (visible.value = false), {
ignore: [iconSelectorDialogRef],
});
watch(() => props.isShow, (val:boolean) =>{
if(val){
filterIconNames.value = props.iconList
}
})
/**
@ 作者: 秦东
@ 时间: 2024-04-22 16:43:49
@ 功能: 关闭
*/
const handleClose = () => {
emits("update:isShow",false)
}
/**
@ 作者: 秦东
@ 时间: 2024-04-22 16:54:03
@ 功能: 确定
*/
const sendClick = () => {
emits("update:svgName","liuChengBiaoDan")
handleClose()
}
</script>
<template>
<el-dialog
v-model="props.isShow"
title="选择图标"
width="500"
:before-close="handleClose"
>
<span>{{filterIconNames}}</span>
<template #footer>
<div class="dialog-footer">
<el-button @click="handleClose">取消</el-button>
<el-button type="primary" @click="sendClick">
确定
</el-button>
</div>
</template>
</el-dialog>
</template>
<style lang='scss' scoped>
</style>

87
src/components/IconSelect/svgPage.vue

@ -0,0 +1,87 @@
<!--
@ 作者: 秦东
@ 时间: 2024-04-22 16:05:27
@ 备注: 图标选择列表
-->
<script lang='ts' setup>
const allIconNames: string[] = []; //
const filterValue = ref(""); //
const filterIconNames = ref<string[]>([]); //
/**
@ 作者: 秦东
@ 时间: 2024-04-22 16:05:52
@ 功能: 加载svg
*/
const loadIcons =() => {
const icons = import.meta.glob("../../assets/icons/*.svg");
for (const icon in icons) {
const iconName = icon.split("assets/icons/")[1].split(".svg")[0];
allIconNames.push(iconName);
}
filterIconNames.value = allIconNames;
// console.log("icon --->",allIconNames);
}
onMounted(()=>{
loadIcons();
})
</script>
<template>
<div class="svgBox">
<el-input
v-model="filterValue"
class="p-2"
placeholder="搜索图标"
clearable
@input="handleFilter"
/>
<el-divider border-style="dashed" style="margin:0px;" />
<el-scrollbar height="150px">
<ul class="icon_list">
<li
v-for="(iconName, index) in filterIconNames"
:key="index"
class="icon-item"
@click="handleSelect(iconName)"
>
<el-tooltip :content="iconName" placement="bottom" effect="light">
<svg-icon color="var(--el-text-color-regular)" :icon-class="iconName" />
</el-tooltip>
</li>
</ul>
</el-scrollbar>
</div>
</template>
<style lang='scss' scoped>
.icon_list {
display: flex;
flex-wrap: wrap;
padding-left: 10px;
margin-top: 10px;
.icon-item {
display: flex;
flex-direction: column;
align-items: center;
justify-items: center;
width: 10%;
padding: 5px;
margin: 0 5px 5px 0;
cursor: pointer;
border: 1px solid #ccc;
padding: 5px 10px;
&:hover {
color: var(--el-color-primary);
border-color: var(--el-color-primary);
transition: all 0.2s;
transform: scaleX(1.1);
}
}
}
.svgBox{
:deep(.el-popper){
padding:0px;
}
}
</style>

2
src/components/SvgIcon/index.vue

@ -21,7 +21,7 @@ const props = defineProps({
},
color: {
type: String,
default: "",
default: "currentColor",
},
size: {
type: String,

29
src/types/components.d.ts

@ -11,6 +11,7 @@ declare module '@vue/runtime-core' {
export interface GlobalComponents {
AceDrawer: typeof import('./../components/DesignForm/aceDrawer.vue')['default']
AddNode: typeof import('./../components/workflow/addNode.vue')['default']
AppMenuSvgPage: typeof import('./../components/IconSelect/appMenuSvgPage.vue')['default']
ApproverDrawer: typeof import('./../components/workflow/drwer/approverDrawer.vue')['default']
BianXian: typeof import('./../components/DesignForm/designLayout/bianXian.vue')['default']
Breadcrumb: typeof import('./../components/Breadcrumb/index.vue')['default']
@ -22,7 +23,6 @@ declare module '@vue/runtime-core' {
DiyIconfont: typeof import('./../components/DesignForm/public/expand/diy-iconfont.vue')['default']
DragControl: typeof import('./../components/DesignForm/dragControl.vue')['default']
ElAffix: typeof import('element-plus/es')['ElAffix']
ElAlert: typeof import('element-plus/es')['ElAlert']
ElAside: typeof import('element-plus/es')['ElAside']
ElAvatar: typeof import('element-plus/es')['ElAvatar']
ElBreadcrumb: typeof import('element-plus/es')['ElBreadcrumb']
@ -53,17 +53,15 @@ declare module '@vue/runtime-core' {
ElFormItem: typeof import('element-plus/es')['ElFormItem']
ElHeader: typeof import('element-plus/es')['ElHeader']
ElIcon: typeof import('element-plus/es')['ElIcon']
ElIconExpand: typeof import('@element-plus/icons-vue')['Expand']
ElIconFold: typeof import('@element-plus/icons-vue')['Fold']
ElImage: typeof import('element-plus/es')['ElImage']
ElImageViewer: typeof import('element-plus/es')['ElImageViewer']
ElInput: typeof import('element-plus/es')['ElInput']
ElInputNumber: typeof import('element-plus/es')['ElInputNumber']
ElLink: typeof import('element-plus/es')['ElLink']
ElMain: typeof import('element-plus/es')['ElMain']
ElMenu: typeof import('element-plus/es')['ElMenu']
ElMenuItem: typeof import('element-plus/es')['ElMenuItem']
ElMenuItemGroup: typeof import('element-plus/es')['ElMenuItemGroup']
ElMenuMenu: typeof import('element-plus/es')['ElMenuMenu']
ElOption: typeof import('element-plus/es')['ElOption']
ElPagination: typeof import('element-plus/es')['ElPagination']
ElPopconfirm: typeof import('element-plus/es')['ElPopconfirm']
@ -76,7 +74,6 @@ declare module '@vue/runtime-core' {
ElRow: typeof import('element-plus/es')['ElRow']
ElScrollbar: typeof import('element-plus/es')['ElScrollbar']
ElSelect: typeof import('element-plus/es')['ElSelect']
ElSelectV2: typeof import('element-plus/es')['ElSelectV2']
ElSlider: typeof import('element-plus/es')['ElSlider']
ElSpace: typeof import('element-plus/es')['ElSpace']
ElStep: typeof import('element-plus/es')['ElStep']
@ -93,7 +90,6 @@ declare module '@vue/runtime-core' {
ElTimelineItem: typeof import('element-plus/es')['ElTimelineItem']
ElTimePicker: typeof import('element-plus/es')['ElTimePicker']
ElTooltip: typeof import('element-plus/es')['ElTooltip']
ElTransfer: typeof import('element-plus/es')['ElTransfer']
ElTree: typeof import('element-plus/es')['ElTree']
ElTreeSelect: typeof import('element-plus/es')['ElTreeSelect']
ElUpload: typeof import('element-plus/es')['ElUpload']
@ -116,35 +112,17 @@ declare module '@vue/runtime-core' {
Hamburger: typeof import('./../components/Hamburger/index.vue')['default']
HeadTools: typeof import('./../components/DesignForm/public/headTools.vue')['default']
HeadToolsNew: typeof import('./../components/DesignForm/public/headToolsNew.vue')['default']
Icon: typeof import('./../components/IconSelect/icon.vue')['default']
IconSelect: typeof import('./../components/IconSelect/index.vue')['default']
IEpCaretBottom: typeof import('~icons/ep/caret-bottom')['default']
IEpCaretTop: typeof import('~icons/ep/caret-top')['default']
IEpClose: typeof import('~icons/ep/close')['default']
IEpCollection: typeof import('~icons/ep/collection')['default']
IEpDelete: typeof import('~icons/ep/delete')['default']
IEpDownload: typeof import('~icons/ep/download')['default']
IEpEdit: typeof import('~icons/ep/edit')['default']
IEpMessageBox: typeof import('~icons/ep/message-box')['default']
<<<<<<< HEAD
IEpMinus: typeof import('~icons/ep/minus')['default']
=======
IEpMoreFilled: typeof import('~icons/ep/more-filled')['default']
>>>>>>> yjf_v3
IEpOperation: typeof import('~icons/ep/operation')['default']
IEpPicture: typeof import('~icons/ep/picture')['default']
IEpPlus: typeof import('~icons/ep/plus')['default']
IEpPosition: typeof import('~icons/ep/position')['default']
IEpRefresh: typeof import('~icons/ep/refresh')['default']
IEpRefreshLeft: typeof import('~icons/ep/refresh-left')['default']
IEpSearch: typeof import('~icons/ep/search')['default']
IEpSetting: typeof import('~icons/ep/setting')['default']
<<<<<<< HEAD
IEpTop: typeof import('~icons/ep/top')['default']
IEpUploadFilled: typeof import('~icons/ep/upload-filled')['default']
=======
IEpStar: typeof import('~icons/ep/star')['default']
>>>>>>> yjf_v3
IEpUser: typeof import('~icons/ep/user')['default']
IEpView: typeof import('~icons/ep/view')['default']
LangSelect: typeof import('./../components/LangSelect/index.vue')['default']
LayoutPage: typeof import('./../components/DesignForm/layoutPage/index.vue')['default']
@ -170,6 +148,7 @@ declare module '@vue/runtime-core' {
SingleUpload: typeof import('./../components/Upload/SingleUpload.vue')['default']
SizeSelect: typeof import('./../components/SizeSelect/index.vue')['default']
SvgIcon: typeof import('./../components/SvgIcon/index.vue')['default']
SvgPage: typeof import('./../components/IconSelect/svgPage.vue')['default']
TableListPage: typeof import('./../components/DesignForm/tableListPage/index.vue')['default']
Template: typeof import('./../components/DesignForm/template.vue')['default']
TextPage: typeof import('./../components/DesignForm/designLayout/textPage.vue')['default']

62
src/views/sysworkflow/codepage/page.vue

@ -54,68 +54,7 @@ const deleteCard = (index: number) => {
};
</script>
<template>
<<<<<<< HEAD
<cardadd v-model:visible="drawerRefadd" :keyval="props.visible" @data="handleNewCard"/>
<cardedit v-model:visible="drawerRefedit" :keyval="props.visible" @data="handleNewCard"/>
<el-row :gutter="10">
<el-col :xs="24" :sm="12" :md="12" :lg="6" :xl="6">
<div class="grid-content ep-bg-purple" >
<el-card class="cardlarge">
<template #header>
<div class="cardhead-large">
<el-row class="block-col-2">
<el-col style="text-align: right;">
<el-dropdown>
<span class="el-dropdown-link">
<el-icon><MoreFilled /></el-icon>
</span>
<template #dropdown>
<el-dropdown-menu>
<el-dropdown-item @click="opencardadd" >添加</el-dropdown-item>
<el-dropdown-item >编辑</el-dropdown-item>
<el-dropdown-item >删除</el-dropdown-item>
</el-dropdown-menu>
</template>
</el-dropdown>
</el-col>
<el-col style="text-align: left;">
<span>标题一</span>
</el-col>
</el-row>
</div>
</template>
<div class="grid-content ep-bg-purple" >
<el-row :gutter="10" >
<el-col v-for="(card, index) in cardData" :key="card.id" :xs="8" :sm="12" :md="8" :lg="8" :xl="8">
<el-card class="cardpattern">
<img
title="示例图片"
class="picture"
/>
<div class="cardhead">
<span>{{ card.name }}</span>
</div>
<div class="bottom">
<el-button size="small" circle class="button" :icon="View"></el-button>
<el-button size="small" circle class="button" :icon="Edit" @click="() => opencardedit(index)"></el-button>
<el-button size="small" circle class="button" :icon="Delete" @click="() => deleteCard(index)"></el-button>
</div>
</el-card>
</el-col>
</el-row>
</div>
</el-card>
</div>
</el-col>
</el-row>
<!-- 分页 -->
<div class="example-pagination-block">
<div class="example-demonstration"></div>
<el-pagination layout="prev, pager, next" :total="50" />
=======
<editpage v-model:Visible="dialogRefedit" @data="handleEdit" />
<div class="common-layout">
<el-container>
@ -161,7 +100,6 @@ const deleteCard = (index: number) => {
</el-main>
</el-container>
</el-container>
>>>>>>> yjf_v3
</div>
</template>
<style scoped>

114
src/views/sysworkflow/lowcodepage/appPage/appMenus.vue

@ -0,0 +1,114 @@
<!--
@ 作者: 秦东
@ 时间: 2024-04-22 08:56:40
@ 备注:
-->
<script lang='ts' setup>
import type {
AllowDropType,
NodeDropType,
} from 'element-plus/es/components/tree/src/tree.type'
import SvgIcon from "@/components/SvgIcon/index.vue";
import { threeShiyanData } from "@/api/date/type"
import AppMenuSvgPage from "@/components/IconSelect/appMenuSvgPage.vue";
const props = defineProps({
formKey:{
type:String,
default:""
}
});
const svgIsShow = ref(false)
/**
@ 作者: 秦东
@ 时间: 2024-04-22 10:06:20
@ 功能: 树移动完毕后执行的操作
*/
const handleDrop = (
draggingNode: Node,
dropNode: Node,
dropType: NodeDropType,
ev: DragEvents
) => {
console.log('tree drop:', dropNode.label, dropNode.key)
console.log('tree drop-->上级:', dropNode.parent.label, dropNode.parent.key)
}
/**
@ 作者: 秦东
@ 时间: 2024-04-22 15:53:35
@ 功能: 加载SVG图标
*/
const allIconNames:string[] = [];
const loadIcons = () => {
const icons = import.meta.glob("../../../../assets/icons/*.svg");
for (const icon in icons) {
const iconName = icon.split("assets/icons/")[1].split(".svg")[0];
allIconNames.push(iconName);
}
console.log("icons",icons)
console.log("allIconNames",allIconNames)
}
onMounted(()=>{
loadIcons();
})
/**
@ 作者: 秦东
@ 时间: 2024-04-22 16:52:03
@ 功能: 设置表单图标
*/
const svgName = ref("")
const setAppMenusSvg = (val:any) =>{
svgName.value = val.svg
svgIsShow.value = true;
}
</script>
<template>
<el-tree
:data="threeShiyanData"
draggable
default-expand-all
node-key="id"
:expand-on-click-node="false"
@node-drop="handleDrop"
>
<template #default="{ node, data }">
<div class="appMenuTitle">
<el-space wrap>
<svg-icon prefix="icon" :icon-class="data.svg" @click="setAppMenusSvg(data)" />
<el-text>{{node.label}}</el-text>
</el-space>
<el-dropdown>
<svg-icon class="svgBox" prefix="icon" icon-class="set" />
<template #dropdown>
<el-dropdown-item>修改名称</el-dropdown-item>
<el-dropdown-item>复制</el-dropdown-item>
<el-dropdown-item>移动到</el-dropdown-item>
<el-dropdown-item divided>新建子分组</el-dropdown-item>
<el-dropdown-item>新建普通表单</el-dropdown-item>
<el-dropdown-item>新建流程表单</el-dropdown-item>
<el-dropdown-item divided>隐藏PC端</el-dropdown-item>
<el-dropdown-item>隐藏移动端</el-dropdown-item>
<el-dropdown-item divided><el-text class="mx-1" type="danger">删除</el-text></el-dropdown-item>
</template>
</el-dropdown>
</div>
</template>
</el-tree>
<AppMenuSvgPage v-model:is-show="svgIsShow" v-model:svg-name="svgName" :icon-list="allIconNames" />
</template>
<style lang='scss' scoped>
.appMenuTitle{
width: 100%;
padding-right: 5px;
display: flex;
align-items: center;
justify-content: space-between;
.svgBox{
display: none;
}
}
.appMenuTitle:hover .svgBox{
display: block;
}
</style>

221
src/views/sysworkflow/lowcodepage/appPage/index.vue

@ -4,6 +4,10 @@
@ 备注: 设置自建应用
-->
<script lang='ts' setup>
import { Search } from '@element-plus/icons-vue'
import SvgIcon from "@/components/SvgIcon/index.vue";
import AppMenus from "@/views/sysworkflow/lowcodepage/appPage/appMenus.vue"
const props = defineProps({
drawerWith:{
type:Number,
@ -14,17 +18,158 @@ const props = defineProps({
default:""
}
});
const squareUrl = 'https://cube.elemecdn.com/9/c2/f0ee8a3c7c9638a54940382568c9dpng.png'
const drawerOpenOrClose = ref(true)
const tabsActive = ref("1")
/**
@ 作者: 秦东
@ 时间: 2024-04-19 15:47:12
@ 功能: 选择选项
*/
const handleClick = () =>{}
</script>
<template>
<div class="drawerClass">
<el-drawer v-model="drawerOpenOrClose" title="设置/编辑自定义表单" :with-header="false" :close-on-click-modal="false" :close-on-press-escape="false" :destroy-on-close="true" :size="props.drawerWith">
<div class="common-layout">
<el-container>
<el-header>Header</el-header>
<el-header class="headerBox">
<div>
<el-space wrap>
<el-avatar shape="square" :size="25" :src="squareUrl" />
<el-text>未命名应用</el-text>
<el-tag type="success">已启用</el-tag>
</el-space>
</div>
<div>
<el-tabs v-model="tabsActive" @tab-click="handleClick" :stretch="true" class="tabsMain">
<el-tab-pane label="① 页面管理" :name="1">
</el-tab-pane>
<el-tab-pane label="② 集成&自动化" :name="2">
</el-tab-pane>
<el-tab-pane label="③ 应用设置" :name="3">
</el-tab-pane>
<el-tab-pane label="④ 应用发布" :name="4">
</el-tab-pane>
</el-tabs>
</div>
<div>
<el-button plain>访问</el-button>
</div>
</el-header>
<el-container>
<el-aside width="200px">Aside</el-aside>
<el-main>Main</el-main>
<el-aside class="asideBox">
<el-row>
<el-col :span="24" class="asideBoxSearch">
<el-input
v-model="input2"
style="width: 180px"
placeholder="搜索"
:suffix-icon="Search"
/>
<el-dropdown>
<el-button type="primary" class="fa fa-plus" />
<template #dropdown>
<el-dropdown-menu>
<el-dropdown-item >
<el-row>
<el-col :span="24">
<el-space wrap>
<svg-icon style="color: #79bbff;" prefix="icon" icon-class="puTongBiaoDan" />
新建普通表单
</el-space>
</el-col>
<el-col :span="24" style="padding-left:20px; font-size:12px;">
数据收集事件记录
</el-col>
</el-row>
</el-dropdown-item>
<el-dropdown-item >
<el-row>
<el-col :span="24">
<el-space wrap>
<svg-icon style="color: #eebe77;" prefix="icon" icon-class="liuChengBiaoDan" />
新建流程表单
</el-space>
</el-col>
<el-col :span="24" style="padding-left:20px; font-size:12px;">
任务协同业务审批
</el-col>
</el-row>
</el-dropdown-item>
<el-dropdown-item divided>
<el-row>
<el-col :span="24">
<el-space wrap>
<svg-icon style="color: #337ecc;" prefix="icon" icon-class="fenZhu" />
新建分组
</el-space>
</el-col>
<el-col :span="24" style="padding-left:20px; font-size:12px;">
应用项目管理
</el-col>
</el-row>
</el-dropdown-item>
</el-dropdown-menu>
</template>
</el-dropdown>
</el-col>
</el-row>
<el-scrollbar class="scroBox">
<el-menu
default-active="1"
@open="handleOpen"
@close="handleClose"
>
<el-menu-item index="1" class="menuBox">
<div class="textCenter">
<el-space wrap>
<svg-icon prefix="icon" icon-class="daiWoCuLi" />
待我处理
</el-space>
</div>
<div>2</div>
</el-menu-item>
<el-menu-item index="2" class="menuBox">
<div class="textCenter">
<el-space wrap>
<svg-icon prefix="icon" icon-class="woYiChuLi" />
我已处理
</el-space>
</div>
<div>2</div>
</el-menu-item>
<el-menu-item index="3" class="menuBox">
<div class="textCenter">
<el-space wrap>
<svg-icon prefix="icon" icon-class="chaoSongWoDe" />
抄送我的
</el-space>
</div>
<div>2</div>
</el-menu-item>
<el-menu-item index="4" class="menuBox">
<div class="textCenter">
<el-space wrap>
<svg-icon prefix="icon" icon-class="woChuangJianDe" />
我创建的
</el-space>
</div>
<div>2</div>
</el-menu-item>
</el-menu>
<AppMenus :form-Key="formKey" />
</el-scrollbar>
</el-aside>
<el-main class="mainBox">
<el-scrollbar class="scroBox">
<svg-icon icon-class="0213-lmp" />
</el-scrollbar>
</el-main>
</el-container>
</el-container>
</div>
@ -33,5 +178,75 @@ const drawerOpenOrClose = ref(true)
</div>
</template>
<style lang='scss' scoped>
.common-layout{
.el-header{
padding-left:10px;
padding-right:10px;
}
.headerBox{
display: flex;
align-items: center;
justify-content: space-between;
border-bottom: 1px solid #F1F2F3;
:deep(.el-tabs__nav-wrap::after) {
position: static !important;
}
:deep(.el-tabs__header){
margin:0 0 1px 0;
}
}
.asideBox{
width:250px;
border-right: 1px solid #F1F2F3;
height: calc(100vh - 40px);
.asideBoxSearch{
display: flex;
align-items: center;
justify-content: space-between;
padding: 10px 10px;
}
.scroBox{
height: calc(100vh - 95px);
.el-menu{
border-right: 0px;
}
li{
padding-left:10px;
padding-right:10px;
}
.menuBox{
display: flex;
align-items: center;
justify-content: space-between;
.textCenter{
display: flex;
align-items: center;
}
}
.el-menu-item{
height:40px;
}
.el-menu-item.is-active {
color: var(--el-menu-active-color);
background-color: #e4e4e4e4;
}
.el-menu-item:hover{
background-color: #f1f1f1f1!important;
}
}
}
.el-main {
padding: 10px;
}
.mainBox{
background-color: #F1F2F3;
.scroBox{
height: calc(100vh - 60px);
}
}
}
</style>

5
src/views/sysworkflow/lowcodepage/workFlow.vue

@ -543,6 +543,7 @@ onMounted(()=>{
<template #icon>
流程可实现需要多人流转的业务场景<br>绘制流程图设定数据流转方式即可搭建线上工作流<br><br>
<el-image
class="imgBox"
:src="FlowImgSrc"
/>
</template>
@ -566,6 +567,10 @@ onMounted(()=>{
display: flex;
align-items: center;
justify-content: center;
.imgBox{
height: calc(100vh - 400px);
// height: 10%;
}
}
/* 去掉tabs标签栏下的下划线 */
::v-deep .el-tabs__nav-wrap::after {

Loading…
Cancel
Save