import{i as y,c as d}from"./app-Ba7ZqSpq.js";import{_ as k}from"./app-CWUdaaxi.js";import{_ as h}from"./app-DFulsyXy.js";import{_ as x,a as f}from"./app-PrSv7rSt.js";import{_ as T}from"./app-T1ysvErZ.js";import{_ as R}from"./app-DWUwCFNm.js";import{T as $}from"./app-CNHjdV6U.js";import{D as B}from"./app-ZeVDYyDS.js";import{r as g,o as a,g as u,b as o,u as t,w as i,F as b,a as s,f as n,h as r,t as l,c as p}from"./app-SC54XQDl.js";import"./app-CL60OiIv.js";import"./app-D9TrJBlL.js";import"./app-_Ovp2dOH.js";import"./app-BjSCO7rC.js";import"./app-Dhl-Bw0H.js";import"./app-B2C_dtYI.js";import"./app-COidJXl1.js";import"./app-BZGObKCm.js";import"./app-BPIIxVwk.js";import"./app-PPG0ZS4d.js";import"./app-DgoEZtNT.js";import"./app-Ch8j4za4.js";import"./app-Dw0jKdCD.js";import"./app-DnXuoh8P.js";import"./app-CCkWSX4Q.js";function q(){y(this),this.keyType="key",this.success=this.$NotifyReloadSuccess("任务提交成功"),this.$delay(function(){this.$refs.keysBox.focus(),this.$watch(()=>this.keyType,function(){setTimeout(()=>{this.$refs.keysBox.focus()})})}),this.isRequesting=!1,this.before=function(){this.isRequesting=!0},this.done=function(){this.isRequesting=!1}}const V=s("div",null,[s("span",{class:"grey"},"刷新缓存指的是标记URL列表或目录为失效状态，当有新的用户请求这些URL时，会再次从源站读取最新的内容。")],-1),w=s("td",{class:"title"},"刷新类型 *",-1),D={key:0},L={key:1},U={class:"comment"},N={key:0},ae={__name:"index",setup(v){const c=g(),e=d(new q,{refs:{keysBox:c}});return(C,m)=>(a(),u(b,null,[o(k,{ctx:t(e),"active-tab":"purge"},null,8,["ctx"]),V,o(h,{action:"$",onSuccess:t(e).success,onBefore:t(e).before,onDone:t(e).done,class:"mt-4"},{default:i(()=>[o(B,null,{default:i(()=>[s("tbody",null,[s("tr",null,[w,s("td",null,[o(x,{name:"keyType",modelValue:t(e).keyType,"onUpdate:modelValue":m[0]||(m[0]=_=>t(e).keyType=_)},{default:i(()=>[o(f,{value:"key"},{default:i(()=>[n("URL")]),_:1}),o(f,{value:"prefix"},{default:i(()=>[n("目录")]),_:1})]),_:1},8,["modelValue"])])]),s("tr",null,[s("td",null,[t(e).keyType=="key"?(a(),u("span",D,"URL列表 *")):r("",!0),t(e).keyType=="prefix"?(a(),u("span",L,"目录列表 *")):r("",!0)]),s("td",null,[o(T,{rows:"20",name:"urlList",ref_key:"keysBox",ref:c,class:"w-full"},null,512),s("p",U,[n("每行一条，每次最多提交"+l(t(e).maxKeysPerTask)+"个URL，每天最多提交"+l(t(e).maxKeysPerDay)+"个",1),t(e).quotaKeysToday>0?(a(),u("span",N,"，今日剩余"+l(t(e).quotaKeysToday)+"个",1)):r("",!0),n("。 ")])])])])]),_:1}),t(e).isRequesting?r("",!0):(a(),p(R,{key:0},{default:i(()=>[n("刷新缓存")]),_:1})),t(e).isRequesting?(a(),p($,{key:1,disabled:"",type:"button"},{default:i(()=>[n("处理中...")]),_:1})):r("",!0)]),_:1},8,["onSuccess","onBefore","onDone"])],64))}};export{ae as default};
