← Back
Editing: apply-lest-ssl-legacy.js
!function(){function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function t(e){return function(e){if(Array.isArray(e))return n(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return n(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function r(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */r=function(){return n};var t,n={},a=Object.prototype,o=a.hasOwnProperty,u=Object.defineProperty||function(e,t,n){e[t]=n.value},i="function"==typeof Symbol?Symbol:{},l=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",s=i.toStringTag||"@@toStringTag";function f(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{f({},"")}catch(t){f=function(e,t,n){return e[t]=n}}function p(e,t,n,r){var a=t&&t.prototype instanceof x?t:x,o=Object.create(a.prototype),i=new A(r||[]);return u(o,"_invoke",{value:E(e,n,i)}),o}function d(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}n.wrap=p;var h="suspendedStart",m="suspendedYield",v="executing",y="completed",g={};function x(){}function w(){}function b(){}var _={};f(_,l,(function(){return this}));var k=Object.getPrototypeOf,L=k&&k(k(D([])));L&&L!==a&&o.call(L,l)&&(_=L);var S=b.prototype=x.prototype=Object.create(_);function j(e){["next","throw","return"].forEach((function(t){f(e,t,(function(e){return this._invoke(t,e)}))}))}function C(t,n){function r(a,u,i,l){var c=d(t[a],t,u);if("throw"!==c.type){var s=c.arg,f=s.value;return f&&"object"==e(f)&&o.call(f,"__await")?n.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):n.resolve(f).then((function(e){s.value=e,i(s)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}var a;u(this,"_invoke",{value:function(e,t){function o(){return new n((function(n,a){r(e,t,n,a)}))}return a=a?a.then(o,o):o()}})}function E(e,n,r){var a=h;return function(o,u){if(a===v)throw Error("Generator is already running");if(a===y){if("throw"===o)throw u;return{value:t,done:!0}}for(r.method=o,r.arg=u;;){var i=r.delegate;if(i){var l=N(i,r);if(l){if(l===g)continue;return l}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(a===h)throw a=y,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);a=v;var c=d(e,n,r);if("normal"===c.type){if(a=r.done?y:m,c.arg===g)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(a=y,r.method="throw",r.arg=c.arg)}}}function N(e,n){var r=n.method,a=e.iterator[r];if(a===t)return n.delegate=null,"throw"===r&&e.iterator.return&&(n.method="return",n.arg=t,N(e,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),g;var o=d(a,e.iterator,n.arg);if("throw"===o.type)return n.method="throw",n.arg=o.arg,n.delegate=null,g;var u=o.arg;return u?u.done?(n[e.resultName]=u.value,n.next=e.nextLoc,"return"!==n.method&&(n.method="next",n.arg=t),n.delegate=null,g):u:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,g)}function O(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function T(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function A(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(O,this),this.reset(!0)}function D(n){if(n||""===n){var r=n[l];if(r)return r.call(n);if("function"==typeof n.next)return n;if(!isNaN(n.length)){var a=-1,u=function e(){for(;++a<n.length;)if(o.call(n,a))return e.value=n[a],e.done=!1,e;return e.value=t,e.done=!0,e};return u.next=u}}throw new TypeError(e(n)+" is not iterable")}return w.prototype=b,u(S,"constructor",{value:b,configurable:!0}),u(b,"constructor",{value:w,configurable:!0}),w.displayName=f(b,s,"GeneratorFunction"),n.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===w||"GeneratorFunction"===(t.displayName||t.name))},n.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,b):(e.__proto__=b,f(e,s,"GeneratorFunction")),e.prototype=Object.create(S),e},n.awrap=function(e){return{__await:e}},j(C.prototype),f(C.prototype,c,(function(){return this})),n.AsyncIterator=C,n.async=function(e,t,r,a,o){void 0===o&&(o=Promise);var u=new C(p(e,t,r,a),o);return n.isGeneratorFunction(t)?u:u.next().then((function(e){return e.done?e.value:u.next()}))},j(S),f(S,s,"Generator"),f(S,l,(function(){return this})),f(S,"toString",(function(){return"[object Generator]"})),n.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},n.values=D,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(T),!e)for(var n in this)"t"===n.charAt(0)&&o.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var n=this;function r(r,a){return i.type="throw",i.arg=e,n.next=r,a&&(n.method="next",n.arg=t),!!a}for(var a=this.tryEntries.length-1;a>=0;--a){var u=this.tryEntries[a],i=u.completion;if("root"===u.tryLoc)return r("end");if(u.tryLoc<=this.prev){var l=o.call(u,"catchLoc"),c=o.call(u,"finallyLoc");if(l&&c){if(this.prev<u.catchLoc)return r(u.catchLoc,!0);if(this.prev<u.finallyLoc)return r(u.finallyLoc)}else if(l){if(this.prev<u.catchLoc)return r(u.catchLoc,!0)}else{if(!c)throw Error("try statement without catch or finally");if(this.prev<u.finallyLoc)return r(u.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&o.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var a=r;break}}a&&("break"===e||"continue"===e)&&a.tryLoc<=t&&t<=a.finallyLoc&&(a=null);var u=a?a.completion:{};return u.type=e,u.arg=t,a?(this.method="next",this.next=a.finallyLoc,g):this.complete(u)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),g},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),T(n),g}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;T(n)}return a}}throw Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:D(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),g}},n}function a(e,t,n,r,a,o,u){try{var i=e[o](u),l=i.value}catch(e){return void n(e)}i.done?t(l):Promise.resolve(l).then(r,a)}function o(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var u=e.apply(t,n);function i(e){a(u,r,o,i,l,"next",e)}function l(e){a(u,r,o,i,l,"throw",e)}i(void 0)}))}}System.register(["./utils-lib-legacy.js?v=VERSION_NUMBER","./base-lib-legacy.js?v=VERSION_NUMBER","./index-legacy103.js?v=VERSION_NUMBER","./site-legacy.js?v=VERSION_NUMBER","./ssl-legacy.js?v=VERSION_NUMBER","./useStore-legacy4.js?v=VERSION_NUMBER","./useStore-legacy12.js?v=VERSION_NUMBER","./useStore-legacy10.js?v=VERSION_NUMBER","./useMethod-legacy10.js?v=VERSION_NUMBER","./useController-legacy13.js?v=VERSION_NUMBER","./useStore-legacy11.js?v=VERSION_NUMBER","./__commonjsHelpers__-legacy.js?v=VERSION_NUMBER","./index-legacy104.js?v=VERSION_NUMBER","./column-legacy.js?v=VERSION_NUMBER","./useController-legacy6.js?v=VERSION_NUMBER","./validator-legacy.js?v=VERSION_NUMBER","./useController-legacy5.js?v=VERSION_NUMBER","./useMethod-legacy5.js?v=VERSION_NUMBER","./useController-legacy4.js?v=VERSION_NUMBER"],(function(e,n){"use strict";var a,u,i,l,c,s,f,p,d,h,m,v,y,g,x,w,b,_,k,L,S,j,C,E,N,O,T,A,D,P,V,I,G,M,U,F,H,J,W,q,B,z,R,X,Y,K,$,Q,Z,ee,te,ne,re,ae,oe,ue,ie,le,ce,se,fe;return{setters:[function(e){a=e.u,u=e.A,i=e.K,l=e.ai,c=e.ag,s=e.J,f=e.W,p=e.l,d=e.j,h=e.b},function(e){m=e.c,v=e.s,y=e.k,g=e.r,x=e.e,w=e.w,b=e.p,_=e.G,k=e.q,L=e.v,S=e.A,j=e.x,C=e.B,E=e.F,N=e.y,O=e.C,T=e.M,A=e.a_,D=e.z,P=e.J,V=e.P,I=e.H,G=e.ax,M=e.ag,U=e.af,F=e.a9,H=e.T,J=e.ai,W=e.aj,q=e.au,B=e.D,z=e.aw,R=e.a7,X=e.n},function(e){Y=e._},function(e){K=e.validateDomain,$=e.authDomainApi,Q=e.setCertToSite},function(e){Z=e.A,ee=e.z,te=e.B,ne=e.C},function(e){re=e.u},function(e){ae=e.u},function(e){oe=e.g},function(e){ue=e.d,ie=e.r},function(e){le=e.l,ce=e.c,se=e.u},function(e){fe=e.u},null,null,null,null,null,null,null,null],execute:function(){var n={class:"py-[1.6rem] relative w-[90%] mx-[auto]"},pe={key:0},de={class:"!max-h-[20rem] overflow-auto"},he=["title"],me={key:1},ve={class:"!max-h-[20rem] overflow-auto"},ye=["title"],ge={class:"p-[1.5rem]"},xe={class:"ml-[.4rem] text-danger"},we={class:"max-h-[38rem] overflow-auto"},be={key:0,class:"flex justify-end"};e("default",m({__name:"apply-lest-ssl",emits:["close"],setup:function(e,m){var _e=m.emit,ke=v(fe()).encryptIsRefresh,Le=a().mainHeight,Se=h(),je=_e,Ce=re().siteInfo,Ee=ae(),Ne=Ee.setApplyInfo,Oe=Ee.letApplyInfo,Te=oe().refs.isRefreshDomainConfigList,Ae=y({resource:"0",autoWildcard:!1,auth_to:!1,checkAll:!1,domain:[],checkList:[]}),De=g(!1);g([]);var Pe=g([]),Ve=y({}),Ie=g(!1),Ge=[{content:"注意:请勿将SSL证书用于非法网站",class:"text-danger"},{content:"如开启后无法使用HTTPS访问,请检查安全组是否正确放行443端口"},{content:"在DNS验证中,我们提供了多种自动化DNS-API,并提供了手动模式"},{content:"使用DNS接口申请证书可自动续期,手动模式下证书到期后需重新申请"}],Me=g([{label:"解析域名",prop:"domain"},{label:"记录值",prop:"auth_value",render:function(e,t){var n="dns"===Ve.auth_type?e.auth_value:e.file_path;return x("div",{class:"flex items-center"},[x("div",{class:"truncate w-[15rem]"},[n]),x("span",{class:"svgtofont-icon-copy ml-[4px] text-[#666] text-[1.6rem] w-[1.6rem] cursor-pointer",onClick:function(){return u({value:n})}},null)])}},{label:"类型",prop:"type",render:function(e,t){return"dns"===Ve.auth_type?x("span",null,[e.type]):x("div",{class:"flex items-center"},[x("div",{class:"truncate w-[15rem]"},[e.content]),x("span",{class:"svgtofont-icon-copy ml-[4px] text-[#666] text-[1.6rem] w-[1.6rem] cursor-pointer",onClick:function(){return u({value:e.content})}},null)])}},{label:"必需",prop:"must",width:100}]),Ue=g([]),Fe=g(!1),He=g(""),Je=g([{text:"解析域名需要一定时间来生效,完成所以上所有解析操作后,请等待1分钟后再点击验证按钮"},{text:""},{text:"若您使用的是宝塔云解析插件,阿里云DNS,DnsPod作为DNS,可使用DNS接口自动解析"}]),We=function(){var e=o(r().mark((function e(){var t,n;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,le();case 2:return t=e.sent,e.next=5,i({request:K({index:Ve.index}),message:!1});case 5:n=e.sent,t._props.onCancel(),!0===n.status?(Ie.value=!1,Be(n,!0)):ce(n,Pe.value,Ve);case 8:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),qe=function(){var e=o(r().mark((function e(t){var n,a,o;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,le();case 2:return n=e.sent,e.next=5,$({index:Ve.index,domain:t.domain});case 5:a=e.sent,o=a.data,n._props.onCancel(),"valid"===o.status?Se.success("验证成功"):!0===o.status?(Ie.value=!1,Be(o,!0)):ce(o,t.data,Ve);case 9:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),Be=function(){var e=o(r().mark((function e(t){var n,a,o,u,l=arguments;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.index,a=l.length>1&&void 0!==l[1]&&l[1],o=l.length>2&&void 0!==l[2]?l[2]:Ce.value.name,e.next=5,i({loading:"正在部署证书,请稍候...",request:Q({index:n,siteName:o}),message:!1,data:{status:Boolean,msg:String}});case 5:u=e.sent,se(u,a);case 7:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),ze=g([]),Re=g(""),Xe=g([]),Ye=g(null),Ke=g([]),$e=g(!0),Qe=g(""),Ze=g(!1),et=function(){var e=o(r().mark((function e(){var t,n,a,o,u,i=arguments;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=1,n={site_id:"1"===Ae.resource?ze.value.join(","):Re.value},De.value=!0,t=Se.load("正在获取域名列表,请稍后..."),e.next=7,ne(n);case 7:if(a=e.sent,o=a.data,Ae.domain=o.map((function(e){return e.name})),Xe.value=o,"1"!==Ae.resource){e.next=16;break}return u=Ae.checkList.filter((function(e){return ze.value.includes(e.site_id)})),e.next=15,X();case 15:u.forEach((function(e){var t=Xe.value.find((function(t){return t.name===e.name}));t&&Ye.value.toggleRowSelection(t,!0)}));case 16:e.next=21;break;case 18:e.prev=18,e.t0=e.catch(1);case 21:return e.prev=21,t&&t.close(),De.value=!1,e.finish(21);case 25:case"end":return e.stop()}}),e,null,[[1,18,21,25]])})));return function(){return e.apply(this,arguments)}}(),tt=function(){var e=o(r().mark((function e(){var t,n,a;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=Se.load("正在获取站点列表,请稍后..."),e.next=4,Z();case 4:if(n=e.sent,!(a=n.data).length){e.next=11;break}return Ke.value=a,$e.value&&(ze.value[0]=a[0].id,Re.value=a[0].id,$e.value=!1),e.next=11,et();case 11:e.next=16;break;case 13:e.prev=13,e.t0=e.catch(0);case 16:return e.prev=16,t&&t.close(),e.finish(16);case 19:case"end":return e.stop()}}),e,null,[[0,13,16,19]])})));return function(){return e.apply(this,arguments)}}(),nt=function(e){if(!e.row.name.includes(Qe.value)&&Ze.value)return"!hidden"},rt=function(e){Ae.checkList=e},at=function(e){Ae.checkList=e},ot=function(){var e=o(r().mark((function e(){return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,et();case 2:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),ut=function(){var e=o(r().mark((function e(t){return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return"1"===Ae.resource?ze.value=t:Re.value=t,e.next=3,et();case 3:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),it=function(e){Ze.value=!0,Qe.value=e},lt=function(){Ze.value=!0},ct=function(){Qe.value="",Ze.value=!1},st=function(e){return e.map((function(e){return e.name}))},ft=function(){var e=o(r().mark((function e(){var t,n,a;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(0!==Ae.checkList.length){e.next=3;break}return Se.error("请选择一个域名"),e.abrupt("return");case 3:if("1"!==Ae.resource||!Ae.checkList.some((function(e){return 0===e.status}))||Ae.auth_to){e.next=6;break}return Se.error("选中的域名存在未设置DNS接口配置"),e.abrupt("return");case 6:if("1"!==Ae.resource||!Ae.autoWildcard||!Ae.checkList.some((function(e){return-1!==e.name.indexOf("*")}))){e.next=9;break}return Se.error("开启自动组合泛域名时不能选择泛域名"),e.abrupt("return");case 9:return t={domains:JSON.stringify(st(Ae.checkList)),auth_type:"1"==Ae.resource?"dns":"http",auth_to:JSON.stringify(st(Ae.checkList)),auto_wildcard:Ae.autoWildcard?"1":"0"},"1"==Ae.resource&&(t.auth_to=Ae.auth_to?"dns":JSON.stringify(st(Ae.checkList))),e.prev=11,e.next=14,le();case 14:return n=e.sent,e.next=17,ee(t);case 17:a=e.sent,n._props.onCancel(),a.status&&(je("close"),ke.value=!0),pt(a.data,t),Je.value[1].text="可通过CMD命令来手动验证域名解析是否生效: nslookup -q=txt _acme-challenge.".concat(st(Ae.checkList)[0].replace("*.","")),e.next=27;break;case 24:e.prev=24,e.t0=e.catch(11);case 27:case"end":return e.stop()}}),e,null,[[11,24]])})));return function(){return e.apply(this,arguments)}}(),pt=function(e,t){if(!1===e.status&&e.hasOwnProperty("msg")&&l(e.msg))Se.msg({customClass:"bt-message-error-html",dangerouslyUseHTMLString:!0,message:e.msg,type:"error",showClose:!0,duration:0});else if(!0!==e.status&&"pending"!==e.status&&void 0===(null==e?void 0:e.save_path))ce(e,Oe.value.dnsTable,Oe.value.info);else{if("pending"===e.status&&"dns"===t.auth_type){Ue.value=[];for(var n=0;n<e.auths.length;n++){var r=[],a=e.auths[n].domain.replace("*.","");r.push({domain:"_acme-challenge.".concat(a),type:"TXT",auth_value:e.auths[n].auth_value,must:"是",force:"是"}),r.push({domain:a,type:"CAA",auth_value:'0 issue "letsencrypt.org"',must:"否",force:"否"}),Ue.value.push({domain:e.auths[n].domain,data:r})}return e.hasOwnProperty("error")?Fe.value=e.error:Fe.value=!1,Ne(e,t),void(Ie.value=!0)}dt(e)}},dt=function(){var e=o(r().mark((function e(n){var a,o,u,l;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,a=Se.load("正在部署证书,请稍后..."),o=[],o="1"===Ae.resource?ze.value.map((function(e){return Ke.value.find((function(t){return t.id===e}))})).filter((function(e){return e})).map((function(e){return{siteName:e.name}})):[{siteName:Ke.value.find((function(e){return e.id===Re.value})).name}],e.next=6,i({request:te({BatchInfo:JSON.stringify(o),privkey:n.private_key,fullchain:n.cert+n.root})});case 6:return u=e.sent,l={resultData:[].concat(t(u.data.faildList),t(u.data.successList)),resultTitle:"部署结果",resultColumn:[{label:"站点名称",prop:"siteName"},{label:"操作结果",render:function(e){return x("div",{class:e.status?"text-primary":"text-danger"},[e.status?"操作成功":x("span",{class:"flex items-center"},[C("操作失败,"),x(G,{popperClass:"el-popover-shadow el-light-popover",trigger:"hover",placement:"top-start",enterable:!1,"open-delay":400,"close-delay":0},{default:function(){return[x("span",{class:"inline-block",innerHTML:e.error_msg||"暂无详情"},null)]},reference:function(){return x("span",{class:"text-primary cursor-pointer"},[C("详情")])}})])])}}]},e.next=10,ie(l);case 10:e.next=15;break;case 12:e.prev=12,e.t0=e.catch(0);case 15:return e.prev=15,a&&a.close(),e.finish(15);case 18:case"end":return e.stop()}}),e,null,[[0,12,15,18]])})));return function(t){return e.apply(this,arguments)}}();return w(Te,(function(e){e&&(tt(),Te.value=!1)}),{immediate:!0}),b((function(){Te.value=!0})),function(e,t){var r=M,a=U,o=F,u=H,i=J,l=c,h=W,m=s,v=q,y=B,g=z,w=Y,b=R,X=f,K=p,$=d,Q=_("bt-loading");return k(),L("div",n,[x(b,{class:"mb-[2rem]"},{default:S((function(){return[x(o,{label:"验证方法"},{default:S((function(){return[x(a,{modelValue:j(Ae).resource,"onUpdate:modelValue":t[0]||(t[0]=function(e){return j(Ae).resource=e}),onChange:ot},{default:S((function(){return[x(r,{label:"0",value:"0"},{default:S((function(){return t[5]||(t[5]=[C("文件验证")])})),_:1}),x(r,{label:"1",value:"1"},{default:S((function(){return t[6]||(t[6]=[C("DNS验证(支持通配符)")])})),_:1})]})),_:1},8,["modelValue"])]})),_:1}),"1"==j(Ae).resource?(k(),L(E,{key:0},[x(o,{label:" ",class:"!mt-[-.3rem]"},{default:S((function(){return[x(u,{modelValue:j(Ae).auth_to,"onUpdate:modelValue":t[1]||(t[1]=function(e){return j(Ae).auth_to=e})},{default:S((function(){return t[7]||(t[7]=[C(" 手动解析")])})),_:1},8,["modelValue"])]})),_:1}),x(o,{label:" ",class:"!mt-[-.3rem] !mb-[2rem]"},{default:S((function(){return[x(u,{modelValue:j(Ae).autoWildcard,"onUpdate:modelValue":t[2]||(t[2]=function(e){return j(Ae).autoWildcard=e})},{default:S((function(){return t[8]||(t[8]=[C(" 自动组合泛域名")])})),_:1},8,["modelValue"]),t[9]||(t[9]=N("div",{class:"text-[1.2rem]"},"* 如需申请通配符域名请勾选此项,且不要在下方域名列表中选中泛域名",-1))]})),_:1})],64)):O("",!0),x(o,{label:"网站"},{default:S((function(){return[N("div",null,["1"==j(Ae).resource?(k(),L("div",pe,[(k(),T(l,{multiple:!0,filterable:"","model-value":j(ze),class:"mr-[.8rem] !w-[22rem] max-h-[100px] overflow-auto",key:j(Ae).resource,onChange:ut},{default:S((function(){return[N("div",de,[(k(!0),L(E,null,A(j(Ke),(function(e,t){return k(),T(i,{key:t,label:e.name,value:e.id},{default:S((function(){return[N("span",{class:"!w-[22rem] truncate",title:e.name,style:{float:"left"}},D(e.name),9,he)]})),_:2},1032,["label","value"])})),128))])]})),_:1},8,["model-value"]))])):(k(),L("div",me,[(k(),T(h,{filterable:"","model-value":j(Re),class:"mr-[.8rem] !w-[22rem]",key:j(Ae).resource,onChange:ut},{default:S((function(){return[N("div",ve,[(k(!0),L(E,null,A(j(Ke),(function(e,t){return k(),T(i,{key:t,label:e.name,value:e.id},{default:S((function(){return[N("span",{class:"!w-[22rem] truncate",title:e.name,style:{float:"left"}},D(e.name),9,ye)]})),_:2},1032,["label","value"])})),128))])]})),_:1},8,["model-value"]))])),t[10]||(t[10]=N("div",{class:"text-[1.2rem] mt-[.5rem]"},"* 根据网站筛选下方域名",-1))])]})),_:1}),x(o,{label:"域名"},{default:S((function(){return[N("div",{class:P(["w-[60rem] !relative border-[1px] border-[#ececec]",j(Le)>1e3?"h-[52rem]":"h-[31rem]"])},[x(m,{class:"!absolute right-[1rem] top-[.7rem] z-99 !w-[200px]",modelValue:j(Qe),"onUpdate:modelValue":t[3]||(t[3]=function(e){return V(Qe)?Qe.value=e:null}),onSearch:it,onClear:ct,onBlur:lt,placeholder:"搜索域名"},null,8,["modelValue"]),x(w,null,{content:S((function(){return[I((k(),T(g,{ref_key:"domainTable",ref:Ye,class:"!mb-[1rem] mt-[-1.2rem]","row-class-name":nt,onSelectionChange:rt,onSelectAll:at,data:j(Xe),"max-height":j(Le)<1e3?290:500,description:"列表为空"},{default:S((function(){return[x(v,{type:"selection",width:"35"}),x(v,{prop:"name",label:"域名"},{default:S((function(e){return[e.row.apply_ssl?(k(),T(j(G),{key:0,placement:"top-start",trigger:"hover",offset:-100},{reference:S((function(){return[N("span",null,D(e.row.name),1)]})),default:S((function(){return[t[11]||(t[11]=N("div",{class:"flex flex-col"},[N("span",null,"Let's Encrypt证书不支持申请IP证书"),N("span",null,"请选择【商用证书】的多域名SSL证书申请")],-1))]})),_:2},1024)):O("",!0)]})),_:1}),x(v,{align:"right"},{default:S((function(e){return["1"!==j(Ae).resource||0!==e.row.status||j(Ae).auth_to?O("",!0):(k(),T(y,{key:0,size:"small",type:"primary",class:"ml-auto",onClick:function(t){return j(ue)(e.row)}},{default:S((function(){return t[12]||(t[12]=[C("配置DNS")])})),_:2},1032,["onClick"]))]})),_:1})]})),_:1},8,["data","max-height"])),[[Q,j(De)],[Q,"正在加载域名列表,请稍后...","title"]])]})),_:1})],2)]})),_:1}),x(o,{label:" "},{default:S((function(){return[x(y,{type:"primary",onClick:ft},{default:S((function(){return t[13]||(t[13]=[C("申请证书")])})),_:1})]})),_:1})]})),_:1}),x(X,{options:Ge,class:"pl-2rem"}),x($,{modelValue:j(Ie),"onUpdate:modelValue":t[4]||(t[4]=function(e){return V(Ie)?Ie.value=e:null}),area:70,title:"手动".concat("dns"===j(Ve).auth_type?"解析TXT记录":"创建验证文件")},{default:S((function(){return[N("div",ge,[t[16]||(t[16]=C(" 请按以下列表做TXT解析: ")),N("span",xe,D(j(He)),1),x(w,null,{content:S((function(){return[N("div",we,[(k(!0),L(E,null,A(j(Ue),(function(e,n){return k(),L(E,null,[e.data.length?(k(),L("div",{key:n},[N("span",null,"验证域名:"+D(e.domain),1),x(K,{class:"my-[1rem]",column:j(Me),data:e.data},null,8,["column","data"]),j(Fe)?(k(),L("div",be,[x(y,{type:"default",onClick:function(t){return qe(e)}},{default:S((function(){return t[14]||(t[14]=[C("验证")])})),_:2},1032,["onClick"])])):O("",!0)])):O("",!0)],64)})),256))])]})),"footer-right":S((function(){return[j(Fe)?O("",!0):(k(),T(y,{key:0,type:"default",onClick:We},{default:S((function(){return t[15]||(t[15]=[C("验证")])})),_:1}))]})),_:1}),x(X,{list:j(Je),listStyle:"disc",class:"ml-[20px]"},null,8,["list"])])]})),_:1},8,["modelValue","title"])])}}}))}}}))}();
Save File
Cancel