import{I as f}from"./IdnodeGrid-U6EqXqja.js";import{I as _}from"./IdnodeConfigForm-BL6DOswR.js";import{M as y}from"./MasterDetailLayout-oilsSeUU.js";import{B as h}from"./BooleanCell-BFiLlZVv.js";import{A as k}from"./ActionMenu-B3aKIJFu.js";import{d as C,u as w,c as I,o as a,e as c,f as l,g as s,P as v,t as E,h as u,r as G,L as R,_ as V}from"./index-D92x6h1h.js";import"./DataGrid-CbtTsx8d.js";import"./index-BG9mM10J.js";import"./index-7HNOjfAo.js";import"./localDay-CoEbUe3O.js";import"./SearchInput-DBHWpJgW.js";import"./useGridLayout-DCIiMD42.js";import"./CollapsibleSection.vue_vue_type_style_index_0_lang-Cq2AVc9p.js";import"./sliders-horizontal-Am8f4Xsv.js";import"./useStaleDataRecovery-BuNK-94T.js";const B={class:"epg-grabber-modules"},M={key:1,class:"epg-grabber-modules__empty"},S=C({__name:"EpgGrabberModulesView",setup(x){const{t}=w(),n=I(),i=G(null),d=[{field:"enabled",label:t("Enabled"),sortable:!0,filterType:"boolean",width:90,minVisible:"phone",phoneOrder:1,cellComponent:h,computeValue:o=>o.status==="epggrabmodEnabled"},{field:"title",sortable:!0,filterType:"string",width:280,minVisible:"phone",phoneRole:"primary"}];async function p(){try{await R("epggrab/internal/rerun",{rerun:1}),n.success(t("Internal EPG grabbers scheduled to re-run."))}catch(o){n.error(o instanceof Error?o.message:String(o),{summary:t("Re-run failed")})}}const m=[{id:"rerun-internal",label:t("Re-run Internal EPG Grabbers"),onClick:p}];function b(o,r){const e=o.uuid;r(typeof e=="string"?e:null)}return(o,r)=>(a(),c("div",B,[l(y,{"selected-uuid":i.value,"onUpdate:selectedUuid":r[0]||(r[0]=e=>i.value=e),"storage-key":"config-channel-epg-grabber-modules"},{master:s(({select:e})=>[l(f,{endpoint:"epggrab/module/list","help-page":"class/epggrab_mod","entity-class":"epggrab_mod",columns:d,"store-key":"config-channel-epg-grabber-modules","default-sort":{key:"title",dir:"ASC"},"lock-level":"advanced","virtual-scroller-options":{itemSize:36,lazy:!1},"count-label":u(t)("modules"),"client-side-filter":"",selectable:"single",class:"epg-grabber-modules__grid",onRowClick:g=>b(g,e)},{toolbarActions:s(()=>[l(k,{actions:m})]),_:1},8,["count-label","onRowClick"])]),detail:s(({selectedUuid:e})=>[e?(a(),v(_,{key:0,uuid:e},null,8,["uuid"])):(a(),c("p",M,E(u(t)("Select a module on the left to view and edit its configuration.")),1))]),_:1},8,["selected-uuid"])]))}}),Q=V(S,[["__scopeId","data-v-c62203cc"]]);export{Q as default};
