import{_ as e}from"./index.vue_vue_type_script_setup_true_lang5.js?v=1763625242172";import{_ as a}from"./index.vue_vue_type_script_setup_true_lang7.js?v=1763625242172";import{c as s,f as t,d as i,h as l}from"./public.js?v=1763625242172";import{n,c as o,bk as p,y as d}from"./page_layout.js?v=1763625242172";import{p as m,q as c}from"./planned.js?v=1763625242172";import{a as r}from"./soft.js?v=1763625242172";import{k as _,P as u,e as f,R as g,S as w,X as k,a3 as y,V as h,aj as j,N as b}from"./vue.js?v=1763625242172";import"./index.vue_vue_type_script_setup_true_lang6.js?v=1763625242172";import"./naive.js?v=1763625242172";import"./common.js?v=1763625242172";import"./__commonjsHelpers__.js?v=1763625242172";import"./site.js?v=1763625242172";const x={class:"p-20px"},v=_({__name:"index",props:{data:{}},setup(_){const{t:v}=u(),R=_,{row:S}=R.data,{keys:z,table:C,columns:T}=s([{type:"selection",width:40},{key:"name",title:v("Site.TableRow.index_22"),ellipsis:{tooltip:!0}},{key:"class",title:v("Ftp.Table.index_3"),width:80},{key:"addtime",title:v("Site.TableRow.index_25"),width:150},{key:"filename",title:v("Crontab.Planned.index_11"),width:200,ellipsis:{tooltip:!0}},{key:"size",title:v("Site.TableRow.index_23"),width:80,render:e=>n(e.size)},t({width:70,options:e=>[{label:v("Public.Btn.Click"),show:"local disk"!==e.class,onClick:()=>{r({title:e.class,name:e.class,admin:!0})}},{label:v("Site.TableOP.index_5"),show:"local disk"===e.class,onClick:async()=>{const{message:a}=await m({cron_id:S.id,filename:e.filename});o(a)&&p(encodeURIComponent(a.path),e.name)}}]})]),P=f({p:1,rows:10,cron_id:S.id}),{loading:U,setLoading:q}=i(),B=async()=>{try{q(!0);const{message:e}=await c(b(P));o(e)?(C.data=e.data.map((e=>({...e,filename:e.filename.includes("|")?"/"+e.filename.split("|").slice(1).join("|"):e.filename,class:e.filename.includes("|")?e.filename.split("|").length>2?e.filename.split("|")[1]:e.filename.split("|")[0]:"local disk"}))),C.total=d(e.page)):(C.data=[],C.total=0)}finally{z.value=[],q(!1)}};return B(),(s,t)=>{const i=l,n=a,o=e;return g(),w("div",x,[k(o,null,{table:y((()=>[k(i,{"checked-row-keys":h(z),"onUpdate:checkedRowKeys":t[0]||(t[0]=e=>j(z)?z.value=e:null),loading:h(U),"loading-num":1,"max-height":340,data:h(C).data,columns:h(T)},null,8,["checked-row-keys","loading","data","columns"])])),pageRight:y((()=>[k(n,{page:h(P).p,"onUpdate:page":t[1]||(t[1]=e=>h(P).p=e),"page-size":h(P).rows,"onUpdate:pageSize":t[2]||(t[2]=e=>h(P).rows=e),"item-count":h(C).total,onRefresh:B},null,8,["page","page-size","item-count"])])),_:1})])}}});export{v as default};
