import{c as s,r as a,v as t,x as e,ba as l,z as i,e as r,B as n,C as o,G as c}from"./base-lib.js?v=1761009159";import{C as f}from"./firewall.js?v=1761009159";import{h as m}from"./useMethod6.js?v=1761009159";import{p as u,b}from"./utils-lib.js?v=1761009159";const d={class:"flex flex-col w-[55rem]"},p={class:"flex justify-center py-4"},x=s({__name:"index",setup(s){const x=b(),v=a(!1),w=async()=>{try{await u({title:"迁移防火墙数据",content:"即将迁移防火墙数据，firewalld/ufw会重载，iptables规则可能会清理，请确认持久化了iptables规则后再操作），是否继续操作？",confirmText:"确认",cancelText:"取消"}),v.value=!0;const{data:s}=await f();s&&s.status&&setTimeout(()=>{m(s.task_id)},500),x.request(s)}finally{v.value=!1}};return(s,a)=>{const f=c;return t(),e("div",d,[a[1]||(a[1]=l('<div class="mb-5"><div class="flex items-center mb-3"><i class="svgtofont-el-question-filled !text-iconLarge text-warning mr-2"></i><span class="text-warning text-subtitleLarge font-bold">检测到需要迁移旧的防火墙到新的服务中</span></div><ul class="list-disc pl-5"><li class="text-base mb-2">仅对面板的防火墙功能进行迁移，不会影响系统防火墙（firewall/ufw）已有的规则将会被保留</li><li class="text-base mb-2">如果使用过iptables命令行添加过的非持久化的规则将会丢失！请注意持久化或保存iptables规则</li></ul></div>',1)),i("div",p,[r(f,{type:"primary",loading:v.value,onClick:w},{default:n(()=>a[0]||(a[0]=[o("立即迁移",-1)])),_:1,__:[0]},8,["loading"])])])}}});export{x as _};
