import{d as a,b as e,a2 as t,r as s,c as i,e as n,T as c,o,h as g,w as p,k as l,l as r,F as h,j as m,N as d,A as b,bN as P,z as u,i as v,a as _,t as w,v as x,aN as S,aF as f,aU as I,O as y}from"./index-Dnh6GPlT.js";/* empty css                                                              */import{_ as k}from"./_plugin-vue_export-helper.BCo6x5W8.js";const j=k(a({__name:"index",props:{pagePath:{default:""},type:{default:0}},setup(a){let k=e();const j=a,{pagePath:F,type:N}=t(j),A=s(!1),C=s(!0);let O=i((()=>k.state.app.enterpriseAuth)),T=i((()=>k.state.app.scheduleMenuPermission)),z=s("/pages/index/index");const B=n([{iconPath:"/static/image/bar-logo01.png",name:"消息",pagePath:"/pages/index/index",selectedIconPath:"/static/image/bar-logo01-active.png",isShow:1},{iconPath:"/static/image/bar-logo02.png",name:"社区",pagePath:"/pages/forum/index",selectedIconPath:"/static/image/bar-logo02-active.png",isShow:1},{iconPath:"/static/image/bar-logo03.png",name:"工作台",pagePath:"/pages/workbench/index",selectedIconPath:"/static/image/bar-logo03-active.png",isShow:1},{iconPath:"/static/image/bar-logo05.png",name:"通讯录",pagePath:"/pages/user/index",selectedIconPath:"/static/image/bar-logo05-active.png",isShow:1}]),H=n([{iconPath:"/static/image/bar-logo07.png",name:"写汇报",pagePath:"/pages/users/report/index",selectedIconPath:"/static/image/bar-logo07-active.png",isShow:1},{iconPath:"/static/image/bar-logo06.png",name:"看汇报",pagePath:"/pages/users/report/check",selectedIconPath:"/static/image/bar-logo06-active.png",isShow:1},{iconPath:"/static/image/bar-logo12.png",name:"统计",pagePath:"/pages/users/report/census",selectedIconPath:"/static/image/bar-logo12-active.png",isShow:0}]),M=n([{iconPath:"/static/image/bar-logo09.png",name:"新申请",pagePath:"/pages/users/examine/index",selectedIconPath:"/static/image/bar-logo09-active.png",isShow:1},{iconPath:"/static/image/bar-logo10.png",name:"我审批的",pagePath:"/pages/users/examine/approve",selectedIconPath:"/static/image/bar-logo10-active.png",isShow:1},{iconPath:"/static/image/bar-logo11.png",name:"已发起",pagePath:"/pages/users/examine/center",selectedIconPath:"/static/image/bar-logo11-active.png",isShow:1}]),Q=n([{iconPath:"/static/image/bar-logo13.png",name:"最新",pagePath:"/pages/users/memorandum/index",selectedIconPath:"/static/image/bar-logo13-active.png",isShow:1},{iconPath:"/static/image/bar-logo14.png",name:"文件夹",pagePath:"/pages/users/memorandum/folder",selectedIconPath:"/static/image/bar-logo14-active.png",isShow:1}]),U=n([{iconPath:"/static/image/attendance/tab-0-0.png",name:"打卡",pagePath:"/pages/attendance/index",selectedIconPath:"/static/image/attendance/tab-0-1.png",isShow:1},{iconPath:"/static/image/attendance/tab-1-0.png",name:"申请",pagePath:"/pages/attendance/apply",selectedIconPath:"/static/image/attendance/tab-1-1.png",isShow:1},{iconPath:"/static/image/attendance/tab-2-0.png",name:"统计",pagePath:"/pages/attendance/statistics",selectedIconPath:"/static/image/attendance/tab-2-1.png",isShow:1},{iconPath:"/static/image/attendance/tab-3-0.png",name:"排班",pagePath:"/pages/attendance/schedule",selectedIconPath:"/static/image/attendance/tab-3-1.png",isShow:0}]),q=n({tabbar:[]});return c((()=>[N,O,T]),((a,e)=>{const t=a[0].value;0===t?q.tabbar=B:1===t?(H[2].isShow=a[1].value.manage_auth,q.tabbar=H):2===t?q.tabbar=M:3===t?q.tabbar=Q:4===t&&(U[3].isShow=T.value?1:0,q.tabbar=U,P())}),{deep:!0,immediate:!0}),(a,e)=>{const t=y,s=u;return o(),g(s,{id:"tabbar",class:b(["uni-tabbar display-center",{borderShow:A.value}])},{default:p((()=>[C.value&&q.tabbar.length?(o(!0),l(h,{key:0},r(q.tabbar,((a,e)=>(o(),l(h,{key:e},[a.isShow?(o(),g(s,{key:0,class:"uni-tabbar_item",onClick:e=>(a=>{if(z.value=a.pagePath,0===N.value)x({url:z.value});else if([2,4].includes(N.value))S({url:z.value});else{const e=f(),t=e[e.length-1].route;if(a.pagePath.indexOf(t)>-1)return!1;I({url:z.value,animationType:"fade-in"})}})(a)},{default:p((()=>[v(s,{class:"uni-tabbar_icon"},{default:p((()=>[a.pagePath===_(F)?(o(),g(t,{key:0,mode:"aspectFit",src:a.selectedIconPath},null,8,["src"])):(o(),g(t,{key:1,mode:"aspectFit",src:a.iconPath},null,8,["src"]))])),_:2},1024),v(s,{class:b(["uni-tabbar_label",{active:a.pagePath==_(F)}])},{default:p((()=>[m(w(a.name),1)])),_:2},1032,["class"])])),_:2},1032,["onClick"])):d("",!0)],64)))),128)):B.length?d("",!0):(o(),g(s,{key:1,class:"empty-img"},{default:p((()=>[m("暂无数据，请设置")])),_:1}))])),_:1},8,["class"])}}}),[["__scopeId","data-v-52e41acf"]]);export{j as B};
