import{g as s,c1 as e,s as t,r as a,o,p as n,w as r,q as l,t as i,v as u,D as c,E as d,F as m,H as h,Q as f,x as y,y as p,I as g}from"./index-P0fyQ2Em.js";import{_ as k}from"./u-search.CSVnMmHg.js";import{r as _}from"./uni-app.es.DOtS5Ldl.js";import{_ as I}from"./index.BuZ8YmVY.js";import{g as w}from"./system.C4NHCleV.js";import{_ as C}from"./_plugin-vue_export-helper.BCo6x5W8.js";import"./u-icon.wXcRZHbn.js";import"./resources.DEPsJg7u.js";const j=C({data:()=>({keyword:"",systemList:[],userInfo:{}}),onShow(){this.keyword="",this.getUserInfo(),this.init()},methods:{onSearchChange(s){this.init()},init(){w({keyword:this.keyword}).then((s=>{this.systemList=s.data||[]}))},async getUserInfo(){this.userInfo=s("userInfo")||{}},handelClick(s){if(s.id===this.userInfo.systemId)return;let o={majorId:s.id,majorType:"system",menuType:1};e(o).then((e=>{this.$u.toast(e.msg),t("systemCode",s.enCode),setTimeout((()=>{a({url:"/pages/index/index"})}),500)})).catch((s=>{this.$u.toast(s)}))}}},[["render",function(s,e,t,a,w,C){const j=_(o("u-search"),k),x=l,b=g,v=_(o("JnpfEmpty"),I);return i(),n(x,{class:"change-system-v"},{default:r((()=>[u(x,{class:"u-p-l-20 u-p-r-20 change-system-search"},{default:r((()=>[u(j,{placeholder:s.$t("app.apply.pleaseKeyword"),modelValue:w.keyword,"onUpdate:modelValue":e[0]||(e[0]=s=>w.keyword=s),height:"72","show-action":!1,onChange:C.onSearchChange,"bg-color":"#f0f2f6",shape:"square",style:{width:"100%"}},null,8,["placeholder","modelValue","onChange"])])),_:1}),u(x,{class:"system-box u-m-t-20"},{default:r((()=>[w.systemList.length?(i(),n(x,{key:0,class:"system-container"},{default:r((()=>[(i(!0),c(m,null,d(w.systemList,((s,e)=>(i(),n(x,{class:"item u-flex-col u-col-center",key:e,onClick:e=>C.handelClick(s)},{default:r((()=>[u(b,{class:h(["u-font-40 item-icon",s.icon]),style:f({background:s.backgroundColor||"#008cff"})},null,8,["class","style"]),u(b,{class:"u-font-24 u-line-1 item-text",style:f({color:w.userInfo.systemId==s.id?"#008cff":""})},{default:r((()=>[y(p(s.fullName),1)])),_:2},1032,["style"])])),_:2},1032,["onClick"])))),128))])),_:1})):(i(),n(v,{key:1}))])),_:1})])),_:1})}],["__scopeId","data-v-21e00811"]]);export{j as default};