import{_ as e}from"./index245.js?v=1764233927359";import{k as a,P as s,R as n,V as t,W as l,U as o,r as i,a2 as r,a3 as u,S as p,F as m,O as c,an as d,a4 as v,j as _,a0 as g,ak as x}from"./vue.js?v=1764233927359";import{eI as y,d as f,T as w,eJ as j,eK as k,x as b,eL as h,u as P}from"./page_layout.js?v=1764233927359";import{_ as S,a as U}from"./index.vue_vue_type_script_setup_true_lang18.js?v=1764233927359";import{O as C}from"./index259.js?v=1764233927359";import{_ as W}from"./index.vue_vue_type_script_setup_true_lang19.js?v=1764233927359";import{c as L,d as N,h as T}from"./public.js?v=1764233927359";import{da as q,df as z,au as A,dV as H,aC as O}from"./naive.js?v=1764233927359";import{_ as R}from"./index104.js?v=1764233927359";import"./__commonjsHelpers__.js?v=1764233927359";import"./common.js?v=1764233927359";import"./php.js?v=1764233927359";import"./soft.js?v=1764233927359";import"./site.js?v=1764233927359";import"./alarm.js?v=1764233927359";import"./index.vue_vue_type_script_setup_true_lang.js?v=1764233927359";import"./index.vue_vue_type_script_setup_true_lang11.js?v=1764233927359";import"./index100.js?v=1764233927359";import"./theme-monokai.js?v=1764233927359";import"./file.js?v=1764233927359";import"./leader-line-vue.js?v=1764233927359";const F=a({__name:"index",setup(e,{expose:a}){const{t:i}=s(),{table:r,columns:u}=L([{key:"title",title:i("Plugin.Apache.index_12")},{width:"30%",key:"value",title:i("Plugin.Apache.index_13")}]),p={active:"Active connections",accepts:"Total accepts",handled:"Total handled",requests:"Total requests",Reading:"Reading",Writing:"Writing",Waiting:"Waiting",worker:"Worker process",workercpu:"Nginx CPU usage",workermen:"Nginx memory usage"},{loading:m,setLoading:c}=N(),d=async()=>{try{c(!0);const{message:e}=await y();f(e)&&(r.data=Object.keys(e).map(a=>({title:p[a],value:e[a]})))}finally{c(!1)}};return d(),a({init:d}),(e,a)=>{const s=T;return t(),n("div",null,[l(s,{data:o(r).data,columns:o(u),loading:o(m)},null,8,["data","columns","loading"])])}}}),I={class:"w-150px! text-right"},J={class:"w-250px! color-#666"},V={class:"text-center"},B=a({__name:"index",setup(e,{expose:a}){const{t:g}=s(),x=i(),y=[{label:g("Config.Panel.index_83_1"),value:"on"},{label:g("Config.Safe.index_84"),value:"off"}],f=async()=>{const e=x.value.reduce((e,a)=>(e[a.name]=a.value,e),{});await j(e)},{loading:h,setLoading:P}=N(),S=async()=>{try{P(!0);const{message:e}=await k();b(e)&&(x.value=e)}finally{P(!1)}};return S(),a({init:S}),(e,a)=>{const s=z,i=A,g=H,j=q,k=O,b=w;return t(),r(b,{show:o(h)},{default:u(()=>[(t(!0),n(m,null,c(o(x),(e,a)=>(t(),r(j,{class:"items-center flex-nowrap! py-2px mb-16px",key:a},{default:u(()=>[p("div",I,v(e.name),1),"gzip"!==e.name&&"worker_processes"!==e.name?(t(),r(s,{key:0,class:"w-150px!",value:e.value,"onUpdate:value":a=>e.value=a,min:0,"show-button":!1},null,8,["value","onUpdate:value"])):d("",!0),"worker_processes"===e.name?(t(),r(i,{key:1,class:"w-150px!",value:e.value,"onUpdate:value":a=>e.value=a},null,8,["value","onUpdate:value"])):d("",!0),"gzip"===e.name?(t(),r(g,{key:2,class:"w-150px!",value:e.value,"onUpdate:value":a=>e.value=a,options:y},null,8,["value","onUpdate:value"])):d("",!0),p("div",J,v(e.ps),1)]),_:2},1024))),128)),p("div",V,[l(k,{type:"primary",onClick:f},{default:u(()=>[_(v(e.$t("Public.Btn.Save")),1)]),_:1})])]),_:1},8,["show"])}}}),K=a({__name:"index",setup(e,{expose:a}){const s=i("None"),{loading:n,setLoading:p}=N(),m=async()=>{try{p(!0);const{message:e}=await h({path:"/www/wwwlogs/nginx_error.log"});f(e)&&(s.value=e.result?e.result:"None")}finally{p(!1)}};return m(),a({init:m}),(e,a)=>{const i=R,p=w;return t(),r(p,{class:"h-580px",show:o(n)},{default:u(()=>[l(i,{log:o(s)},null,8,["log"])]),_:1},8,["show"])}}}),M=a({__name:"index",setup(a){const{multiService:n,isWebServerJump:l}=g(P()),{t:u}=s(),p=i("service"),m=[{key:"service",label:u("Security.History.Index_10"),component:S},{key:"webserver",label:u("Soft.Plugin.index_1"),component:C},{key:"file",label:u("Site.Config.index_15"),data:{path:"/www/server/nginx/conf/nginx.conf"},component:U},{key:"version",label:u("Plugin.Ftp.index_9"),component:W},{key:"load",label:u("Home.index_30"),component:F},{key:"optimization",label:u("Plugin.Mysql.index_27"),component:B},{key:"logs",label:u("Site.Config.index_101"),component:K}];return p.value=n.value||l.value?"webserver":"service",l.value&&(l.value=!1),(a,s)=>{const n=e;return t(),r(n,{value:o(p),"onUpdate:value":s[0]||(s[0]=e=>x(p)?p.value=e:null),data:m},null,8,["value"])}}});export{M as default};
