import{_ as w,n as g,am as m}from"./index-CsRk2AqG.js";import{a as k}from"./VRow-DHfYjRE7.js";import{a0 as f}from"./vendor-vuetify-BaOIwHiz.js";import{R as b,X as n,Y as _,Z as x,k as t,a1 as r,S as s,_ as l,F as c,a2 as p,$ as o,n as C}from"./vendor-vue-wu2SJQxD.js";const A={name:"AttendanceSidebar",props:{studentList:{type:Array,required:!0},attendance:{type:Object,required:!0},isEditingDisabled:{type:Boolean,default:!1}},emits:["click","disabled-click"],setup(){return{display:f()}},methods:{getSetting:g,handleClick(){this.isEditingDisabled?this.$emit("disabled-click"):this.$emit("click")}}},D={style:{"white-space":"nowrap"}},S={style:{"white-space":"nowrap"}},L={style:{"white-space":"nowrap"}},v={key:0},B={style:{"white-space":"nowrap"}},E={style:{"white-space":"nowrap"}},V={key:0},N={style:{"white-space":"nowrap"}},U={style:{"white-space":"nowrap"}},q={key:0},F={style:{"white-space":"nowrap"}};function M(h,e,a,u,R,y){return a.studentList&&a.studentList.length?b((n(),_(k,{key:0,class:C([{"cursor-not-allowed":a.isEditingDisabled},"attendance-area no-select"]),cols:"1",onClick:y.handleClick},{default:x(()=>[e[10]||(e[10]=t("h1",null,"出勤",-1)),t("h2",null,[e[0]||(e[0]=t("span",{style:{"white-space":"nowrap"}}," 应到",-1)),e[1]||(e[1]=r(" : ",-1)),t("span",D,s(a.studentList.length-a.attendance.exclude.length)+"人 ",1)]),t("h2",null,[e[2]||(e[2]=t("span",{style:{"white-space":"nowrap"}}," 实到",-1)),e[3]||(e[3]=r(" : ",-1)),t("span",S,s(a.studentList.length-a.attendance.absent.length-!y.getSetting("display.lateStudentsArePresent")*a.attendance.late.length-a.attendance.exclude.length)+"人 ",1)]),t("h2",null,[e[4]||(e[4]=t("span",{style:{"white-space":"nowrap"}}," 请假",-1)),e[5]||(e[5]=r(" : ",-1)),t("span",L,s(a.attendance.absent.length)+"人 ",1)]),(n(!0),l(c,null,p(a.attendance.absent,(d,i)=>(n(),l("h3",{key:"absent-"+i,class:"gray-text"},[u.display.lgAndUp.value?(n(),l("span",v,s(`${i+1}. `),1)):o("",!0),t("span",B,s(d),1)]))),128)),t("h2",null,[e[6]||(e[6]=t("span",{style:{"white-space":"nowrap"}},"迟到",-1)),e[7]||(e[7]=r(" : ",-1)),t("span",E,s(a.attendance.late.length)+"人 ",1)]),(n(!0),l(c,null,p(a.attendance.late,(d,i)=>(n(),l("h3",{key:"late-"+i,class:"gray-text"},[u.display.lgAndUp.value?(n(),l("span",V,s(`${i+1}. `),1)):o("",!0),t("span",N,s(d),1)]))),128)),t("h2",null,[e[8]||(e[8]=t("span",{style:{"white-space":"nowrap"}},"不参与",-1)),e[9]||(e[9]=r(" : ",-1)),t("span",U,s(a.attendance.exclude.length)+"人 ",1)]),(n(!0),l(c,null,p(a.attendance.exclude,(d,i)=>(n(),l("h3",{key:"exclude-"+i,class:"gray-text"},[u.display.lgAndUp.value?(n(),l("span",q,s(`${i+1}. `),1)):o("",!0),t("span",F,s(d),1)]))),128))]),_:1},8,["class","onClick"])),[[m,a.isEditingDisabled?!1:{class:`text-${["primary","secondary","info","success","warning","error"][Math.floor(Math.random()*6)]}`}]]):o("",!0)}const P=w(A,[["render",M],["__scopeId","data-v-5a7eaf6a"]]);export{P as default};
