File: /www/server/panel/BTPanel/static/js/today-legacy.js
!function(){function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t(e)}function e(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */e=function(){return n};var r,n={},a=Object.prototype,o=a.hasOwnProperty,i=Object.defineProperty||function(t,e,r){t[e]=r.value},c="function"==typeof Symbol?Symbol:{},l=c.iterator||"@@iterator",s=c.asyncIterator||"@@asyncIterator",u=c.toStringTag||"@@toStringTag";function f(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{f({},"")}catch(r){f=function(t,e,r){return t[e]=r}}function d(t,e,r,n){var a=e&&e.prototype instanceof x?e:x,o=Object.create(a.prototype),c=new P(n||[]);return i(o,"_invoke",{value:O(t,r,c)}),o}function h(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}n.wrap=d;var p="suspendedStart",v="suspendedYield",y="executing",m="completed",g={};function x(){}function b(){}function w(){}var L={};f(L,l,(function(){return this}));var E=Object.getPrototypeOf,_=E&&E(E(A([])));_&&_!==a&&o.call(_,l)&&(L=_);var S=w.prototype=x.prototype=Object.create(L);function j(t){["next","throw","return"].forEach((function(e){f(t,e,(function(t){return this._invoke(e,t)}))}))}function k(e,r){function n(a,i,c,l){var s=h(e[a],e,i);if("throw"!==s.type){var u=s.arg,f=u.value;return f&&"object"==t(f)&&o.call(f,"__await")?r.resolve(f.__await).then((function(t){n("next",t,c,l)}),(function(t){n("throw",t,c,l)})):r.resolve(f).then((function(t){u.value=t,c(u)}),(function(t){return n("throw",t,c,l)}))}l(s.arg)}var a;i(this,"_invoke",{value:function(t,e){function o(){return new r((function(r,a){n(t,e,r,a)}))}return a=a?a.then(o,o):o()}})}function O(t,e,n){var a=p;return function(o,i){if(a===y)throw Error("Generator is already running");if(a===m){if("throw"===o)throw i;return{value:r,done:!0}}for(n.method=o,n.arg=i;;){var c=n.delegate;if(c){var l=H(c,n);if(l){if(l===g)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(a===p)throw a=m,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);a=y;var s=h(t,e,n);if("normal"===s.type){if(a=n.done?m:v,s.arg===g)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(a=m,n.method="throw",n.arg=s.arg)}}}function H(t,e){var n=e.method,a=t.iterator[n];if(a===r)return e.delegate=null,"throw"===n&&t.iterator.return&&(e.method="return",e.arg=r,H(t,e),"throw"===e.method)||"return"!==n&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+n+"' method")),g;var o=h(a,t.iterator,e.arg);if("throw"===o.type)return e.method="throw",e.arg=o.arg,e.delegate=null,g;var i=o.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=r),e.delegate=null,g):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,g)}function C(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function G(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function P(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(C,this),this.reset(!0)}function A(e){if(e||""===e){var n=e[l];if(n)return n.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var a=-1,i=function t(){for(;++a<e.length;)if(o.call(e,a))return t.value=e[a],t.done=!1,t;return t.value=r,t.done=!0,t};return i.next=i}}throw new TypeError(t(e)+" is not iterable")}return b.prototype=w,i(S,"constructor",{value:w,configurable:!0}),i(w,"constructor",{value:b,configurable:!0}),b.displayName=f(w,u,"GeneratorFunction"),n.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===b||"GeneratorFunction"===(e.displayName||e.name))},n.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,w):(t.__proto__=w,f(t,u,"GeneratorFunction")),t.prototype=Object.create(S),t},n.awrap=function(t){return{__await:t}},j(k.prototype),f(k.prototype,s,(function(){return this})),n.AsyncIterator=k,n.async=function(t,e,r,a,o){void 0===o&&(o=Promise);var i=new k(d(t,e,r,a),o);return n.isGeneratorFunction(e)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},j(S),f(S,u,"Generator"),f(S,l,(function(){return this})),f(S,"toString",(function(){return"[object Generator]"})),n.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},n.values=A,P.prototype={constructor:P,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=r,this.done=!1,this.delegate=null,this.method="next",this.arg=r,this.tryEntries.forEach(G),!t)for(var e in this)"t"===e.charAt(0)&&o.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=r)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(n,a){return c.type="throw",c.arg=t,e.next=n,a&&(e.method="next",e.arg=r),!!a}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var l=o.call(i,"catchLoc"),s=o.call(i,"finallyLoc");if(l&&s){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(l){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.tryLoc<=this.prev&&o.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var a=n;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,g):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),g},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),G(r),g}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var a=n.arg;G(r)}return a}}throw Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:A(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=r),g}},n}function r(t,e,r,n,a,o,i){try{var c=t[o](i),l=c.value}catch(t){return void r(t)}c.done?e(l):Promise.resolve(l).then(n,a)}function n(t){return function(){var e=this,n=arguments;return new Promise((function(a,o){var i=t.apply(e,n);function c(t){r(i,a,o,c,l,"next",t)}function l(t){r(i,a,o,c,l,"throw",t)}c(void 0)}))}}System.register(["./utils-lib-legacy.js?v=1777008528","./base-lib-legacy.js?v=1777008528","./mail-legacy.js?v=1777008528","./validator-legacy.js?v=1777008528","./__commonjsHelpers__-legacy.js?v=1777008528","./index-legacy105.js?v=1777008528","./column-legacy.js?v=1777008528"],(function(t,r){"use strict";var a,o,i,c,l,s,u,f,d,h,p,v,y,m,g,x,b,w,L,E,_,S,j,k,O,H,C,G;return{setters:[function(t){a=t.O,o=t.H,i=t.M,c=t.bl,l=t.u,s=t.a3,u=t.c,f=t.e},function(t){d=t.g,h=t.r,p=t.a$,v=t.i,y=t.c,m=t.t,g=t.s,x=t.o,b=t.a1,w=t.k,L=t.l,E=t.e,_=t.x,S=t.q,j=t.p,k=t.v,O=t.aT},function(t){H=t.g,C=t.u},function(t){G=t.e},null,null,null],execute:function(){var r=d("MAIL_OVERVIEW",(function(){var t=h({delivered:0,bounced:0,received:0,rejected:0}),r=h(),l=h(),s=p({tooltip:{trigger:"axis",order:"seriesDesc",axisPointer:{type:"shadow",label:{formatter:function(t){return a(t.value,"HH:mm")}}}},legend:{top:0,itemGap:16,icon:"circle",itemWidth:10,itemHeight:10,data:["发送成功","发送失败"],textStyle:{lineHeight:12,padding:[0,0,-2,0],rich:{a:{verticalAlign:"middle"}}}},grid:{top:"16%",left:"2%",right:"3%",bottom:"4%",containLabel:!0},xAxis:{type:"category",name:"小时",axisLabel:{formatter:function(t){return a(t,"HH:mm")}}},yAxis:{type:"value",minInterval:1,boundaryGap:[0,"6%"],splitLine:{show:!0,lineStyle:{type:"dashed",width:1,color:"#ebeef5"}}},series:[{type:"bar",name:"发送失败",data:[]},{type:"bar",name:"发送成功",data:[]}]}),u=p({tooltip:{trigger:"axis",order:"seriesDesc",axisPointer:{type:"shadow",label:{formatter:function(t){return a(t.value,"HH:mm")}}}},legend:{top:0,itemGap:16,icon:"circle",itemWidth:10,itemHeight:10,data:["接收成功","接收失败"],textStyle:{lineHeight:12,padding:[0,0,-2,0],rich:{a:{verticalAlign:"middle"}}}},grid:{top:"16%",left:"2%",right:"3%",bottom:"4%",containLabel:!0},xAxis:{type:"category",name:"小时",axisLabel:{formatter:function(t){return a(t,"HH:mm")}}},yAxis:{type:"value",minInterval:1,boundaryGap:[0,"6%"],splitLine:{show:!0,lineStyle:{type:"dashed",width:1,color:"#ebeef5"}}},series:[{type:"bar",name:"接收失败",data:[]},{type:"bar",name:"接收成功",data:[]}]}),f=v((function(){return t.value.delivered||0})),d=v((function(){return t.value.bounced||0})),y=v((function(){var t=d.value+f.value;return 0===t?0:(f.value/t*100).toFixed(1)})),m=v((function(){return t.value.received||0})),g=v((function(){return t.value.rejected||0})),x=v((function(){var t=g.value+m.value;return 0===t?0:(m.value/t*100).toFixed(1)})),b=function(){var a=n(e().mark((function a(f,d,h,p){return e().wrap((function(a){for(;;)switch(a.prev=a.next){case 0:o({request:H(),loading:"数据加载中...",success:function(){var a=n(e().mark((function n(a){var o;return e().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if((o=a.data).status){e.next=3;break}return e.abrupt("return",i.error(o.msg));case 3:if(!c(o.data)){e.next=14;break}return t.value=o.data.stats_dict,e.next=7,f();case 7:return l.value=e.sent,e.next=10,d();case 10:r.value=e.sent,w(o.data.hourly_stats),h(s),p(u);case 14:case"end":return e.stop()}}),n)})));return function(t){return a.apply(this,arguments)}}()});case 1:case"end":return a.stop()}}),a)})));return function(t,e,r,n){return a.apply(this,arguments)}}(),w=function(t){var e=[],r=[],n=[],a=[];t.forEach((function(t){e.push([t.time,t.bounced]),r.push([t.time,t.delivered]),n.push([t.time,t.received]),a.push([t.time,t.rejected])})),s.series=[{type:"bar",name:"发送失败",data:e,stack:"total",itemStyle:{color:"#1A519B"}},{type:"bar",name:"发送成功",data:r,stack:"total",itemStyle:{color:"#91CC75"}}],u.series=[{type:"bar",name:"接收失败",data:a,stack:"total",itemStyle:{color:"#1A519B"}},{type:"bar",name:"接收成功",data:n,stack:"total",itemStyle:{color:"#91CC75"}}]};return{total:t,sendOption:s,receivedOption:u,sendSuccess:f,sendFail:d,sendSuccessRate:y,receiveSuccess:m,receiveFail:g,receiveSuccessRate:x,getData:b,$reset:function(){t.value={delivered:0,bounced:0,received:0,rejected:0},l.value=null,r.value=null}}})),P=h({period:{total:"--",used:"--",surplus:"--"},free:{total:"--",used:"--",surplus:"--"}}),A=function(){window.open("https://www.bt.cn/bbs/thread-141971-1-1.html")},F=function(){G({name:"宝塔邮局",type:36,id:63})},I={class:"flex items-center"},N={class:"p-24px"},R={class:"total-list"},T={class:"total-item"},B={class:"total-value text-primary text-22px"},D={class:"total-item"},q={class:"total-value text-17px"},W={class:"total-item"},$={class:"total-value text-17px"},M={class:"h-200px"},V={class:"p-24px"},Y={class:"total-list"},Q={class:"total-item"},z={class:"total-value text-primary text-22px"},J={class:"total-item"},K={class:"total-value text-17px"},U={class:"total-item"},X={class:"total-value text-17px"},Z={class:"h-200px"},tt=y({__name:"today",setup:function(t){var e=l().payment;m(e.value);var n=r(),a=g(n),c=a.sendSuccessRate,f=a.sendSuccess,d=a.sendFail,h=a.receiveSuccessRate,p=a.receiveSuccess,v=a.receiveFail,y=s({options:{}}),H=y.BtECharts,G=y.getEChart,tt=y.setOption,et=(y.setQuickOption,s({options:{}})),rt=et.BtECharts,nt=et.getEChart,at=et.setOption;return x((function(){!function(){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];o({request:C(arguments.length>0&&void 0!==arguments[0]&&arguments[0]?{fresh:1}:{}),success:function(e){Object.keys(P.value).forEach((function(t){P.value[t]=e.data.hasOwnProperty(t)?e.data[t]:"--"})),t&&i.success("刷新成功")}})}(),n.getData(G,nt,tt,at)})),b((function(){n.$reset()})),function(t,e){var r=u,n=O;return w(),L("div",null,[E(n,{class:"mb-[14px] !border-none"},{header:_((function(){return[S("div",I,[e[2]||(e[2]=S("span",{class:"text-[1.6rem]"},"今日发送",-1)),E(r,{class:"ml-[12px]",onClick:j(F)},{default:_((function(){return e[0]||(e[0]=[S("div",{class:"flex items-center"},[S("span",{class:"svgtofont-desired text-[1.6rem]"}),S("span",null,"需求反馈")],-1)])})),_:1},8,["onClick"]),E(r,{class:"ml-[12px]",onClick:j(A)},{default:_((function(){return e[1]||(e[1]=[S("div",{class:"flex items-center"},[S("span",{class:"text-[1.2rem]"},">>"),S("span",null,"使用说明")],-1)])})),_:1},8,["onClick"])])]})),default:_((function(){return[S("div",N,[S("div",R,[S("div",T,[e[3]||(e[3]=S("div",{class:"total-label"},"发送成功率",-1)),S("div",B,k(j(c))+"%",1)]),S("div",D,[e[4]||(e[4]=S("div",{class:"total-label"},"发送成功",-1)),S("div",q,k(j(f)),1)]),S("div",W,[e[5]||(e[5]=S("div",{class:"total-label"},"发送失败",-1)),S("div",$,k(j(d)),1)])]),S("div",M,[E(j(H),{ref:"echartRef",style:{height:"200px"}},null,512)])])]})),_:1}),E(n,{class:"!border-none"},{header:_((function(){return e[6]||(e[6]=[S("div",{class:"flex items-center"},[S("span",{class:"text-[1.6rem]"},"今日接收")],-1)])})),default:_((function(){return[S("div",V,[S("div",Y,[S("div",Q,[e[7]||(e[7]=S("div",{class:"total-label"},"接收成功率",-1)),S("div",z,k(j(h))+"%",1)]),S("div",J,[e[8]||(e[8]=S("div",{class:"total-label"},"接收成功",-1)),S("div",K,k(j(p)),1)]),S("div",U,[e[9]||(e[9]=S("div",{class:"total-label"},"接收失败",-1)),S("div",X,k(j(v)),1)])]),S("div",Z,[E(j(rt),{ref:"sendEchartRef",style:{height:"200px"}},null,512)])])]})),_:1})])}}});t("default",f(tt,[["__scopeId","data-v-d19fc40f"]]))}}}))}();