import{_ as u}from"./SmartDataTable-2Nc3Ohem.js";import{d as i,H as m,f as a,h as n,i as _,D as d,y as f,v as b}from"./index-C5GbdPxY.js";import{V as y}from"./VChip-CsS_5IS6.js";import"./VAvatar-RkAR0u0e.js";import"./VImg-BlqLjeEy.js";import"./VSelect-vtfYszIh.js";import"./VTextField-DxEUpn3-.js";import"./index-XcTykuv2.js";import"./forwardRefs-CB8NoG9r.js";import"./VList-C3dIUnee.js";import"./VMenu-CT0Fri-T.js";import"./VOverlay-DlJb3QlW.js";import"./getScrollParent-DE35ecf2.js";import"./VVirtualScroll-BUlcGoHW.js";import"./confirmDialog-CDDTmj30.js";import"./VCard-DptrO3GI.js";import"./VDialog-Dr29crN8.js";import"./_plugin-vue_export-helper-DlAUqK2U.js";import"./lodash-kem28dbC.js";import"./_commonjsHelpers-_d1bhYXs.js";import"./VForm-BZc3SavJ.js";import"./VCheckbox-rNAD_QU_.js";import"./VDatePicker-DHBX-k2T.js";import"./VSpacer-79sITyKz.js";import"./VBadge-DZHesqMo.js";import"./VTooltip-DPhSY2Qe.js";import"./TableAgent.vue_vue_type_script_setup_true_lang-XA6R7TPe.js";import"./TableEnum.vue_vue_type_script_setup_true_lang-5ITYgflT.js";import"./TableStatus.vue_vue_type_script_setup_true_lang-BRbfAU0T.js";import"./RoleBadge.vue_vue_type_script_setup_true_lang-Ctl8Qye7.js";import"./VDataTable-BFiF8jPV.js";import"./VTable-M43pjJD_.js";import"./filter-DERJvhSS.js";const h=i({__name:"TableRoleType",props:{item:{}},setup(s){const{t}=m();return(e,o)=>(n(),a(y,{color:e.item.built_in?"info":"success",size:"small"},{default:_(()=>[d(f(b(t)(`user::roles.role_types.${e.item.built_in?"built_in":"custom"}`)),1)]),_:1},8,["color"]))}}),Z=i({__name:"Index",setup(s){const{t}=m(),e=[{title:t("user::roles.table.name"),value:"name",sortable:!0},{title:t("user::roles.table.role_type"),value:"role_type",sortable:!1},{title:t("admin::admin.table.created_at"),value:"created_at",sortable:!0},{title:t("admin::admin.table.updated_at"),value:"updated_at",sortable:!0}],o=[{key:"edit"},{key:"destroy",hidden:r=>r.built_in,confirm:{message:t("admin::admin.delete.confirmation_message"),confirmButtonText:t("admin::admin.delete.confirm_button_text")}}],p={role_type:{component:h}},l=[{key:"destroy",confirm:{message:t("admin::admin.delete.confirmation_message"),confirmButtonText:t("admin::admin.delete.confirm_button_text")}}];return(r,k)=>{const c=u;return n(),a(c,{actions:o,"api-uri":"/v1/roles","bulk-actions":l,"cell-components":p,"header-actions":[{key:"create"}],headers:e,module:"user",name:"role",resource:"roles"})}}});export{Z as default};
