anncic-api 1.3.1 → 1.3.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/config/config.default.js +1 -1
- package/dist/config/config.production.js +1 -1
- package/dist/configuration.js +1 -1
- package/dist/decorator/Action.js +1 -1
- package/dist/decorator/ActionApi.js +1 -1
- package/dist/decorator/ActionApitest.js +1 -1
- package/dist/exception/ApiError.js +1 -1
- package/dist/helper/getAppsConfig.js +1 -1
- package/dist/helper/getRoutes.js +1 -1
- package/dist/index.js +1 -1
- package/dist/service/ApiService.js +1 -1
- package/dist/service/ApitestService.js +1 -1
- package/dist/service/ExcelService.js +1 -1
- package/dist/types/action.js +1 -1
- package/dist/types/common.js +1 -1
- package/package.json +8 -8
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';function a0_0x3c76(){var _0x22a3ff=['1722644YTGhXa','7CYiIJO','text','4154016dcBUML','8yVwMrC','1339812bnVWqH','dhauo1234420123gg3234901','3aFByFA','20mb','zhiulanuiy7892387985hnoi','80mjqXVh','2672248SAelZN','1851806lxWAAm','/runtime/.upload','23619XdRWxq','762900dsOLln'];a0_0x3c76=function(){return _0x22a3ff;};return a0_0x3c76();}(function(_0x2a1781,_0x4d286b){var _0x195fc9=a0_0x548c,_0x3ed042=_0x2a1781();while(!![]){try{var _0x5b1156=-parseInt(_0x195fc9(0xb1))/0x1*(parseInt(_0x195fc9(0xb7))/0x2)+parseInt(_0x195fc9(0xaa))/0x3*(parseInt(_0x195fc9(0xb3))/0x4)+-parseInt(_0x195fc9(0xb2))/0x5+-parseInt(_0x195fc9(0xb6))/0x6+-parseInt(_0x195fc9(0xb4))/0x7*(parseInt(_0x195fc9(0xae))/0x8)+-parseInt(_0x195fc9(0xb8))/0x9+-parseInt(_0x195fc9(0xad))/0xa*(-parseInt(_0x195fc9(0xaf))/0xb);if(_0x5b1156===_0x4d286b)break;else _0x3ed042['push'](_0x3ed042['shift']());}catch(_0x3045fd){_0x3ed042['push'](_0x3ed042['shift']());}}}(a0_0x3c76,0x56b42));function a0_0x548c(_0x5da734,_0x21bd10){var _0x3c7629=a0_0x3c76();return a0_0x548c=function(_0x548c82,_0x4a2abe){_0x548c82=_0x548c82-0xaa;var _0x2c57f5=_0x3c7629[_0x548c82];return _0x2c57f5;},a0_0x548c(_0x5da734,_0x21bd10);}Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports['default']=_0x6fc9c6=>{var _0x1d7651=a0_0x548c;return{'apitest':!![],'keys':_0x6fc9c6['name'],'anncicapi':{'timeout':0x1388,'password':_0x1d7651(0xac),'devices':{'DEFAULT':{'secret':_0x1d7651(0xb9),'checkcode':'dhauo1234420123gg3234901'}}},'bodyParser':{'enableTypes':['json','form',_0x1d7651(0xb5),'xml'],'formLimit':'20mb','jsonLimit':_0x1d7651(0xab),'textLimit':'20mb','xmlLimit':'20mb'},'upload':{'tmpdir':_0x6fc9c6['appDir']+_0x1d7651(0xb0),'cleanTimeout':0x5265c00}};};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';function
|
|
1
|
+
'use strict';var a1_0x5e546e=a1_0x1450;function a1_0x1450(_0x27216f,_0x3612c2){var _0x55dc6d=a1_0x55dc();return a1_0x1450=function(_0x14503e,_0xbb5cdf){_0x14503e=_0x14503e-0x15a;var _0xb4efff=_0x55dc6d[_0x14503e];return _0xb4efff;},a1_0x1450(_0x27216f,_0x3612c2);}function a1_0x55dc(){var _0x58775f=['defineProperty','65708QnuoFK','1476522aufqNP','4287018bmcvPF','default','975140adRlqw','99DWRvBd','488lyqVAs','2429538rPPQHv','250mfltzu','2850304ToNXMh','107541hsKgoH','__esModule'];a1_0x55dc=function(){return _0x58775f;};return a1_0x55dc();}(function(_0x151345,_0x12553c){var _0x43c54a=a1_0x1450,_0x450ad5=_0x151345();while(!![]){try{var _0x3cfe12=parseInt(_0x43c54a(0x160))/0x1+-parseInt(_0x43c54a(0x15b))/0x2+parseInt(_0x43c54a(0x166))/0x3+parseInt(_0x43c54a(0x15f))/0x4*(-parseInt(_0x43c54a(0x15a))/0x5)+parseInt(_0x43c54a(0x161))/0x6+-parseInt(_0x43c54a(0x15c))/0x7*(parseInt(_0x43c54a(0x165))/0x8)+parseInt(_0x43c54a(0x164))/0x9*(parseInt(_0x43c54a(0x163))/0xa);if(_0x3cfe12===_0x12553c)break;else _0x450ad5['push'](_0x450ad5['shift']());}catch(_0x1fb13a){_0x450ad5['push'](_0x450ad5['shift']());}}}(a1_0x55dc,0xd9418));Object[a1_0x5e546e(0x15e)](exports,a1_0x5e546e(0x15d),{'value':!![]}),exports[a1_0x5e546e(0x162)]={'apitest':![],'anncicapi':{'timeout':0x1388}};
|
package/dist/configuration.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const a2_0x34fb96=a2_0x429d;(function(_0x55a346,_0x232e62){const _0x4a31bd=a2_0x429d,_0x189d45=_0x55a346();while(!![]){try{const _0x1fe9db=parseInt(_0x4a31bd(0x7a))/0x1*(-parseInt(_0x4a31bd(0x84))/0x2)+parseInt(_0x4a31bd(0xc4))/0x3*(parseInt(_0x4a31bd(0x8d))/0x4)+-parseInt(_0x4a31bd(0xc5))/0x5*(parseInt(_0x4a31bd(0x78))/0x6)+parseInt(_0x4a31bd(0xce))/0x7+-parseInt(_0x4a31bd(0xa3))/0x8+parseInt(_0x4a31bd(0x98))/0x9*(-parseInt(_0x4a31bd(0x83))/0xa)+-parseInt(_0x4a31bd(0xc2))/0xb*(-parseInt(_0x4a31bd(0x80))/0xc);if(_0x1fe9db===_0x232e62)break;else _0x189d45['push'](_0x189d45['shift']());}catch(_0xa5754){_0x189d45['push'](_0x189d45['shift']());}}}(a2_0x7862,0xe6f9d));function a2_0x429d(_0x10411d,_0x5388d9){const _0x78624d=a2_0x7862();return a2_0x429d=function(_0x429db1,_0x393308){_0x429db1=_0x429db1-0x6d;let _0x572a34=_0x78624d[_0x429db1];return _0x572a34;},a2_0x429d(_0x10411d,_0x5388d9);}var __decorate=this&&this[a2_0x34fb96(0xba)]||function(_0x38d352,_0x5780e6,_0x506439,_0x354cc7){const _0x55bfd0=a2_0x34fb96;var _0x1d98c5=arguments[_0x55bfd0(0x73)],_0x3302f7=_0x1d98c5<0x3?_0x5780e6:_0x354cc7===null?_0x354cc7=Object[_0x55bfd0(0xbf)](_0x5780e6,_0x506439):_0x354cc7,_0x354b9e;if(typeof Reflect===_0x55bfd0(0xc0)&&typeof Reflect[_0x55bfd0(0xa9)]==='function')_0x3302f7=Reflect[_0x55bfd0(0xa9)](_0x38d352,_0x5780e6,_0x506439,_0x354cc7);else{for(var _0x3b394e=_0x38d352[_0x55bfd0(0x73)]-0x1;_0x3b394e>=0x0;_0x3b394e--)if(_0x354b9e=_0x38d352[_0x3b394e])_0x3302f7=(_0x1d98c5<0x3?_0x354b9e(_0x3302f7):_0x1d98c5>0x3?_0x354b9e(_0x5780e6,_0x506439,_0x3302f7):_0x354b9e(_0x5780e6,_0x506439))||_0x3302f7;}return _0x1d98c5>0x3&&_0x3302f7&&Object[_0x55bfd0(0x86)](_0x5780e6,_0x506439,_0x3302f7),_0x3302f7;},__metadata=this&&this[a2_0x34fb96(0xcf)]||function(_0x5ee13e,_0x2e9275){const _0x21e9b8=a2_0x34fb96;if(typeof Reflect===_0x21e9b8(0xc0)&&typeof Reflect[_0x21e9b8(0xc8)]===_0x21e9b8(0xcd))return Reflect[_0x21e9b8(0xc8)](_0x5ee13e,_0x2e9275);};Object['defineProperty'](exports,a2_0x34fb96(0xd0),{'value':!![]}),exports[a2_0x34fb96(0x9c)]=void 0x0;const core_1=require(a2_0x34fb96(0xbe)),core_2=require('@midwayjs/core'),ApiError_1=require(a2_0x34fb96(0x8b)),ApiService_1=require(a2_0x34fb96(0x8a)),action_1=require(a2_0x34fb96(0x8e)),fs=require('fs'),koa=require(a2_0x34fb96(0xb4)),i18n=require(a2_0x34fb96(0x7d)),upload=require('@midwayjs/upload'),staticFile=require(a2_0x34fb96(0x99)),crossDomain=require(a2_0x34fb96(0xc7)),ConfigDefault=require(a2_0x34fb96(0xaa)),ConfigProduction=require(a2_0x34fb96(0x97)),anncic=require(a2_0x34fb96(0x9d)),anncicCache=require(a2_0x34fb96(0xc6)),anncicEvent=require(a2_0x34fb96(0xae)),anncicTypeorm=require(a2_0x34fb96(0x87)),anncicValidator=require(a2_0x34fb96(0x77)),anncicHelper=require(a2_0x34fb96(0x90));let CustomConfiguration=class CustomConfiguration{async[a2_0x34fb96(0x95)](){const _0x430818=a2_0x34fb96;await this[_0x430818(0xb2)](),await this[_0x430818(0x76)](),await this[_0x430818(0x92)](),await this[_0x430818(0xbc)]();}async[a2_0x34fb96(0x76)](){}async[a2_0x34fb96(0x92)](){const _0xc0c44e=a2_0x34fb96,_0x126768=this[_0xc0c44e(0x9e)][_0xc0c44e(0xcc)]();this[_0xc0c44e(0xc1)][_0xc0c44e(0x96)](action_1['ACTION_ROUTE_KEY'],_0x11a6c6=>{const _0x2b53da=_0xc0c44e,_0x2d0ea9=_0x11a6c6[_0x2b53da(0xc8)];return{'before':async _0x1f1a9c=>{const _0x154f77=_0x2b53da;var _0x104719,_0x5b7de0;const _0x14a0d8=(_0x104719=_0x1f1a9c===null||_0x1f1a9c===void 0x0?void 0x0:_0x1f1a9c['target'])===null||_0x104719===void 0x0?void 0x0:_0x104719[core_2[_0x154f77(0x81)]];if(_0x14a0d8&&(_0x2d0ea9===null||_0x2d0ea9===void 0x0?void 0x0:_0x2d0ea9[_0x154f77(0x93)])){if(!this[_0x154f77(0xb5)][_0x154f77(0xcb)]((_0x5b7de0=_0x14a0d8===null||_0x14a0d8===void 0x0?void 0x0:_0x14a0d8[_0x154f77(0x85)])===null||_0x5b7de0===void 0x0?void 0x0:_0x5b7de0[_0x154f77(0xca)]))throw new AnnError(ApiError_1[_0x154f77(0x94)][_0x154f77(0xa4)]);}},'around':async _0xbf818=>{const _0x5e67dd=_0x2b53da;var _0x5d1beb,_0x20cf90,_0x40b3a9,_0x3e70ee,_0xb3b9c4;const _0x1ccd04=(_0x5d1beb=_0xbf818===null||_0xbf818===void 0x0?void 0x0:_0xbf818['target'])===null||_0x5d1beb===void 0x0?void 0x0:_0x5d1beb[core_2[_0x5e67dd(0x81)]];if(_0x1ccd04&&(_0x2d0ea9===null||_0x2d0ea9===void 0x0?void 0x0:_0x2d0ea9[_0x5e67dd(0x93)])){if(((_0x20cf90=_0x1ccd04['headers'])===null||_0x20cf90===void 0x0?void 0x0:_0x20cf90['device'])&&((_0xb3b9c4=(_0x3e70ee=(_0x40b3a9=_0x126768===null||_0x126768===void 0x0?void 0x0:_0x126768[_0x5e67dd(0x74)])===null||_0x40b3a9===void 0x0?void 0x0:_0x40b3a9[_0x5e67dd(0x7c)])===null||_0x3e70ee===void 0x0?void 0x0:_0x3e70ee[_0x1ccd04[_0x5e67dd(0xca)][_0x5e67dd(0xaf)]])===null||_0xb3b9c4===void 0x0?void 0x0:_0xb3b9c4[_0x5e67dd(0xd1)])){const _0x28a3d8=Array['isArray'](_0x126768[_0x5e67dd(0x74)][_0x5e67dd(0x7c)][_0x1ccd04[_0x5e67dd(0xca)][_0x5e67dd(0xaf)]]['intercept'])?_0x126768[_0x5e67dd(0x74)][_0x5e67dd(0x7c)][_0x1ccd04[_0x5e67dd(0xca)][_0x5e67dd(0xaf)]][_0x5e67dd(0xd1)]:[_0x126768['anncicapi'][_0x5e67dd(0x7c)][_0x1ccd04[_0x5e67dd(0xca)]['device']][_0x5e67dd(0xd1)]];for(const _0x305bff of _0x28a3d8){if(core_1[_0x5e67dd(0x91)][_0x5e67dd(0xbd)](_0x305bff)||typeof _0x305bff=='string'){const _0x334110=await _0x1ccd04[_0x5e67dd(0xa8)][_0x5e67dd(0xb8)](_0x305bff);typeof(_0x334110===null||_0x334110===void 0x0?void 0x0:_0x334110[_0x5e67dd(0xad)])==_0x5e67dd(0xcd)&&await _0x334110['handler'](typeof(_0x1ccd04===null||_0x1ccd04===void 0x0?void 0x0:_0x1ccd04[_0x5e67dd(0xc9)])=='string'&&(_0x1ccd04===null||_0x1ccd04===void 0x0?void 0x0:_0x1ccd04[_0x5e67dd(0x70)])?_0x1ccd04[_0x5e67dd(0xc9)][_0x5e67dd(0xb7)]()+'@'+(_0x1ccd04===null||_0x1ccd04===void 0x0?void 0x0:_0x1ccd04['_matchedRoute']):undefined,_0x1ccd04,_0x2d0ea9);}else core_1['Types'][_0x5e67dd(0xb1)](_0x305bff)&&await _0x305bff(typeof(_0x1ccd04===null||_0x1ccd04===void 0x0?void 0x0:_0x1ccd04[_0x5e67dd(0xc9)])==_0x5e67dd(0xb9)&&(_0x1ccd04===null||_0x1ccd04===void 0x0?void 0x0:_0x1ccd04[_0x5e67dd(0x70)])?_0x1ccd04[_0x5e67dd(0xc9)]['toLowerCase']()+'@'+(_0x1ccd04===null||_0x1ccd04===void 0x0?void 0x0:_0x1ccd04[_0x5e67dd(0x70)]):undefined,_0x1ccd04,_0x2d0ea9);}}}return await _0xbf818[_0x5e67dd(0xa2)](..._0xbf818['args']);},'afterThrow':(_0x198ac3,_0x57aed6)=>{throw _0x57aed6;}};});}async['hanlderApplications'](){const _0x4d91b6=a2_0x34fb96;this[_0x4d91b6(0x8f)][_0x4d91b6(0x89)](['koa'])[_0x4d91b6(0x9f)](_0x28b816=>{const _0x4626c5=_0x4d91b6;(_0x28b816===null||_0x28b816===void 0x0?void 0x0:_0x28b816[_0x4626c5(0x71)])&&Object['defineProperties'](_0x28b816['context'],{'ok':{'value':function(_0x193f65,_0x1bb7f2,_0x10cc02=0x0){return{'code':_0x10cc02,'data':_0x193f65,'extra':_0x1bb7f2};}},'input':{'value':function(_0x3cedeb,_0xa0501a){const _0x32ad8c=_0x4626c5;var _0x260a01;const _0x49dabb=lodash[_0x32ad8c(0x72)]({},this['request']['body']||this[_0x32ad8c(0x85)][((_0x260a01=config===null||config===void 0x0?void 0x0:config['bodyXml'])===null||_0x260a01===void 0x0?void 0x0:_0x260a01[_0x32ad8c(0x9a)])||_0x32ad8c(0xab)]||{},this[_0x32ad8c(0x85)]['query']||{});return _0x3cedeb?lodash[_0x32ad8c(0x8c)](_0x49dabb,_0x3cedeb,_0xa0501a):_0x49dabb;}},'when':{'value':async function(_0x255fba,_0x7e5863){const _0x201205=this['input'](_0x255fba,null);if(!lodash['isNull'](_0x201205))return await _0x7e5863(_0x201205);}},'only':{'value':function(_0x54e605){const _0x39ea8f=_0x4626c5,_0x39b25d={};for(let _0x3405a5=0x0;_0x3405a5<_0x54e605[_0x39ea8f(0x73)];_0x3405a5++){lodash['isArray'](_0x54e605[_0x3405a5])&&_0x54e605[_0x3405a5]['length']>0x0&&lodash[_0x39ea8f(0x7e)](_0x54e605[_0x3405a5][0x0])&&(_0x39b25d[_0x54e605[_0x3405a5][0x0]]=this[_0x39ea8f(0xa0)](_0x54e605[_0x3405a5][0x0],_0x54e605[_0x3405a5][_0x39ea8f(0x73)]>0x1?_0x54e605[_0x3405a5][0x1]:null));}return _0x39b25d;}}});});}async['filterConfig'](){const _0x5804ee=a2_0x34fb96;var _0xd4547,_0x465cfe,_0x5c2b90,_0x24c0a5,_0x27af89,_0x17408a;const _0xda124c=this[_0x5804ee(0x9e)][_0x5804ee(0xcc)]();((_0x465cfe=(_0xd4547=_0xda124c===null||_0xda124c===void 0x0?void 0x0:_0xda124c[_0x5804ee(0x74)])===null||_0xd4547===void 0x0?void 0x0:_0xd4547[_0x5804ee(0x7c)])===null||_0x465cfe===void 0x0?void 0x0:_0x465cfe[_0x5804ee(0xb3)])&&Object[_0x5804ee(0x6f)](_0xda124c[_0x5804ee(0x74)][_0x5804ee(0x7c)])[_0x5804ee(0x73)]>0x1&&delete _0xda124c[_0x5804ee(0x74)]['devices'][_0x5804ee(0xb3)];if((_0x5c2b90=_0xda124c===null||_0xda124c===void 0x0?void 0x0:_0xda124c[_0x5804ee(0x82)])===null||_0x5c2b90===void 0x0?void 0x0:_0x5c2b90['dirs'])for(const _0x44c911 in _0xda124c[_0x5804ee(0x82)][_0x5804ee(0xa6)]){((_0x24c0a5=_0xda124c[_0x5804ee(0x82)][_0x5804ee(0xa6)][_0x44c911])===null||_0x24c0a5===void 0x0?void 0x0:_0x24c0a5[_0x5804ee(0x6e)])&&typeof((_0x27af89=_0xda124c[_0x5804ee(0x82)][_0x5804ee(0xa6)][_0x44c911])===null||_0x27af89===void 0x0?void 0x0:_0x27af89['dir'])==_0x5804ee(0xb9)&&!fs['existsSync'](_0xda124c['staticFile'][_0x5804ee(0xa6)][_0x44c911][_0x5804ee(0x6e)])&&(fs[_0x5804ee(0x7b)](_0xda124c[_0x5804ee(0x82)][_0x5804ee(0xa6)][_0x44c911][_0x5804ee(0x6e)],{'recursive':!![]}),console[_0x5804ee(0xa1)](_0x5804ee(0xb6)+_0xda124c[_0x5804ee(0x82)][_0x5804ee(0xa6)][_0x44c911][_0x5804ee(0x6e)]));}((_0x17408a=_0xda124c===null||_0xda124c===void 0x0?void 0x0:_0xda124c['upload'])===null||_0x17408a===void 0x0?void 0x0:_0x17408a['tmpdir'])&&!fs[_0x5804ee(0x9b)](_0xda124c[_0x5804ee(0x79)]['tmpdir'])&&(fs['mkdirSync'](_0xda124c[_0x5804ee(0x79)]['tmpdir'],{'recursive':!![]}),console[_0x5804ee(0xa1)]('Anncic-api\x20upload-tmpdir\x20:\x20mkdir\x20'+_0xda124c[_0x5804ee(0x79)][_0x5804ee(0xac)])),this[_0x5804ee(0x9e)]['addObject'](_0xda124c);}};__decorate([(0x0,core_1[a2_0x34fb96(0x6d)])(),__metadata(a2_0x34fb96(0xa5),core_2['MidwayConfigService'])],CustomConfiguration['prototype'],a2_0x34fb96(0x9e),void 0x0),__decorate([(0x0,core_1[a2_0x34fb96(0x6d)])(),__metadata(a2_0x34fb96(0xa5),core_2[a2_0x34fb96(0x88)])],CustomConfiguration[a2_0x34fb96(0xc3)],a2_0x34fb96(0xc1),void 0x0),__decorate([(0x0,core_1[a2_0x34fb96(0x6d)])(),__metadata('design:type',core_2[a2_0x34fb96(0xa7)])],CustomConfiguration['prototype'],a2_0x34fb96(0x8f),void 0x0),__decorate([(0x0,core_1['Inject'])(),__metadata(a2_0x34fb96(0xa5),core_2[a2_0x34fb96(0x7f)])],CustomConfiguration[a2_0x34fb96(0xc3)],a2_0x34fb96(0x75),void 0x0),__decorate([(0x0,core_1[a2_0x34fb96(0x6d)])(),__metadata(a2_0x34fb96(0xa5),ApiService_1[a2_0x34fb96(0xb5)])],CustomConfiguration[a2_0x34fb96(0xc3)],a2_0x34fb96(0xb5),void 0x0),CustomConfiguration=__decorate([(0x0,core_1[a2_0x34fb96(0xb0)])({'imports':[koa,i18n,upload,staticFile,crossDomain,anncic,anncicCache,anncicEvent,anncicTypeorm,anncicValidator,anncicHelper],'namespace':a2_0x34fb96(0xbb),'conflictCheck':![],'importConfigs':[{'default':ConfigDefault,'production':ConfigProduction}]})],CustomConfiguration),exports['CustomConfiguration']=CustomConfiguration;function a2_0x7862(){const _0x154eea=['@anncic-api/event','device','Configuration','isFunction','filterConfig','DEFAULT','@midwayjs/koa','ApiService','Anncic-api\x20static-file\x20:\x20mkdir\x20','toLowerCase','getAsync','string','__decorate','anncic-api','hanlderApplications','isClass','@midwayjs/core','getOwnPropertyDescriptor','object','decorator','1063865YWgIMa','prototype','12qdOMWk','10665RQczRV','@anncic-api/cache','@midwayjs/cross-domain','metadata','method','headers','checksign','getConfiguration','function','665658llSsdz','__metadata','__esModule','intercept','Inject','dir','keys','_matchedRoute','context','defaultsDeep','length','anncicapi','environment','checkConfigKeys','@anncic-api/validator','4890sMHoHX','upload','75wLynJk','mkdirSync','devices','@midwayjs/i18n','isString','MidwayEnvironmentService','372rHBDON','REQUEST_OBJ_CTX_KEY','staticFile','342340ORIfuu','27038mRYMSJ','request','defineProperty','@anncic-api/typeorm','MidwayDecoratorService','getApplications','./service/ApiService','./exception/ApiError','get','1304068ATwgFz','./types/action','application','anncic-apihelper','Types','handlerActionRoute','apimit','ApiError','onReady','registerMethodHandler','./config/config.production','180awYyim','@midwayjs/static-file','key','existsSync','CustomConfiguration','@anncic-api/core','config','forEach','input','log','proceed','114000OSDmmc','HEADERS_SIGNATURE','design:type','dirs','MidwayApplicationManager','requestContext','decorate','./config/config.default','body','tmpdir','handler'];a2_0x7862=function(){return _0x154eea;};return a2_0x7862();}
|
|
1
|
+
'use strict';const a2_0x4ea3bf=a2_0x48a9;(function(_0x315002,_0x4cf290){const _0x4e18ec=a2_0x48a9,_0x4559a0=_0x315002();while(!![]){try{const _0x3b5cd1=parseInt(_0x4e18ec(0x1f2))/0x1+parseInt(_0x4e18ec(0x207))/0x2*(parseInt(_0x4e18ec(0x213))/0x3)+-parseInt(_0x4e18ec(0x235))/0x4*(-parseInt(_0x4e18ec(0x1ff))/0x5)+-parseInt(_0x4e18ec(0x1ea))/0x6*(parseInt(_0x4e18ec(0x23c))/0x7)+parseInt(_0x4e18ec(0x227))/0x8+-parseInt(_0x4e18ec(0x21a))/0x9*(-parseInt(_0x4e18ec(0x20c))/0xa)+-parseInt(_0x4e18ec(0x1fa))/0xb;if(_0x3b5cd1===_0x4cf290)break;else _0x4559a0['push'](_0x4559a0['shift']());}catch(_0x5b521e){_0x4559a0['push'](_0x4559a0['shift']());}}}(a2_0xd265,0x94be8));function a2_0x48a9(_0x9cb1a,_0xc27b26){const _0xd265fd=a2_0xd265();return a2_0x48a9=function(_0x48a92a,_0x3bfced){_0x48a92a=_0x48a92a-0x1d9;let _0x260cf5=_0xd265fd[_0x48a92a];return _0x260cf5;},a2_0x48a9(_0x9cb1a,_0xc27b26);}function a2_0xd265(){const _0x4acdbc=['MidwayEnvironmentService','ACTION_ROUTE_KEY','staticFile','getConfiguration','Inject','key','design:type','Anncic-api\x20upload-tmpdir\x20:\x20mkdir\x20','checkConfigKeys','isClass','isArray','intercept','5762292FswFaO','environment','getOwnPropertyDescriptor','handlerActionRoute','getAsync','application','./types/action','@midwayjs/core','1174685BvBSvu','registerMethodHandler','length','@anncic-api/typeorm','context','method','@midwayjs/i18n','addObject','12945361rTQUZD','handler','tmpdir','HEADERS_SIGNATURE','forEach','15iouOXO','MidwayConfigService','__metadata','Types','dir','prototype','devices','REQUEST_OBJ_CTX_KEY','234338MkHEEo','__esModule','isFunction','ApiService','decorate','20vXyXvn','getApplications','anncic-api','request','device','function','target','9ABfimE','anncic-apihelper','isString','@anncic-api/cache','requestContext','MidwayDecoratorService','mkdirSync','482643oZOBqx','@midwayjs/koa','@midwayjs/cross-domain','defineProperties','MidwayApplicationManager','checksign','proceed','decorator','metadata','Configuration','./config/config.default','defineProperty','CustomConfiguration','4741472ECRqqv','hanlderApplications','object','input','./service/ApiService','string','filterConfig','headers','defaultsDeep','@midwayjs/static-file','Anncic-api\x20static-file\x20:\x20mkdir\x20','@anncic-api/core','bodyXml','apimit','693812McjilR','log','config','toLowerCase','dirs','_matchedRoute','@anncic-api/event','7ICXTuY','./exception/ApiError','anncicapi','onReady','DEFAULT','upload','args'];a2_0xd265=function(){return _0x4acdbc;};return a2_0xd265();}var __decorate=this&&this['__decorate']||function(_0x19d0e0,_0x4a8442,_0x4e6d5c,_0x489dac){const _0x1b03c5=a2_0x48a9;var _0x422b5e=arguments[_0x1b03c5(0x1f4)],_0x48c63f=_0x422b5e<0x3?_0x4a8442:_0x489dac===null?_0x489dac=Object[_0x1b03c5(0x1ec)](_0x4a8442,_0x4e6d5c):_0x489dac,_0x20cd85;if(typeof Reflect===_0x1b03c5(0x229)&&typeof Reflect[_0x1b03c5(0x20b)]===_0x1b03c5(0x211))_0x48c63f=Reflect[_0x1b03c5(0x20b)](_0x19d0e0,_0x4a8442,_0x4e6d5c,_0x489dac);else{for(var _0x576652=_0x19d0e0[_0x1b03c5(0x1f4)]-0x1;_0x576652>=0x0;_0x576652--)if(_0x20cd85=_0x19d0e0[_0x576652])_0x48c63f=(_0x422b5e<0x3?_0x20cd85(_0x48c63f):_0x422b5e>0x3?_0x20cd85(_0x4a8442,_0x4e6d5c,_0x48c63f):_0x20cd85(_0x4a8442,_0x4e6d5c))||_0x48c63f;}return _0x422b5e>0x3&&_0x48c63f&&Object[_0x1b03c5(0x225)](_0x4a8442,_0x4e6d5c,_0x48c63f),_0x48c63f;},__metadata=this&&this[a2_0x4ea3bf(0x201)]||function(_0x531184,_0x4caefd){const _0x5837fd=a2_0x4ea3bf;if(typeof Reflect===_0x5837fd(0x229)&&typeof Reflect[_0x5837fd(0x222)]===_0x5837fd(0x211))return Reflect[_0x5837fd(0x222)](_0x531184,_0x4caefd);};Object[a2_0x4ea3bf(0x225)](exports,a2_0x4ea3bf(0x208),{'value':!![]}),exports[a2_0x4ea3bf(0x226)]=void 0x0;const core_1=require(a2_0x4ea3bf(0x1f1)),core_2=require(a2_0x4ea3bf(0x1f1)),ApiError_1=require(a2_0x4ea3bf(0x23d)),ApiService_1=require(a2_0x4ea3bf(0x22b)),action_1=require(a2_0x4ea3bf(0x1f0)),fs=require('fs'),koa=require(a2_0x4ea3bf(0x21b)),i18n=require(a2_0x4ea3bf(0x1f8)),upload=require('@midwayjs/upload'),staticFile=require(a2_0x4ea3bf(0x230)),crossDomain=require(a2_0x4ea3bf(0x21c)),ConfigDefault=require(a2_0x4ea3bf(0x224)),ConfigProduction=require('./config/config.production'),anncic=require(a2_0x4ea3bf(0x232)),anncicCache=require(a2_0x4ea3bf(0x216)),anncicEvent=require(a2_0x4ea3bf(0x23b)),anncicTypeorm=require(a2_0x4ea3bf(0x1f5)),anncicValidator=require('@anncic-api/validator'),anncicHelper=require(a2_0x4ea3bf(0x214));let CustomConfiguration=class CustomConfiguration{async[a2_0x4ea3bf(0x1da)](){const _0xa863d=a2_0x4ea3bf;await this[_0xa863d(0x22d)](),await this[_0xa863d(0x1e6)](),await this['handlerActionRoute'](),await this[_0xa863d(0x228)]();}async[a2_0x4ea3bf(0x1e6)](){}async[a2_0x4ea3bf(0x1ed)](){const _0x1ec051=a2_0x4ea3bf,_0x5ba284=this[_0x1ec051(0x237)]['getConfiguration']();this[_0x1ec051(0x221)][_0x1ec051(0x1f3)](action_1[_0x1ec051(0x1df)],_0x3b682a=>{const _0x1c42fd=_0x3b682a['metadata'];return{'before':async _0x4d39ab=>{const _0x187f84=a2_0x48a9;var _0x1f5d69,_0x1b4743;const _0x4f4d4c=(_0x1f5d69=_0x4d39ab===null||_0x4d39ab===void 0x0?void 0x0:_0x4d39ab[_0x187f84(0x212)])===null||_0x1f5d69===void 0x0?void 0x0:_0x1f5d69[core_2[_0x187f84(0x206)]];if(_0x4f4d4c&&(_0x1c42fd===null||_0x1c42fd===void 0x0?void 0x0:_0x1c42fd[_0x187f84(0x234)])){if(!this[_0x187f84(0x20a)][_0x187f84(0x21f)]((_0x1b4743=_0x4f4d4c===null||_0x4f4d4c===void 0x0?void 0x0:_0x4f4d4c[_0x187f84(0x20f)])===null||_0x1b4743===void 0x0?void 0x0:_0x1b4743[_0x187f84(0x22e)]))throw new AnnError(ApiError_1['ApiError'][_0x187f84(0x1fd)]);}},'around':async _0x2fff2a=>{const _0x107dd7=a2_0x48a9;var _0x35a76c,_0x347e99,_0x8206e,_0x1ccc4c,_0x381cf2;const _0xddcdc=(_0x35a76c=_0x2fff2a===null||_0x2fff2a===void 0x0?void 0x0:_0x2fff2a[_0x107dd7(0x212)])===null||_0x35a76c===void 0x0?void 0x0:_0x35a76c[core_2['REQUEST_OBJ_CTX_KEY']];if(_0xddcdc&&(_0x1c42fd===null||_0x1c42fd===void 0x0?void 0x0:_0x1c42fd[_0x107dd7(0x234)])){if(((_0x347e99=_0xddcdc['headers'])===null||_0x347e99===void 0x0?void 0x0:_0x347e99['device'])&&((_0x381cf2=(_0x1ccc4c=(_0x8206e=_0x5ba284===null||_0x5ba284===void 0x0?void 0x0:_0x5ba284[_0x107dd7(0x1d9)])===null||_0x8206e===void 0x0?void 0x0:_0x8206e[_0x107dd7(0x205)])===null||_0x1ccc4c===void 0x0?void 0x0:_0x1ccc4c[_0xddcdc[_0x107dd7(0x22e)][_0x107dd7(0x210)]])===null||_0x381cf2===void 0x0?void 0x0:_0x381cf2['intercept'])){const _0x52b286=Array[_0x107dd7(0x1e8)](_0x5ba284[_0x107dd7(0x1d9)]['devices'][_0xddcdc['headers']['device']][_0x107dd7(0x1e9)])?_0x5ba284['anncicapi']['devices'][_0xddcdc[_0x107dd7(0x22e)][_0x107dd7(0x210)]][_0x107dd7(0x1e9)]:[_0x5ba284[_0x107dd7(0x1d9)][_0x107dd7(0x205)][_0xddcdc['headers']['device']][_0x107dd7(0x1e9)]];for(const _0x3c9838 of _0x52b286){if(core_1[_0x107dd7(0x202)][_0x107dd7(0x1e7)](_0x3c9838)||typeof _0x3c9838==_0x107dd7(0x22c)){const _0x374d49=await _0xddcdc[_0x107dd7(0x217)][_0x107dd7(0x1ee)](_0x3c9838);typeof(_0x374d49===null||_0x374d49===void 0x0?void 0x0:_0x374d49[_0x107dd7(0x1fb)])==_0x107dd7(0x211)&&await _0x374d49['handler'](typeof(_0xddcdc===null||_0xddcdc===void 0x0?void 0x0:_0xddcdc[_0x107dd7(0x1f7)])==_0x107dd7(0x22c)&&(_0xddcdc===null||_0xddcdc===void 0x0?void 0x0:_0xddcdc[_0x107dd7(0x23a)])?_0xddcdc[_0x107dd7(0x1f7)][_0x107dd7(0x238)]()+'@'+(_0xddcdc===null||_0xddcdc===void 0x0?void 0x0:_0xddcdc[_0x107dd7(0x23a)]):undefined,_0xddcdc,_0x1c42fd);}else core_1[_0x107dd7(0x202)][_0x107dd7(0x209)](_0x3c9838)&&await _0x3c9838(typeof(_0xddcdc===null||_0xddcdc===void 0x0?void 0x0:_0xddcdc[_0x107dd7(0x1f7)])==_0x107dd7(0x22c)&&(_0xddcdc===null||_0xddcdc===void 0x0?void 0x0:_0xddcdc['_matchedRoute'])?_0xddcdc[_0x107dd7(0x1f7)][_0x107dd7(0x238)]()+'@'+(_0xddcdc===null||_0xddcdc===void 0x0?void 0x0:_0xddcdc[_0x107dd7(0x23a)]):undefined,_0xddcdc,_0x1c42fd);}}}return await _0x2fff2a[_0x107dd7(0x220)](..._0x2fff2a[_0x107dd7(0x1dd)]);},'afterThrow':(_0x180638,_0xead44b)=>{throw _0xead44b;}};});}async[a2_0x4ea3bf(0x228)](){const _0x3ac3be=a2_0x4ea3bf;this['application'][_0x3ac3be(0x20d)](['koa'])[_0x3ac3be(0x1fe)](_0x1274ff=>{const _0x7c06da=_0x3ac3be;(_0x1274ff===null||_0x1274ff===void 0x0?void 0x0:_0x1274ff[_0x7c06da(0x1f6)])&&Object[_0x7c06da(0x21d)](_0x1274ff[_0x7c06da(0x1f6)],{'ok':{'value':function(_0xc756cd,_0x21662a,_0x2442a0=0x0){return{'code':_0x2442a0,'data':_0xc756cd,'extra':_0x21662a};}},'input':{'value':function(_0x219ea6,_0x3f9bb4){const _0x18547e=_0x7c06da;var _0x5973b8;const _0x1fe1a2=lodash[_0x18547e(0x22f)]({},this[_0x18547e(0x20f)]['body']||this[_0x18547e(0x20f)][((_0x5973b8=config===null||config===void 0x0?void 0x0:config[_0x18547e(0x233)])===null||_0x5973b8===void 0x0?void 0x0:_0x5973b8[_0x18547e(0x1e3)])||'body']||{},this['request']['query']||{});return _0x219ea6?lodash['get'](_0x1fe1a2,_0x219ea6,_0x3f9bb4):_0x1fe1a2;}},'when':{'value':async function(_0x119063,_0x207193){const _0x1eaa6c=this['input'](_0x119063,null);if(!lodash['isNull'](_0x1eaa6c))return await _0x207193(_0x1eaa6c);}},'only':{'value':function(_0x4df4b3){const _0x1f5927=_0x7c06da,_0x145b22={};for(let _0x3bcd0c=0x0;_0x3bcd0c<_0x4df4b3[_0x1f5927(0x1f4)];_0x3bcd0c++){lodash[_0x1f5927(0x1e8)](_0x4df4b3[_0x3bcd0c])&&_0x4df4b3[_0x3bcd0c]['length']>0x0&&lodash[_0x1f5927(0x215)](_0x4df4b3[_0x3bcd0c][0x0])&&(_0x145b22[_0x4df4b3[_0x3bcd0c][0x0]]=this[_0x1f5927(0x22a)](_0x4df4b3[_0x3bcd0c][0x0],_0x4df4b3[_0x3bcd0c][_0x1f5927(0x1f4)]>0x1?_0x4df4b3[_0x3bcd0c][0x1]:null));}return _0x145b22;}}});});}async[a2_0x4ea3bf(0x22d)](){const _0x325802=a2_0x4ea3bf;var _0x59b35b,_0x51857b,_0x57c961,_0x53b72f,_0x19218f,_0x5f39b5;const _0x1e569b=this[_0x325802(0x237)][_0x325802(0x1e1)]();((_0x51857b=(_0x59b35b=_0x1e569b===null||_0x1e569b===void 0x0?void 0x0:_0x1e569b[_0x325802(0x1d9)])===null||_0x59b35b===void 0x0?void 0x0:_0x59b35b[_0x325802(0x205)])===null||_0x51857b===void 0x0?void 0x0:_0x51857b[_0x325802(0x1db)])&&Object['keys'](_0x1e569b[_0x325802(0x1d9)]['devices'])[_0x325802(0x1f4)]>0x1&&delete _0x1e569b['anncicapi'][_0x325802(0x205)][_0x325802(0x1db)];if((_0x57c961=_0x1e569b===null||_0x1e569b===void 0x0?void 0x0:_0x1e569b[_0x325802(0x1e0)])===null||_0x57c961===void 0x0?void 0x0:_0x57c961[_0x325802(0x239)])for(const _0x445ea7 in _0x1e569b['staticFile'][_0x325802(0x239)]){((_0x53b72f=_0x1e569b[_0x325802(0x1e0)]['dirs'][_0x445ea7])===null||_0x53b72f===void 0x0?void 0x0:_0x53b72f[_0x325802(0x203)])&&typeof((_0x19218f=_0x1e569b[_0x325802(0x1e0)]['dirs'][_0x445ea7])===null||_0x19218f===void 0x0?void 0x0:_0x19218f[_0x325802(0x203)])=='string'&&!fs['existsSync'](_0x1e569b[_0x325802(0x1e0)]['dirs'][_0x445ea7][_0x325802(0x203)])&&(fs['mkdirSync'](_0x1e569b[_0x325802(0x1e0)]['dirs'][_0x445ea7][_0x325802(0x203)],{'recursive':!![]}),console[_0x325802(0x236)](_0x325802(0x231)+_0x1e569b[_0x325802(0x1e0)][_0x325802(0x239)][_0x445ea7][_0x325802(0x203)]));}((_0x5f39b5=_0x1e569b===null||_0x1e569b===void 0x0?void 0x0:_0x1e569b[_0x325802(0x1dc)])===null||_0x5f39b5===void 0x0?void 0x0:_0x5f39b5['tmpdir'])&&!fs['existsSync'](_0x1e569b['upload'][_0x325802(0x1fc)])&&(fs[_0x325802(0x219)](_0x1e569b[_0x325802(0x1dc)][_0x325802(0x1fc)],{'recursive':!![]}),console[_0x325802(0x236)](_0x325802(0x1e5)+_0x1e569b[_0x325802(0x1dc)][_0x325802(0x1fc)])),this[_0x325802(0x237)][_0x325802(0x1f9)](_0x1e569b);}};__decorate([(0x0,core_1['Inject'])(),__metadata(a2_0x4ea3bf(0x1e4),core_2[a2_0x4ea3bf(0x200)])],CustomConfiguration[a2_0x4ea3bf(0x204)],'config',void 0x0),__decorate([(0x0,core_1[a2_0x4ea3bf(0x1e2)])(),__metadata(a2_0x4ea3bf(0x1e4),core_2[a2_0x4ea3bf(0x218)])],CustomConfiguration['prototype'],a2_0x4ea3bf(0x221),void 0x0),__decorate([(0x0,core_1[a2_0x4ea3bf(0x1e2)])(),__metadata(a2_0x4ea3bf(0x1e4),core_2[a2_0x4ea3bf(0x21e)])],CustomConfiguration[a2_0x4ea3bf(0x204)],a2_0x4ea3bf(0x1ef),void 0x0),__decorate([(0x0,core_1[a2_0x4ea3bf(0x1e2)])(),__metadata('design:type',core_2[a2_0x4ea3bf(0x1de)])],CustomConfiguration[a2_0x4ea3bf(0x204)],a2_0x4ea3bf(0x1eb),void 0x0),__decorate([(0x0,core_1[a2_0x4ea3bf(0x1e2)])(),__metadata(a2_0x4ea3bf(0x1e4),ApiService_1[a2_0x4ea3bf(0x20a)])],CustomConfiguration[a2_0x4ea3bf(0x204)],a2_0x4ea3bf(0x20a),void 0x0),CustomConfiguration=__decorate([(0x0,core_1[a2_0x4ea3bf(0x223)])({'imports':[koa,i18n,upload,staticFile,crossDomain,anncic,anncicCache,anncicEvent,anncicTypeorm,anncicValidator,anncicHelper],'namespace':a2_0x4ea3bf(0x20e),'conflictCheck':![],'importConfigs':[{'default':ConfigDefault,'production':ConfigProduction}]})],CustomConfiguration),exports[a2_0x4ea3bf(0x226)]=CustomConfiguration;
|
package/dist/decorator/Action.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';function a3_0x25b6(_0x1482cb,_0x48ad7e){const _0x496804=a3_0x4968();return a3_0x25b6=function(_0x25b66e,_0x57baa1){_0x25b66e=_0x25b66e-0x1eb;let _0x31eede=_0x496804[_0x25b66e];return _0x31eede;},a3_0x25b6(_0x1482cb,_0x48ad7e);}const a3_0x34e55b=a3_0x25b6;(function(_0x189308,_0x10cfcb){const _0x1c69d5=a3_0x25b6,_0x39f97c=_0x189308();while(!![]){try{const _0x186975=parseInt(_0x1c69d5(0x21a))/0x1*(-parseInt(_0x1c69d5(0x216))/0x2)+parseInt(_0x1c69d5(0x1f9))/0x3+-parseInt(_0x1c69d5(0x208))/0x4*(parseInt(_0x1c69d5(0x1fe))/0x5)+parseInt(_0x1c69d5(0x213))/0x6+-parseInt(_0x1c69d5(0x20d))/0x7*(-parseInt(_0x1c69d5(0x21d))/0x8)+-parseInt(_0x1c69d5(0x217))/0x9+parseInt(_0x1c69d5(0x1f5))/0xa;if(_0x186975===_0x10cfcb)break;else _0x39f97c['push'](_0x39f97c['shift']());}catch(_0x37fa59){_0x39f97c['push'](_0x39f97c['shift']());}}}(a3_0x4968,0xaa0f6));Object['defineProperty'](exports,a3_0x34e55b(0x1f2),{'value':!![]}),exports[a3_0x34e55b(0x21f)]=exports['Action']=void 0x0;const fs=require('fs'),core_1=require(a3_0x34e55b(0x21c)),action_1=require('../types/action');function Action(_0x4c79b6,_0x43b6fd,_0x48ee02={'middleware':[],'sensitive':!![]}){return _0x39c6bc=>{const _0x457eaf=a3_0x25b6;_0x48ee02[_0x457eaf(0x218)]=_0x43b6fd;const _0x106012=parseRoute(_0x4c79b6);if(_0x106012[_0x457eaf(0x1ed)]){_0x48ee02[_0x457eaf(0x200)]=_0x48ee02[_0x457eaf(0x200)]?'/'+_0x106012[_0x457eaf(0x1ed)]+'/'+_0x48ee02[_0x457eaf(0x200)]:'/'+_0x106012[_0x457eaf(0x215)];_0x106012['prefix']&&(_0x48ee02[_0x457eaf(0x200)]='/'+_0x106012[_0x457eaf(0x200)]+'/'+_0x48ee02[_0x457eaf(0x200)]);if(fs[_0x457eaf(0x209)](_0x106012[_0x457eaf(0x1fc)]+'/apps/'+_0x106012['module']+_0x457eaf(0x1ee)+(lodash[_0x457eaf(0x219)](_0x106012['filepath'],'ts')?'ts':'js'))){const _0xd2e2f4=include(_0x106012[_0x457eaf(0x1fc)]+_0x457eaf(0x1f6)+_0x106012[_0x457eaf(0x1ed)]+_0x457eaf(0x1ee)+(lodash[_0x457eaf(0x219)](_0x106012[_0x457eaf(0x212)],'ts')?'ts':'js'));if(_0xd2e2f4[_0x457eaf(0x1ec)]&&lodash[_0x457eaf(0x1f4)](_0xd2e2f4[_0x457eaf(0x1ec)])&&_0xd2e2f4[_0x457eaf(0x1ec)]['length']>0x0)for(let _0x100ecc in _0xd2e2f4['middleware']){_0xd2e2f4[_0x457eaf(0x1f3)]['indexOf'](_0xd2e2f4[_0x457eaf(0x1ec)][_0x100ecc])==-0x1&&_0x48ee02[_0x457eaf(0x1ec)][_0x457eaf(0x1eb)](_0xd2e2f4[_0x457eaf(0x1ec)][_0x100ecc]);}const _0x17c5d0=(0x0,core_1[_0x457eaf(0x220)])(action_1[_0x457eaf(0x20f)],action_1[_0x457eaf(0x204)])||{};_0x17c5d0[''+_0x106012[_0x457eaf(0x1ed)]]=_0xd2e2f4,(0x0,core_1['saveClassMetadata'])(action_1[_0x457eaf(0x20f)],_0x17c5d0,action_1[_0x457eaf(0x204)]);}_0x48ee02[_0x457eaf(0x200)]=_0x48ee02[_0x457eaf(0x200)][_0x457eaf(0x205)]()[_0x457eaf(0x1ff)](/\/{2,}/g,'/'),(0x0,core_1[_0x457eaf(0x214)])(action_1[_0x457eaf(0x206)],_0x39c6bc),(0x0,core_1[_0x457eaf(0x207)])(_0x48ee02[_0x457eaf(0x200)],_0x48ee02)(_0x39c6bc),(0x0,core_1['saveClassMetadata'])(action_1[_0x457eaf(0x206)],{'prefix':_0x48ee02[_0x457eaf(0x200)],'pprefix':_0x106012['prefix'],'module':_0x106012[_0x457eaf(0x1ed)],'filepath':_0x106012['filepath'],'routerOptions':_0x48ee02},_0x39c6bc);}else _0x48ee02[_0x457eaf(0x200)]=_0x48ee02[_0x457eaf(0x200)]?'/'+_0x48ee02[_0x457eaf(0x200)]:'/'+_0x106012['route'],_0x106012[_0x457eaf(0x200)]&&(_0x48ee02[_0x457eaf(0x200)]='/'+_0x106012[_0x457eaf(0x200)]+'/'+_0x48ee02[_0x457eaf(0x200)]),_0x48ee02[_0x457eaf(0x200)]=_0x48ee02[_0x457eaf(0x200)]['toLowerCase']()[_0x457eaf(0x1ff)](/\/{2,}/g,'/'),(0x0,core_1[_0x457eaf(0x214)])(action_1[_0x457eaf(0x206)],_0x39c6bc),(0x0,core_1[_0x457eaf(0x207)])(_0x48ee02[_0x457eaf(0x200)],_0x48ee02)(_0x39c6bc),(0x0,core_1['saveClassMetadata'])(action_1[_0x457eaf(0x206)],{'prefix':_0x48ee02[_0x457eaf(0x200)],'module':_0x106012[_0x457eaf(0x1ed)],'pprefix':_0x106012[_0x457eaf(0x200)],'filepath':_0x106012['filepath'],'routerOptions':_0x48ee02},_0x39c6bc);};}exports[a3_0x34e55b(0x202)]=Action;function parseRoute(_0x4a6c17){const _0x597375=a3_0x34e55b;_0x4a6c17=_0x4a6c17[_0x597375(0x1ff)](/(\\|\/)/g,'/');const _0x3a8e5b=process[_0x597375(0x21e)]()[_0x597375(0x1ff)](/(\\|\/)/g,'/'),_0x91db4=_0x4a6c17['substring'](0x0,_0x3a8e5b[_0x597375(0x1fb)]+_0x4a6c17[_0x597375(0x21b)](_0x3a8e5b[_0x597375(0x1fb)]+0x1)['indexOf']('/')+0x1),_0x43c1f6=_0x4a6c17['substring'](_0x91db4[_0x597375(0x1fb)]+0x1)[_0x597375(0x1ff)](/(\\|\/)/g,'/'),_0x1173f5={'route':'','prefix':![],'module':![],'rootpath':_0x91db4,'filepath':_0x43c1f6};if(_0x43c1f6[_0x597375(0x20b)](_0x597375(0x1fa))){const _0x34e9e6=_0x43c1f6['substring'](_0x597375(0x1fa)[_0x597375(0x1fb)])['split']('/')[_0x597375(0x211)](_0x4809f6=>_0x4809f6&&_0x4809f6['trim']());return _0x34e9e6[_0x597375(0x1fb)]>0x1&&(_0x1173f5[_0x597375(0x200)]=_0x34e9e6[0x0][_0x597375(0x205)](),_0x34e9e6['splice'](0x0,0x1)),_0x1173f5[_0x597375(0x215)]=('/'+_0x34e9e6[_0x597375(0x1f0)]('/'))[_0x597375(0x1ff)](/(\.ts|\.js)$/,'')[_0x597375(0x1ff)](/\/{2,}/g,'/')[_0x597375(0x1fd)](/[\/|A-Z]*[^A-Z]+/g)[_0x597375(0x1f0)]('-')[_0x597375(0x205)]()['replace'](/\/\-/g,'/'),_0x1173f5[_0x597375(0x215)][_0x597375(0x219)](_0x597375(0x20c))&&(_0x1173f5[_0x597375(0x215)]=_0x1173f5[_0x597375(0x215)][_0x597375(0x21b)](0x0,_0x1173f5[_0x597375(0x215)][_0x597375(0x1fb)]-0x7)),_0x1173f5[_0x597375(0x215)][_0x597375(0x219)]('-controller')&&(_0x1173f5['route']=_0x1173f5['route'][_0x597375(0x21b)](0x0,_0x1173f5[_0x597375(0x215)][_0x597375(0x1fb)]-0xb)),_0x1173f5;}else{if(_0x43c1f6[_0x597375(0x20b)]('apps/')){const _0x344fc6=_0x43c1f6[_0x597375(0x21b)](0x0,_0x43c1f6['indexOf']('/apps/')+0x5),_0x1faf47=_0x43c1f6[_0x597375(0x21b)](_0x344fc6[_0x597375(0x1fb)]+0x1)[_0x597375(0x1ff)](/(\\|\/)/g,'/')[_0x597375(0x1f8)]('/')[0x0];if(_0x43c1f6[_0x597375(0x20b)](_0x597375(0x210)+_0x1faf47+'/controller/')){const _0x403246=_0x43c1f6[_0x597375(0x21b)]((_0x344fc6+'/'+_0x1faf47+_0x597375(0x20a))[_0x597375(0x1fb)])[_0x597375(0x1f8)]('/')[_0x597375(0x211)](_0x40a252=>_0x40a252&&_0x40a252[_0x597375(0x1f1)]());return _0x403246[_0x597375(0x1fb)]>0x1&&(_0x1173f5[_0x597375(0x200)]=_0x403246[0x0]['toLowerCase'](),_0x403246[_0x597375(0x1ef)](0x0,0x1)),_0x1173f5[_0x597375(0x1ed)]=_0x1faf47,_0x1173f5[_0x597375(0x215)]=('/'+_0x1faf47+'/'+_0x403246['join']('/'))[_0x597375(0x1ff)](/(\.ts|\.js)$/,'')[_0x597375(0x1ff)](/\/{2,}/,'/')[_0x597375(0x1fd)](/[\/|A-Z]*[^A-Z]+/g)[_0x597375(0x1f0)]('-')[_0x597375(0x205)]()[_0x597375(0x1ff)](/\/\-/g,'/'),_0x1173f5[_0x597375(0x215)][_0x597375(0x219)](_0x597375(0x20c))&&(_0x1173f5[_0x597375(0x215)]=_0x1173f5['route'][_0x597375(0x21b)](0x0,_0x1173f5[_0x597375(0x215)][_0x597375(0x1fb)]-0x7)),_0x1173f5[_0x597375(0x215)][_0x597375(0x219)](_0x597375(0x20e))&&(_0x1173f5[_0x597375(0x215)]=_0x1173f5['route'][_0x597375(0x21b)](0x0,_0x1173f5[_0x597375(0x215)]['length']-0xb)),_0x1173f5;}throw new Error(_0x43c1f6+_0x597375(0x201)+_0x1faf47+_0x597375(0x1f7));}}throw new Error(_0x43c1f6+_0x597375(0x203));}exports[a3_0x34e55b(0x21f)]=parseRoute;function a3_0x4968(){const _0x5953d1=['\x20文件请放在apps/','Action','\x20文件请放在app/controller/文件下','AppsConfigTmp','toLowerCase','ACTION_KEY','Controller','12RdMhqw','existsSync','/controller/','startsWith','-action','14gLSotX','-controller','APPSCONFIG_KEY','apps/','filter','filepath','7794954ZWmfls','saveModule','route','9236HLuTjc','10195929kYhpVG','tagName','endsWith','134PgMZjt','substring','@midwayjs/core','1664048DezZus','cwd','parseRoute','getClassMetadata','push','middleware','module','/config.','splice','join','trim','__esModule','middlewareIgnore','isArray','5575620bOcBIQ','/apps/','/controller/文件下','split','2009337hUXqPq','app/controller/','length','rootpath','match','823755xwhtDS','replace','prefix'];a3_0x4968=function(){return _0x5953d1;};return a3_0x4968();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a4_0x31e18a=a4_0x35cc;function a4_0x2e48(){const _0x32f98a=['attachClassMetadata','Validator','routerName','indexOf','string','apimit','5FsXlSe','validate','63UlcZLd','delete','8zvAANS','defineProperty','1442092gEUWFv','26NtWkPw','@anncic-api/validator','3569IAufpE','ACTION_ROUTE_KEY','__esModule','validationOptions','1491807TniMWL','description','length','del','../types/action','middleware','218826piMFxd','@midwayjs/core','filter','Api','middlewareIgnore','3671415aCatji','get','toLowerCase','assign','createCustomMethodDecorator','1348920rheMbS','22553377qfuMPv'];a4_0x2e48=function(){return _0x32f98a;};return a4_0x2e48();}(function(_0x434c24,_0x3a6ff8){const _0x20b2fd=a4_0x35cc,_0x23f665=_0x434c24();while(!![]){try{const _0x2099cb=parseInt(_0x20b2fd(0x19b))/0x1*(-parseInt(_0x20b2fd(0x199))/0x2)+-parseInt(_0x20b2fd(0x19f))/0x3+-parseInt(_0x20b2fd(0x198))/0x4*(parseInt(_0x20b2fd(0x1b7))/0x5)+parseInt(_0x20b2fd(0x1a5))/0x6*(-parseInt(_0x20b2fd(0x1b9))/0x7)+-parseInt(_0x20b2fd(0x196))/0x8*(parseInt(_0x20b2fd(0x1aa))/0x9)+-parseInt(_0x20b2fd(0x1af))/0xa+parseInt(_0x20b2fd(0x1b0))/0xb;if(_0x2099cb===_0x3a6ff8)break;else _0x23f665['push'](_0x23f665['shift']());}catch(_0x2ba4ca){_0x23f665['push'](_0x23f665['shift']());}}}(a4_0x2e48,0x4326c));Object[a4_0x31e18a(0x197)](exports,a4_0x31e18a(0x19d),{'value':!![]}),exports[a4_0x31e18a(0x1a8)]=void 0x0;const validator_1=require(a4_0x31e18a(0x19a)),core_1=require(a4_0x31e18a(0x1a6)),action_1=require(a4_0x31e18a(0x1a3));function Api(_0x2ea1ff,_0x52eac1=a4_0x31e18a(0x1ab),_0x324b7d='/',_0x4705c3={'apimit':!![],'validate':{},'middleware':[],'middlewareIgnore':[]}){return(_0x3d12ad,_0x89561e,_0x2034e7)=>{const _0x1713a2=a4_0x35cc;var _0x4bff12,_0x85fd3f,_0x7fd357;!_0x4705c3[_0x1713a2(0x1a4)]&&(_0x4705c3[_0x1713a2(0x1a4)]=[]);!((_0x4bff12=_0x4705c3===null||_0x4705c3===void 0x0?void 0x0:_0x4705c3[_0x1713a2(0x1b8)])===null||_0x4bff12===void 0x0?void 0x0:_0x4bff12[_0x1713a2(0x19e)])&&(_0x4705c3[_0x1713a2(0x1b8)]={'validationOptions':{'allowUnknown':!![],'stripUnknown':!![],'dateFormat':_0x1713a2(0x1b5)}});if(((_0x85fd3f=_0x4705c3===null||_0x4705c3===void 0x0?void 0x0:_0x4705c3[_0x1713a2(0x1a4)])===null||_0x85fd3f===void 0x0?void 0x0:_0x85fd3f['length'])>0x0&&((_0x7fd357=_0x4705c3===null||_0x4705c3===void 0x0?void 0x0:_0x4705c3[_0x1713a2(0x1a9)])===null||_0x7fd357===void 0x0?void 0x0:_0x7fd357[_0x1713a2(0x1a1)])>0x0)for(let _0x43c5b9 in _0x4705c3['middleware']){_0x4705c3[_0x1713a2(0x1a9)][_0x1713a2(0x1b4)](_0x4705c3[_0x1713a2(0x1a4)][_0x43c5b9])!==-0x1&&(_0x4705c3[_0x1713a2(0x1a4)][_0x43c5b9]=null);}_0x4705c3[_0x1713a2(0x1b3)]=_0x2ea1ff,(0x0,validator_1[_0x1713a2(0x1b2)])(_0x4705c3['validate'])(_0x3d12ad,_0x89561e,_0x2034e7),(0x0,core_1['RequestMapping'])(Object[_0x1713a2(0x1ad)](_0x4705c3,{'path':_0x324b7d,'requestMethod':(_0x52eac1==_0x1713a2(0x1a2)?_0x1713a2(0x195):_0x52eac1)[_0x1713a2(0x1ac)]()}))(_0x3d12ad,_0x89561e,_0x2034e7),(0x0,core_1[_0x1713a2(0x1b1)])(action_1[_0x1713a2(0x19c)],{'path':_0x324b7d,'method':_0x89561e,'apimit':_0x4705c3[_0x1713a2(0x1b6)],'routerName':_0x4705c3[_0x1713a2(0x1b3)],'description':_0x4705c3[_0x1713a2(0x1a0)],'middleware':(_0x4705c3[_0x1713a2(0x1a4)]||[])[_0x1713a2(0x1a7)](_0x13b657=>!!_0x13b657),'requestMethod':(_0x52eac1==_0x1713a2(0x1a2)?_0x1713a2(0x195):_0x52eac1)['toLowerCase']()},_0x3d12ad),(0x0,core_1[_0x1713a2(0x1ae)])(action_1['ACTION_ROUTE_KEY'],{'path':_0x324b7d,'method':_0x89561e,'apimit':_0x4705c3[_0x1713a2(0x1b6)],'routerName':_0x4705c3[_0x1713a2(0x1b3)],'description':_0x4705c3[_0x1713a2(0x1a0)],'middleware':(_0x4705c3[_0x1713a2(0x1a4)]||[])[_0x1713a2(0x1a7)](_0x2ae7e2=>!!_0x2ae7e2),'requestMethod':(_0x52eac1==_0x1713a2(0x1a2)?_0x1713a2(0x195):_0x52eac1)[_0x1713a2(0x1ac)]()})(_0x3d12ad,_0x89561e,_0x2034e7);};}function a4_0x35cc(_0x422fff,_0x1a76b9){const _0x2e482c=a4_0x2e48();return a4_0x35cc=function(_0x35cc06,_0x23fd60){_0x35cc06=_0x35cc06-0x195;let _0x3ab522=_0x2e482c[_0x35cc06];return _0x3ab522;},a4_0x35cc(_0x422fff,_0x1a76b9);}exports[a4_0x31e18a(0x1a8)]=Api;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';function a5_0x1d0e(_0x116733,_0x7c787d){const _0xd86f8a=a5_0xd86f();return a5_0x1d0e=function(_0x1d0eb6,_0x3179f0){_0x1d0eb6=_0x1d0eb6-0x1c6;let _0x5020bb=_0xd86f8a[_0x1d0eb6];return _0x5020bb;},a5_0x1d0e(_0x116733,_0x7c787d);}function a5_0xd86f(){const _0x4cb398=['886044Cnhcgn','@midwayjs/core','app','5BKHdHj','filepath','apitest','Apitest','/apitest','REQUEST_OBJ_CTX_KEY','319560ueBcsK','203274UEqFsZ','1618362pcBSGf','1652652KsDZcP','RequestMapping','9663090DfxoEO','value','getAsync','../service/ApitestService','608NIMQnA','apidoc','isDevelopmentEnvironment','ApitestService','3871770oOQSjO','defineProperty','MidwayEnvironmentService'];a5_0xd86f=function(){return _0x4cb398;};return a5_0xd86f();}const a5_0x191b3f=a5_0x1d0e;(function(_0x2049bc,_0x13c7ff){const _0x1b1a45=a5_0x1d0e,_0x2e3343=_0x2049bc();while(!![]){try{const _0x34df67=parseInt(_0x1b1a45(0x1cd))/0x1+-parseInt(_0x1b1a45(0x1ce))/0x2+-parseInt(_0x1b1a45(0x1db))/0x3+-parseInt(_0x1b1a45(0x1cb))/0x4+-parseInt(_0x1b1a45(0x1de))/0x5*(-parseInt(_0x1b1a45(0x1d0))/0x6)+parseInt(_0x1b1a45(0x1d8))/0x7+parseInt(_0x1b1a45(0x1d4))/0x8*(-parseInt(_0x1b1a45(0x1cc))/0x9);if(_0x34df67===_0x13c7ff)break;else _0x2e3343['push'](_0x2e3343['shift']());}catch(_0x1c2de2){_0x2e3343['push'](_0x2e3343['shift']());}}}(a5_0xd86f,0xd2e8f));Object[a5_0x191b3f(0x1d9)](exports,'__esModule',{'value':!![]}),exports[a5_0x191b3f(0x1c8)]=void 0x0;const core_1=require(a5_0x191b3f(0x1dc)),ApitestService_1=require(a5_0x191b3f(0x1d3));function Apitest(_0x28ec6f=a5_0x191b3f(0x1c9),_0x396832){return(_0x1b77a5,_0x4cd8a4,_0x55f99e)=>{const _0xc1d869=a5_0x1d0e;return(0x0,core_1[_0xc1d869(0x1cf)])({'path':_0x28ec6f,'requestMethod':'get'})(_0x1b77a5,_0x4cd8a4,_0x55f99e),_0x55f99e[_0xc1d869(0x1d1)]=async function(..._0x5d53ad){const _0x1b6a19=_0xc1d869;var _0x2d6d34;const _0x46e460=(_0x2d6d34=this[core_1[_0x1b6a19(0x1ca)]])===null||_0x2d6d34===void 0x0?void 0x0:_0x2d6d34[_0x1b6a19(0x1dd)];if(_0x46e460&&_0x46e460['getConfig'](_0x1b6a19(0x1c7))){const _0x50b35f=await _0x46e460['getApplicationContext']()[_0x1b6a19(0x1d2)](ApitestService_1[_0x1b6a19(0x1d7)]),_0x5bba3d=await _0x46e460['getApplicationContext']()[_0x1b6a19(0x1d2)](core_1[_0x1b6a19(0x1da)]);return _0x5bba3d[_0x1b6a19(0x1d6)]()&&(_0x396832[_0x1b6a19(0x1c6)]=!![]),await _0x50b35f[_0x1b6a19(0x1d5)](_0x396832);}return'';},_0x55f99e;};}exports[a5_0x191b3f(0x1c8)]=Apitest;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';var a6_0x502444=a6_0x5147;function a6_0x5147(_0xc067d5,_0x1aa2c1){var _0x1d7b30=a6_0x1d7b();return a6_0x5147=function(_0x51478e,_0x364312){_0x51478e=_0x51478e-0x17d;var _0x3c9795=_0x1d7b30[_0x51478e];return _0x3c9795;},a6_0x5147(_0xc067d5,_0x1aa2c1);}(function(_0x20c28d,_0x37d75e){var _0x370e54=a6_0x5147,_0x4ded17=_0x20c28d();while(!![]){try{var _0x1e60af=parseInt(_0x370e54(0x19c))/0x1*(-parseInt(_0x370e54(0x193))/0x2)+parseInt(_0x370e54(0x192))/0x3*(-parseInt(_0x370e54(0x196))/0x4)+-parseInt(_0x370e54(0x18c))/0x5*(parseInt(_0x370e54(0x182))/0x6)+-parseInt(_0x370e54(0x17e))/0x7+-parseInt(_0x370e54(0x18b))/0x8+parseInt(_0x370e54(0x180))/0x9+-parseInt(_0x370e54(0x195))/0xa*(-parseInt(_0x370e54(0x185))/0xb);if(_0x1e60af===_0x37d75e)break;else _0x4ded17['push'](_0x4ded17['shift']());}catch(_0x593e28){_0x4ded17['push'](_0x4ded17['shift']());}}}(a6_0x1d7b,0x9fc93));var __decorate=this&&this['__decorate']||function(_0xe79edc,_0x554908,_0xe7dd9f,_0x1a0861){var _0x49d7d2=a6_0x5147,_0x30a51f=arguments['length'],_0x472edf=_0x30a51f<0x3?_0x554908:_0x1a0861===null?_0x1a0861=Object[_0x49d7d2(0x183)](_0x554908,_0xe7dd9f):_0x1a0861,_0x200159;if(typeof Reflect===_0x49d7d2(0x18d)&&typeof Reflect[_0x49d7d2(0x198)]===_0x49d7d2(0x17d))_0x472edf=Reflect['decorate'](_0xe79edc,_0x554908,_0xe7dd9f,_0x1a0861);else{for(var _0x228549=_0xe79edc[_0x49d7d2(0x197)]-0x1;_0x228549>=0x0;_0x228549--)if(_0x200159=_0xe79edc[_0x228549])_0x472edf=(_0x30a51f<0x3?_0x200159(_0x472edf):_0x30a51f>0x3?_0x200159(_0x554908,_0xe7dd9f,_0x472edf):_0x200159(_0x554908,_0xe7dd9f))||_0x472edf;}return _0x30a51f>0x3&&_0x472edf&&Object[_0x49d7d2(0x19b)](_0x554908,_0xe7dd9f,_0x472edf),_0x472edf;},__metadata=this&&this[a6_0x502444(0x191)]||function(_0x3590d1,_0x295a51){var _0x146c3c=a6_0x502444;if(typeof Reflect===_0x146c3c(0x18d)&&typeof Reflect[_0x146c3c(0x19a)]===_0x146c3c(0x17d))return Reflect[_0x146c3c(0x19a)](_0x3590d1,_0x295a51);};Object[a6_0x502444(0x19b)](exports,a6_0x502444(0x186),{'value':!![]}),exports[a6_0x502444(0x17f)]=void 0x0;class ApiError{}ApiError[a6_0x502444(0x184)]=0x3d7e31,ApiError['HEADERS_LACK']=0x3d7e32,ApiError[a6_0x502444(0x190)]=0x3d7e33,ApiError[a6_0x502444(0x189)]=0x3d7e34,ApiError[a6_0x502444(0x199)]=0x3d7e35,__decorate([AnnErrorMsg(a6_0x502444(0x18a)),__metadata(a6_0x502444(0x194),Object)],ApiError,a6_0x502444(0x184),void 0x0),__decorate([AnnErrorMsg(a6_0x502444(0x18e)),__metadata('design:type',Object)],ApiError,a6_0x502444(0x188),void 0x0),__decorate([AnnErrorMsg(a6_0x502444(0x181)),__metadata('design:type',Object)],ApiError,'HEADERS_DEVICE',void 0x0),__decorate([AnnErrorMsg(a6_0x502444(0x187)),__metadata(a6_0x502444(0x194),Object)],ApiError,a6_0x502444(0x189),void 0x0),__decorate([AnnErrorMsg(a6_0x502444(0x18f)),__metadata(a6_0x502444(0x194),Object)],ApiError,a6_0x502444(0x199),void 0x0),exports[a6_0x502444(0x17f)]=ApiError;function a6_0x1d7b(){var _0x1eef16=['9354nLxixU','getOwnPropertyDescriptor','TIMEOUT','319PQEUSB','__esModule','验证失败,请重新登录','HEADERS_LACK','HEADERS_CHECKCODE','网络繁忙,请稍后重试','3054920iCeaGi','2455zCJTYR','object','请求头信息不完整','signature验证失败','HEADERS_DEVICE','__metadata','633XOfokp','6BsOkks','design:type','900190KTxFLk','10012PAiqNZ','length','decorate','HEADERS_SIGNATURE','metadata','defineProperty','213338SsvmLw','function','2502759gsgLkp','ApiError','6452550XQjcNE','请使用正确的设备'];a6_0x1d7b=function(){return _0x1eef16;};return a6_0x1d7b();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a7_0xe4a427=a7_0x6878;(function(_0x3d8f70,_0x2c7cbd){const _0x409d29=a7_0x6878,_0x548ee1=_0x3d8f70();while(!![]){try{const _0x3c94ec=parseInt(_0x409d29(0x194))/0x1*(-parseInt(_0x409d29(0x18f))/0x2)+parseInt(_0x409d29(0x188))/0x3*(-parseInt(_0x409d29(0x18b))/0x4)+-parseInt(_0x409d29(0x198))/0x5*(parseInt(_0x409d29(0x195))/0x6)+-parseInt(_0x409d29(0x191))/0x7+parseInt(_0x409d29(0x18e))/0x8*(parseInt(_0x409d29(0x18d))/0x9)+parseInt(_0x409d29(0x199))/0xa+parseInt(_0x409d29(0x189))/0xb;if(_0x3c94ec===_0x2c7cbd)break;else _0x548ee1['push'](_0x548ee1['shift']());}catch(_0x2595ab){_0x548ee1['push'](_0x548ee1['shift']());}}}(a7_0x54fd,0x89b5d));function a7_0x54fd(){const _0x335f91=['13282QWPrys','2484cuveCy','../types/action','defineProperty','8070VHZdzj','9708050PyxUXT','3ZLxaxw','16454328eMSrSE','getClassMetadata','2420276eWpflo','getAppsConfig','2745711SZCjlT','16XTomEs','88bbGYds','get','4585539PlPgFl','APPSCONFIG_KEY','__esModule'];a7_0x54fd=function(){return _0x335f91;};return a7_0x54fd();}function a7_0x6878(_0x15c589,_0x4333c4){const _0x54fd3c=a7_0x54fd();return a7_0x6878=function(_0x68782a,_0x5429ca){_0x68782a=_0x68782a-0x188;let _0x3500d6=_0x54fd3c[_0x68782a];return _0x3500d6;},a7_0x6878(_0x15c589,_0x4333c4);}Object[a7_0xe4a427(0x197)](exports,a7_0xe4a427(0x193),{'value':!![]}),exports[a7_0xe4a427(0x18c)]=void 0x0;const core_1=require('@midwayjs/core'),action_1=require(a7_0xe4a427(0x196));function getAppsConfig(_0x576313){const _0x21cf4a=a7_0xe4a427,_0x223a01=(0x0,core_1[_0x21cf4a(0x18a)])(action_1[_0x21cf4a(0x192)],action_1['AppsConfigTmp'])||{};return _0x576313?lodash[_0x21cf4a(0x190)](_0x223a01,_0x576313):_0x223a01;}exports['getAppsConfig']=getAppsConfig;
|
package/dist/helper/getRoutes.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';function a8_0x187a(_0x42758f,_0x116095){const _0x28bb38=a8_0x28bb();return a8_0x187a=function(_0x187aa7,_0x2bd314){_0x187aa7=_0x187aa7-0x145;let _0x2589ba=_0x28bb38[_0x187aa7];return _0x2589ba;},a8_0x187a(_0x42758f,_0x116095);}const a8_0x43e050=a8_0x187a;(function(_0x12d448,_0x419e12){const _0x2558a6=a8_0x187a,_0x5402c8=_0x12d448();while(!![]){try{const _0x17160b=-parseInt(_0x2558a6(0x168))/0x1+-parseInt(_0x2558a6(0x14c))/0x2+parseInt(_0x2558a6(0x165))/0x3*(-parseInt(_0x2558a6(0x174))/0x4)+-parseInt(_0x2558a6(0x16c))/0x5*(parseInt(_0x2558a6(0x19b))/0x6)+parseInt(_0x2558a6(0x183))/0x7*(parseInt(_0x2558a6(0x151))/0x8)+parseInt(_0x2558a6(0x173))/0x9*(-parseInt(_0x2558a6(0x16e))/0xa)+parseInt(_0x2558a6(0x176))/0xb;if(_0x17160b===_0x419e12)break;else _0x5402c8['push'](_0x5402c8['shift']());}catch(_0x2a5c93){_0x5402c8['push'](_0x5402c8['shift']());}}}(a8_0x28bb,0x98d5d));Object[a8_0x43e050(0x15d)](exports,a8_0x43e050(0x148),{'value':!![]}),exports[a8_0x43e050(0x18c)]=void 0x0;function a8_0x28bb(){const _0x23e069=['split','summary','routerOptions','WEB_ROUTER_PARAM_KEY','file','FILESTREAM','HEADERS','976955kcvFTN','flags.description','description','FIELDS','query','getClassExtendedMetadata','tagName','get','filepath','getRoutes','allow','listModule','RULES_KEY','limit','push','title','body','items','function','startsWith','@anncic-api/validator','只允许:[','string','routes','150324vDqRHl','prefix','path','object','文件上传-','lodash','length','test','boolean','route','metadata','children','__esModule','ACTION_ROUTE_KEY','module','Object','1186678mRpLiD','flags.default','method','File','default','24fHUiNU','request','type','Number','describe','name','flags.label','propertyData','indexOf','routerName','ACTION_KEY','concat','defineProperty','filter','getMethodParamTypes','RouteParamTypes','pprefix','getClassMetadata','required','static/apitest','15VNgZhn','key','@midwayjs/core','25524eAcWZM','String','join','parameterIndex','205nvHgUO','header','1420rnmWbJ','iterator','find','/static/apitest','replace','25101XnLqpp','5484ESqjEV','noreq','24819168Dqyabe','rules','-array','args','max','requestMethod'];a8_0x28bb=function(){return _0x23e069;};return a8_0x28bb();}const lodash_1=require(a8_0x43e050(0x1a0)),validator_1=require(a8_0x43e050(0x197)),core_1=require('@midwayjs/core'),core_2=require(a8_0x43e050(0x167)),core_3=require(a8_0x43e050(0x167)),action_1=require('../types/action');function getRoutes(_0x3663e1={'prefix':'/','module':![]}){const _0x26cd68=a8_0x43e050;var _0xd78c0d,_0x27302d;const _0x3dbc4c=(0x0,core_3[_0x26cd68(0x18e)])(action_1[_0x26cd68(0x15b)]),_0x359bb5={},_0x793bf5=Array['isArray'](_0x3663e1['filter']||[])?_0x3663e1['filter']||[]:[_0x3663e1[_0x26cd68(0x15e)]];_0x29599a:for(const _0x44745f of _0x3dbc4c){let _0x10178a=(0x0,core_3[_0x26cd68(0x162)])(action_1[_0x26cd68(0x15b)],_0x44745f),_0x56fbf1=(0x0,core_3[_0x26cd68(0x162)])(action_1[_0x26cd68(0x149)],_0x44745f);if(_0x10178a&&_0x56fbf1){let _0x178dbf=_0x10178a['prefix'],_0x483d2f={};if(_0x3663e1['module']&&(0x0,lodash_1['get'])(_0x10178a,_0x26cd68(0x14a),![])!=_0x3663e1[_0x26cd68(0x14a)])continue _0x29599a;else{if(_0x3663e1[_0x26cd68(0x14a)]===![]&&!!(0x0,lodash_1[_0x26cd68(0x18a)])(_0x10178a,_0x26cd68(0x14a),null))continue _0x29599a;}if(_0x3663e1[_0x26cd68(0x19c)]&&!_0x178dbf['startsWith'](_0x3663e1[_0x26cd68(0x19c)]))continue _0x29599a;_0x178dbf!=='/'?(_0x483d2f[_0x26cd68(0x17d)]=(_0x10178a===null||_0x10178a===void 0x0?void 0x0:_0x10178a[_0x26cd68(0x17e)][_0x26cd68(0x189)])||(/^\//[_0x26cd68(0x1a2)](_0x178dbf)?_0x178dbf[_0x26cd68(0x17c)]('/')[0x1]:_0x178dbf),_0x483d2f['description']=(_0x10178a===null||_0x10178a===void 0x0?void 0x0:_0x10178a[_0x26cd68(0x17e)][_0x26cd68(0x185)])||_0x483d2f[_0x26cd68(0x17d)],_0x483d2f[_0x26cd68(0x19a)]=[]):(_0x483d2f[_0x26cd68(0x17d)]=(_0x10178a===null||_0x10178a===void 0x0?void 0x0:_0x10178a[_0x26cd68(0x17e)][_0x26cd68(0x189)])||'default',_0x483d2f[_0x26cd68(0x185)]=(_0x10178a===null||_0x10178a===void 0x0?void 0x0:_0x10178a[_0x26cd68(0x17e)]['description'])||'',_0x483d2f[_0x26cd68(0x19a)]=[]);_0x3663e1[_0x26cd68(0x18b)]&&(_0x483d2f[_0x26cd68(0x18b)]=_0x10178a===null||_0x10178a===void 0x0?void 0x0:_0x10178a[_0x26cd68(0x18b)]);(_0x10178a===null||_0x10178a===void 0x0?void 0x0:_0x10178a[_0x26cd68(0x161)])&&(_0x483d2f[_0x26cd68(0x19c)]=_0x10178a[_0x26cd68(0x161)]);(_0x10178a===null||_0x10178a===void 0x0?void 0x0:_0x10178a['module'])&&(_0x483d2f[_0x26cd68(0x14a)]=_0x10178a[_0x26cd68(0x14a)]);let _0x2a1b49=(0x0,core_3[_0x26cd68(0x162)])(core_2['INJECT_CUSTOM_PARAM'],_0x44745f)||{};if(typeof _0x56fbf1[Symbol[_0x26cd68(0x16f)]]===_0x26cd68(0x195))for(let _0x28ae99 of _0x56fbf1){let _0x38fd22={};_0x38fd22[_0x26cd68(0x14e)]=_0x28ae99[_0x26cd68(0x17b)],_0x38fd22[_0x26cd68(0x145)]=(_0x178dbf+_0x28ae99[_0x26cd68(0x19d)])[_0x26cd68(0x172)](/\/{1,}/,'/'),_0x38fd22['summary']=(_0x28ae99===null||_0x28ae99===void 0x0?void 0x0:_0x28ae99[_0x26cd68(0x15a)])||_0x483d2f[_0x26cd68(0x17d)]||'default',_0x38fd22[_0x26cd68(0x185)]=(_0x28ae99===null||_0x28ae99===void 0x0?void 0x0:_0x28ae99[_0x26cd68(0x185)])||'',_0x38fd22[_0x26cd68(0x152)]=[];if(!(0x0,lodash_1[_0x26cd68(0x196)])(_0x38fd22[_0x26cd68(0x145)],_0x26cd68(0x164))&&!(0x0,lodash_1[_0x26cd68(0x196)])(_0x38fd22[_0x26cd68(0x145)],_0x26cd68(0x171))&&_0x793bf5[_0x26cd68(0x159)](_0x38fd22[_0x26cd68(0x145)])===-0x1){if(!(_0x3663e1===null||_0x3663e1===void 0x0?void 0x0:_0x3663e1[_0x26cd68(0x175)])){let _0xd74d6f=(0x0,core_3[_0x26cd68(0x15f)])(new _0x44745f(),_0x28ae99['method']);for(const _0x96c0e0 in _0xd74d6f){let _0x429809=(_0xd78c0d=_0x2a1b49[_0x28ae99[_0x26cd68(0x14e)]])===null||_0xd78c0d===void 0x0?void 0x0:_0xd78c0d[_0x26cd68(0x170)](_0x5bb0b5=>_0x5bb0b5['parameterIndex']==_0x96c0e0&&_0x5bb0b5[_0x26cd68(0x166)]===core_2[_0x26cd68(0x17f)]&&(_0x5bb0b5===null||_0x5bb0b5===void 0x0?void 0x0:_0x5bb0b5[_0x26cd68(0x146)]));if(_0x429809===null||_0x429809===void 0x0?void 0x0:_0x429809[_0x26cd68(0x146)]){let _0x57a224=convertTypeToString(_0x429809['metadata']['type']||0x0);if([_0x26cd68(0x187),_0x26cd68(0x193)][_0x26cd68(0x159)](_0x57a224)!=-0x1&&_0x429809[_0x26cd68(0x146)]['propertyData']['indexOf'](':')==-0x1&&!_0x38fd22[_0x26cd68(0x152)][_0x26cd68(0x170)](_0x53f33f=>_0x53f33f[_0x26cd68(0x166)]==_0x429809[_0x26cd68(0x146)][_0x26cd68(0x158)]))_0x38fd22['request']['push']({'key':_0x429809[_0x26cd68(0x146)]['propertyData'],'title':_0x429809[_0x26cd68(0x146)][_0x26cd68(0x158)],'type':convertSchemaType(_0xd74d6f[_0x429809[_0x26cd68(0x16b)]][_0x26cd68(0x156)]),'required':![],'default':'','desc':''});else{if(_0x57a224=='file'){let _0x372456=((_0x27302d=_0x429809===null||_0x429809===void 0x0?void 0x0:_0x429809['metadata'])===null||_0x27302d===void 0x0?void 0x0:_0x27302d['propertyData'])||_0x26cd68(0x180);_0x372456[_0x26cd68(0x159)](':')==-0x1&&!_0x38fd22[_0x26cd68(0x152)]['find'](_0x4f594d=>_0x4f594d[_0x26cd68(0x166)]==_0x372456&&_0x4f594d[_0x26cd68(0x153)]==_0x26cd68(0x180))&&_0x38fd22[_0x26cd68(0x152)]['push']({'key':_0x372456,'title':_0x26cd68(0x19f)+_0x372456,'type':'file','required':!![],'default':'','desc':''});}}}else{const _0x281b6a=(0x0,core_3[_0x26cd68(0x188)])(validator_1[_0x26cd68(0x18f)],_0xd74d6f[_0x96c0e0]);_0x281b6a&&_0x38fd22[_0x26cd68(0x152)][_0x26cd68(0x191)](...getJoiRequest(_0x281b6a));}}}_0x483d2f[_0x26cd68(0x19a)][_0x26cd68(0x191)](_0x38fd22);}}if(_0x483d2f[_0x26cd68(0x19a)][_0x26cd68(0x1a1)]>0x0){let _0xeafa66=_0x359bb5[_0x178dbf];_0xeafa66?(_0xeafa66[_0x26cd68(0x17d)]!=_0x483d2f[_0x26cd68(0x17d)]&&(_0xeafa66['summary']=_0xeafa66[_0x26cd68(0x17d)]+','+_0x483d2f[_0x26cd68(0x17d)]),_0xeafa66[_0x26cd68(0x185)]!=_0x483d2f[_0x26cd68(0x185)]&&(_0xeafa66[_0x26cd68(0x185)]=_0xeafa66[_0x26cd68(0x185)]+','+_0x483d2f[_0x26cd68(0x185)]),_0xeafa66[_0x26cd68(0x19a)]=_0xeafa66[_0x26cd68(0x19a)][_0x26cd68(0x15c)](_0x483d2f[_0x26cd68(0x19a)]),_0x359bb5[_0x178dbf]=_0xeafa66):_0x359bb5[_0x178dbf]=_0x483d2f;}}}return _0x359bb5;}exports['getRoutes']=getRoutes;function getJoiRequest(_0x15f02b){const _0x3d8a77=a8_0x43e050,_0x1de5b6=[];for(let _0x1f9bee in _0x15f02b){const _0x4bf2b6={'title':'','key':'','type':'','description':'','rules':{},'children':[]},_0x4a4c49=typeof _0x15f02b[_0x1f9bee][_0x3d8a77(0x155)]==_0x3d8a77(0x195)?_0x15f02b[_0x1f9bee][_0x3d8a77(0x155)]():_0x15f02b[_0x1f9bee];_0x4bf2b6[_0x3d8a77(0x166)]=_0x1f9bee,_0x4bf2b6[_0x3d8a77(0x153)]=_0x4a4c49['type'],_0x4bf2b6[_0x3d8a77(0x192)]=(0x0,lodash_1[_0x3d8a77(0x18a)])(_0x4a4c49,_0x3d8a77(0x157),_0x1f9bee),_0x4bf2b6[_0x3d8a77(0x150)]=(0x0,lodash_1[_0x3d8a77(0x18a)])(_0x4a4c49,_0x3d8a77(0x14d),''),_0x4bf2b6['required']=(0x0,lodash_1['get'])(_0x4a4c49,'flags.presence','')==_0x3d8a77(0x163),_0x4bf2b6['description']=(0x0,lodash_1[_0x3d8a77(0x18a)])(_0x4a4c49,_0x3d8a77(0x184),'');if(_0x4a4c49[_0x3d8a77(0x153)]==_0x3d8a77(0x19e))_0x4bf2b6[_0x3d8a77(0x147)]=getJoiRequest(_0x4a4c49['keys']);else _0x4a4c49['type']=='array'&&_0x4a4c49[_0x3d8a77(0x194)]&&Array['isArray'](_0x4a4c49['items'])&&_0x4a4c49[_0x3d8a77(0x194)][0x0]&&console['log'](_0x1f9bee+_0x3d8a77(0x178),_0x4a4c49);_0x4a4c49[_0x3d8a77(0x18d)]&&Array['isArray'](_0x4a4c49[_0x3d8a77(0x18d)])&&_0x4a4c49['allow']['length']>0x0&&(_0x4bf2b6[_0x3d8a77(0x185)]=_0x3d8a77(0x198)+_0x4a4c49[_0x3d8a77(0x18d)][_0x3d8a77(0x16a)](',')+'];'+_0x4bf2b6[_0x3d8a77(0x185)]);if(_0x4bf2b6['key']&&_0x4bf2b6[_0x3d8a77(0x153)]){const _0x35ab78={};for(const _0x3cd4f7 of _0x4a4c49[_0x3d8a77(0x177)]||[]){if(_0x3cd4f7['name']==='min'&&_0x3cd4f7[_0x3d8a77(0x179)])_0x35ab78['min']=_0x3cd4f7[_0x3d8a77(0x179)]['limit'];else _0x3cd4f7[_0x3d8a77(0x156)]==='max'&&(_0x35ab78[_0x3d8a77(0x17a)]=_0x3cd4f7['args'][_0x3d8a77(0x190)]);}_0x4bf2b6[_0x3d8a77(0x177)]=_0x35ab78;}_0x4bf2b6[_0x3d8a77(0x166)]&&_0x4bf2b6[_0x3d8a77(0x192)]&&_0x1de5b6['push'](_0x4bf2b6);}return _0x1de5b6;}function convertSchemaType(_0x1e8afe){const _0x5079c4=a8_0x43e050;switch(_0x1e8afe){case _0x5079c4(0x14b):return _0x5079c4(0x19e);case'Boolean':return _0x5079c4(0x1a3);case _0x5079c4(0x154):return'number';case _0x5079c4(0x169):return _0x5079c4(0x199);case _0x5079c4(0x14f):return _0x5079c4(0x180);default:return _0x5079c4(0x199);}}function convertTypeToString(_0x21172d){const _0x570e85=a8_0x43e050;switch(_0x21172d){case core_1[_0x570e85(0x160)][_0x570e85(0x182)]:return'header';case core_1['RouteParamTypes']['QUERY']:return _0x570e85(0x187);case core_1[_0x570e85(0x160)]['PARAM']:return'path';case core_1['RouteParamTypes']['BODY']:return _0x570e85(0x193);case core_1[_0x570e85(0x160)][_0x570e85(0x186)]:case core_1['RouteParamTypes']['FILESSTREAM']:case core_1[_0x570e85(0x160)][_0x570e85(0x181)]:return _0x570e85(0x180);default:return _0x570e85(0x16d);}}
|
|
1
|
+
'use strict';const a8_0x40cd39=a8_0x40e3;(function(_0x4ffa61,_0x5732f1){const _0x266484=a8_0x40e3,_0x1ea212=_0x4ffa61();while(!![]){try{const _0x35f0be=-parseInt(_0x266484(0x1bc))/0x1*(-parseInt(_0x266484(0x1a4))/0x2)+parseInt(_0x266484(0x172))/0x3*(-parseInt(_0x266484(0x189))/0x4)+-parseInt(_0x266484(0x1a1))/0x5*(-parseInt(_0x266484(0x198))/0x6)+-parseInt(_0x266484(0x188))/0x7+parseInt(_0x266484(0x1af))/0x8*(parseInt(_0x266484(0x195))/0x9)+-parseInt(_0x266484(0x1c3))/0xa*(-parseInt(_0x266484(0x18f))/0xb)+parseInt(_0x266484(0x1be))/0xc*(-parseInt(_0x266484(0x1bb))/0xd);if(_0x35f0be===_0x5732f1)break;else _0x1ea212['push'](_0x1ea212['shift']());}catch(_0x36d11e){_0x1ea212['push'](_0x1ea212['shift']());}}}(a8_0x48d9,0xad592));Object[a8_0x40cd39(0x179)](exports,a8_0x40cd39(0x17a),{'value':!![]}),exports[a8_0x40cd39(0x18c)]=void 0x0;function a8_0x40e3(_0x16b558,_0x488e13){const _0x48d97e=a8_0x48d9();return a8_0x40e3=function(_0x40e361,_0x254c73){_0x40e361=_0x40e361-0x16c;let _0x2d4828=_0x48d97e[_0x40e361];return _0x2d4828;},a8_0x40e3(_0x16b558,_0x488e13);}const lodash_1=require('lodash'),validator_1=require(a8_0x40cd39(0x1aa)),core_1=require(a8_0x40cd39(0x193)),core_2=require(a8_0x40cd39(0x193)),core_3=require(a8_0x40cd39(0x193)),action_1=require('../types/action');function getRoutes(_0x429910={'prefix':'/','module':![]}){const _0x3ddd8b=a8_0x40cd39;var _0xe97122,_0x4acd1c;const _0x212f40=(0x0,core_3[_0x3ddd8b(0x18e)])(action_1[_0x3ddd8b(0x1b1)]),_0x2b6ca6={},_0x224c73=Array['isArray'](_0x429910[_0x3ddd8b(0x1c2)]||[])?_0x429910[_0x3ddd8b(0x1c2)]||[]:[_0x429910[_0x3ddd8b(0x1c2)]];_0x123f84:for(const _0x5d0ce7 of _0x212f40){let _0x4ee5f5=(0x0,core_3[_0x3ddd8b(0x19d)])(action_1[_0x3ddd8b(0x1b1)],_0x5d0ce7),_0x28f505=(0x0,core_3[_0x3ddd8b(0x19d)])(action_1[_0x3ddd8b(0x187)],_0x5d0ce7);if(_0x4ee5f5&&_0x28f505){let _0x26d0f9=_0x4ee5f5[_0x3ddd8b(0x1c6)],_0x4b9c3d={};if(_0x429910['module']&&(0x0,lodash_1[_0x3ddd8b(0x1cb)])(_0x4ee5f5,'module',![])!=_0x429910[_0x3ddd8b(0x1ca)])continue _0x123f84;else{if(_0x429910['module']===![]&&!!(0x0,lodash_1['get'])(_0x4ee5f5,_0x3ddd8b(0x1ca),null))continue _0x123f84;}if(_0x429910[_0x3ddd8b(0x1c6)]&&!_0x26d0f9[_0x3ddd8b(0x18a)](_0x429910[_0x3ddd8b(0x1c6)]))continue _0x123f84;_0x26d0f9!=='/'?(_0x4b9c3d[_0x3ddd8b(0x1a7)]=(_0x4ee5f5===null||_0x4ee5f5===void 0x0?void 0x0:_0x4ee5f5['routerOptions'][_0x3ddd8b(0x184)])||(/^\//[_0x3ddd8b(0x185)](_0x26d0f9)?_0x26d0f9[_0x3ddd8b(0x1a5)]('/')[0x1]:_0x26d0f9),_0x4b9c3d[_0x3ddd8b(0x18d)]=(_0x4ee5f5===null||_0x4ee5f5===void 0x0?void 0x0:_0x4ee5f5[_0x3ddd8b(0x1b2)][_0x3ddd8b(0x18d)])||_0x4b9c3d['summary'],_0x4b9c3d[_0x3ddd8b(0x181)]=[]):(_0x4b9c3d[_0x3ddd8b(0x1a7)]=(_0x4ee5f5===null||_0x4ee5f5===void 0x0?void 0x0:_0x4ee5f5['routerOptions']['tagName'])||'default',_0x4b9c3d[_0x3ddd8b(0x18d)]=(_0x4ee5f5===null||_0x4ee5f5===void 0x0?void 0x0:_0x4ee5f5['routerOptions']['description'])||'',_0x4b9c3d['routes']=[]);_0x429910['filepath']&&(_0x4b9c3d[_0x3ddd8b(0x19a)]=_0x4ee5f5===null||_0x4ee5f5===void 0x0?void 0x0:_0x4ee5f5[_0x3ddd8b(0x19a)]);(_0x4ee5f5===null||_0x4ee5f5===void 0x0?void 0x0:_0x4ee5f5[_0x3ddd8b(0x17f)])&&(_0x4b9c3d['prefix']=_0x4ee5f5[_0x3ddd8b(0x17f)]);(_0x4ee5f5===null||_0x4ee5f5===void 0x0?void 0x0:_0x4ee5f5[_0x3ddd8b(0x1ca)])&&(_0x4b9c3d[_0x3ddd8b(0x1ca)]=_0x4ee5f5[_0x3ddd8b(0x1ca)]);let _0x50e8fb=(0x0,core_3[_0x3ddd8b(0x19d)])(core_2[_0x3ddd8b(0x16d)],_0x5d0ce7)||{};if(typeof _0x28f505[Symbol[_0x3ddd8b(0x1c4)]]==='function')for(let _0x230307 of _0x28f505){let _0xae9637={};_0xae9637[_0x3ddd8b(0x1a3)]=_0x230307['requestMethod'],_0xae9637['route']=(_0x26d0f9+_0x230307[_0x3ddd8b(0x1ab)])[_0x3ddd8b(0x1bf)](/\/{1,}/,'/'),_0xae9637['summary']=(_0x230307===null||_0x230307===void 0x0?void 0x0:_0x230307[_0x3ddd8b(0x1b8)])||_0x4b9c3d[_0x3ddd8b(0x1a7)]||'default',_0xae9637[_0x3ddd8b(0x18d)]=(_0x230307===null||_0x230307===void 0x0?void 0x0:_0x230307['description'])||'',_0xae9637[_0x3ddd8b(0x1b7)]=[];if(!(0x0,lodash_1[_0x3ddd8b(0x18a)])(_0xae9637['route'],'static/apitest')&&!(0x0,lodash_1[_0x3ddd8b(0x18a)])(_0xae9637['route'],_0x3ddd8b(0x19e))&&_0x224c73[_0x3ddd8b(0x1c0)](_0xae9637['route'])===-0x1){if(!(_0x429910===null||_0x429910===void 0x0?void 0x0:_0x429910[_0x3ddd8b(0x19c)])){let _0x208e91=(0x0,core_3[_0x3ddd8b(0x16c)])(new _0x5d0ce7(),_0x230307[_0x3ddd8b(0x1a3)]);for(const _0x2464d1 in _0x208e91){let _0x1749b6=(_0xe97122=_0x50e8fb[_0x230307[_0x3ddd8b(0x1a3)]])===null||_0xe97122===void 0x0?void 0x0:_0xe97122['find'](_0x29b0bb=>_0x29b0bb['parameterIndex']==_0x2464d1&&_0x29b0bb[_0x3ddd8b(0x1ad)]===core_2[_0x3ddd8b(0x16e)]&&(_0x29b0bb===null||_0x29b0bb===void 0x0?void 0x0:_0x29b0bb[_0x3ddd8b(0x173)]));if(_0x1749b6===null||_0x1749b6===void 0x0?void 0x0:_0x1749b6[_0x3ddd8b(0x173)]){let _0x4f7948=convertTypeToString(_0x1749b6[_0x3ddd8b(0x173)][_0x3ddd8b(0x176)]||0x0);if([_0x3ddd8b(0x196),_0x3ddd8b(0x183)]['indexOf'](_0x4f7948)!=-0x1&&_0x1749b6['metadata'][_0x3ddd8b(0x17b)][_0x3ddd8b(0x1c0)](':')==-0x1&&!_0xae9637[_0x3ddd8b(0x1b7)]['find'](_0x4ea8f0=>_0x4ea8f0[_0x3ddd8b(0x1ad)]==_0x1749b6['metadata']['propertyData']))_0xae9637[_0x3ddd8b(0x1b7)][_0x3ddd8b(0x170)]({'key':_0x1749b6['metadata'][_0x3ddd8b(0x17b)],'title':_0x1749b6[_0x3ddd8b(0x173)]['propertyData'],'type':convertSchemaType(_0x208e91[_0x1749b6[_0x3ddd8b(0x199)]][_0x3ddd8b(0x1c9)]),'required':![],'default':'','desc':''});else{if(_0x4f7948==_0x3ddd8b(0x1b0)){let _0x5235af=((_0x4acd1c=_0x1749b6===null||_0x1749b6===void 0x0?void 0x0:_0x1749b6[_0x3ddd8b(0x173)])===null||_0x4acd1c===void 0x0?void 0x0:_0x4acd1c[_0x3ddd8b(0x17b)])||'file';_0x5235af[_0x3ddd8b(0x1c0)](':')==-0x1&&!_0xae9637['request'][_0x3ddd8b(0x1b4)](_0x271471=>_0x271471[_0x3ddd8b(0x1ad)]==_0x5235af&&_0x271471['type']=='file')&&_0xae9637[_0x3ddd8b(0x1b7)]['push']({'key':_0x5235af,'title':_0x3ddd8b(0x1a9)+_0x5235af,'type':'file','required':!![],'default':'','desc':''});}}}else{const _0x5603ca=(0x0,core_3[_0x3ddd8b(0x1c8)])(validator_1[_0x3ddd8b(0x1ba)],_0x208e91[_0x2464d1]);_0x5603ca&&_0xae9637[_0x3ddd8b(0x1b7)][_0x3ddd8b(0x170)](...getJoiRequest(_0x5603ca));}}}_0x4b9c3d[_0x3ddd8b(0x181)][_0x3ddd8b(0x170)](_0xae9637);}}if(_0x4b9c3d[_0x3ddd8b(0x181)][_0x3ddd8b(0x19f)]>0x0){let _0x343754=_0x2b6ca6[_0x26d0f9];_0x343754?(_0x343754[_0x3ddd8b(0x1a7)]!=_0x4b9c3d[_0x3ddd8b(0x1a7)]&&(_0x343754[_0x3ddd8b(0x1a7)]=_0x343754[_0x3ddd8b(0x1a7)]+','+_0x4b9c3d[_0x3ddd8b(0x1a7)]),_0x343754[_0x3ddd8b(0x18d)]!=_0x4b9c3d['description']&&(_0x343754['description']=_0x343754[_0x3ddd8b(0x18d)]+','+_0x4b9c3d['description']),_0x343754[_0x3ddd8b(0x181)]=_0x343754[_0x3ddd8b(0x181)]['concat'](_0x4b9c3d[_0x3ddd8b(0x181)]),_0x2b6ca6[_0x26d0f9]=_0x343754):_0x2b6ca6[_0x26d0f9]=_0x4b9c3d;}}}return _0x2b6ca6;}exports[a8_0x40cd39(0x18c)]=getRoutes;function a8_0x48d9(){const _0x82e039=['find','FILESTREAM','children','request','routerName','array','RULES_KEY','143RLkroa','856021NUomlu','min','112536ELGUjy','replace','indexOf','BODY','filter','230LwZWAV','iterator','number','prefix','PARAM','getClassExtendedMetadata','name','module','get','getMethodParamTypes','INJECT_CUSTOM_PARAM','WEB_ROUTER_PARAM_KEY','只允许:[','push','describe','1895217cMJanS','metadata','flags.description','args','type','header','keys','defineProperty','__esModule','propertyData','flags.label','default','title','pprefix','allow','routes','required','body','tagName','test','isArray','ACTION_ROUTE_KEY','4961859ufqBhB','4cGgLAn','startsWith','limit','getRoutes','description','listModule','238711aidNRJ','HEADERS','RouteParamTypes','flags.presence','@midwayjs/core','-array','117jLGdAr','query','max','112686LumRJK','parameterIndex','filepath','string','noreq','getClassMetadata','/static/apitest','length','boolean','55IGhQzW','object','method','2rpFTOg','split','Number','summary','String','文件上传-','@anncic-api/validator','path','items','key','Boolean','364328hkbmtI','file','ACTION_KEY','routerOptions','rules'];a8_0x48d9=function(){return _0x82e039;};return a8_0x48d9();}function getJoiRequest(_0x597441){const _0x1a36e8=a8_0x40cd39,_0x355a9c=[];for(let _0x58f938 in _0x597441){const _0x4df219={'title':'','key':'','type':'','description':'','rules':{},'children':[]},_0x3ec1d2=typeof _0x597441[_0x58f938][_0x1a36e8(0x171)]=='function'?_0x597441[_0x58f938][_0x1a36e8(0x171)]():_0x597441[_0x58f938];_0x4df219[_0x1a36e8(0x1ad)]=_0x58f938,_0x4df219[_0x1a36e8(0x176)]=_0x3ec1d2[_0x1a36e8(0x176)],_0x4df219['title']=(0x0,lodash_1['get'])(_0x3ec1d2,_0x1a36e8(0x17c),_0x58f938),_0x4df219[_0x1a36e8(0x17d)]=(0x0,lodash_1[_0x1a36e8(0x1cb)])(_0x3ec1d2,'flags.default',''),_0x4df219['required']=(0x0,lodash_1[_0x1a36e8(0x1cb)])(_0x3ec1d2,_0x1a36e8(0x192),'')==_0x1a36e8(0x182),_0x4df219[_0x1a36e8(0x18d)]=(0x0,lodash_1[_0x1a36e8(0x1cb)])(_0x3ec1d2,_0x1a36e8(0x174),'');if(_0x3ec1d2[_0x1a36e8(0x176)]==_0x1a36e8(0x1a2))_0x4df219[_0x1a36e8(0x1b6)]=getJoiRequest(_0x3ec1d2[_0x1a36e8(0x178)]);else _0x3ec1d2[_0x1a36e8(0x176)]==_0x1a36e8(0x1b9)&&_0x3ec1d2[_0x1a36e8(0x1ac)]&&Array[_0x1a36e8(0x186)](_0x3ec1d2[_0x1a36e8(0x1ac)])&&_0x3ec1d2[_0x1a36e8(0x1ac)][0x0]&&console['log'](_0x58f938+_0x1a36e8(0x194),_0x3ec1d2);_0x3ec1d2[_0x1a36e8(0x180)]&&Array[_0x1a36e8(0x186)](_0x3ec1d2[_0x1a36e8(0x180)])&&_0x3ec1d2[_0x1a36e8(0x180)][_0x1a36e8(0x19f)]>0x0&&(_0x4df219[_0x1a36e8(0x18d)]=_0x1a36e8(0x16f)+_0x3ec1d2['allow']['join'](',')+'];'+_0x4df219[_0x1a36e8(0x18d)]);if(_0x4df219[_0x1a36e8(0x1ad)]&&_0x4df219[_0x1a36e8(0x176)]){const _0x22dd98={};for(const _0x269e41 of _0x3ec1d2[_0x1a36e8(0x1b3)]||[]){if(_0x269e41[_0x1a36e8(0x1c9)]===_0x1a36e8(0x1bd)&&_0x269e41[_0x1a36e8(0x175)])_0x22dd98[_0x1a36e8(0x1bd)]=_0x269e41['args'][_0x1a36e8(0x18b)];else _0x269e41['name']===_0x1a36e8(0x197)&&(_0x22dd98[_0x1a36e8(0x197)]=_0x269e41[_0x1a36e8(0x175)][_0x1a36e8(0x18b)]);}_0x4df219[_0x1a36e8(0x1b3)]=_0x22dd98;}_0x4df219[_0x1a36e8(0x1ad)]&&_0x4df219[_0x1a36e8(0x17e)]&&_0x355a9c[_0x1a36e8(0x170)](_0x4df219);}return _0x355a9c;}function convertSchemaType(_0x21060e){const _0x45a35b=a8_0x40cd39;switch(_0x21060e){case'Object':return _0x45a35b(0x1a2);case _0x45a35b(0x1ae):return _0x45a35b(0x1a0);case _0x45a35b(0x1a6):return _0x45a35b(0x1c5);case _0x45a35b(0x1a8):return _0x45a35b(0x19b);case'File':return _0x45a35b(0x1b0);default:return _0x45a35b(0x19b);}}function convertTypeToString(_0x432f6a){const _0x526e0b=a8_0x40cd39;switch(_0x432f6a){case core_1[_0x526e0b(0x191)][_0x526e0b(0x190)]:return _0x526e0b(0x177);case core_1[_0x526e0b(0x191)]['QUERY']:return _0x526e0b(0x196);case core_1[_0x526e0b(0x191)][_0x526e0b(0x1c7)]:return _0x526e0b(0x1ab);case core_1[_0x526e0b(0x191)][_0x526e0b(0x1c1)]:return _0x526e0b(0x183);case core_1['RouteParamTypes']['FIELDS']:case core_1[_0x526e0b(0x191)]['FILESSTREAM']:case core_1[_0x526e0b(0x191)][_0x526e0b(0x1b5)]:return _0x526e0b(0x1b0);default:return _0x526e0b(0x177);}}
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';var a9_0x30284f=a9_0x1be5;(function(_0x16ad3f,_0xbb464b){var _0x3c5c84=a9_0x1be5,_0x1aaeaf=_0x16ad3f();while(!![]){try{var _0x3f257f=-parseInt(_0x3c5c84(0xd6))/0x1+-parseInt(_0x3c5c84(0xbc))/0x2*(parseInt(_0x3c5c84(0xe4))/0x3)+parseInt(_0x3c5c84(0xd7))/0x4+parseInt(_0x3c5c84(0xbf))/0x5+parseInt(_0x3c5c84(0xc9))/0x6*(-parseInt(_0x3c5c84(0xb7))/0x7)+parseInt(_0x3c5c84(0xc2))/0x8*(parseInt(_0x3c5c84(0xae))/0x9)+-parseInt(_0x3c5c84(0xb3))/0xa*(-parseInt(_0x3c5c84(0xbb))/0xb);if(_0x3f257f===_0xbb464b)break;else _0x1aaeaf['push'](_0x1aaeaf['shift']());}catch(_0x5a6677){_0x1aaeaf['push'](_0x1aaeaf['shift']());}}}(a9_0xe18f,0x89036));var __createBinding=this&&this[a9_0x30284f(0xca)]||(Object['create']?function(_0x2fe61d,_0x335409,_0x31271f,_0x5bbc0f){var _0x37a313=a9_0x30284f;if(_0x5bbc0f===undefined)_0x5bbc0f=_0x31271f;var _0xadc516=Object['getOwnPropertyDescriptor'](_0x335409,_0x31271f);(!_0xadc516||(_0x37a313(0xd5)in _0xadc516?!_0x335409[_0x37a313(0xda)]:_0xadc516['writable']||_0xadc516[_0x37a313(0xb9)]))&&(_0xadc516={'enumerable':!![],'get':function(){return _0x335409[_0x31271f];}}),Object[_0x37a313(0xe0)](_0x2fe61d,_0x5bbc0f,_0xadc516);}:function(_0x356fff,_0x56680c,_0x19ebf8,_0x461ef6){if(_0x461ef6===undefined)_0x461ef6=_0x19ebf8;_0x356fff[_0x461ef6]=_0x56680c[_0x19ebf8];}),__exportStar=this&&this['__exportStar']||function(_0x25f592,_0x1a98e7){var _0x575a05=a9_0x30284f;for(var _0x33c6c0 in _0x25f592)if(_0x33c6c0!==_0x575a05(0xe5)&&!Object[_0x575a05(0xd9)][_0x575a05(0xc1)][_0x575a05(0xd1)](_0x1a98e7,_0x33c6c0))__createBinding(_0x1a98e7,_0x25f592,_0x33c6c0);};Object[a9_0x30284f(0xe0)](exports,'__esModule',{'value':!![]}),exports[a9_0x30284f(0xd8)]=exports[a9_0x30284f(0xdb)]=exports[a9_0x30284f(0xd3)]=exports[a9_0x30284f(0xcc)]=exports[a9_0x30284f(0xb6)]=exports[a9_0x30284f(0xc0)]=exports['Config']=exports['App']=exports[a9_0x30284f(0xb4)]=exports['Headers']=exports['Query']=exports[a9_0x30284f(0xe3)]=exports['Body']=exports[a9_0x30284f(0xba)]=exports['Files']=exports[a9_0x30284f(0xde)]=exports[a9_0x30284f(0xc3)]=exports[a9_0x30284f(0xcb)]=exports[a9_0x30284f(0xd0)]=exports[a9_0x30284f(0xe1)]=exports[a9_0x30284f(0xac)]=exports['EventService']=exports[a9_0x30284f(0xce)]=exports[a9_0x30284f(0xc8)]=exports[a9_0x30284f(0xb2)]=exports['Apitest']=exports[a9_0x30284f(0xaf)]=exports['Api']=void 0x0;const getAppsConfig_1=require(a9_0x30284f(0xcf));Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xd8),{'enumerable':!![],'get':function(){var _0x11d34d=a9_0x30284f;return getAppsConfig_1[_0x11d34d(0xd8)];}}),__exportStar(require(a9_0x30284f(0xa9)),exports),__exportStar(require(a9_0x30284f(0xb1)),exports);var ActionApi_1=require(a9_0x30284f(0xb5));Object[a9_0x30284f(0xe0)](exports,'Api',{'enumerable':!![],'get':function(){var _0x47bd8d=a9_0x30284f;return ActionApi_1[_0x47bd8d(0xcd)];}});var Action_1=require('./decorator/Action');Object['defineProperty'](exports,a9_0x30284f(0xaf),{'enumerable':!![],'get':function(){var _0x24c6fd=a9_0x30284f;return Action_1[_0x24c6fd(0xaf)];}});var ActionApitest_1=require(a9_0x30284f(0xdf));Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xbd),{'enumerable':!![],'get':function(){var _0xf81fae=a9_0x30284f;return ActionApitest_1[_0xf81fae(0xbd)];}});var getRoutes_1=require('./helper/getRoutes');Object['defineProperty'](exports,a9_0x30284f(0xb2),{'enumerable':!![],'get':function(){var _0x4c3a5a=a9_0x30284f;return getRoutes_1[_0x4c3a5a(0xb2)];}});var ApiError_1=require(a9_0x30284f(0xaa));Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xc8),{'enumerable':!![],'get':function(){return ApiError_1['ApiError'];}});var cache_1=require(a9_0x30284f(0xd4));Object['defineProperty'](exports,a9_0x30284f(0xce),{'enumerable':!![],'get':function(){var _0x5db22d=a9_0x30284f;return cache_1[_0x5db22d(0xce)];}});var event_1=require(a9_0x30284f(0xd2));Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xc7),{'enumerable':!![],'get':function(){var _0x15aff5=a9_0x30284f;return event_1[_0x15aff5(0xc7)];}});var ApiService_1=require(a9_0x30284f(0xc4));Object['defineProperty'](exports,'ApiService',{'enumerable':!![],'get':function(){var _0x450eac=a9_0x30284f;return ApiService_1[_0x450eac(0xac)];}});var ExcelService_1=require(a9_0x30284f(0xa8));Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xe1),{'enumerable':!![],'get':function(){var _0x1878be=a9_0x30284f;return ExcelService_1[_0x1878be(0xe1)];}});function a9_0x1be5(_0x3a1894,_0x2de795){var _0xe18f88=a9_0xe18f();return a9_0x1be5=function(_0x1be5aa,_0x1e72e1){_0x1be5aa=_0x1be5aa-0xa8;var _0x5655dc=_0xe18f88[_0x1be5aa];return _0x5655dc;},a9_0x1be5(_0x3a1894,_0x2de795);}var validator_1=require(a9_0x30284f(0xad));Object[a9_0x30284f(0xe0)](exports,'ValidatorError',{'enumerable':!![],'get':function(){return validator_1['ValidatorError'];}}),Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xcb),{'enumerable':!![],'get':function(){return validator_1['ValidatorService'];}});var configuration_1=require(a9_0x30284f(0xdd));Object[a9_0x30284f(0xe0)](exports,'Configuration',{'enumerable':!![],'get':function(){var _0x45febb=a9_0x30284f;return configuration_1[_0x45febb(0xc6)];}});var core_1=require(a9_0x30284f(0xe2));Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xde),{'enumerable':!![],'get':function(){return core_1['File'];}}),Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xbe),{'enumerable':!![],'get':function(){return core_1['Files'];}}),Object['defineProperty'](exports,'Fields',{'enumerable':!![],'get':function(){return core_1['Fields'];}}),Object[a9_0x30284f(0xe0)](exports,'Body',{'enumerable':!![],'get':function(){var _0x341deb=a9_0x30284f;return core_1[_0x341deb(0xc5)];}}),Object['defineProperty'](exports,a9_0x30284f(0xe3),{'enumerable':!![],'get':function(){var _0x3dd666=a9_0x30284f;return core_1[_0x3dd666(0xe3)];}}),Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xab),{'enumerable':!![],'get':function(){return core_1['Query'];}}),Object['defineProperty'](exports,a9_0x30284f(0xb0),{'enumerable':!![],'get':function(){var _0x5ec491=a9_0x30284f;return core_1[_0x5ec491(0xb0)];}}),Object[a9_0x30284f(0xe0)](exports,'Init',{'enumerable':!![],'get':function(){return core_1['Init'];}});var core_2=require('@midwayjs/core');Object['defineProperty'](exports,a9_0x30284f(0xdc),{'enumerable':!![],'get':function(){return core_2['App'];}}),Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xb8),{'enumerable':!![],'get':function(){var _0x462226=a9_0x30284f;return core_2[_0x462226(0xb8)];}}),Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xc0),{'enumerable':!![],'get':function(){var _0x904cb=a9_0x30284f;return core_2[_0x904cb(0xc0)];}}),Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xb6),{'enumerable':!![],'get':function(){return core_2['Provide'];}}),Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xcc),{'enumerable':!![],'get':function(){var _0x57b69c=a9_0x30284f;return core_2[_0x57b69c(0xcc)];}}),Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xd3),{'enumerable':!![],'get':function(){var _0xe48f10=a9_0x30284f;return core_2[_0xe48f10(0xd3)];}}),Object[a9_0x30284f(0xe0)](exports,a9_0x30284f(0xdb),{'enumerable':!![],'get':function(){var _0x547895=a9_0x30284f;return core_2[_0x547895(0xdb)];}}),global[a9_0x30284f(0xd8)]=getAppsConfig_1[a9_0x30284f(0xd8)];function a9_0xe18f(){var _0x555aa6=['Apitest','Files','4667665rdAhrf','Logger','hasOwnProperty','8ePdlme','Configuration','./service/ApiService','Body','CustomConfiguration','EventService','ApiError','9942LpHVJK','__createBinding','ValidatorService','Inject','Api','CacheService','./helper/getAppsConfig','ValidatorError','call','@anncic-api/event','Scope','@anncic-api/cache','get','61092cQRVaG','484340neyLUc','getAppsConfig','prototype','__esModule','ScopeEnum','App','./configuration','File','./decorator/ActionApitest','defineProperty','ExcelService','@midwayjs/core','Param','553791Mzpvaq','default','./service/ExcelService','./types/common','./exception/ApiError','Query','ApiService','@anncic-api/validator','631539VbxMdg','Action','Headers','./service/ApitestService','getRoutes','250YLFNSR','Init','./decorator/ActionApi','Provide','2009WoJDgH','Config','configurable','Fields','475486wixinw','12kNVhvm'];a9_0xe18f=function(){return _0x555aa6;};return a9_0xe18f();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';var a10_0x528cf7=a10_0x331e;function a10_0x331e(_0x513e40,_0x20e359){var _0x467ae1=a10_0x467a();return a10_0x331e=function(_0x331ebe,_0x376005){_0x331ebe=_0x331ebe-0x18c;var _0x53a538=_0x467ae1[_0x331ebe];return _0x53a538;},a10_0x331e(_0x513e40,_0x20e359);}(function(_0x19f681,_0x37786c){var _0x5564ea=a10_0x331e,_0x1fa157=_0x19f681();while(!![]){try{var _0x51431f=parseInt(_0x5564ea(0x1b4))/0x1*(parseInt(_0x5564ea(0x195))/0x2)+-parseInt(_0x5564ea(0x18c))/0x3*(-parseInt(_0x5564ea(0x1a3))/0x4)+parseInt(_0x5564ea(0x1b7))/0x5+parseInt(_0x5564ea(0x1b1))/0x6+-parseInt(_0x5564ea(0x1b3))/0x7+parseInt(_0x5564ea(0x18d))/0x8+-parseInt(_0x5564ea(0x1bd))/0x9*(parseInt(_0x5564ea(0x1c0))/0xa);if(_0x51431f===_0x37786c)break;else _0x1fa157['push'](_0x1fa157['shift']());}catch(_0xcb18e2){_0x1fa157['push'](_0x1fa157['shift']());}}}(a10_0x467a,0x5aa05));function a10_0x467a(){var _0x466775=['5843760oQCmTu','HEADERS_CHECKCODE','map','now','device','join','decorate','HEADERS_DEVICE','56314jYgsoV','toLowerCase','getOwnPropertyDescriptor','push','checksign','entries','secret','__decorate','__metadata','token','Singleton','password','getcheck','HEADERS_SIGNATURE','4HQZvPh','signature','HEADERS_LACK','object','logintime','config','ApiError','prototype','getsign','defineProperty','devices','../exception/ApiError','crypto-js','ApiService','1233594dkxWCb','abs','2495465uInNMz','14XSyzFz','function','length','3545385ViIPUG','缺少头信息:','undefined','fromEntries','MD5','requesttime','16489485euCAnM','Provide','缺少头信息:signature','10qECATy','toString','sort','checkcode','1561563WfxNWG'];a10_0x467a=function(){return _0x466775;};return a10_0x467a();}var __decorate=this&&this[a10_0x528cf7(0x19c)]||function(_0x4aec44,_0xbc6fff,_0x471b83,_0x1b7380){var _0x1b9429=a10_0x528cf7,_0x5e17ec=arguments[_0x1b9429(0x1b6)],_0x120c70=_0x5e17ec<0x3?_0xbc6fff:_0x1b7380===null?_0x1b7380=Object[_0x1b9429(0x197)](_0xbc6fff,_0x471b83):_0x1b7380,_0x3aadf6;if(typeof Reflect===_0x1b9429(0x1a6)&&typeof Reflect[_0x1b9429(0x193)]===_0x1b9429(0x1b5))_0x120c70=Reflect['decorate'](_0x4aec44,_0xbc6fff,_0x471b83,_0x1b7380);else{for(var _0x12e376=_0x4aec44[_0x1b9429(0x1b6)]-0x1;_0x12e376>=0x0;_0x12e376--)if(_0x3aadf6=_0x4aec44[_0x12e376])_0x120c70=(_0x5e17ec<0x3?_0x3aadf6(_0x120c70):_0x5e17ec>0x3?_0x3aadf6(_0xbc6fff,_0x471b83,_0x120c70):_0x3aadf6(_0xbc6fff,_0x471b83))||_0x120c70;}return _0x5e17ec>0x3&&_0x120c70&&Object[_0x1b9429(0x1ac)](_0xbc6fff,_0x471b83,_0x120c70),_0x120c70;},__metadata=this&&this[a10_0x528cf7(0x19d)]||function(_0xf702ca,_0x118910){var _0x260b1e=a10_0x528cf7;if(typeof Reflect==='object'&&typeof Reflect['metadata']===_0x260b1e(0x1b5))return Reflect['metadata'](_0xf702ca,_0x118910);};Object[a10_0x528cf7(0x1ac)](exports,'__esModule',{'value':!![]}),exports['ApiService']=void 0x0;const crypto_js_1=require(a10_0x528cf7(0x1af)),core_1=require('@midwayjs/core'),ApiError_1=require(a10_0x528cf7(0x1ae));let ApiService=class ApiService{['password'](_0x47f965){var _0xeaa03e=a10_0x528cf7,_0x40c86d;return _0x47f965?(0x0,crypto_js_1[_0xeaa03e(0x1bb)])(_0x47f965+(0x0,crypto_js_1[_0xeaa03e(0x1bb)])((0x0,crypto_js_1[_0xeaa03e(0x1bb)])(_0x47f965)['toString']()+((_0x40c86d=this['config'])===null||_0x40c86d===void 0x0?void 0x0:_0x40c86d[_0xeaa03e(0x1a0)]))['toString']())[_0xeaa03e(0x1c1)]():'';}[a10_0x528cf7(0x1a1)](_0x4da372,_0x4d0c7a,_0x1b4973=Date[a10_0x528cf7(0x190)]()){return{'Token':_0x4da372,'Logintime':_0x1b4973,'Checkcode':this['checkcode'](_0x4da372,_0x4d0c7a,_0x1b4973)};}[a10_0x528cf7(0x1ab)](_0x325373={}){var _0x449ee9=a10_0x528cf7;const _0x20bec9=[],_0x25e2bc=Object[_0x449ee9(0x1ba)](Object['entries'](_0x325373)[_0x449ee9(0x18f)](_0x257809=>[_0x257809[0x0][_0x449ee9(0x196)](),_0x257809[0x1]]));for(let _0x39bbdb of[_0x449ee9(0x191),_0x449ee9(0x1bc),_0x449ee9(0x19e),'logintime',_0x449ee9(0x1c3)]){if(typeof _0x25e2bc[_0x39bbdb]==_0x449ee9(0x1b9))throw new AnnError(ApiError_1[_0x449ee9(0x1a9)][_0x449ee9(0x1a5)],{'message':_0x449ee9(0x1b8)+_0x39bbdb});_0x20bec9['push'](_0x39bbdb+'='+_0x25e2bc[_0x39bbdb]);}if(Math[_0x449ee9(0x1b2)](_0x25e2bc['requesttime'])-Date['now']()>this[_0x449ee9(0x1a8)]['timeout'])throw new AnnError(ApiError_1[_0x449ee9(0x1a9)]['TIMEOUT']);if(!this[_0x449ee9(0x1a8)]['devices'][_0x25e2bc[_0x449ee9(0x191)]]||!this[_0x449ee9(0x1a8)][_0x449ee9(0x1ad)][_0x25e2bc[_0x449ee9(0x191)]][_0x449ee9(0x19b)]||!this[_0x449ee9(0x1a8)][_0x449ee9(0x1ad)][_0x25e2bc['device']][_0x449ee9(0x1c3)])throw new AnnError(ApiError_1[_0x449ee9(0x1a9)][_0x449ee9(0x194)]);if(_0x25e2bc[_0x449ee9(0x19e)]&&_0x25e2bc[_0x449ee9(0x1c3)]!=this[_0x449ee9(0x1c3)](_0x25e2bc[_0x449ee9(0x19e)],_0x25e2bc[_0x449ee9(0x191)],_0x25e2bc[_0x449ee9(0x1a7)]))throw new AnnError(ApiError_1[_0x449ee9(0x1a9)][_0x449ee9(0x18e)]);return _0x20bec9[_0x449ee9(0x198)]('secret='+this[_0x449ee9(0x1a8)][_0x449ee9(0x1ad)][_0x25e2bc[_0x449ee9(0x191)]][_0x449ee9(0x19b)]),(0x0,crypto_js_1[_0x449ee9(0x1bb)])(_0x20bec9[_0x449ee9(0x1c2)]()[_0x449ee9(0x192)](''))[_0x449ee9(0x1c1)]();}['checkcode'](_0x5d4b63,_0x3b30ce,_0x3f4d28=Date[a10_0x528cf7(0x190)]()){var _0x1950b7=a10_0x528cf7,_0x3cc1c7,_0x23225b,_0x26a596;if(!((_0x3cc1c7=this['config'])===null||_0x3cc1c7===void 0x0?void 0x0:_0x3cc1c7['devices'][_0x3b30ce])||!((_0x26a596=(_0x23225b=this[_0x1950b7(0x1a8)])===null||_0x23225b===void 0x0?void 0x0:_0x23225b[_0x1950b7(0x1ad)][_0x3b30ce])===null||_0x26a596===void 0x0?void 0x0:_0x26a596[_0x1950b7(0x1c3)]))throw new AnnError(ApiError_1[_0x1950b7(0x1a9)][_0x1950b7(0x194)]);return(0x0,crypto_js_1['MD5'])(_0x5d4b63+(0x0,crypto_js_1['MD5'])(_0x3f4d28+this['config']['devices'][_0x3b30ce]['checkcode'])[_0x1950b7(0x1c1)]())[_0x1950b7(0x1c1)]();}[a10_0x528cf7(0x199)](_0x38dbba={}){var _0x374adf=a10_0x528cf7;const _0xec0cb1=Object[_0x374adf(0x1ba)](Object[_0x374adf(0x19a)](_0x38dbba)[_0x374adf(0x18f)](_0x4240cd=>[_0x4240cd[0x0][_0x374adf(0x196)](),_0x4240cd[0x1]]));if(!(_0xec0cb1===null||_0xec0cb1===void 0x0?void 0x0:_0xec0cb1[_0x374adf(0x1a4)]))throw new AnnError(ApiError_1[_0x374adf(0x1a9)][_0x374adf(0x1a5)],{'message':_0x374adf(0x1bf)});if((_0xec0cb1===null||_0xec0cb1===void 0x0?void 0x0:_0xec0cb1['signature'])!=this[_0x374adf(0x1ab)](_0xec0cb1))throw new AnnError(ApiError_1[_0x374adf(0x1a9)][_0x374adf(0x1a2)]);return!![];}};__decorate([(0x0,core_1['Config'])('anncicapi'),__metadata('design:type',Object)],ApiService[a10_0x528cf7(0x1aa)],'config',void 0x0),ApiService=__decorate([(0x0,core_1[a10_0x528cf7(0x1be)])(),(0x0,core_1['Scope'])(core_1['ScopeEnum'][a10_0x528cf7(0x19f)])],ApiService),exports[a10_0x528cf7(0x1b0)]=ApiService;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';
|
|
1
|
+
'use strict';function a11_0x348d(){const _0x2d4a64=['354cbMADX','stringify','getOwnPropertyDescriptor','apiteststatic','readFileSync','MidwayEnvironmentService','/apiteststatic/','design:type','109085RYYirJ','text/css;\x20charset=utf-8','url','../../public/index.html','public,\x20max-age=604800','9048704xfuKCn','.js','existsSync','/apiteststatic/*','/apitest-:module','80cRfHQM','substring','request','length','metadata','../../public/','Request','1DiChgW','@midwayjs/core','__apiList__','__devices__','summary','anncicapi','__esModule','Environment','isDevelopmentEnvironment','apidoc','ApitestStaticController','3083326zVXIwH','module','__param','path','prototype','apitesthtml','replace','4303521HmlYgt','Singleton','Scope','function','object','Config','getRoutes','1503990BdNfvc','set','Inject','devices','64544348KrYwdr','apitest','filepath','decorate','/index.html','description','cache-control','.css','design:returntype','../helper/getRoutes','ApitestService','defineProperty','270165aqjWJi','ScopeEnum','routes','config','Get','/apitest','ctx','extname','Controller','design:paramtypes','__metadata','content-type','join','utf-8','24ZCCnSR'];a11_0x348d=function(){return _0x2d4a64;};return a11_0x348d();}const a11_0xb63b6d=a11_0x21ae;(function(_0x4fecec,_0x4ac17a){const _0x2e504d=a11_0x21ae,_0x550dc7=_0x4fecec();while(!![]){try{const _0x124a15=-parseInt(_0x2e504d(0xe6))/0x1*(parseInt(_0x2e504d(0xf1))/0x2)+parseInt(_0x2e504d(0x10f))/0x3*(-parseInt(_0x2e504d(0xdf))/0x4)+-parseInt(_0x2e504d(0x126))/0x5*(-parseInt(_0x2e504d(0x11e))/0x6)+-parseInt(_0x2e504d(0x12b))/0x7+-parseInt(_0x2e504d(0x11d))/0x8*(parseInt(_0x2e504d(0xf8))/0x9)+-parseInt(_0x2e504d(0xff))/0xa+parseInt(_0x2e504d(0x103))/0xb;if(_0x124a15===_0x4ac17a)break;else _0x550dc7['push'](_0x550dc7['shift']());}catch(_0x26a74f){_0x550dc7['push'](_0x550dc7['shift']());}}}(a11_0x348d,0xe4282));function a11_0x21ae(_0x2873c9,_0x5193d7){const _0x348d3c=a11_0x348d();return a11_0x21ae=function(_0x21ae6e,_0x5149ce){_0x21ae6e=_0x21ae6e-0xdd;let _0x54cd60=_0x348d3c[_0x21ae6e];return _0x54cd60;},a11_0x21ae(_0x2873c9,_0x5193d7);}var __decorate=this&&this['__decorate']||function(_0x5f32e0,_0x1ff775,_0x224058,_0xcb3b39){const _0x4fa5f0=a11_0x21ae;var _0x48b073=arguments[_0x4fa5f0(0xe2)],_0xd57f93=_0x48b073<0x3?_0x1ff775:_0xcb3b39===null?_0xcb3b39=Object[_0x4fa5f0(0x120)](_0x1ff775,_0x224058):_0xcb3b39,_0x38aa59;if(typeof Reflect==='object'&&typeof Reflect['decorate']===_0x4fa5f0(0xfb))_0xd57f93=Reflect[_0x4fa5f0(0x106)](_0x5f32e0,_0x1ff775,_0x224058,_0xcb3b39);else{for(var _0x1019cf=_0x5f32e0[_0x4fa5f0(0xe2)]-0x1;_0x1019cf>=0x0;_0x1019cf--)if(_0x38aa59=_0x5f32e0[_0x1019cf])_0xd57f93=(_0x48b073<0x3?_0x38aa59(_0xd57f93):_0x48b073>0x3?_0x38aa59(_0x1ff775,_0x224058,_0xd57f93):_0x38aa59(_0x1ff775,_0x224058))||_0xd57f93;}return _0x48b073>0x3&&_0xd57f93&&Object[_0x4fa5f0(0x10e)](_0x1ff775,_0x224058,_0xd57f93),_0xd57f93;},__metadata=this&&this[a11_0xb63b6d(0x119)]||function(_0x1385fc,_0x120ba8){const _0xf975be=a11_0xb63b6d;if(typeof Reflect===_0xf975be(0xfc)&&typeof Reflect['metadata']==='function')return Reflect[_0xf975be(0xe3)](_0x1385fc,_0x120ba8);},__param=this&&this[a11_0xb63b6d(0xf3)]||function(_0x1743a2,_0x502880){return function(_0x176fea,_0x2d1f06){_0x502880(_0x176fea,_0x2d1f06,_0x1743a2);};};Object[a11_0xb63b6d(0x10e)](exports,a11_0xb63b6d(0xec),{'value':!![]}),exports[a11_0xb63b6d(0xf0)]=exports['ApitestService']=void 0x0;const path_1=require(a11_0xb63b6d(0xf4)),fs_1=require('fs'),core_1=require(a11_0xb63b6d(0xe7)),core_2=require(a11_0xb63b6d(0xe7)),core_3=require(a11_0xb63b6d(0xe7)),getRoutes_1=require(a11_0xb63b6d(0x10c));let ApitestService=class ApitestService{async[a11_0xb63b6d(0xef)](_0x372aec){const _0x4dba0c=a11_0xb63b6d,_0x1f45e8=(0x0,getRoutes_1[_0x4dba0c(0xfe)])(_0x372aec),_0x572f15=[];for(let _0x28babe in _0x1f45e8){for(let _0x25670d in _0x1f45e8[_0x28babe][_0x4dba0c(0x111)]){let _0x3e1a32=_0x1f45e8[_0x28babe][_0x4dba0c(0x111)][_0x25670d],_0x5e6aaa=[];for(let _0xf69313 in _0x3e1a32['request']){_0x5e6aaa['push'](_0x3e1a32[_0x4dba0c(0xe1)][_0xf69313]);}_0x572f15['push']({'title':_0x1f45e8[_0x28babe][_0x4dba0c(0xea)]+':'+_0x3e1a32[_0x4dba0c(0xea)],'prefix':_0x1f45e8[_0x28babe]['prefix'],'router':_0x3e1a32['route'],'method':_0x3e1a32['method'],'describe':_0x3e1a32[_0x4dba0c(0x108)]||'','filepath':_0x1f45e8[_0x28babe][_0x4dba0c(0x105)]||'','request':_0x5e6aaa});}}const _0x2be326=(0x0,path_1[_0x4dba0c(0x11b)])(__dirname,_0x4dba0c(0x129));return(0x0,fs_1[_0x4dba0c(0x122)])(_0x2be326,{'encoding':_0x4dba0c(0x11c)})[_0x4dba0c(0xf7)](/__res__/g,_0x4dba0c(0x124))['replace'](_0x4dba0c(0xe8),JSON[_0x4dba0c(0x11f)](_0x572f15))[_0x4dba0c(0xf7)](_0x4dba0c(0xe9),JSON['stringify'](this[_0x4dba0c(0x112)][_0x4dba0c(0x102)]));}};__decorate([(0x0,core_3[a11_0xb63b6d(0xfd)])(a11_0xb63b6d(0xeb)),__metadata(a11_0xb63b6d(0x125),Object)],ApitestService['prototype'],'config',void 0x0),ApitestService=__decorate([(0x0,core_2['Provide'])(a11_0xb63b6d(0x104)),(0x0,core_3[a11_0xb63b6d(0xfa)])(core_3[a11_0xb63b6d(0x110)][a11_0xb63b6d(0xf9)])],ApitestService),exports['ApitestService']=ApitestService;let ApitestStaticController=class ApitestStaticController{async[a11_0xb63b6d(0xf6)](){const _0x180a07=a11_0xb63b6d;if(this[_0x180a07(0x104)]){const _0x35818e={'module':![]};return this[_0x180a07(0xed)][_0x180a07(0xee)]()&&(_0x35818e[_0x180a07(0x105)]=!![]),await this[_0x180a07(0x10d)][_0x180a07(0xef)](_0x35818e);}return'';}async['apitestmodule'](_0x2bad8f){const _0x478d5b=a11_0xb63b6d;if(this[_0x478d5b(0x104)]){const _0x1a8d98={'module':_0x2bad8f};return this[_0x478d5b(0xed)]['isDevelopmentEnvironment']()&&(_0x1a8d98['filepath']=!![]),await this['ApitestService'][_0x478d5b(0xef)](_0x1a8d98);}return'';}async[a11_0xb63b6d(0x121)](){const _0xf11ffe=a11_0xb63b6d;if((0x0,path_1[_0xf11ffe(0x116)])(this[_0xf11ffe(0x115)][_0xf11ffe(0xe1)]['url'])){var _0x44fb27=(0x0,path_1['join'])(__dirname,_0xf11ffe(0xe4)+this[_0xf11ffe(0x115)][_0xf11ffe(0xe1)][_0xf11ffe(0x128)][_0xf11ffe(0xf7)]('/apiteststatic/','/'));if(_0x44fb27[_0xf11ffe(0xe0)](_0x44fb27[_0xf11ffe(0xe2)]-0xb)!=_0xf11ffe(0x107)){this[_0xf11ffe(0x115)][_0xf11ffe(0x100)](_0xf11ffe(0x109),_0xf11ffe(0x12a));if((0x0,path_1[_0xf11ffe(0x116)])(this['ctx'][_0xf11ffe(0xe1)][_0xf11ffe(0x128)])==_0xf11ffe(0x12c))this['ctx'][_0xf11ffe(0x100)](_0xf11ffe(0x11a),'application/javascript;\x20charset=utf-8');else(0x0,path_1['extname'])(this['ctx'][_0xf11ffe(0xe1)][_0xf11ffe(0x128)])==_0xf11ffe(0x10a)&&this[_0xf11ffe(0x115)][_0xf11ffe(0x100)]('content-type',_0xf11ffe(0x127));return(0x0,fs_1[_0xf11ffe(0x12d)])(_0x44fb27)&&(0x0,fs_1['readFileSync'])(_0x44fb27,{'encoding':'utf-8'});}}return'';}};__decorate([(0x0,core_3[a11_0xb63b6d(0x101)])(),__metadata(a11_0xb63b6d(0x125),Object)],ApitestStaticController['prototype'],a11_0xb63b6d(0x115),void 0x0),__decorate([(0x0,core_3[a11_0xb63b6d(0x101)])(),__metadata(a11_0xb63b6d(0x125),core_1[a11_0xb63b6d(0x123)])],ApitestStaticController['prototype'],a11_0xb63b6d(0xed),void 0x0),__decorate([(0x0,core_3[a11_0xb63b6d(0x101)])(),__metadata(a11_0xb63b6d(0x125),ApitestService)],ApitestStaticController['prototype'],a11_0xb63b6d(0x10d),void 0x0),__decorate([(0x0,core_3[a11_0xb63b6d(0xfd)])(a11_0xb63b6d(0x104)),__metadata(a11_0xb63b6d(0x125),Boolean)],ApitestStaticController[a11_0xb63b6d(0xf5)],'apitest',void 0x0),__decorate([(0x0,core_3['Config'])(a11_0xb63b6d(0xeb)),__metadata(a11_0xb63b6d(0x125),Object)],ApitestStaticController[a11_0xb63b6d(0xf5)],a11_0xb63b6d(0x112),void 0x0),__decorate([(0x0,core_2[a11_0xb63b6d(0x113)])(a11_0xb63b6d(0x114)),__metadata(a11_0xb63b6d(0x125),Function),__metadata(a11_0xb63b6d(0x118),[]),__metadata(a11_0xb63b6d(0x10b),Promise)],ApitestStaticController[a11_0xb63b6d(0xf5)],a11_0xb63b6d(0xf6),null),__decorate([(0x0,core_2['Get'])(a11_0xb63b6d(0xde)),__param(0x0,(0x0,core_2['Param'])(a11_0xb63b6d(0xf2))),__metadata(a11_0xb63b6d(0x125),Function),__metadata(a11_0xb63b6d(0x118),[String]),__metadata(a11_0xb63b6d(0x10b),Promise)],ApitestStaticController['prototype'],'apitestmodule',null),__decorate([(0x0,core_2['Get'])(a11_0xb63b6d(0xdd)),__metadata('design:type',Function),__metadata(a11_0xb63b6d(0x118),[]),__metadata(a11_0xb63b6d(0x10b),Promise)],ApitestStaticController[a11_0xb63b6d(0xf5)],'apiteststatic',null),ApitestStaticController=__decorate([(0x0,core_2[a11_0xb63b6d(0x117)])('/'),(0x0,core_3['Scope'])(core_3[a11_0xb63b6d(0x110)][a11_0xb63b6d(0xe5)])],ApitestStaticController),exports[a11_0xb63b6d(0xf0)]=ApitestStaticController;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a12_0x284e8d=a12_0x362e;(function(_0x61cab6,_0xb82121){const _0x240617=a12_0x362e,_0x2578e2=_0x61cab6();while(!![]){try{const _0x4259bd=parseInt(_0x240617(0x1da))/0x1*(parseInt(_0x240617(0x1c6))/0x2)+parseInt(_0x240617(0x1e6))/0x3+parseInt(_0x240617(0x1d7))/0x4*(-parseInt(_0x240617(0x1bd))/0x5)+parseInt(_0x240617(0x1df))/0x6+-parseInt(_0x240617(0x1db))/0x7+parseInt(_0x240617(0x1e3))/0x8*(parseInt(_0x240617(0x1d0))/0x9)+-parseInt(_0x240617(0x1f3))/0xa;if(_0x4259bd===_0xb82121)break;else _0x2578e2['push'](_0x2578e2['shift']());}catch(_0x1554c5){_0x2578e2['push'](_0x2578e2['shift']());}}}(a12_0x4480,0x83cc9));function a12_0x362e(_0x2de81b,_0x537362){const _0x44803e=a12_0x4480();return a12_0x362e=function(_0x362e5f,_0x20744c){_0x362e5f=_0x362e5f-0x1b9;let _0x70c88b=_0x44803e[_0x362e5f];return _0x70c88b;},a12_0x362e(_0x2de81b,_0x537362);}var __decorate=this&&this[a12_0x284e8d(0x1cb)]||function(_0x2b58de,_0x3e817b,_0x18592e,_0x2756f7){const _0x4f0d76=a12_0x284e8d;var _0x5a8ea1=arguments[_0x4f0d76(0x1f5)],_0x3a0f00=_0x5a8ea1<0x3?_0x3e817b:_0x2756f7===null?_0x2756f7=Object['getOwnPropertyDescriptor'](_0x3e817b,_0x18592e):_0x2756f7,_0x2e95cd;if(typeof Reflect===_0x4f0d76(0x1d6)&&typeof Reflect[_0x4f0d76(0x1c3)]===_0x4f0d76(0x1cc))_0x3a0f00=Reflect[_0x4f0d76(0x1c3)](_0x2b58de,_0x3e817b,_0x18592e,_0x2756f7);else{for(var _0x2a7790=_0x2b58de[_0x4f0d76(0x1f5)]-0x1;_0x2a7790>=0x0;_0x2a7790--)if(_0x2e95cd=_0x2b58de[_0x2a7790])_0x3a0f00=(_0x5a8ea1<0x3?_0x2e95cd(_0x3a0f00):_0x5a8ea1>0x3?_0x2e95cd(_0x3e817b,_0x18592e,_0x3a0f00):_0x2e95cd(_0x3e817b,_0x18592e))||_0x3a0f00;}return _0x5a8ea1>0x3&&_0x3a0f00&&Object['defineProperty'](_0x3e817b,_0x18592e,_0x3a0f00),_0x3a0f00;},__metadata=this&&this[a12_0x284e8d(0x1d9)]||function(_0x34860f,_0x1fc5d3){const _0x30034e=a12_0x284e8d;if(typeof Reflect===_0x30034e(0x1d6)&&typeof Reflect[_0x30034e(0x1e1)]===_0x30034e(0x1cc))return Reflect[_0x30034e(0x1e1)](_0x34860f,_0x1fc5d3);};function a12_0x4480(){const _0x3bf3ff=['app','key','20142yFiaCP','existsSync','eachCell','@midwayjs/core','endsWith','__decorate','function','writeFile','getAppDir','push','7311771fSXCTL','mkdirSync','ScopeEnum','random','header','isNumber','object','386980FAgKwh','replace','__metadata','89DBrapc','4463172hyxwKF','/public/xlsx','download','xlsx','383424vuTKDB','findRows','metadata','col','8KhOJbg','startsWith','koa-send','877023HLbncM','worksheets','log','handler','exceljs','model','prototype','Singleton','keys','columns','ExcelService','getCell','.xlsx','4038130DfTKOl','\x20is\x20read\x20fail','length','parse','Provide','defineProperty','Api\x20Excel\x20Error:\x20','substring','cellCount','Scope','value','__esModule','App','25NlHOfr','frozen','Sheet\x201','getWorksheet','Workbook','addRow','decorate'];a12_0x4480=function(){return _0x3bf3ff;};return a12_0x4480();}Object[a12_0x284e8d(0x1f8)](exports,a12_0x284e8d(0x1bb),{'value':!![]}),exports[a12_0x284e8d(0x1f0)]=void 0x0;const fs=require('fs'),exceljs=require(a12_0x284e8d(0x1ea)),koasend=require(a12_0x284e8d(0x1e5)),core_1=require(a12_0x284e8d(0x1c9));let ExcelService=class ExcelService{async[a12_0x284e8d(0x1f6)](_0x3de7db,_0x3ec5aa,_0x34da70=[0x0]){const _0x128b76=a12_0x284e8d;var _0x47dfad,_0x137c91;const _0x3720ab=new exceljs[(_0x128b76(0x1c1))](),_0x4a1a7c=[];let _0x366129=_0x3de7db[_0x128b76(0x1d8)](/(\\|\/)/g,'/')[_0x128b76(0x1d8)](/\/{2,}/g,'/');!(_0x366129===null||_0x366129===void 0x0?void 0x0:_0x366129['startsWith']('/'))&&(_0x366129=this['app']['getAppDir']()+'/'+_0x366129);try{await _0x3720ab[_0x128b76(0x1de)]['readFile'](_0x366129);}catch(_0x10d6a7){return console[_0x128b76(0x1e8)](_0x128b76(0x1f9)+_0x366129+_0x128b76(0x1f4)),_0x4a1a7c;}for(const _0x29543b of _0x34da70){const _0x5a0a9d=lodash[_0x128b76(0x1d5)](_0x29543b)?((_0x47dfad=_0x3720ab[_0x128b76(0x1e7)])===null||_0x47dfad===void 0x0?void 0x0:_0x47dfad[_0x29543b])||undefined:_0x3720ab[_0x128b76(0x1c0)](_0x29543b);if(_0x5a0a9d){var _0x2b8139=0x1;const _0x3c5f4c=_0x5a0a9d['getRow'](0x1),_0x463b2a=await new Promise(_0x1989dc=>{const _0x383ed5=_0x128b76,_0x458daa={};_0x3c5f4c[_0x383ed5(0x1c8)]((_0xf4abb8,_0x532a40)=>{const _0x5a4e47=_0x383ed5;for(const _0x39fb9c of _0x3ec5aa){if(_0xf4abb8[_0x5a4e47(0x1ba)]==_0x39fb9c[_0x5a4e47(0x1d4)])_0x2b8139=0x2,_0x458daa[_0x39fb9c['key']]={'header':_0xf4abb8[_0x5a4e47(0x1e2)],'handler':_0x39fb9c['handler']};else{if(!_0x458daa[_0x39fb9c[_0x5a4e47(0x1c5)]])try{const _0x527b51=_0x3c5f4c[_0x5a4e47(0x1f1)](_0x39fb9c[_0x5a4e47(0x1d4)]);_0x527b51&&(_0x458daa[_0x39fb9c[_0x5a4e47(0x1c5)]]={'header':_0x527b51[_0x5a4e47(0x1e2)],'handler':_0x39fb9c['handler']});}catch{}}}_0x3c5f4c[_0x5a4e47(0x1fb)]==_0x532a40&&_0x1989dc(_0x458daa);});});for(const _0x539640 of _0x5a0a9d[_0x128b76(0x1e0)](_0x2b8139,_0x5a0a9d['rowCount'])){const _0x27bdc9={};for(const _0x454c0c in _0x463b2a){if(_0x463b2a[_0x454c0c][_0x128b76(0x1d4)]){const _0x185349=_0x539640[_0x128b76(0x1f1)](_0x463b2a[_0x454c0c]['header']);typeof((_0x137c91=_0x463b2a[_0x454c0c])===null||_0x137c91===void 0x0?void 0x0:_0x137c91[_0x128b76(0x1e9)])=='function'?_0x27bdc9[_0x454c0c]=await _0x463b2a[_0x454c0c][_0x128b76(0x1e9)]((_0x185349===null||_0x185349===void 0x0?void 0x0:_0x185349['toString']())||'',_0x185349[_0x128b76(0x1eb)]):_0x27bdc9[_0x454c0c]=(_0x185349===null||_0x185349===void 0x0?void 0x0:_0x185349['toString']())||'';}}Object[_0x128b76(0x1ee)](_0x27bdc9)[_0x128b76(0x1f5)]>0x0&&_0x4a1a7c[_0x128b76(0x1cf)](_0x27bdc9);}}}return _0x4a1a7c;}async['export'](_0x296571,_0x35cf95,_0x5f1ee4,_0x55b5ab='public/xlsx'){const _0x5597b5=a12_0x284e8d;var _0x31a4d4,_0x41d207;const _0x31aa2d=new exceljs[(_0x5597b5(0x1c1))](),_0x19d4fb={},_0x213f2f=[],_0x1ecfe5=_0x31aa2d['addWorksheet'](_0x5597b5(0x1bf),{'views':[{'state':_0x5597b5(0x1be),'xSplit':0x1}]});for(const _0x1d1f66 in _0x35cf95){_0x19d4fb[_0x35cf95[_0x1d1f66]['key']]=_0x35cf95[_0x1d1f66][_0x5597b5(0x1d4)],_0x213f2f[_0x5597b5(0x1cf)]({'header':_0x35cf95[_0x1d1f66][_0x5597b5(0x1d4)],'key':(_0x31a4d4=_0x35cf95[_0x1d1f66])===null||_0x31a4d4===void 0x0?void 0x0:_0x31a4d4[_0x5597b5(0x1c5)][_0x5597b5(0x1d8)](/\./g,'_')});}_0x1ecfe5[_0x5597b5(0x1ef)]=_0x213f2f;for(const _0x14cce6 of _0x5f1ee4){const _0x176a33={};for(const _0x5ea5d3 in _0x35cf95){typeof((_0x41d207=_0x35cf95[_0x5ea5d3])===null||_0x41d207===void 0x0?void 0x0:_0x41d207[_0x5597b5(0x1e9)])==_0x5597b5(0x1cc)?_0x176a33[_0x35cf95[_0x5ea5d3]['key']['replace'](/\./g,'_')]=await _0x35cf95[_0x5ea5d3][_0x5597b5(0x1e9)](_0x14cce6):_0x176a33[_0x35cf95[_0x5ea5d3][_0x5597b5(0x1c5)][_0x5597b5(0x1d8)](/\./g,'_')]=lodash['get'](_0x14cce6,_0x35cf95[_0x5ea5d3][_0x5597b5(0x1c5)],'');}_0x1ecfe5[_0x5597b5(0x1c2)](_0x176a33);}let _0x281a49='';const _0x3d6106=_0x296571+'-'+lodash[_0x5597b5(0x1d3)](0x2710,0x1869f)+_0x5597b5(0x1f2);if(_0x55b5ab&&_0x55b5ab[_0x5597b5(0x1e4)]('/'))_0x281a49=''+_0x55b5ab;else _0x55b5ab&&!_0x55b5ab[_0x5597b5(0x1e4)]('/')&&!_0x55b5ab['startsWith']('\x5c')?_0x281a49=this[_0x5597b5(0x1c4)][_0x5597b5(0x1ce)]()+'/'+_0x55b5ab:_0x281a49=this[_0x5597b5(0x1c4)]['getAppDir']()+_0x5597b5(0x1dc);return(_0x281a49[_0x5597b5(0x1ca)]('/')||_0x281a49[_0x5597b5(0x1ca)]('\x5c'))&&(_0x281a49=_0x281a49[_0x5597b5(0x1fa)](0x0,_0x281a49[_0x5597b5(0x1f5)]-0x1)),_0x281a49=_0x281a49['replace'](/(\\|\/)/g,'/')[_0x5597b5(0x1d8)](/\/{2,}/g,'/'),!fs[_0x5597b5(0x1c7)](_0x281a49)&&fs[_0x5597b5(0x1d1)](_0x281a49,{'recursive':!![]}),await _0x31aa2d['xlsx'][_0x5597b5(0x1cd)]((_0x281a49+'/'+_0x3d6106)['replace'](/(\\|\/)/g,'/')[_0x5597b5(0x1d8)](/\/{2,}/g,'/')),{'filename':_0x3d6106,'filepath':(_0x281a49[_0x5597b5(0x1fa)]((''+this[_0x5597b5(0x1c4)][_0x5597b5(0x1ce)]())[_0x5597b5(0x1f5)])+'/'+_0x3d6106)['replace'](/(\\|\/)/g,'/')['replace'](/\/{2,}/g,'/')};}async[a12_0x284e8d(0x1dd)](_0xd0e367,_0x6254e1){return await koasend(_0xd0e367,''+_0x6254e1);}};__decorate([(0x0,core_1[a12_0x284e8d(0x1bc)])(),__metadata('design:type',Object)],ExcelService[a12_0x284e8d(0x1ec)],a12_0x284e8d(0x1c4),void 0x0),ExcelService=__decorate([(0x0,core_1[a12_0x284e8d(0x1f7)])(),(0x0,core_1[a12_0x284e8d(0x1b9)])(core_1[a12_0x284e8d(0x1d2)][a12_0x284e8d(0x1ed)])],ExcelService),exports['ExcelService']=ExcelService;
|
package/dist/types/action.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';var a13_0xfc766b=a13_0x47ee;(function(_0x595e28,_0x131d72){var _0x2a07cd=a13_0x47ee,_0x7d93e8=_0x595e28();while(!![]){try{var _0x5eb55a=-parseInt(_0x2a07cd(0x98))/0x1*(-parseInt(_0x2a07cd(0x90))/0x2)+parseInt(_0x2a07cd(0xa2))/0x3*(-parseInt(_0x2a07cd(0x95))/0x4)+-parseInt(_0x2a07cd(0x8e))/0x5*(parseInt(_0x2a07cd(0x9b))/0x6)+parseInt(_0x2a07cd(0x9c))/0x7*(parseInt(_0x2a07cd(0x97))/0x8)+-parseInt(_0x2a07cd(0x93))/0x9*(-parseInt(_0x2a07cd(0xa1))/0xa)+-parseInt(_0x2a07cd(0x94))/0xb+parseInt(_0x2a07cd(0x9d))/0xc*(parseInt(_0x2a07cd(0x9a))/0xd);if(_0x5eb55a===_0x131d72)break;else _0x7d93e8['push'](_0x7d93e8['shift']());}catch(_0x5d4709){_0x7d93e8['push'](_0x7d93e8['shift']());}}}(a13_0x4ef7,0xe6d66));function a13_0x4ef7(){var _0x4eb6b2=['5932810cEQiOv','7349946TTPLvb','934654kHCUpA','36QMgmve','anncic-api:action:route','ACTION_KEY','anncic-api:apps:config','40DDVpoV','30bROVRh','anncic-api:action','5TxgWLc','defineProperty','1226858aTzyZi','AppsConfigTmp','__esModule','2709738NeEYUW','2230778JFjuRt','378836OvPNPy','APPSCONFIG_KEY','8vNVjst','1btiZQp','ACTION_ROUTE_KEY'];a13_0x4ef7=function(){return _0x4eb6b2;};return a13_0x4ef7();}function a13_0x47ee(_0x1a13c6,_0x3be2bb){var _0x4ef737=a13_0x4ef7();return a13_0x47ee=function(_0x47ee6b,_0x149e04){_0x47ee6b=_0x47ee6b-0x8d;var _0xab0fac=_0x4ef737[_0x47ee6b];return _0xab0fac;},a13_0x47ee(_0x1a13c6,_0x3be2bb);}Object[a13_0xfc766b(0x8f)](exports,a13_0xfc766b(0x92),{'value':!![]}),exports[a13_0xfc766b(0x91)]=exports['APPSCONFIG_KEY']=exports[a13_0xfc766b(0x99)]=exports[a13_0xfc766b(0x9f)]=void 0x0,exports['ACTION_KEY']=a13_0xfc766b(0x8d),exports[a13_0xfc766b(0x99)]=a13_0xfc766b(0x9e),exports[a13_0xfc766b(0x96)]=a13_0xfc766b(0xa0);class AppsConfigTmp{}exports[a13_0xfc766b(0x91)]=AppsConfigTmp;
|
package/dist/types/common.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';function a14_0x4230(_0x512832,_0x56638a){var _0x5cb9e6=a14_0x5cb9();return a14_0x4230=function(_0x4230f4,_0x4d6eea){_0x4230f4=_0x4230f4-0xb5;var _0x21b88b=_0x5cb9e6[_0x4230f4];return _0x21b88b;},a14_0x4230(_0x512832,_0x56638a);}function a14_0x5cb9(){var _0x545944=['min','第一页为1,第二页为2','length','getOwnPropertyDescriptor','460iipJPC','__metadata','_size','分页数量','__decorate','prototype','@anncic-api/validator','__esModule','1404150FfJRvO','metadata','RuleType','decorate','982791IATKfI','PageDTO','Rule','8EMKsoi','1548120XRVdEs','defineProperty','2163SvYFXR','design:type','function','1778702KzrExC','trim','5273110AqWQDo','valid','35992QRclDi','integer','object','number','1076097hHnveX','string'];a14_0x5cb9=function(){return _0x545944;};return a14_0x5cb9();}var a14_0x3b7415=a14_0x4230;(function(_0x2b23fd,_0x4d68b9){var _0x2fe5f0=a14_0x4230,_0x19d7f0=_0x2b23fd();while(!![]){try{var _0xbefad8=-parseInt(_0x2fe5f0(0xb9))/0x1+-parseInt(_0x2fe5f0(0xc6))/0x2+parseInt(_0x2fe5f0(0xce))/0x3*(parseInt(_0x2fe5f0(0xc0))/0x4)+-parseInt(_0x2fe5f0(0xc8))/0x5+-parseInt(_0x2fe5f0(0xc1))/0x6+-parseInt(_0x2fe5f0(0xc3))/0x7*(parseInt(_0x2fe5f0(0xca))/0x8)+-parseInt(_0x2fe5f0(0xbd))/0x9*(-parseInt(_0x2fe5f0(0xd4))/0xa);if(_0xbefad8===_0x4d68b9)break;else _0x19d7f0['push'](_0x19d7f0['shift']());}catch(_0x112de1){_0x19d7f0['push'](_0x19d7f0['shift']());}}}(a14_0x5cb9,0xb5b1a));var __decorate=this&&this[a14_0x3b7415(0xb5)]||function(_0x296e48,_0x56914f,_0x14c5a7,_0xe3fc0){var _0x226f0f=a14_0x3b7415,_0x3eff08=arguments['length'],_0x3fbae9=_0x3eff08<0x3?_0x56914f:_0xe3fc0===null?_0xe3fc0=Object[_0x226f0f(0xd3)](_0x56914f,_0x14c5a7):_0xe3fc0,_0x243fa4;if(typeof Reflect===_0x226f0f(0xcc)&&typeof Reflect[_0x226f0f(0xbc)]===_0x226f0f(0xc5))_0x3fbae9=Reflect[_0x226f0f(0xbc)](_0x296e48,_0x56914f,_0x14c5a7,_0xe3fc0);else{for(var _0x298092=_0x296e48[_0x226f0f(0xd2)]-0x1;_0x298092>=0x0;_0x298092--)if(_0x243fa4=_0x296e48[_0x298092])_0x3fbae9=(_0x3eff08<0x3?_0x243fa4(_0x3fbae9):_0x3eff08>0x3?_0x243fa4(_0x56914f,_0x14c5a7,_0x3fbae9):_0x243fa4(_0x56914f,_0x14c5a7))||_0x3fbae9;}return _0x3eff08>0x3&&_0x3fbae9&&Object['defineProperty'](_0x56914f,_0x14c5a7,_0x3fbae9),_0x3fbae9;},__metadata=this&&this[a14_0x3b7415(0xd5)]||function(_0x5a7621,_0x4d5582){var _0x181346=a14_0x3b7415;if(typeof Reflect==='object'&&typeof Reflect[_0x181346(0xba)]==='function')return Reflect[_0x181346(0xba)](_0x5a7621,_0x4d5582);};Object[a14_0x3b7415(0xc2)](exports,a14_0x3b7415(0xb8),{'value':!![]}),exports[a14_0x3b7415(0xbe)]=void 0x0;const validator_1=require(a14_0x3b7415(0xb7));class PageDTO{}__decorate([(0x0,validator_1[a14_0x3b7415(0xbf)])('分页',validator_1[a14_0x3b7415(0xbb)][a14_0x3b7415(0xcd)]()[a14_0x3b7415(0xcb)]()[a14_0x3b7415(0xd0)](0x1),a14_0x3b7415(0xd1)),__metadata('design:type',Number)],PageDTO[a14_0x3b7415(0xb6)],'_page',void 0x0),__decorate([(0x0,validator_1['Rule'])(a14_0x3b7415(0xd7),validator_1['RuleType']['number']()[a14_0x3b7415(0xcb)]()['min'](0x1)),__metadata(a14_0x3b7415(0xc4),Number)],PageDTO[a14_0x3b7415(0xb6)],a14_0x3b7415(0xd6),void 0x0),__decorate([(0x0,validator_1['Rule'])('排序方式',validator_1['RuleType'][a14_0x3b7415(0xcf)]()[a14_0x3b7415(0xc7)]()),__metadata(a14_0x3b7415(0xc4),String)],PageDTO[a14_0x3b7415(0xb6)],'_order',void 0x0),__decorate([(0x0,validator_1[a14_0x3b7415(0xbf)])('是否倒序',validator_1[a14_0x3b7415(0xbb)][a14_0x3b7415(0xcd)]()['integer']()[a14_0x3b7415(0xc9)](0x0,0x1),'1:是;0:否'),__metadata('design:type',Number)],PageDTO[a14_0x3b7415(0xb6)],'_isreverse',void 0x0),exports[a14_0x3b7415(0xbe)]=PageDTO;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "anncic-api",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.4",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"typings": "index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -17,17 +17,17 @@
|
|
|
17
17
|
"build": "tsc && javascript-obfuscator ./dist --output ./dist --config obfuscator.json"
|
|
18
18
|
},
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"@anncic-api/cache": "^1.3.
|
|
21
|
-
"@anncic-api/core": "^1.3.
|
|
22
|
-
"@anncic-api/event": "^1.3.
|
|
23
|
-
"@anncic-api/typeorm": "^1.3.
|
|
24
|
-
"@anncic-api/validator": "^1.3.
|
|
20
|
+
"@anncic-api/cache": "^1.3.4",
|
|
21
|
+
"@anncic-api/core": "^1.3.4",
|
|
22
|
+
"@anncic-api/event": "^1.3.4",
|
|
23
|
+
"@anncic-api/typeorm": "^1.3.4",
|
|
24
|
+
"@anncic-api/validator": "^1.3.4",
|
|
25
25
|
"@midwayjs/cross-domain": "^3.7.1",
|
|
26
26
|
"@midwayjs/i18n": "^3.7.1",
|
|
27
27
|
"@midwayjs/koa": "^3.7.1",
|
|
28
28
|
"@midwayjs/static-file": "^3.7.1",
|
|
29
29
|
"@midwayjs/upload": "^3.7.1",
|
|
30
|
-
"anncic-apihelper": "^1.3.
|
|
30
|
+
"anncic-apihelper": "^1.3.4",
|
|
31
31
|
"exceljs": "^4.3.0",
|
|
32
32
|
"koa-send": "^5.0.1",
|
|
33
33
|
"urllib": "^3.3.0"
|
|
@@ -37,5 +37,5 @@
|
|
|
37
37
|
"javascript-obfuscator": "2.19.0",
|
|
38
38
|
"typescript": "^4.8.4"
|
|
39
39
|
},
|
|
40
|
-
"gitHead": "
|
|
40
|
+
"gitHead": "612827d5d03f34f9a9339a6e8646070d74ad3c22"
|
|
41
41
|
}
|