@anncic-api/validator 3.7.2 → 3.7.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/configuration.js +1 -1
- package/dist/decorator/Rule.js +1 -1
- package/dist/decorator/Validator.js +1 -1
- package/dist/exception/ValidatorError.js +1 -1
- package/dist/helper/dtoHelper.js +1 -1
- package/dist/helper/getSchema.js +1 -1
- package/dist/index.js +1 -1
- package/dist/interface.js +1 -1
- package/dist/service/ValidatorService.js +1 -1
- package/package.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a0_0x49f364=a0_0x4797;(function(_0x54d344,_0x406e37){const _0x550eb8=a0_0x4797,_0x4f34d2=_0x54d344();while(!![]){try{const _0x13d98f=-parseInt(_0x550eb8(0x7e))/0x1*(-parseInt(_0x550eb8(0x84))/0x2)+-parseInt(_0x550eb8(0x89))/0x3+parseInt(_0x550eb8(0x85))/0x4+-parseInt(_0x550eb8(0x8e))/0x5*(-parseInt(_0x550eb8(0x7d))/0x6)+-parseInt(_0x550eb8(0x7f))/0x7*(-parseInt(_0x550eb8(0x87))/0x8)+parseInt(_0x550eb8(0x82))/0x9+-parseInt(_0x550eb8(0x88))/0xa;if(_0x13d98f===_0x406e37)break;else _0x4f34d2['push'](_0x4f34d2['shift']());}catch(_0x27b094){_0x4f34d2['push'](_0x4f34d2['shift']());}}}(a0_0x44e7,0xad4b7));const a0_0x365510=(function(){let _0x4930de=!![];return function(_0x26d771,_0xb307ce){const _0x534dba=_0x4930de?function(){const _0x255a4b=a0_0x4797;if(_0xb307ce){const _0x5bfada=_0xb307ce[_0x255a4b(0x81)](_0x26d771,arguments);return _0xb307ce=null,_0x5bfada;}}:function(){};return _0x4930de=![],_0x534dba;};}()),a0_0x3992a7=a0_0x365510(this,function(){const _0x1fb57e=a0_0x4797;return a0_0x3992a7[_0x1fb57e(0x86)]()['search'](_0x1fb57e(0x8d))[_0x1fb57e(0x86)]()[_0x1fb57e(0x8c)](a0_0x3992a7)['search'](_0x1fb57e(0x8d));});function a0_0x4797(_0x54d8c3,_0x3ebe24){const _0x3a219b=a0_0x44e7();return a0_0x4797=function(_0x3992a7,_0x365510){_0x3992a7=_0x3992a7-0x7c;let _0x44e7c3=_0x3a219b[_0x3992a7];return _0x44e7c3;},a0_0x4797(_0x54d8c3,_0x3ebe24);}a0_0x3992a7();function a0_0x44e7(){const _0x4d4226=['2773940YnSztA','../../locales/zh_CN.json','6gbxOnS','9675SVgDUL','129171LDSzCN','string','apply','10757151cPVwcf','defineProperty','278CSlcAh','1122592krSpbl','toString','104tOkMzF','19749590izAjQc','2791845GufaWV','../exception/ValidatorError','ValidatorError','constructor','(((.+)+)+)+$'];a0_0x44e7=function(){return _0x4d4226;};return a0_0x44e7();}'use strict';Object[a0_0x49f364(0x83)](exports,'__esModule',{'value':!![]});const ValidatorError_1=require(a0_0x49f364(0x8a));exports['default']={'validator':{'errorStatus':ValidatorError_1[a0_0x49f364(0x8b)]['PARAMS'],'validationOptions':{'allowUnknown':!![],'stripUnknown':!![],'dateFormat':a0_0x49f364(0x80)}},'i18n':{'localeTable':{'en_US':{'validator':require('../../locales/en_US.json')},'zh_CN':{'validator':require(a0_0x49f364(0x7c))}}}};
|
package/dist/configuration.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a1_0x21b808=a1_0x3380;(function(_0x3928a2,_0x5e3fd9){const _0x3a52a=a1_0x3380,_0xddde5f=_0x3928a2();while(!![]){try{const _0xc46fd9=parseInt(_0x3a52a(0x182))/0x1*(parseInt(_0x3a52a(0x16d))/0x2)+parseInt(_0x3a52a(0x172))/0x3+parseInt(_0x3a52a(0x167))/0x4+parseInt(_0x3a52a(0x176))/0x5*(-parseInt(_0x3a52a(0x14e))/0x6)+parseInt(_0x3a52a(0x149))/0x7*(-parseInt(_0x3a52a(0x17f))/0x8)+-parseInt(_0x3a52a(0x157))/0x9*(-parseInt(_0x3a52a(0x177))/0xa)+-parseInt(_0x3a52a(0x14b))/0xb;if(_0xc46fd9===_0x5e3fd9)break;else _0xddde5f['push'](_0xddde5f['shift']());}catch(_0x15133f){_0xddde5f['push'](_0xddde5f['shift']());}}}(a1_0x5113,0xafe10));function a1_0x3380(_0x41db69,_0xce31b9){const _0x56d739=a1_0x5113();return a1_0x3380=function(_0x5133d3,_0x4815a7){_0x5133d3=_0x5133d3-0x148;let _0x511385=_0x56d739[_0x5133d3];return _0x511385;},a1_0x3380(_0x41db69,_0xce31b9);}function a1_0x5113(){const _0x4f2ede=['getMethodParamTypes','./config/config.default','decorate','ValidatorService','8GJdGaZ','propertyName','methodName','257539CIQbgG','CustomConfiguration','4877369QlsoWl','Inject','6435946BKHpAZ','bound\x20dispatch','object','12cAXUKP','getAttr','@midwayjs/i18n','MidwayDecoratorService','methodArgs','body','apply','decorator','splice','9CuJuwy','__decorate','registerMethodHandler','@midwayjs/core','metadata','assign','param','target','getOwnPropertyDescriptor','undefined','onReady','design:type','constructor','(((.+)+)+)+$','__metadata','defineProperty','1333944fIQEac','function','method','I18N_ATTR_KEY','req','__esModule','8HQlOfo','length','request','toString','params','1009845wbiEzL','locale','REQUEST_OBJ_CTX_KEY','prototype','1741220LRZmPR','9984840gjBSmF','args','@anncic-api/core','search'];a1_0x5113=function(){return _0x4f2ede;};return a1_0x5113();}const a1_0x4815a7=(function(){let _0x4f92e0=!![];return function(_0x3754a7,_0xd9e413){const _0x20d46d=_0x4f92e0?function(){const _0x465e90=a1_0x3380;if(_0xd9e413){const _0x26c8c1=_0xd9e413[_0x465e90(0x154)](_0x3754a7,arguments);return _0xd9e413=null,_0x26c8c1;}}:function(){};return _0x4f92e0=![],_0x20d46d;};}()),a1_0x5133d3=a1_0x4815a7(this,function(){const _0x357536=a1_0x3380;return a1_0x5133d3[_0x357536(0x170)]()[_0x357536(0x17a)](_0x357536(0x164))['toString']()[_0x357536(0x163)](a1_0x5133d3)[_0x357536(0x17a)](_0x357536(0x164));});a1_0x5133d3();'use strict';var __decorate=this&&this[a1_0x21b808(0x158)]||function(_0x253bb4,_0xd0d290,_0x44f814,_0x1eb448){const _0x4e5750=a1_0x21b808;var _0x267b74=arguments[_0x4e5750(0x16e)],_0x10a60e=_0x267b74<0x3?_0xd0d290:_0x1eb448===null?_0x1eb448=Object[_0x4e5750(0x15f)](_0xd0d290,_0x44f814):_0x1eb448,_0x13a01f;if(typeof Reflect===_0x4e5750(0x14d)&&typeof Reflect[_0x4e5750(0x17d)]===_0x4e5750(0x168))_0x10a60e=Reflect[_0x4e5750(0x17d)](_0x253bb4,_0xd0d290,_0x44f814,_0x1eb448);else{for(var _0x4bf29c=_0x253bb4[_0x4e5750(0x16e)]-0x1;_0x4bf29c>=0x0;_0x4bf29c--)if(_0x13a01f=_0x253bb4[_0x4bf29c])_0x10a60e=(_0x267b74<0x3?_0x13a01f(_0x10a60e):_0x267b74>0x3?_0x13a01f(_0xd0d290,_0x44f814,_0x10a60e):_0x13a01f(_0xd0d290,_0x44f814))||_0x10a60e;}return _0x267b74>0x3&&_0x10a60e&&Object[_0x4e5750(0x166)](_0xd0d290,_0x44f814,_0x10a60e),_0x10a60e;},__metadata=this&&this[a1_0x21b808(0x165)]||function(_0x1b43c7,_0x51e7d6){const _0x10e4e5=a1_0x21b808;if(typeof Reflect===_0x10e4e5(0x14d)&&typeof Reflect['metadata']===_0x10e4e5(0x168))return Reflect['metadata'](_0x1b43c7,_0x51e7d6);};Object[a1_0x21b808(0x166)](exports,a1_0x21b808(0x16c),{'value':!![]}),exports[a1_0x21b808(0x148)]=void 0x0;const i18n_1=require('@midwayjs/i18n'),core_1=require('@midwayjs/core'),core_2=require(a1_0x21b808(0x15a)),interface_1=require('./interface'),ValidatorService_1=require('./service/ValidatorService'),i18n=require(a1_0x21b808(0x150)),anncic=require(a1_0x21b808(0x179)),ConfigDefault=require(a1_0x21b808(0x17c));let CustomConfiguration=class CustomConfiguration{async[a1_0x21b808(0x161)](){const _0x3d8dba=a1_0x21b808;this[_0x3d8dba(0x155)][_0x3d8dba(0x159)](interface_1['VALIDATOR_KEY'],_0x376f54=>{const _0xfd7571=_0x3d8dba,_0x2fc65b=_0x376f54[_0xfd7571(0x15b)],_0x5cc38d=(0x0,core_2[_0xfd7571(0x17b)])(_0x376f54[_0xfd7571(0x15e)],_0x376f54[_0xfd7571(0x180)]);return{'before':_0x37d95d=>{const _0x47b9d9=_0xfd7571;var _0x26aa78,_0x34018a,_0x2a7161,_0x36a066,_0x536f5d,_0x55f213,_0xe4e8eb,_0x4d29b8,_0x95f8f,_0x1f5fc1,_0x4c2e45,_0x5ee338,_0x5bad02;const _0x9a3394=_0x37d95d[_0x47b9d9(0x15e)][core_1[_0x47b9d9(0x174)]],_0x4c2323=Object[_0x47b9d9(0x15c)]({},((_0x26aa78=_0x9a3394===null||_0x9a3394===void 0x0?void 0x0:_0x9a3394[_0x47b9d9(0x16f)])===null||_0x26aa78===void 0x0?void 0x0:_0x26aa78['query'])||{},((_0x34018a=_0x9a3394===null||_0x9a3394===void 0x0?void 0x0:_0x9a3394['request'])===null||_0x34018a===void 0x0?void 0x0:_0x34018a[_0x47b9d9(0x153)])||{}),_0x2b39f9=((0x0,core_2['getClassMetadata'])(interface_1['VALIDATOR_KEY'],_0x37d95d[_0x47b9d9(0x15e)])||[])['find'](_0x233b8d=>_0x233b8d[_0x47b9d9(0x169)]==_0x37d95d[_0x47b9d9(0x181)]);!(_0x2fc65b===null||_0x2fc65b===void 0x0?void 0x0:_0x2fc65b[_0x47b9d9(0x173)])&&_0x9a3394&&_0x9a3394['getAttr']&&(_0x2fc65b['locale']=_0x9a3394[_0x47b9d9(0x14f)](i18n_1[_0x47b9d9(0x16a)]));for(let _0x372de3=0x0;_0x372de3<_0x5cc38d[_0x47b9d9(0x16e)];_0x372de3++){const _0x160825=_0x5cc38d[_0x372de3],_0x104595=this[_0x47b9d9(0x17e)]['getSchema'](_0x160825);if(_0x104595){if(typeof _0x37d95d['args'][_0x372de3]==_0x47b9d9(0x160)||((_0x2a7161=_0x37d95d['args'][_0x372de3])===null||_0x2a7161===void 0x0?void 0x0:_0x2a7161[_0x47b9d9(0x16f)])&&((_0x36a066=_0x37d95d['args'][_0x372de3])===null||_0x36a066===void 0x0?void 0x0:_0x36a066['res'])&&((_0x536f5d=_0x37d95d['args'][_0x372de3])===null||_0x536f5d===void 0x0?void 0x0:_0x536f5d[_0x47b9d9(0x16b)]))_0x37d95d['args'][_0x372de3]=_0x4c2323;else((_0x55f213=_0x37d95d[_0x47b9d9(0x178)][_0x372de3])===null||_0x55f213===void 0x0?void 0x0:_0x55f213['name'])==_0x47b9d9(0x14c)&&_0x37d95d[_0x47b9d9(0x178)][_0x47b9d9(0x156)](_0x372de3,0x0,_0x4c2323);const _0x4799ef=this[_0x47b9d9(0x17e)]['validator'](_0x104595,_0x37d95d[_0x47b9d9(0x178)][_0x372de3],_0x2fc65b);_0x4799ef&&(_0x37d95d[_0x47b9d9(0x178)][_0x372de3]=_0x4799ef);}else{if((_0x2b39f9===null||_0x2b39f9===void 0x0?void 0x0:_0x2b39f9[_0x47b9d9(0x152)][_0x372de3])&&((_0xe4e8eb=_0x37d95d['args'][_0x372de3])===null||_0xe4e8eb===void 0x0?void 0x0:_0xe4e8eb[_0x47b9d9(0x171)])&&typeof _0x37d95d[_0x47b9d9(0x178)][_0x372de3][_0x47b9d9(0x15d)]=='function'&&((_0x4d29b8=_0x9a3394===null||_0x9a3394===void 0x0?void 0x0:_0x9a3394['params'])===null||_0x4d29b8===void 0x0?void 0x0:_0x4d29b8[_0x2b39f9[_0x47b9d9(0x152)][_0x372de3]]))_0x37d95d[_0x47b9d9(0x178)][_0x372de3]=_0x160825((_0x95f8f=_0x9a3394===null||_0x9a3394===void 0x0?void 0x0:_0x9a3394[_0x47b9d9(0x171)])===null||_0x95f8f===void 0x0?void 0x0:_0x95f8f[_0x2b39f9[_0x47b9d9(0x152)][_0x372de3]]);else(_0x2b39f9===null||_0x2b39f9===void 0x0?void 0x0:_0x2b39f9[_0x47b9d9(0x152)][_0x372de3])&&((_0x4c2e45=(_0x1f5fc1=_0x37d95d[_0x47b9d9(0x178)][_0x372de3])===null||_0x1f5fc1===void 0x0?void 0x0:_0x1f5fc1[_0x47b9d9(0x171)])===null||_0x4c2e45===void 0x0?void 0x0:_0x4c2e45[_0x2b39f9[_0x47b9d9(0x152)][_0x372de3]])&&(_0x37d95d['args'][_0x372de3]=(_0x5bad02=(_0x5ee338=_0x37d95d[_0x47b9d9(0x178)][_0x372de3])===null||_0x5ee338===void 0x0?void 0x0:_0x5ee338[_0x47b9d9(0x171)])===null||_0x5bad02===void 0x0?void 0x0:_0x5bad02[_0x2b39f9[_0x47b9d9(0x152)][_0x372de3]]);}}},'afterThrow':(_0x5f4273,_0x19e758)=>{throw _0x19e758;}};});}};exports['CustomConfiguration']=CustomConfiguration,__decorate([(0x0,core_2[a1_0x21b808(0x14a)])(),__metadata(a1_0x21b808(0x162),core_1[a1_0x21b808(0x151)])],CustomConfiguration[a1_0x21b808(0x175)],'decorator',void 0x0),__decorate([(0x0,core_2[a1_0x21b808(0x14a)])(),__metadata(a1_0x21b808(0x162),ValidatorService_1['ValidatorService'])],CustomConfiguration[a1_0x21b808(0x175)],a1_0x21b808(0x17e),void 0x0),exports[a1_0x21b808(0x148)]=CustomConfiguration=__decorate([(0x0,core_2['Configuration'])({'conflictCheck':![],'imports':[i18n,anncic],'namespace':'anncic-api:validator','importConfigs':[{'default':ConfigDefault}]})],CustomConfiguration);
|
package/dist/decorator/Rule.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a2_0x50c049=a2_0x55a6;(function(_0x227408,_0x3329b3){const _0x1e4e34=a2_0x55a6,_0x126c7f=_0x227408();while(!![]){try{const _0xee269=-parseInt(_0x1e4e34(0x206))/0x1+parseInt(_0x1e4e34(0x1ef))/0x2+parseInt(_0x1e4e34(0x1fe))/0x3*(-parseInt(_0x1e4e34(0x1f3))/0x4)+-parseInt(_0x1e4e34(0x208))/0x5*(parseInt(_0x1e4e34(0x201))/0x6)+parseInt(_0x1e4e34(0x1f4))/0x7+-parseInt(_0x1e4e34(0x209))/0x8*(-parseInt(_0x1e4e34(0x1fa))/0x9)+parseInt(_0x1e4e34(0x1f8))/0xa;if(_0xee269===_0x3329b3)break;else _0x126c7f['push'](_0x126c7f['shift']());}catch(_0x3663b1){_0x126c7f['push'](_0x126c7f['shift']());}}}(a2_0x2bc7,0x5154a));const a2_0x5e78ae=(function(){let _0xdc9b5d=!![];return function(_0x38f6f3,_0x61f275){const _0x4208cd=_0xdc9b5d?function(){const _0x2e35a0=a2_0x55a6;if(_0x61f275){const _0x155f69=_0x61f275[_0x2e35a0(0x1ee)](_0x38f6f3,arguments);return _0x61f275=null,_0x155f69;}}:function(){};return _0xdc9b5d=![],_0x4208cd;};}()),a2_0x4f3953=a2_0x5e78ae(this,function(){const _0x49bb0e=a2_0x55a6;return a2_0x4f3953[_0x49bb0e(0x1fc)]()[_0x49bb0e(0x1f1)](_0x49bb0e(0x1eb))[_0x49bb0e(0x1fc)]()[_0x49bb0e(0x1f6)](a2_0x4f3953)['search'](_0x49bb0e(0x1eb));});a2_0x4f3953();'use strict';function a2_0x55a6(_0x3a3543,_0x4fd0e8){const _0xed4a78=a2_0x2bc7();return a2_0x55a6=function(_0x4f3953,_0x5e78ae){_0x4f3953=_0x4f3953-0x1e8;let _0x2bc7c9=_0xed4a78[_0x4f3953];return _0x2bc7c9;},a2_0x55a6(_0x3a3543,_0x4fd0e8);}function a2_0x2bc7(){const _0x2f5c9c=['544520YTeQAC','19816fcpRqN','items','array','description','saveClassMetadata','isSchema','extend','(((.+)+)+)+$','object','__esModule','apply','542828dREMLe','default','search','RULES_KEY','958756YnJirW','2314228GSZQDg','label','constructor','name','1804690ihZiiS','Array','2007akFgta','map','toString','getPropertyType','3TNHLlR','RuleType','getClassMetadata','6wegAIh','Rule','function','meta','defineProperty','653135inIlEp','@midwayjs/core'];a2_0x2bc7=function(){return _0x2f5c9c;};return a2_0x2bc7();}Object[a2_0x50c049(0x205)](exports,a2_0x50c049(0x1ed),{'value':!![]}),exports[a2_0x50c049(0x1ff)]=void 0x0,exports[a2_0x50c049(0x202)]=Rule;const joi=require('joi'),date_1=require('@joi/date'),core_1=require(a2_0x50c049(0x207)),interface_1=require('../interface');exports[a2_0x50c049(0x1ff)]=joi[a2_0x50c049(0x1ea)](date_1[a2_0x50c049(0x1f0)]);function Rule(_0x2a2506,_0x8671c0,_0x210e3e=''){return(_0x44535d,_0x86ba05)=>{const _0x16156d=a2_0x55a6;var _0x5bc847;if(_0x86ba05)!joi[_0x16156d(0x1e9)](_0x8671c0)&&(_0x8671c0===null||_0x8671c0===void 0x0?void 0x0:_0x8671c0[_0x16156d(0x1f7)])&&(_0x8671c0=joi[_0x16156d(0x1ec)]((0x0,core_1[_0x16156d(0x200)])(interface_1[_0x16156d(0x1f2)],_0x8671c0))[_0x16156d(0x204)]({'id':_0x8671c0['name']}),(0x0,core_1[_0x16156d(0x1fd)])(_0x44535d,_0x86ba05)['name']===_0x16156d(0x1f9)&&(_0x8671c0=joi[_0x16156d(0x20b)]()[_0x16156d(0x20a)](_0x8671c0))),joi[_0x16156d(0x1e9)](_0x8671c0)&&(_0x2a2506&&typeof(_0x8671c0===null||_0x8671c0===void 0x0?void 0x0:_0x8671c0[_0x16156d(0x1f5)])==_0x16156d(0x203)&&(_0x8671c0=_0x8671c0[_0x16156d(0x1f5)](_0x2a2506)),_0x210e3e&&typeof(_0x8671c0===null||_0x8671c0===void 0x0?void 0x0:_0x8671c0[_0x16156d(0x20c)])==_0x16156d(0x203)&&(_0x8671c0=_0x8671c0['description'](_0x210e3e)),(0x0,core_1['attachClassMetadata'])(interface_1['RULES_KEY'],_0x8671c0,_0x44535d,_0x86ba05));else{const _0x471e66=(0x0,core_1[_0x16156d(0x200)])(interface_1[_0x16156d(0x1f2)],_0x8671c0);if(_0x471e66){let _0x3c79a8=(_0x5bc847=(0x0,core_1[_0x16156d(0x200)])(interface_1[_0x16156d(0x1f2)],_0x44535d))!==null&&_0x5bc847!==void 0x0?_0x5bc847:{};Object['keys'](_0x471e66)[_0x16156d(0x1fb)](_0x1bec4d=>{!_0x3c79a8[_0x1bec4d]&&(_0x3c79a8[_0x1bec4d]=_0x471e66[_0x1bec4d]);}),(0x0,core_1[_0x16156d(0x1e8)])(interface_1[_0x16156d(0x1f2)],_0x3c79a8,_0x44535d);}}};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a3_0x5359a2=a3_0x4d6e;function a3_0x4d6e(_0x1edc75,_0x1da92d){const _0x3915dd=a3_0x359a();return a3_0x4d6e=function(_0x3efbd9,_0x294a11){_0x3efbd9=_0x3efbd9-0x94;let _0x359afe=_0x3915dd[_0x3efbd9];return _0x359afe;},a3_0x4d6e(_0x1edc75,_0x1da92d);}(function(_0x202ddd,_0x1bb135){const _0x1afe0f=a3_0x4d6e,_0x43d0cf=_0x202ddd();while(!![]){try{const _0x4364bb=-parseInt(_0x1afe0f(0x9f))/0x1*(parseInt(_0x1afe0f(0x94))/0x2)+-parseInt(_0x1afe0f(0xab))/0x3+parseInt(_0x1afe0f(0x9a))/0x4+parseInt(_0x1afe0f(0x99))/0x5+parseInt(_0x1afe0f(0xa6))/0x6+-parseInt(_0x1afe0f(0xa1))/0x7*(parseInt(_0x1afe0f(0xa3))/0x8)+parseInt(_0x1afe0f(0xa7))/0x9;if(_0x4364bb===_0x1bb135)break;else _0x43d0cf['push'](_0x43d0cf['shift']());}catch(_0x254737){_0x43d0cf['push'](_0x43d0cf['shift']());}}}(a3_0x359a,0x56308));function a3_0x359a(){const _0x1999ad=['2002656kzOSZc','6806lWykSq','defineProperty','__esModule','indexOf','(((.+)+)+)+$','826420vQwzDY','527428cGYhAm','match','constructor','function','VALIDATOR_KEY','50uBNwXL','attachClassMetadata','211526uEBZtv','replace','136CWpdpo','getFuncArgs','toString','3610308wZQCgd','7250229ORTBsd','Validator','../interface','search'];a3_0x359a=function(){return _0x1999ad;};return a3_0x359a();}const a3_0x294a11=(function(){let _0x399211=!![];return function(_0x428b0e,_0x549090){const _0x5bdbf2=_0x399211?function(){if(_0x549090){const _0x52ca1a=_0x549090['apply'](_0x428b0e,arguments);return _0x549090=null,_0x52ca1a;}}:function(){};return _0x399211=![],_0x5bdbf2;};}()),a3_0x3efbd9=a3_0x294a11(this,function(){const _0x1eb68b=a3_0x4d6e;return a3_0x3efbd9[_0x1eb68b(0xa5)]()['search'](_0x1eb68b(0x98))[_0x1eb68b(0xa5)]()[_0x1eb68b(0x9c)](a3_0x3efbd9)[_0x1eb68b(0xaa)](_0x1eb68b(0x98));});a3_0x3efbd9();'use strict';Object[a3_0x5359a2(0x95)](exports,a3_0x5359a2(0x96),{'value':!![]}),exports[a3_0x5359a2(0xa8)]=Validator,exports[a3_0x5359a2(0xa4)]=getFuncArgs;const core_1=require('@midwayjs/core'),interface_1=require(a3_0x5359a2(0xa9));function Validator(_0x2aed16={}){return(_0x28fcb4,_0x45124c,_0x575bf0)=>{const _0x2b6702=a3_0x4d6e,_0x29ea55=getFuncArgs(_0x28fcb4[_0x45124c]);(0x0,core_1[_0x2b6702(0xa0)])(interface_1[_0x2b6702(0x9e)],{'method':_0x45124c,'methodArgs':_0x29ea55},_0x28fcb4),(0x0,core_1['createCustomMethodDecorator'])(interface_1['VALIDATOR_KEY'],_0x2aed16)(_0x28fcb4,_0x45124c,_0x575bf0);};}function getFuncArgs(_0x807754){const _0xbbe8c4=a3_0x5359a2;if(typeof _0x807754==_0xbbe8c4(0x9d)){const _0x369cef=/=>.*$/mg,_0x24c7a2=/=[^,)]+/mg,_0x3efddf=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/mg,_0xe8c048=(_0x807754['prototype']?_0x807754['prototype']['constructor'][_0xbbe8c4(0xa5)]():_0x807754[_0xbbe8c4(0xa5)]())[_0xbbe8c4(0xa2)](_0x3efddf,'')[_0xbbe8c4(0xa2)](_0x369cef,'')['replace'](_0x24c7a2,''),_0x1f8462=_0xe8c048['slice'](_0xe8c048['indexOf']('(')+0x1,_0xe8c048[_0xbbe8c4(0x97)](')'))[_0xbbe8c4(0x9b)](/([^\s,]+)/g)||[];return _0x1f8462;}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
function a4_0xab87(_0x25c743,_0x31cba3){var _0x1e7009=a4_0xcc59();return a4_0xab87=function(_0x52fbbb,_0xbd0048){_0x52fbbb=_0x52fbbb-0xeb;var _0xcc592b=_0x1e7009[_0x52fbbb];return _0xcc592b;},a4_0xab87(_0x25c743,_0x31cba3);}var a4_0x521b69=a4_0xab87;(function(_0x204f25,_0x24d06e){var _0x2b4376=a4_0xab87,_0x1ca2c1=_0x204f25();while(!![]){try{var _0x47bcff=-parseInt(_0x2b4376(0xfb))/0x1+parseInt(_0x2b4376(0xeb))/0x2+-parseInt(_0x2b4376(0xf1))/0x3+-parseInt(_0x2b4376(0x106))/0x4+-parseInt(_0x2b4376(0xfc))/0x5+-parseInt(_0x2b4376(0xf7))/0x6*(parseInt(_0x2b4376(0x105))/0x7)+parseInt(_0x2b4376(0xf0))/0x8;if(_0x47bcff===_0x24d06e)break;else _0x1ca2c1['push'](_0x1ca2c1['shift']());}catch(_0xa5781b){_0x1ca2c1['push'](_0x1ca2c1['shift']());}}}(a4_0xcc59,0x1daae));var a4_0xbd0048=(function(){var _0x14cecf=!![];return function(_0x540518,_0x3f0cf1){var _0x55a159=_0x14cecf?function(){var _0x4d25dc=a4_0xab87;if(_0x3f0cf1){var _0xce9382=_0x3f0cf1[_0x4d25dc(0xf6)](_0x540518,arguments);return _0x3f0cf1=null,_0xce9382;}}:function(){};return _0x14cecf=![],_0x55a159;};}()),a4_0x52fbbb=a4_0xbd0048(this,function(){var _0xf9213e=a4_0xab87;return a4_0x52fbbb['toString']()[_0xf9213e(0xec)](_0xf9213e(0xed))[_0xf9213e(0xef)]()[_0xf9213e(0xf3)](a4_0x52fbbb)['search'](_0xf9213e(0xed));});a4_0x52fbbb();'use strict';var __decorate=this&&this[a4_0x521b69(0x103)]||function(_0x283b0c,_0x4ab3ed,_0x20d7cf,_0x57ea2d){var _0x422977=a4_0x521b69,_0x25d3c3=arguments[_0x422977(0xf4)],_0x96c43b=_0x25d3c3<0x3?_0x4ab3ed:_0x57ea2d===null?_0x57ea2d=Object[_0x422977(0xee)](_0x4ab3ed,_0x20d7cf):_0x57ea2d,_0x2e328a;if(typeof Reflect==='object'&&typeof Reflect['decorate']===_0x422977(0xfe))_0x96c43b=Reflect['decorate'](_0x283b0c,_0x4ab3ed,_0x20d7cf,_0x57ea2d);else{for(var _0x1f498b=_0x283b0c['length']-0x1;_0x1f498b>=0x0;_0x1f498b--)if(_0x2e328a=_0x283b0c[_0x1f498b])_0x96c43b=(_0x25d3c3<0x3?_0x2e328a(_0x96c43b):_0x25d3c3>0x3?_0x2e328a(_0x4ab3ed,_0x20d7cf,_0x96c43b):_0x2e328a(_0x4ab3ed,_0x20d7cf))||_0x96c43b;}return _0x25d3c3>0x3&&_0x96c43b&&Object[_0x422977(0xfa)](_0x4ab3ed,_0x20d7cf,_0x96c43b),_0x96c43b;},__metadata=this&&this['__metadata']||function(_0x2988ed,_0x467f6f){var _0x2a32f3=a4_0x521b69;if(typeof Reflect===_0x2a32f3(0xff)&&typeof Reflect[_0x2a32f3(0xf9)]===_0x2a32f3(0xfe))return Reflect[_0x2a32f3(0xf9)](_0x2988ed,_0x467f6f);};Object[a4_0x521b69(0xfa)](exports,a4_0x521b69(0xf5),{'value':!![]}),exports[a4_0x521b69(0xf2)]=void 0x0;const core_1=require(a4_0x521b69(0x104));class ValidatorError extends AnnError{}function a4_0xcc59(){var _0x5b15ee=['constructor','length','__esModule','apply','2922RAGiro','PARAMS','metadata','defineProperty','74158TPVFhx','105105bRDAvx','design:type','function','object','NOFIND_SCHEMA','参数验证失败','AnnErrorMsg','__decorate','@anncic-api/core','238SJkfhY','710804nEFCSm','37266BZyPST','search','(((.+)+)+)+$','getOwnPropertyDescriptor','toString','3855184HPsCwk','268725WuMgpr','ValidatorError'];a4_0xcc59=function(){return _0x5b15ee;};return a4_0xcc59();}exports[a4_0x521b69(0xf2)]=ValidatorError,ValidatorError[a4_0x521b69(0xf8)]=0x18c1e,ValidatorError[a4_0x521b69(0x100)]=0x18c1c,__decorate([(0x0,core_1[a4_0x521b69(0x102)])(a4_0x521b69(0x101)),__metadata('design:type',Object)],ValidatorError,a4_0x521b69(0xf8),void 0x0),__decorate([(0x0,core_1[a4_0x521b69(0x102)])(a4_0x521b69(0x101)),__metadata(a4_0x521b69(0xfd),Object)],ValidatorError,a4_0x521b69(0x100),void 0x0);
|
package/dist/helper/dtoHelper.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a5_0x1891(_0x4ea803,_0x392ee1){const _0x3f25b7=a5_0x3c31();return a5_0x1891=function(_0x590ff8,_0x2dde62){_0x590ff8=_0x590ff8-0x79;let _0x3c317b=_0x3f25b7[_0x590ff8];return _0x3c317b;},a5_0x1891(_0x4ea803,_0x392ee1);}const a5_0x17711c=a5_0x1891;(function(_0x32e443,_0xbce880){const _0x4ab424=a5_0x1891,_0x3ca9c9=_0x32e443();while(!![]){try{const _0x3976e3=-parseInt(_0x4ab424(0x7b))/0x1+-parseInt(_0x4ab424(0x84))/0x2*(parseInt(_0x4ab424(0x7f))/0x3)+-parseInt(_0x4ab424(0x8e))/0x4*(parseInt(_0x4ab424(0x87))/0x5)+parseInt(_0x4ab424(0x7e))/0x6+-parseInt(_0x4ab424(0x83))/0x7+parseInt(_0x4ab424(0x82))/0x8*(-parseInt(_0x4ab424(0x7d))/0x9)+-parseInt(_0x4ab424(0x80))/0xa*(-parseInt(_0x4ab424(0x8c))/0xb);if(_0x3976e3===_0xbce880)break;else _0x3ca9c9['push'](_0x3ca9c9['shift']());}catch(_0x11b80d){_0x3ca9c9['push'](_0x3ca9c9['shift']());}}}(a5_0x3c31,0xd4d0a));const a5_0x2dde62=(function(){let _0x22f3a4=!![];return function(_0x3cbb72,_0x3b1953){const _0x36922d=_0x22f3a4?function(){if(_0x3b1953){const _0x17497c=_0x3b1953['apply'](_0x3cbb72,arguments);return _0x3b1953=null,_0x17497c;}}:function(){};return _0x22f3a4=![],_0x36922d;};}()),a5_0x590ff8=a5_0x2dde62(this,function(){const _0x18f95a=a5_0x1891;return a5_0x590ff8[_0x18f95a(0x89)]()['search'](_0x18f95a(0x8a))[_0x18f95a(0x89)]()[_0x18f95a(0x8b)](a5_0x590ff8)['search']('(((.+)+)+)+$');});a5_0x590ff8();'use strict';Object[a5_0x17711c(0x7a)](exports,a5_0x17711c(0x79),{'value':!![]}),exports['PickDto']=PickDto,exports[a5_0x17711c(0x8f)]=OmitDto;const core_1=require(a5_0x17711c(0x81)),interface_1=require(a5_0x17711c(0x88));function a5_0x3c31(){const _0x588928=['302635FXtmTV','../interface','toString','(((.+)+)+)+$','constructor','99IXnRky','prototype','8IEdZNH','OmitDto','RULES_KEY','__esModule','defineProperty','8971bUYZrH','saveClassMetadata','40572MjxZYL','5385984zFuGvF','15UpGGeK','2374090Lykpws','@midwayjs/core','312YiOWwK','6919241zaGdfz','347342LqKlFu','assign','getClassExtendedMetadata'];a5_0x3c31=function(){return _0x588928;};return a5_0x3c31();}function PickDto(_0x303aaf,_0x5db8b4){const _0x219ca3=a5_0x17711c,_0x38481a=function(){};_0x38481a[_0x219ca3(0x8d)]=_0x303aaf[_0x219ca3(0x8d)];const _0x293e51=(0x0,core_1[_0x219ca3(0x86)])(interface_1[_0x219ca3(0x90)],_0x303aaf),_0x40d24c={};for(const _0x3dc671 of _0x5db8b4){_0x293e51[_0x3dc671]&&(_0x40d24c[_0x3dc671]=_0x293e51[_0x3dc671]);}return(0x0,core_1[_0x219ca3(0x7c)])(interface_1[_0x219ca3(0x90)],_0x40d24c,_0x38481a),_0x38481a;}function OmitDto(_0x5a976a,_0x3de426){const _0x140d6e=a5_0x17711c,_0xefa51d=function(){};_0xefa51d[_0x140d6e(0x8d)]=_0x5a976a['prototype'];const _0x48ca46=(0x0,core_1[_0x140d6e(0x86)])(interface_1['RULES_KEY'],_0x5a976a),_0x164134=Object[_0x140d6e(0x85)]({},_0x48ca46);for(const _0x1f5265 of _0x3de426){delete _0x164134[_0x1f5265];}return(0x0,core_1['saveClassMetadata'])(interface_1[_0x140d6e(0x90)],_0x164134,_0xefa51d),_0xefa51d;}
|
package/dist/helper/getSchema.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a6_0x5909fa=a6_0x3cc1;(function(_0x1b154e,_0x534ea5){const _0x55c637=a6_0x3cc1,_0x268fec=_0x1b154e();while(!![]){try{const _0x4fa866=-parseInt(_0x55c637(0x1e0))/0x1*(parseInt(_0x55c637(0x1ec))/0x2)+-parseInt(_0x55c637(0x1e9))/0x3*(parseInt(_0x55c637(0x1e3))/0x4)+-parseInt(_0x55c637(0x1e8))/0x5*(-parseInt(_0x55c637(0x1e4))/0x6)+parseInt(_0x55c637(0x1e1))/0x7+-parseInt(_0x55c637(0x1ed))/0x8*(-parseInt(_0x55c637(0x1df))/0x9)+parseInt(_0x55c637(0x1ee))/0xa+parseInt(_0x55c637(0x1ea))/0xb*(parseInt(_0x55c637(0x1eb))/0xc);if(_0x4fa866===_0x534ea5)break;else _0x268fec['push'](_0x268fec['shift']());}catch(_0xeb3749){_0x268fec['push'](_0x268fec['shift']());}}}(a6_0x39b7,0xf1e08));const a6_0x21becf=(function(){let _0x18690c=!![];return function(_0x7c9186,_0x22d833){const _0xa3c7cb=_0x18690c?function(){const _0xac1252=a6_0x3cc1;if(_0x22d833){const _0x315bba=_0x22d833[_0xac1252(0x1e6)](_0x7c9186,arguments);return _0x22d833=null,_0x315bba;}}:function(){};return _0x18690c=![],_0xa3c7cb;};}()),a6_0x5760af=a6_0x21becf(this,function(){const _0x4ab660=a6_0x3cc1;return a6_0x5760af[_0x4ab660(0x1dc)]()[_0x4ab660(0x1de)](_0x4ab660(0x1d9))['toString']()[_0x4ab660(0x1e2)](a6_0x5760af)['search'](_0x4ab660(0x1d9));});a6_0x5760af();function a6_0x3cc1(_0x59bb25,_0x34765c){const _0x34f9dd=a6_0x39b7();return a6_0x3cc1=function(_0x5760af,_0x21becf){_0x5760af=_0x5760af-0x1d8;let _0x39b76a=_0x34f9dd[_0x5760af];return _0x39b76a;},a6_0x3cc1(_0x59bb25,_0x34765c);}'use strict';Object['defineProperty'](exports,a6_0x5909fa(0x1db),{'value':!![]}),exports[a6_0x5909fa(0x1e5)]=getSchema;const Joi=require('joi'),core_1=require(a6_0x5909fa(0x1d8)),interface_1=require(a6_0x5909fa(0x1dd));function a6_0x39b7(){const _0x9431c3=['4NPlXRr','42UBSJFw','getSchema','apply','object','114685KivzDe','1320465Ozsutn','5241126YmTsVU','12rMdcgA','664956BggbyD','8kdCPRT','5892230WBdnfI','@midwayjs/core','(((.+)+)+)+$','getClassExtendedMetadata','__esModule','toString','../interface','search','10396422KErGyn','3wKqXeD','328377AlXzgJ','constructor'];a6_0x39b7=function(){return _0x9431c3;};return a6_0x39b7();}function getSchema(_0x3f5fde){const _0x4d5082=a6_0x5909fa,_0x1de45c=(0x0,core_1[_0x4d5082(0x1da)])(interface_1['RULES_KEY'],_0x3f5fde);if(_0x1de45c)return Joi[_0x4d5082(0x1e7)](_0x1de45c);}
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a7_0x3c8c7d=a7_0x2113;(function(_0x21a3d7,_0x6d43fb){var _0x53b91b=a7_0x2113,_0x36de3f=_0x21a3d7();while(!![]){try{var _0x15a3c6=parseInt(_0x53b91b(0x133))/0x1+parseInt(_0x53b91b(0x144))/0x2+parseInt(_0x53b91b(0x136))/0x3*(-parseInt(_0x53b91b(0x132))/0x4)+parseInt(_0x53b91b(0x13b))/0x5*(-parseInt(_0x53b91b(0x139))/0x6)+-parseInt(_0x53b91b(0x147))/0x7*(parseInt(_0x53b91b(0x138))/0x8)+parseInt(_0x53b91b(0x145))/0x9+-parseInt(_0x53b91b(0x134))/0xa*(parseInt(_0x53b91b(0x130))/0xb);if(_0x15a3c6===_0x6d43fb)break;else _0x36de3f['push'](_0x36de3f['shift']());}catch(_0x187d06){_0x36de3f['push'](_0x36de3f['shift']());}}}(a7_0x30fe,0x48d35));var a7_0x5e26d1=(function(){var _0x249e93=!![];return function(_0x438c7b,_0x42577c){var _0xc00dc3=_0x249e93?function(){var _0x3c450d=a7_0x2113;if(_0x42577c){var _0x6d9e57=_0x42577c[_0x3c450d(0x12c)](_0x438c7b,arguments);return _0x42577c=null,_0x6d9e57;}}:function(){};return _0x249e93=![],_0xc00dc3;};}()),a7_0x14b94d=a7_0x5e26d1(this,function(){var _0x3aa24b=a7_0x2113;return a7_0x14b94d[_0x3aa24b(0x13a)]()[_0x3aa24b(0x14e)](_0x3aa24b(0x14d))[_0x3aa24b(0x13a)]()['constructor'](a7_0x14b94d)['search'](_0x3aa24b(0x14d));});a7_0x14b94d();'use strict';var __createBinding=this&&this[a7_0x3c8c7d(0x12e)]||(Object['create']?function(_0x3f8332,_0x1794e8,_0x13a610,_0x30cf98){var _0x3668df=a7_0x3c8c7d;if(_0x30cf98===undefined)_0x30cf98=_0x13a610;var _0x13751a=Object['getOwnPropertyDescriptor'](_0x1794e8,_0x13a610);(!_0x13751a||(_0x3668df(0x14c)in _0x13751a?!_0x1794e8['__esModule']:_0x13751a[_0x3668df(0x12f)]||_0x13751a[_0x3668df(0x13d)]))&&(_0x13751a={'enumerable':!![],'get':function(){return _0x1794e8[_0x13a610];}}),Object[_0x3668df(0x141)](_0x3f8332,_0x30cf98,_0x13751a);}:function(_0x5686a6,_0x4f7732,_0x151cfa,_0x4ff857){if(_0x4ff857===undefined)_0x4ff857=_0x151cfa;_0x5686a6[_0x4ff857]=_0x4f7732[_0x151cfa];}),__exportStar=this&&this[a7_0x3c8c7d(0x12a)]||function(_0x2186aa,_0x314d3c){var _0x5e176c=a7_0x3c8c7d;for(var _0xce99a2 in _0x2186aa)if(_0xce99a2!==_0x5e176c(0x12d)&&!Object[_0x5e176c(0x148)][_0x5e176c(0x135)][_0x5e176c(0x14a)](_0x314d3c,_0xce99a2))__createBinding(_0x314d3c,_0x2186aa,_0xce99a2);};function a7_0x30fe(){var _0xe71f10=['hasOwnProperty','21goVRbU','./helper/getSchema','56JrDSYo','1038yfSRVZ','toString','7215yGCABn','./decorator/Validator','configurable','Validator','ValidatorError','ValidatorService','defineProperty','./configuration','RuleType','762352PWayjk','5141367wfNgVa','./exception/ValidatorError','449918bibtpi','prototype','Rule','call','Configuration','get','(((.+)+)+)+$','search','__esModule','__exportStar','./decorator/Rule','apply','default','__createBinding','writable','11pCHCKQ','CustomConfiguration','16556Knpvfa','437877PEsfhU','3634930xtGviB'];a7_0x30fe=function(){return _0xe71f10;};return a7_0x30fe();}Object[a7_0x3c8c7d(0x141)](exports,a7_0x3c8c7d(0x14f),{'value':!![]}),exports[a7_0x3c8c7d(0x14b)]=exports[a7_0x3c8c7d(0x140)]=exports['ValidatorError']=exports[a7_0x3c8c7d(0x143)]=exports[a7_0x3c8c7d(0x149)]=exports['Validator']=void 0x0,__exportStar(require('./interface'),exports),__exportStar(require('./helper/dtoHelper'),exports),__exportStar(require(a7_0x3c8c7d(0x137)),exports);var Validator_1=require(a7_0x3c8c7d(0x13c));Object['defineProperty'](exports,a7_0x3c8c7d(0x13e),{'enumerable':!![],'get':function(){return Validator_1['Validator'];}});var Rule_1=require(a7_0x3c8c7d(0x12b));Object[a7_0x3c8c7d(0x141)](exports,a7_0x3c8c7d(0x149),{'enumerable':!![],'get':function(){return Rule_1['Rule'];}}),Object[a7_0x3c8c7d(0x141)](exports,a7_0x3c8c7d(0x143),{'enumerable':!![],'get':function(){var _0x4a1e4a=a7_0x3c8c7d;return Rule_1[_0x4a1e4a(0x143)];}});var ValidatorError_1=require(a7_0x3c8c7d(0x146));Object[a7_0x3c8c7d(0x141)](exports,a7_0x3c8c7d(0x13f),{'enumerable':!![],'get':function(){return ValidatorError_1['ValidatorError'];}});var ValidatorService_1=require('./service/ValidatorService');Object[a7_0x3c8c7d(0x141)](exports,a7_0x3c8c7d(0x140),{'enumerable':!![],'get':function(){var _0x355c9a=a7_0x3c8c7d;return ValidatorService_1[_0x355c9a(0x140)];}});function a7_0x2113(_0x256879,_0x37bbf9){var _0x8c063e=a7_0x30fe();return a7_0x2113=function(_0x14b94d,_0x5e26d1){_0x14b94d=_0x14b94d-0x12a;var _0x30feed=_0x8c063e[_0x14b94d];return _0x30feed;},a7_0x2113(_0x256879,_0x37bbf9);}var configuration_1=require(a7_0x3c8c7d(0x142));Object['defineProperty'](exports,a7_0x3c8c7d(0x14b),{'enumerable':!![],'get':function(){var _0x2abaf8=a7_0x3c8c7d;return configuration_1[_0x2abaf8(0x131)];}});
|
package/dist/interface.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a8_0x3145a7=a8_0x1208;(function(_0x31b8e2,_0x3fc2c5){var _0x8df3ad=a8_0x1208,_0x68c4af=_0x31b8e2();while(!![]){try{var _0x59ea9c=parseInt(_0x8df3ad(0x17a))/0x1*(-parseInt(_0x8df3ad(0x16f))/0x2)+-parseInt(_0x8df3ad(0x174))/0x3+parseInt(_0x8df3ad(0x179))/0x4*(-parseInt(_0x8df3ad(0x17b))/0x5)+-parseInt(_0x8df3ad(0x175))/0x6+parseInt(_0x8df3ad(0x170))/0x7+parseInt(_0x8df3ad(0x172))/0x8*(parseInt(_0x8df3ad(0x177))/0x9)+parseInt(_0x8df3ad(0x176))/0xa;if(_0x59ea9c===_0x3fc2c5)break;else _0x68c4af['push'](_0x68c4af['shift']());}catch(_0x16ce1e){_0x68c4af['push'](_0x68c4af['shift']());}}}(a8_0x2584,0xdf83b));var a8_0x375f53=(function(){var _0xd735f8=!![];return function(_0x804b03,_0x2434c0){var _0x26aed0=_0xd735f8?function(){if(_0x2434c0){var _0x450385=_0x2434c0['apply'](_0x804b03,arguments);return _0x2434c0=null,_0x450385;}}:function(){};return _0xd735f8=![],_0x26aed0;};}()),a8_0x4e689a=a8_0x375f53(this,function(){var _0x56e494=a8_0x1208;return a8_0x4e689a[_0x56e494(0x180)]()['search'](_0x56e494(0x17e))[_0x56e494(0x180)]()[_0x56e494(0x171)](a8_0x4e689a)[_0x56e494(0x17d)]('(((.+)+)+)+$');});function a8_0x1208(_0x100fef,_0x43a204){var _0x449b0d=a8_0x2584();return a8_0x1208=function(_0x4e689a,_0x375f53){_0x4e689a=_0x4e689a-0x16f;var _0x258476=_0x449b0d[_0x4e689a];return _0x258476;},a8_0x1208(_0x100fef,_0x43a204);}function a8_0x2584(){var _0xc9d83b=['__esModule','search','(((.+)+)+)+$','VALIDATOR_KEY','toString','defineProperty','anncic-api:validator:validator','182498ARwUUo','16093YTlskK','constructor','1688VetQwo','anncic-api:validator:rules','5225799NxnqcW','5968140cwJpSA','33956180vISZKZ','28719EqdSgW','RULES_KEY','1876QhUQDh','1zGnxYw','3495hMTXbB'];a8_0x2584=function(){return _0xc9d83b;};return a8_0x2584();}a8_0x4e689a();'use strict';Object[a8_0x3145a7(0x181)](exports,a8_0x3145a7(0x17c),{'value':!![]}),exports[a8_0x3145a7(0x17f)]=exports[a8_0x3145a7(0x178)]=void 0x0,exports[a8_0x3145a7(0x178)]=a8_0x3145a7(0x173),exports['VALIDATOR_KEY']=a8_0x3145a7(0x182);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a9_0x28999e=a9_0x4810;(function(_0x3ef9f8,_0x1f8953){const _0x39a8f4=a9_0x4810,_0x576a2b=_0x3ef9f8();while(!![]){try{const _0x2d4086=parseInt(_0x39a8f4(0x205))/0x1*(-parseInt(_0x39a8f4(0x1e1))/0x2)+parseInt(_0x39a8f4(0x20c))/0x3+parseInt(_0x39a8f4(0x1f5))/0x4*(-parseInt(_0x39a8f4(0x1f8))/0x5)+parseInt(_0x39a8f4(0x1e5))/0x6*(-parseInt(_0x39a8f4(0x200))/0x7)+parseInt(_0x39a8f4(0x1d8))/0x8+parseInt(_0x39a8f4(0x213))/0x9+parseInt(_0x39a8f4(0x202))/0xa;if(_0x2d4086===_0x1f8953)break;else _0x576a2b['push'](_0x576a2b['shift']());}catch(_0x1d3e75){_0x576a2b['push'](_0x576a2b['shift']());}}}(a9_0xd573,0xbbdd2));const a9_0x2b247d=(function(){let _0x5c731c=!![];return function(_0x47d2db,_0x12739e){const _0xd392be=_0x5c731c?function(){const _0x5a42d8=a9_0x4810;if(_0x12739e){const _0x2a9be6=_0x12739e[_0x5a42d8(0x1ee)](_0x47d2db,arguments);return _0x12739e=null,_0x2a9be6;}}:function(){};return _0x5c731c=![],_0xd392be;};}()),a9_0x4f0d7a=a9_0x2b247d(this,function(){const _0x4499ca=a9_0x4810;return a9_0x4f0d7a[_0x4499ca(0x1fb)]()['search'](_0x4499ca(0x214))[_0x4499ca(0x1fb)]()['constructor'](a9_0x4f0d7a)[_0x4499ca(0x1df)](_0x4499ca(0x214));});a9_0x4f0d7a();'use strict';var __decorate=this&&this[a9_0x28999e(0x218)]||function(_0x80c880,_0x4a09ce,_0x11c440,_0x517b0e){const _0x286668=a9_0x28999e;var _0x58af1c=arguments[_0x286668(0x216)],_0x1b7315=_0x58af1c<0x3?_0x4a09ce:_0x517b0e===null?_0x517b0e=Object[_0x286668(0x208)](_0x4a09ce,_0x11c440):_0x517b0e,_0x25f421;if(typeof Reflect===_0x286668(0x211)&&typeof Reflect[_0x286668(0x1e6)]==='function')_0x1b7315=Reflect[_0x286668(0x1e6)](_0x80c880,_0x4a09ce,_0x11c440,_0x517b0e);else{for(var _0x38a597=_0x80c880[_0x286668(0x216)]-0x1;_0x38a597>=0x0;_0x38a597--)if(_0x25f421=_0x80c880[_0x38a597])_0x1b7315=(_0x58af1c<0x3?_0x25f421(_0x1b7315):_0x58af1c>0x3?_0x25f421(_0x4a09ce,_0x11c440,_0x1b7315):_0x25f421(_0x4a09ce,_0x11c440))||_0x1b7315;}return _0x58af1c>0x3&&_0x1b7315&&Object['defineProperty'](_0x4a09ce,_0x11c440,_0x1b7315),_0x1b7315;},__metadata=this&&this[a9_0x28999e(0x21b)]||function(_0x9a19f9,_0x4ba811){const _0x23f713=a9_0x28999e;if(typeof Reflect===_0x23f713(0x211)&&typeof Reflect['metadata']===_0x23f713(0x212))return Reflect['metadata'](_0x9a19f9,_0x4ba811);};Object[a9_0x28999e(0x1fe)](exports,'__esModule',{'value':!![]}),exports[a9_0x28999e(0x1f2)]=void 0x0;function a9_0xd573(){const _0x4a6ba9=['823956ftCFpM','message','assign','20UyBKIS','prototype','i18nConfig','toString','RULES_KEY','validationOptions','defineProperty','format','8765190VcXUJn','ValidatorError','4585110TrstbO','validator','messages','569FkPVWy','language','type','getOwnPropertyDescriptor','YYYY-MM-DD\x20HH:mm:ss','errors','date','3362058wFOgKo','Init','$_terms','getSchema','init','object','function','10193148bDhxYE','(((.+)+)+)+$','validate','length','fromEntries','__decorate','@midwayjs/core','keys','__metadata','../interface','getClassExtendedMetadata','8813728hmhzbY','PARAMS','参数验证失败','../exception/ValidatorError','design:paramtypes','getAvailableLocale','forEach','search','design:type','3402IlqAoh','details','i18n','i18nService','6heLJRb','decorate','Config','ScopeEnum','error','key','locale','NOFIND_SCHEMA','validatorConfig','apply','value','formatLocale','defaultLocale','ValidatorService','MidwayI18nServiceSingleton','schema'];a9_0xd573=function(){return _0x4a6ba9;};return a9_0xd573();}const Joi=require('joi'),i18n_1=require('@midwayjs/i18n'),core_1=require(a9_0x28999e(0x219)),interface_1=require(a9_0x28999e(0x21c)),ValidatorError_1=require(a9_0x28999e(0x1db));let ValidatorService=class ValidatorService{constructor(){const _0xfa7e08=a9_0x28999e;this[_0xfa7e08(0x204)]={};}async[a9_0x28999e(0x210)](){const _0x22a75b=a9_0x28999e,_0x198851=Object[_0x22a75b(0x21a)](this['i18nConfig']['localeTable']);_0x198851[_0x22a75b(0x1de)](_0x6e0af8=>{const _0x156c03=_0x22a75b;this[_0x156c03(0x204)][(0x0,i18n_1[_0x156c03(0x1f0)])(_0x6e0af8)]=Object[_0x156c03(0x217)](this[_0x156c03(0x1e4)]['getLocaleMapping'](_0x6e0af8,'validator'));});}[a9_0x28999e(0x20f)](_0x19e314){const _0x5153bf=a9_0x28999e,_0x3e2139=(0x0,core_1[_0x5153bf(0x21d)])(interface_1[_0x5153bf(0x1fc)],_0x19e314);return _0x3e2139?Joi['object'](_0x3e2139):undefined;}[a9_0x28999e(0x203)](_0xca55e,_0x3ed381,_0x353d91={}){const _0x3c8791=a9_0x28999e;var _0x4f6b98,_0x319486,_0x3dbf94,_0x577ffb,_0x5e5db3,_0x4ffa1e;const _0xb4f1bf=Joi['isSchema'](_0xca55e)?_0xca55e:this[_0x3c8791(0x20f)](_0xca55e);if(!_0xb4f1bf)throw new AnnError(ValidatorError_1[_0x3c8791(0x201)][_0x3c8791(0x1ec)]);_0x353d91[_0x3c8791(0x1fd)]=Object[_0x3c8791(0x1f7)]((_0x4f6b98=this[_0x3c8791(0x1ed)][_0x3c8791(0x1fd)])!==null&&_0x4f6b98!==void 0x0?_0x4f6b98:{},{'messages':this[_0x3c8791(0x204)]},_0x353d91[_0x3c8791(0x1fd)]||{}),_0x353d91[_0x3c8791(0x1fd)][_0x3c8791(0x20a)]=_0x353d91[_0x3c8791(0x1fd)]['errors']||{},_0x353d91[_0x3c8791(0x1fd)]['errors']['language']=(0x0,i18n_1['formatLocale'])(this['i18nService'][_0x3c8791(0x1dd)](_0x353d91['validationOptions'][_0x3c8791(0x20a)][_0x3c8791(0x206)]||_0x353d91[_0x3c8791(0x1eb)]||this['i18nConfig'][_0x3c8791(0x1f1)],_0x3c8791(0x203)));const _0x93084=_0xb4f1bf[_0x3c8791(0x215)](_0x3ed381,_0x353d91[_0x3c8791(0x1fd)]);if(_0x93084===null||_0x93084===void 0x0?void 0x0:_0x93084[_0x3c8791(0x1e9)]){if(_0x93084[_0x3c8791(0x1e9)]instanceof AnnError)throw _0x93084[_0x3c8791(0x1e9)];else{if(_0x93084['error']instanceof Error)throw new AnnError(ValidatorError_1[_0x3c8791(0x201)][_0x3c8791(0x1d9)],{'message':((_0x319486=_0x93084[_0x3c8791(0x1e9)])===null||_0x319486===void 0x0?void 0x0:_0x319486[_0x3c8791(0x1f6)])||_0x3c8791(0x1da)});else throw new AnnError(ValidatorError_1['ValidatorError'][_0x3c8791(0x1d9)],{'message':((_0x5e5db3=(_0x577ffb=(_0x3dbf94=_0x93084[_0x3c8791(0x1e9)])===null||_0x3dbf94===void 0x0?void 0x0:_0x3dbf94[_0x3c8791(0x1e2)])===null||_0x577ffb===void 0x0?void 0x0:_0x577ffb[0x0])===null||_0x5e5db3===void 0x0?void 0x0:_0x5e5db3[_0x3c8791(0x1f6)])||'参数验证失败'});}}if(_0x93084===null||_0x93084===void 0x0?void 0x0:_0x93084[_0x3c8791(0x1ef)]){const _0x12e099=(_0x4ffa1e=_0xb4f1bf===null||_0xb4f1bf===void 0x0?void 0x0:_0xb4f1bf['$_terms'])===null||_0x4ffa1e===void 0x0?void 0x0:_0x4ffa1e['keys'],_0x13250a=function(_0x6d0400,_0x53f015){const _0x2af343=_0x3c8791;var _0x27b681,_0x5f3898,_0x483e71,_0x326905,_0x1a84f6,_0x152923,_0x381c73,_0x581326,_0x58b136,_0x129b6f,_0x5458f2;for(let _0x266824 in _0x6d0400){if(_0x53f015[(_0x27b681=_0x6d0400[_0x266824])===null||_0x27b681===void 0x0?void 0x0:_0x27b681[_0x2af343(0x1ea)]]&&((_0x483e71=(_0x5f3898=_0x6d0400[_0x266824])===null||_0x5f3898===void 0x0?void 0x0:_0x5f3898[_0x2af343(0x1f4)])===null||_0x483e71===void 0x0?void 0x0:_0x483e71[_0x2af343(0x207)])){if(((_0x1a84f6=(_0x326905=_0x6d0400[_0x266824])===null||_0x326905===void 0x0?void 0x0:_0x326905[_0x2af343(0x1f4)])===null||_0x1a84f6===void 0x0?void 0x0:_0x1a84f6[_0x2af343(0x207)])=='object')_0x53f015[_0x6d0400[_0x266824]['key']]=_0x13250a((_0x381c73=(_0x152923=_0x6d0400[_0x266824])===null||_0x152923===void 0x0?void 0x0:_0x152923[_0x2af343(0x1f4)][_0x2af343(0x20e)])===null||_0x381c73===void 0x0?void 0x0:_0x381c73['keys'],_0x53f015[_0x6d0400[_0x266824][_0x2af343(0x1ea)]]);else{if(_0x6d0400[_0x266824]['schema']['type']==_0x2af343(0x20b)&&_0x93084[_0x2af343(0x1ef)][(_0x581326=_0x6d0400[_0x266824])===null||_0x581326===void 0x0?void 0x0:_0x581326[_0x2af343(0x1ea)]]){const _0x3392c8=((_0x5458f2=(_0x129b6f=(_0x58b136=_0x6d0400[_0x266824])===null||_0x58b136===void 0x0?void 0x0:_0x58b136[_0x2af343(0x1f4)])===null||_0x129b6f===void 0x0?void 0x0:_0x129b6f['_flags'])===null||_0x5458f2===void 0x0?void 0x0:_0x5458f2[_0x2af343(0x1ff)])||_0x2af343(0x209);_0x53f015[_0x6d0400[_0x266824]['key']]=dayjs(_0x93084[_0x2af343(0x1ef)][_0x6d0400[_0x266824][_0x2af343(0x1ea)]])[_0x2af343(0x1ff)](_0x3392c8);}}}}return _0x53f015;};return _0x13250a(_0x12e099,_0x93084[_0x3c8791(0x1ef)]);}throw new AnnError(ValidatorError_1['ValidatorError'][_0x3c8791(0x1d9)]);}};function a9_0x4810(_0x373386,_0x1a8ab1){const _0x1ff9c4=a9_0xd573();return a9_0x4810=function(_0x4f0d7a,_0x2b247d){_0x4f0d7a=_0x4f0d7a-0x1d8;let _0xd573ee=_0x1ff9c4[_0x4f0d7a];return _0xd573ee;},a9_0x4810(_0x373386,_0x1a8ab1);}exports[a9_0x28999e(0x1f2)]=ValidatorService,__decorate([(0x0,core_1['Config'])(a9_0x28999e(0x1e3)),__metadata('design:type',Object)],ValidatorService['prototype'],a9_0x28999e(0x1fa),void 0x0),__decorate([(0x0,core_1[a9_0x28999e(0x1e7)])('validator'),__metadata(a9_0x28999e(0x1e0),Object)],ValidatorService['prototype'],a9_0x28999e(0x1ed),void 0x0),__decorate([(0x0,core_1['Inject'])(),__metadata(a9_0x28999e(0x1e0),i18n_1[a9_0x28999e(0x1f3)])],ValidatorService['prototype'],a9_0x28999e(0x1e4),void 0x0),__decorate([(0x0,core_1[a9_0x28999e(0x20d)])(),__metadata(a9_0x28999e(0x1e0),Function),__metadata(a9_0x28999e(0x1dc),[]),__metadata('design:returntype',Promise)],ValidatorService[a9_0x28999e(0x1f9)],a9_0x28999e(0x210),null),exports['ValidatorService']=ValidatorService=__decorate([(0x0,core_1['Provide'])(a9_0x28999e(0x203)),(0x0,core_1['Scope'])(core_1[a9_0x28999e(0x1e8)]['Singleton'])],ValidatorService);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anncic-api/validator",
|
|
3
|
-
"version": "3.7.
|
|
3
|
+
"version": "3.7.4",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"typings": "index.d.ts",
|
|
6
6
|
"license": "MIT",
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"build": "tsc && javascript-obfuscator ./dist --output ./dist --config obfuscator.json"
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@anncic-api/core": "^3.7.
|
|
21
|
+
"@anncic-api/core": "^3.7.4",
|
|
22
22
|
"@joi/date": "^2.1.0",
|
|
23
23
|
"joi": "^17.11.0"
|
|
24
24
|
},
|
|
@@ -27,5 +27,5 @@
|
|
|
27
27
|
"javascript-obfuscator": "^4.0.2",
|
|
28
28
|
"typescript": "^5.5.4"
|
|
29
29
|
},
|
|
30
|
-
"gitHead": "
|
|
30
|
+
"gitHead": "d30ac0ec86b6e84d976377804ade361ce8ba63d5"
|
|
31
31
|
}
|