import{d as u,ez as f,H as b,b as y,c as g,u as _}from"./outputWidgets.a8447bcb.js";import{a as w}from"./asyncComputed.6c2627ea.js";import"./router.8be149da.js";import{M as m}from"./member.17b0a038.js";import"./columns.79610386.js";import{C as I}from"./CrudView.996cd8b2.js";import"./Form.a869b3cf.js";import"./Title.4127a4b4.js";import"./transButton.26020e2e.js";import"./Text.722e2789.js";import"./index.41d49230.js";import"./gateway.9d217caa.js";import"./activeRecord.52c1b6f8.js";import"./pubsub.3b516de1.js";import"./index.f4ac7424.js";import"./icons.6de7af10.js";import"./url.0a1547fb.js";import"./index.ee9a096e.js";import"./index.c058ebd2.js";import"./index.823e1eed.js";import"./index.71f713cd.js";import"./index.5fa32c06.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},o=new Error().stack;o&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[o]="4a16c2e7-2907-4438-afa6-d8879649712d",e._sentryDebugIdIdentifier="sentry-dbid-4a16c2e7-2907-4438-afa6-d8879649712d")}catch{}})();const K=u({__name:"Members",setup(e){const r=f().params.organizationId,n=[{key:"email",label:"Email"}],s=async t=>{await m.create(r,t.email),p()},{loading:l,result:d,refetch:p}=w(()=>m.list(r)),c=b(()=>{var t,a;return{columns:[{name:"Email"},{name:"Role"}],rows:(a=(t=d.value)==null?void 0:t.map(i=>({key:i.email,cells:[{text:i.email},{text:i.role}]})))!=null?a:[]}});return(t,a)=>(y(),g(I,{"entity-name":"members",loading:_(l),title:"Organization members",description:"List all organization members.","empty-title":"No members yet",table:c.value,"create-button-text":"Add members",fields:n,onCreate:s},null,8,["loading","table"]))}});export{K as default};
//# sourceMappingURL=Members.c60fcd4f.js.map
