import{h as k,u as C,m as H,t as P,r as o,o as c,a as m,f as n,l as t,e as d,F as V,k as I,x as l,y as s,d as _,b as y}from"./app-44623493.js";const N={class:"grid grid-cols-1 gap-x-4 gap-y-8 sm:grid-cols-2"},D={key:0},L=["innerHTML"],R={name:"AttendanceTypeShow"},F=Object.assign(R,{setup(j){k();const p=C(),u=H(),b={},f="attendance/type/",a=P({...b}),g=e=>{Object.assign(a,e)};return(e,i)=>{const $=o("PageHeaderAction"),B=o("PageHeader"),r=o("BaseDataView"),T=o("BaseButton"),h=o("ShowButton"),A=o("BaseCard"),v=o("ShowItem"),w=o("ParentTransition");return c(),m(V,null,[n(B,{title:e.$trans(d(p).meta.trans,{attribute:e.$trans(d(p).meta.label)}),navs:[{label:e.$trans("attendance.attendance"),path:"Attendance"},{label:e.$trans("attendance.type.type"),path:"AttendanceTypeList"}]},{default:t(()=>[n($,{name:"AttendanceType",title:e.$trans("attendance.type.type"),actions:["list"]},null,8,["title"])]),_:1},8,["title","navs"]),n(w,{appear:"",visibility:!0},{default:t(()=>[n(v,{"init-url":f,uuid:d(p).params.uuid,onSetItem:g,onRedirectTo:i[1]||(i[1]=S=>d(u).push({name:"AttendanceType"}))},{default:t(()=>[a.uuid?(c(),I(A,{key:0},{title:t(()=>[l(s(a.name),1)]),footer:t(()=>[n(h,null,{default:t(()=>[n(T,{design:"primary",onClick:i[0]||(i[0]=S=>d(u).push({name:"AttendanceTypeEdit",params:{uuid:a.uuid}}))},{default:t(()=>[l(s(e.$trans("general.edit")),1)]),_:1})]),_:1})]),default:t(()=>[_("dl",N,[n(r,{label:e.$trans("attendance.type.props.name")},{default:t(()=>[l(s(a.name),1)]),_:1},8,["label"]),n(r,{label:e.$trans("attendance.type.props.code")},{default:t(()=>[l(s(a.code),1)]),_:1},8,["label"]),n(r,{label:e.$trans("attendance.type.props.category")},{default:t(()=>[l(s(a.category.label)+" ",1),a.unit.value?(c(),m("span",D,"("+s(a.unit.label)+")",1)):y("",!0)]),_:1},8,["label"]),n(r,{label:e.$trans("attendance.type.props.alias")},{default:t(()=>[l(s(a.alias),1)]),_:1},8,["label"]),n(r,{class:"col-span-1 sm:col-span-2",label:e.$trans("attendance.type.props.description")},{default:t(()=>[_("div",{innerHTML:a.description},null,8,L)]),_:1},8,["label"]),n(r,{label:e.$trans("general.created_at")},{default:t(()=>[l(s(a.createdAt.formatted),1)]),_:1},8,["label"]),n(r,{label:e.$trans("general.updated_at")},{default:t(()=>[l(s(a.updatedAt.formatted),1)]),_:1},8,["label"])])]),_:1})):y("",!0)]),_:1},8,["uuid"])]),_:1})],64)}}});export{F as default};
