← Back
Editing: index-legacy73.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)}var e=["type_id"];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 e,n={},o=Object.prototype,i=o.hasOwnProperty,a=Object.defineProperty||function(t,e,r){t[e]=r.value},c="function"==typeof Symbol?Symbol:{},u=c.iterator||"@@iterator",s=c.asyncIterator||"@@asyncIterator",l=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(e){f=function(t,e,r){return t[e]=r}}function p(t,e,r,n){var o=e&&e.prototype instanceof b?e:b,i=Object.create(o.prototype),c=new T(n||[]);return a(i,"_invoke",{value:S(t,r,c)}),i}function h(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}n.wrap=p;var v="suspendedStart",y="suspendedYield",d="executing",g="completed",m={};function b(){}function w(){}function _(){}var x={};f(x,u,(function(){return this}));var j=Object.getPrototypeOf,O=j&&j(j(B([])));O&&O!==o&&i.call(O,u)&&(x=O);var L=_.prototype=b.prototype=Object.create(x);function k(t){["next","throw","return"].forEach((function(e){f(t,e,(function(t){return this._invoke(e,t)}))}))}function P(e,r){function n(o,a,c,u){var s=h(e[o],e,a);if("throw"!==s.type){var l=s.arg,f=l.value;return f&&"object"==t(f)&&i.call(f,"__await")?r.resolve(f.__await).then((function(t){n("next",t,c,u)}),(function(t){n("throw",t,c,u)})):r.resolve(f).then((function(t){l.value=t,c(l)}),(function(t){return n("throw",t,c,u)}))}u(s.arg)}var o;a(this,"_invoke",{value:function(t,e){function i(){return new r((function(r,o){n(t,e,r,o)}))}return o=o?o.then(i,i):i()}})}function S(t,r,n){var o=v;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===g){if("throw"===i)throw a;return{value:e,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=E(c,n);if(u){if(u===m)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===v)throw o=g,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var s=h(t,r,n);if("normal"===s.type){if(o=n.done?g:y,s.arg===m)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(o=g,n.method="throw",n.arg=s.arg)}}}function E(t,r){var n=r.method,o=t.iterator[n];if(o===e)return r.delegate=null,"throw"===n&&t.iterator.return&&(r.method="return",r.arg=e,E(t,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var i=h(o,t.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,m;var a=i.arg;return a?a.done?(r[t.resultName]=a.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,m):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function N(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 C(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function T(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(N,this),this.reset(!0)}function B(r){if(r||""===r){var n=r[u];if(n)return n.call(r);if("function"==typeof r.next)return r;if(!isNaN(r.length)){var o=-1,a=function t(){for(;++o<r.length;)if(i.call(r,o))return t.value=r[o],t.done=!1,t;return t.value=e,t.done=!0,t};return a.next=a}}throw new TypeError(t(r)+" is not iterable")}return w.prototype=_,a(L,"constructor",{value:_,configurable:!0}),a(_,"constructor",{value:w,configurable:!0}),w.displayName=f(_,l,"GeneratorFunction"),n.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===w||"GeneratorFunction"===(e.displayName||e.name))},n.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,_):(t.__proto__=_,f(t,l,"GeneratorFunction")),t.prototype=Object.create(L),t},n.awrap=function(t){return{__await:t}},k(P.prototype),f(P.prototype,s,(function(){return this})),n.AsyncIterator=P,n.async=function(t,e,r,o,i){void 0===i&&(i=Promise);var a=new P(p(t,e,r,o),i);return n.isGeneratorFunction(e)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},k(L),f(L,l,"Generator"),f(L,u,(function(){return this})),f(L,"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=B,T.prototype={constructor:T,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(C),!t)for(var r in this)"t"===r.charAt(0)&&i.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},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 r=this;function n(n,o){return c.type="throw",c.arg=t,r.next=n,o&&(r.method="next",r.arg=e),!!o}for(var o=this.tryEntries.length-1;o>=0;--o){var a=this.tryEntries[o],c=a.completion;if("root"===a.tryLoc)return n("end");if(a.tryLoc<=this.prev){var u=i.call(a,"catchLoc"),s=i.call(a,"finallyLoc");if(u&&s){if(this.prev<a.catchLoc)return n(a.catchLoc,!0);if(this.prev<a.finallyLoc)return n(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return n(a.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return n(a.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&&i.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var o=n;break}}o&&("break"===t||"continue"===t)&&o.tryLoc<=e&&e<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,m):this.complete(a)},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),m},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),C(r),m}},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 o=n.arg;C(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:B(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),m}},n}function n(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function o(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?n(Object(r),!0).forEach((function(e){i(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):n(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function i(e,r,n){return(r=function(e){var r=function(e,r){if("object"!=t(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,r||"default");if("object"!=t(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===r?String:Number)(e)}(e,"string");return"symbol"==t(r)?r:r+""}(r))in e?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,e}function a(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function c(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function c(t){a(i,n,o,c,u,"next",t)}function u(t){a(i,n,o,c,u,"throw",t)}c(void 0)}))}}System.register(["./utils-lib-legacy.js?v=VERSION_NUMBER","./index-legacy103.js?v=VERSION_NUMBER","./base-lib-legacy.js?v=VERSION_NUMBER","./column-legacy.js?v=VERSION_NUMBER","./useController-legacy6.js?v=VERSION_NUMBER","./useStore-legacy4.js?v=VERSION_NUMBER","./index-legacy141.js?v=VERSION_NUMBER","./validator-legacy.js?v=VERSION_NUMBER","./index.vue_vue_type_style_index_0_scoped_b3c4124c_lang-legacy.js?v=VERSION_NUMBER","./site-legacy.js?v=VERSION_NUMBER"],(function(t,n){"use strict";var i,a,u,s,l,f,p,h,v,y,d,g,m,b,w,_,x,j,O,L,k,P,S,E,N,C,T,B,G,I,F,D,M,q,A,R,Y,z,H,J,U,V,$,K,Q,W;return{setters:[function(t){i=t.n,a=t.L,u=t.M,s=t.fg,l=t.u,f=t.aM,p=t.a6,h=t.q,v=t.a8},function(t){y=t._},function(t){d=t.r,g=t.g,m=t.c,b=t.s,w=t.e,_=t.B,x=t.w,j=t.p,O=t.n,L=t.q,k=t.M,P=t.A,S=t.x,E=t.y},function(t){N=t.a,C=t.d,T=t.g,B=t.u},function(t){G=t.b,I=t.g,F=t.d,D=t.f,M=t.h,q=t.s,A=t.i,R=t.u,Y=t.a,z=t.l,H=t.j},function(t){J=t.u,U=t.S},function(t){V=t.u},function(t){$=t.f,K=t.l},null,function(t){Q=t.getNetVersion,W=t.getPluginInfo}],execute:function(){var X=J(),Z=X.isRefreshList,tt=X.siteInfo,et=U(),rt=et.editGeneralProject,nt=et.addGeneralProject,ot=et.setSiteInfo,it=function(){tt.value=null,i({title:"添加.Net项目",area:72,component:function(){return a((function(){return n.import("./index-legacy372.js?v=VERSION_NUMBER")}),void 0,n.meta.url)},showFooter:!0})},at=function(t){ot(t,arguments.length>1&&void 0!==arguments[1]?arguments[1]:""),i({title:".Net项目管理["+t.name+"] -- 添加时间["+t.addtime+"]",area:[84,72],component:function(){return a((function(){return n.import("./index-legacy373.js?v=VERSION_NUMBER")}),void 0,n.meta.url)}})},ct=(t("i",(function(t){})),t("v",d([]))),ut=t("c",g((function(){return!!tt.value}))),st=t("n",d({project_path:"",project_name:"",port:"",project_cmd:"",run_user:"www",project_ps:"",release_firewall:!1,dotnet_version:"",is_power_on:!1,bind_extranet:!1})),lt=(t("a",function(){var t=c(r().mark((function t(e,n,i){var a,c,s;return r().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,i.value.validate();case 3:return a={data:JSON.stringify(o(o({},e.value),{},{is_power_on:e.value.is_power_on?1:0}))},c=tt.value?rt:nt,t.next=7,c(a);case 7:return s=t.sent,u.msg({dangerouslyUseHTMLString:!0,message:s.msg,type:s.status?"success":"error",duration:s.status?2e3:0,showClose:!s.status,customClass:"!max-w-[66rem]"}),Z.value=!0,t.abrupt("return",s.status);case 13:return t.prev=13,t.t0=t.catch(0),t.abrupt("return",!1);case 17:case"end":return t.stop()}}),t,null,[[0,13]])})));return function(e,r,n){return t.apply(this,arguments)}}()),t("o",(function(){$({type:"all",path:st.value.project_path,change:function(t){st.value.project_path=t}})})),t("g",c(r().mark((function t(){var e,n,o=arguments;return r().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e=o.length>0&&void 0!==o[0]&&o[0],t.prev=1,t.next=4,Q();case 4:if(n=t.sent,ct.value=n.data.map((function(t){return{label:t,value:t}})),!e){t.next=8;break}return t.abrupt("return",u.success("Net版本,刷新成功"));case 8:st.value.dotnet_version=n.data[0],t.next=14;break;case 11:t.prev=11,t.t0=t.catch(1);case 14:case"end":return t.stop()}}),t,null,[[1,11]])}))))),ft=(t("b",c(r().mark((function t(){var e,n,i;return r().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,lt();case 2:ut.value&&(e=tt.value,n=e.project_config,i=e.ps,Object.assign(st.value,o(o({},n),{},{project_ps:s(i),bind_extranet:1===n.bind_extranet,is_power_on:1===n.is_power_on,port:n.port})));case 3:case"end":return t.stop()}}),t)})))),t("$",(function(){Object.assign(st.value,{project_path:"",project_name:"",port:"",project_cmd:"",run_user:"www",project_ps:"",release_firewall:!1,dotnet_version:"",is_power_on:!1,bind_extranet:!1})})),t("d",c(r().mark((function t(){var e,n;return r().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,W({sName:"dotnet"});case 3:return e=t.sent,n=e.data,t.next=7,K({name:"dotnet",softData:n});case 7:t.next=12;break;case 9:t.prev=9,t.t0=t.catch(0);case 12:case"end":return t.stop()}}),t,null,[[0,9]])}))))),pt=m({__name:"index",setup:function(t){l();var i=U(),u=i.getSiteList,s=i.setSiteInfo,d=b(U()),g=(d.activeType,d.isRefreshList),m=d.siteInfo,J=f({options:[{type:"button",label:"添加项目",active:!0,onClick:it},{type:"button",label:".Net环境管理",onClick:ft}]}).BtOperation,$=V({key:"type_id",name:"Net分类",options:function(){return[{label:"全部分类",value:"all"}]},event:M,ignore:["0"],field:"type_name"}),K=v([R(),Y({classList:H}),{label:"删除项目",value:"delete",event:z}]),Q=p({request:function(t){var r=t.type_id,n=function(t,e){if(null==t)return{};var r,n,o=function(t,e){if(null==t)return{};var r={};for(var n in t)if({}.hasOwnProperty.call(t,n)){if(-1!==e.indexOf(n))continue;r[n]=t[n]}return r}(t,e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(n=0;n<i.length;n++)r=i[n],-1===e.indexOf(r)&&{}.propertyIsEnumerable.call(t,r)&&(o[r]=t[r])}return o}(t,e);return u(o(o({},n),{},{type_id:h(r)||"all"===r?"":r,table:"sites"}))},columns:[N(),G({onClick:function(t){at(t)}}),I({onClick:function(t,e){if("setting"!==e){var r=t.run?"stop":"start";q(t,"restart"===e?e:r)}else at(t,"state")}}),C(),T({table:"sites",width:200}),F({onClick:function(t){at(t,"ssl")}}),B([{title:"设置",onClick:function(t){at(t)}},{title:"删除",onClick:function(t){A(t)}}])],extension:[$,K],empty:function(){return w("span",null,[_("您的列表为空,您可以"),w("span",{class:"bt-link",onClick:it},[_("添加一个项目")])])}}),W=Q.BtTable,X=Q.BtPage,Z=Q.BtRefresh,tt=Q.BtSearch,et=Q.BtColumn,rt=Q.BtBatch,nt=Q.BtTableCategory,ot=Q.refresh,ct=Q.config;return x(g,function(){var t=c(r().mark((function t(e){var n,o;return r().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!e){t.next=6;break}return t.next=4,ot();case 4:null!==(n=m.value)&&void 0!==n&&n.name&&(o=ct.data.find((function(t){return t.name===m.value.name})))&&s(o),g.value=!1;case 6:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()),j((function(){O((function(){a((function(){return n.import("./index-legacy372.js?v=VERSION_NUMBER")}),void 0,n.meta.url),a((function(){return n.import("./index-legacy373.js?v=VERSION_NUMBER")}),void 0,n.meta.url)}))})),function(t,e){var r=y;return L(),k(r,null,{"header-left":P((function(){return[w(S(J)),E("div",{class:"flex items-center ml-1rem",onClick:e[0]||(e[0]=function(){return S(D)&&S(D).apply(void 0,arguments)})},e[1]||(e[1]=[E("i",{class:"svgtofont-desired text-[1.6rem]"},null,-1),E("span",{class:"bt-link"},"需求反馈",-1)]))]})),"header-right":P((function(){return[w(S(nt),{class:"!w-[200px] mr-[10px]"}),w(S(tt),{class:"mr-[10px]",placeholder:"请输入项目名称或备注"}),w(S(Z),{class:"mr-[10px]"}),w(S(et))]})),content:P((function(){return[w(S(W))]})),"footer-left":P((function(){return[w(S(rt))]})),"footer-right":P((function(){return[w(S(X))]})),_:1})}}}),ht=Object.freeze(Object.defineProperty({__proto__:null,default:pt},Symbol.toStringTag,{value:"Module"}));t("e",ht)}}}))}();
Save File
Cancel