import{a as v}from"./Z4eZ-m2s.js";import{O as B,j as C,d as L,w as D,m as s,o as r,b as e,c as u,t as l,F as x,g as P,D as c,G as S,H as U,K as V,e as j,E as F}from"./Bgmy51Qv.js";import{u as I}from"./BE7GDBwC.js";import{u as N}from"./CYl1ofbh.js";import"./7pZkuj9N.js";import"./BHvLfWtM.js";import"./hSbGpNHU.js";import"./DuhDFJjj.js";import"./ByXs6QR-.js";import"./D_7E8SMU.js";import"./DKgjlGGV.js";const O={class:"lite-bold"},R=["value"],E={class:"mx-w-300x"},H={class:"mx-w-300x"},M=["onClick"],ee={__name:"index",setup(z){const{t:o}=B(),f=C({created_at:{title:o("category.date")},name:{title:o("user.name")},email:{title:o("fSale.email")},verified:{title:o("user.verified")}}),{getDataFromObject:d,getVerificationStatus:k}=I(),{cbList:i,deleteBulk:g,listPageRef:h,setItemList:_,checkAll:m,deleteNode:b}=N();return(n,a)=>{const y=v;return r(),L(y,{ref_key:"listPageRef",ref:h,"list-api":"getUsers","delete-api":"deleteUser","route-name":"users",name:n.$t("user.users"),gate:"user","add-button":!1,"order-options":s(f),onDeleteBulk:s(g),onList:s(_)},{table:D(({list:w})=>[e("tr",O,[e("th",null,[e("input",{type:"checkbox",onChange:a[0]||(a[0]=(...t)=>s(m)&&s(m)(...t))},null,32)]),e("th",null,l(n.$t("user.name")),1),e("th",null,l(n.$t("fSale.email")),1),e("th",null,l(n.$t("user.verified")),1),e("th",null,l(n.$t("category.created")),1),a[2]||(a[2]=e("th",null,null,-1))]),(r(!0),u(x,null,P(w,(t,$)=>(r(),u("tr",{key:$,class:c({"new-data":!parseInt(t.viewed)})},[e("td",null,[S(e("input",{type:"checkbox",value:t.id,"onUpdate:modelValue":a[1]||(a[1]=p=>U(i)?i.value=p:null)},null,8,R),[[V,s(i)]])]),e("td",null,[e("span",E,l(s(d)(t,"name","n/a")),1)]),e("td",null,[e("span",H,l(s(d)(t,"email","n/a")),1)]),e("td",{class:c(["status",{active:t.verified==1}])},[e("span",null,l(s(k)(t.verified)),1)],2),e("td",null,l(t.created),1),e("td",null,[n.$can("user","delete")?(r(),u("button",{key:0,onClick:F(p=>s(b)(t),["prevent"]),class:"delete-btn lite-btn"},l(n.$t("category.delete")),9,M)):j("",!0)])],2))),128))]),_:1},8,["name","order-options","onDeleteBulk","onList"])}}};export{ee as default};
