File: /www/server/panel/BTPanel/static/js/detect-history-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(t){return function(t){if(Array.isArray(t))return n(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return n(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(t,e):void 0}}(t)||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(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}function r(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */var t,e,n="function"==typeof Symbol?Symbol:{},i=n.iterator||"@@iterator",a=n.toStringTag||"@@toStringTag";function u(n,r,i,a){var u=r&&r.prototype instanceof s?r:s,l=Object.create(u.prototype);return o(l,"_invoke",function(n,r,o){var i,a,u,s=0,l=o||[],f=!1,p={p:0,n:0,v:t,a:m,f:m.bind(t,4),d:function(e,n){return i=e,a=0,u=t,p.n=n,c}};function m(n,r){for(a=n,u=r,e=0;!f&&s&&!o&&e<l.length;e++){var o,i=l[e],m=p.p,y=i[2];n>3?(o=y===r)&&(u=i[(a=i[4])?5:(a=3,3)],i[4]=i[5]=t):i[0]<=m&&((o=n<2&&m<i[1])?(a=0,p.v=r,p.n=i[1]):m<y&&(o=n<3||i[0]>r||r>y)&&(i[4]=n,i[5]=r,p.n=y,a=0))}if(o||n>1)return c;throw f=!0,r}return function(o,l,y){if(s>1)throw TypeError("Generator is already running");for(f&&1===l&&m(l,y),a=l,u=y;(e=a<2?t:u)||!f;){i||(a?a<3?(a>1&&(p.n=-1),m(a,u)):p.n=u:p.v=u);try{if(s=2,i){if(a||(o="next"),e=i[o]){if(!(e=e.call(i,u)))throw TypeError("iterator result is not an object");if(!e.done)return e;u=e.value,a<2&&(a=0)}else 1===a&&(e=i.return)&&e.call(i),a<2&&(u=TypeError("The iterator does not provide a '"+o+"' method"),a=1);i=t}else if((e=(f=p.n<0)?u:n.call(r,p))!==c)break}catch(e){i=t,a=1,u=e}finally{s=1}}return{value:e,done:f}}}(n,i,a),!0),l}var c={};function s(){}function l(){}function f(){}e=Object.getPrototypeOf;var p=[][i]?e(e([][i]())):(o(e={},i,function(){return this}),e),m=f.prototype=s.prototype=Object.create(p);function y(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,f):(t.__proto__=f,o(t,a,"GeneratorFunction")),t.prototype=Object.create(m),t}return l.prototype=f,o(m,"constructor",f),o(f,"constructor",l),l.displayName="GeneratorFunction",o(f,a,"GeneratorFunction"),o(m),o(m,a,"Generator"),o(m,i,function(){return this}),o(m,"toString",function(){return"[object Generator]"}),(r=function(){return{w:u,m:y}})()}function o(t,e,n,r){var i=Object.defineProperty;try{i({},"",{})}catch(t){i=0}o=function(t,e,n,r){function a(e,n){o(t,e,function(t){return this._invoke(e,n,t)})}e?i?i(t,e,{value:n,enumerable:!r,configurable:!r,writable:!r}):t[e]=n:(a("next",0),a("throw",1),a("return",2))},o(t,e,n,r)}function i(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),n.push.apply(n,r)}return n}function a(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?i(Object(n),!0).forEach(function(e){u(t,e,n[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))})}return t}function u(e,n,r){return(n=function(e){var n=function(e,n){if("object"!=t(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,n||"default");if("object"!=t(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===n?String:Number)(e)}(e,"string");return"symbol"==t(n)?n:n+""}(n))in e?Object.defineProperty(e,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[n]=r,e}function c(t,e,n,r,o,i,a){try{var u=t[i](a),c=u.value}catch(t){return void n(t)}u.done?e(c):Promise.resolve(c).then(r,o)}System.register(["./utils-lib-legacy.js?v=1777008528","./index-legacy118.js?v=1777008528","./site-legacy.js?v=1777008528","./base-lib-legacy.js?v=1777008528","./__commonjsHelpers__-legacy.js?v=1777008528"],function(t,n){"use strict";var o,i,u,s,l,f,p,m,y,b,d,v,g,h,_,j,O,w,S,P;return{setters:[function(t){o=t.c,i=t.ed,u=t.o,s=t.dE,l=t.a2,f=t.R,p=t.e,m=t._},function(t){y=t._},function(t){b=t.getSingleSiteRisk,d=t.getRisk},function(t){v=t.c,g=t.r,h=t.j,_=t.C,j=t.v,O=t.e,w=t.p,S=t.L,P=t.x},null],execute:function(){t("default",v({__name:"detect-history",props:{compData:{default:function(){return{isPopup:!1,name:""}}}},setup:function(t){var v=t,k=o().mainHeight,x=g(v.compData.isPopup);v.compData;var D=function(){var t,e=(t=r().m(function t(e){var n,o,i;return r().w(function(t){for(;;)switch(t.n){case 0:return n=x.value?b(a({site_name:v.compData.name},e)):d(a({},e)),t.n=1,n;case 1:return o=t.v,i=o.data,t.a(2,{data:i.data||[],total:i.page?u(i.page):0})}},t)}),function(){var e=this,n=arguments;return new Promise(function(r,o){var i=t.apply(e,n);function a(t){c(i,r,o,a,u,"next",t)}function u(t){c(i,r,o,a,u,"throw",t)}a(void 0)})});return function(t){return e.apply(this,arguments)}}(),T=function(t){p({title:"风险详情",area:[70,55],component:function(){return m(function(){return n.import("./risk-detail-legacy.js?v=1777008528")},void 0,n.meta.url)},compData:t})},E=i({request:D,columns:[{label:"网站列表",prop:"site_name",width:120},{label:"扫描URL总数",prop:"scans",width:100},{label:"扫描耗时",prop:"time",render:function(t){return[t.end_time<=1||t.end_time-t.start_time<=0?O("span",null,[P("0秒")]):O("span",null,[s(t.end_time-t.start_time)])]}},{label:"风险次数",prop:"risks",render:function(t){return[0==t.risks?O("span",null,[P("无风险")]):O("span",{class:"bt-link !text-danger",onClick:function(){return T(t)}},[t.risks])]}},{label:"状态",prop:"status",render:function(t){return[0===t.is_status&&0===t.end_time||1===t.end_time?O("span",{class:"text-red"},[P("扫描未完成")]):1===t.is_status&&0===t.end_time?O("span",{class:"text-warning"},[P("扫描中")]):O("span",null,[P("扫描完成")])]}},{label:"扫描时间",prop:"start_time",width:200,render:function(t){var e=l(t.start_time,"number",0);return O("span",null,[f(e)])}},{label:"操作",align:"right",render:function(t){return[0===t.is_status&&0===t.end_time||1===t.end_time||1===t.is_status&&0===t.end_time?O("span",{class:"text-disabled cursor-not-allowed"},[P("扫描未完成")]):O("span",{class:"bt-link",onClick:function(){return function(t){window.open("/project/content/report/html?id="+t.testing_id,"_blank","noopener,noreferrer")}(t)}},[P("查看报告")])]}}]}),A=E.BtTable,G=(E.refresh,E.BtPage);return function(t,n){var r=y;return h(),_(r,{class:S({"p-[2rem]":w(x)})},{content:j(function(){return[O(w(A),{"max-height":w(x)?500:w(k)-240,description:"检测历史列表为空"},null,8,["max-height"])]}),"footer-right":j(function(){return[O(w(G))]}),popup:j(function(){return e(n[0]||(n[0]=[]))}),_:1},8,["class"])}}}))}}})}();