import{d as f,s as k,r as c,c as a,o as n,a as t,e as w,t as s,F as b,g,b as l,w as y,h as u,n as v,u as _}from"./app-Do7K7VDV.js";import{_ as C}from"./Paginate-BZTS8QtF.js";import{_ as x}from"./NoDataFound-BCWTwO3P.js";import{_ as B}from"./AdminLayout-DeT_GLTC.js";import{h as M}from"./moment-BAtM24Ew.js";import"./AssetModal-C18ToIEK.js";import"./_plugin-vue_export-helper-DlAUqK2U.js";import"./InputFieldError-0BmYlL24.js";import"./ToastrContainer-CtYDvNPN.js";const $={class:"table-responsive mt-4 w-full"},D={class:"table"},I={class:"!text-right"},L={key:0,class:"tbody"},N={key:1},V={class:"!text-right"},j={class:"flex justify-end"},A={class:"dropdown","data-placement":"bottom-start"},F={class:"dropdown-toggle"},O={class:"dropdown-content w-56"},S={class:"dropdown-list"},T={class:"dropdown-list-item"},z=["onClick"],E={class:"w-full"},P=f({layout:B}),X=Object.assign(P,{__name:"Index",props:["platforms"],setup(d){const{deleteRow:h}=k();return(e,R)=>{const m=c("Link"),i=c("Icon");return n(),a("div",$,[t("table",D,[t("thead",null,[t("tr",null,[t("th",null,s(e.trans("Platform")),1),t("th",null,s(e.trans("Module")),1),t("th",null,s(e.trans("Owner")),1),t("th",null,s(e.trans("Status")),1),t("th",null,s(e.trans("Created At")),1),t("th",I,s(e.trans("Action")),1)])]),d.platforms.data.length?(n(),a("tbody",L,[(n(!0),a(b,null,g(d.platforms.data,(o,p)=>(n(),a("tr",{key:p},[t("td",null,s(o.name),1),t("td",null,s(o.module),1),t("td",null,[l(m,{href:e.route("admin.users.show",o.owner)},{default:y(()=>{var r;return[u(s((r=o.owner)==null?void 0:r.name),1)]}),_:2},1032,["href"])]),t("td",null,[o.status?(n(),a("span",{key:0,class:v(["badge",o.status=="connected"?"badge-success":"badge-danger"])},s(o.status),3)):(n(),a("span",N," - "))]),t("td",null,s(_(M)(o.created_at).format("D-MMM-Y")),1),t("td",V,[t("div",j,[t("div",A,[t("div",F,[l(i,{class:"h-5 text-3xl text-slate-400",icon:"bx:dots-vertical-rounded"})]),t("div",O,[t("ul",S,[t("li",T,[t("a",{class:"dropdown-link",onClick:r=>_(h)(e.route("admin.logs.platforms.destroy",o))},[l(i,{class:"h-5 text-3xl text-slate-400",icon:"bx:trash"}),u(" "+s(e.trans("Delete")),1)],8,z)])])])])])])]))),128))])):(n(),w(x,{key:1,forTable:!0}))]),t("div",E,[l(C,{links:d.platforms.links},null,8,["links"])])])}}});export{X as default};
