Files
Migu2.0/MiGu.Server/wwwroot/assets/AppShell-BE7Z2zMC.js
T

2 lines
9.7 KiB
JavaScript
Raw Normal View History

2026-05-31 00:16:56 +08:00
import{aG as R,bt as O,bv as G,b7 as o,aA as p,bH as e,aF as t,$ as me,aE as u,av as f,a0 as ue,X as pe,bw as q,az as a,b2 as V,bo as s,br as l,Q as H,aq as J,K,aC as y,ah as S,bh as T,J as Q,b1 as A,ar as _e,aB as D,I as X,aj as Z,aD as be,A as fe,bu as he,bj as ge,m as ve,V as ke,a6 as ye,W as we,bk as I,P as Ee,aP as Ce,aL as Me,p as Se,q as xe,n as Pe,U as $e,M as De,aR as Ie,aZ as W,bp as Te,b3 as j,bm as Ae,a_ as Re,bA as Ne,bc as Be}from"./index-D5OuyicD.js";/* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css */import"./el-tooltip-l0sNRNKZ.js";/* empty css */const Le="/FRLD-logo-white-no_title.png",ze="/FRLD-logo-white.png",Fe=R({__name:"ScopeSwitcher",setup(N){const i=O(),E=G(),r=f(()=>i.scope??"Platform");let c=!1;async function g(_){if(!c){c=!0;try{await w(_)}finally{c=!1}}}async function w(_){try{await i.switchScope(_),E.push(_==="Platform"?"/admin/map-monitor":"/monitor/map")}catch(b){pe.error(b?.message??`切换到 ${_} 失败`)}}return(_,b)=>{const C=me,x=ue;return o(),p(x,{"model-value":r.value,size:"small",onChange:g},{default:e(()=>[t(C,{value:"Platform"},{default:e(()=>[...b[0]||(b[0]=[u("管理员",-1)])]),_:1}),t(C,{value:"RCSMonitor"},{default:e(()=>[...b[1]||(b[1]=[u("运营",-1)])]),_:1})]),_:1},8,["model-value"])}}}),Ue=["title"],Ve={class:"theme-label"},We={class:"option-text"},je={class:"option-name"},Oe={class:"option-desc"},Ge=R({__name:"ThemeSwitcher",setup(N){const i=q(),E=f(()=>({background:`linear-gradient(135deg, ${i.activeTheme.preview} 0%, ${i.activeTheme.previewAccent} 100%)`}));function r(g){const w=i.getMergedTheme(g);return{background:`linear-gradient(135deg, ${w.preview} 0%, ${w.previewAccent} 100%)`}}function c(g){i.setThemeId(g)}return(g,w)=>{const _=H,b=Q,C=K,x=X;return o(),p(x,{trigger:"click",onCommand:c},{dropdown:e(()=>[t(C,{class:"theme-menu"},{default:e(()=>[(o(!0),y(S,null,T(l(i).availableThemes,h=>(o(),p(b,{key:h.id,command:h.id,class:A({"is-active":h.id===l(i).themeId})},{default:e(()=>[a("span",{class:"option-swatch",style:V(r(h))},null,4),a("span",We,[a("span",je,s(h.name),1),a("span",Oe,s(h.description),1)]),h.id===l(i).themeId?(o(),p(_,{key:0,class:"check"},{default:e(()=>[t(l(_e))]),_:1})):D("",!0)]),_:2},1032,["command","class"]))),128))]),_:1})]),default:e(()=>[a("button",{class:"theme-trigger",type:"button",title:`当前主题:${l(i).activeTheme.name}`},[a("span",{class:"swatch",style:V(E.value)},null,4),a("span",Ve,s(l(i).activeTheme.name),1),t(_,{class:"caret"},{default:e(()=>[t(l(J))]),_:1})],8,Ue)]),_:1})}}}),qe=Z(Ge,[["__scopeId","data-v-28ea4aeb"]]),He={class:"app-shell"},Je={class:"aside-footer"},Ke={key:0},Qe={class:"header-left"},Xe={class:"header-right"},Ze={class:"user-link"},Ye={class:"user-name"},ea=R({__name:"AppShell",setup(N){const i=he(),E=G(),r=O(),c=q(),g=f(()=>"localhost:8223".split(":")[1]??"8223"),w=f(()=>"/api"),_=f(()=>(r.user?.displayName??r.user?.username??"?").slice(0,1).toUpperCase()),b=f(()=>r.scope==="Platform"?"管理员 (Platform)":"运营 (RCSMonitor)"),C=f(()=>{switch(r.runMode){case"WebOnly":return"Web-Only";case"WebEnabled":return"Web + Desktop";case"Detached":return"SimpleLite 未连接";default:return String(r.runMode??"Unknown")}}),x=[{path:"/admin/dashboard",label:"总览",icon:Ie,key:"admin-dashboard"},{path:"/admin/map-monitor",label:"地图监控",icon:W,key:"admin-map-monitor"},{path:"/admin/design",label:"设计与编排",icon:Te,children:[{path:"/admin/map-editor",label:"地图编辑",key:"admin-map-editor"},{path:"/admin/project-properties",label:"项目属性",key:"admin-project-properties"},{path:"/admin/tracks",label:"场景管理",key:"admin-tracks"},{path:"/admin/cars",label:"车辆管理",key:"admin-cars"},{path:"/admin/vehicle-hub",label:"车辆运维",key:"admin-vehicle-hub"},{path:"/admin/processes",label:"进程管理",key:"admin-processes"},{path:"/admin/scripts",label:"脚本管理",key:"admin-scripts"},{path:"/admin/missions",label