@anncic-api/validator 2.0.6 → 2.0.7
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/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
|
-
function
|
|
1
|
+
const a0_0x3bf3f4=a0_0x4296;function a0_0x2e91(){const _0x22b4a2=['ValidatorError','__esModule','8172864IUubXF','(((.+)+)+)+$','default','defineProperty','14EgMOQE','3496024aRkkBn','apply','937492TCdfud','35mjVXTr','../exception/ValidatorError','21517680uYEuAr','search','PARAMS','24561pOzZdf','1312DcERkJ','1597252fItCKr','constructor','toString','775473IiIrKL','../../locales/zh_CN.json'];a0_0x2e91=function(){return _0x22b4a2;};return a0_0x2e91();}(function(_0x17faf1,_0x3a1cc8){const _0x1435a1=a0_0x4296,_0x3dfe35=_0x17faf1();while(!![]){try{const _0x514ede=parseInt(_0x1435a1(0xd3))/0x1+parseInt(_0x1435a1(0xde))/0x2*(parseInt(_0x1435a1(0xd6))/0x3)+parseInt(_0x1435a1(0xe1))/0x4*(-parseInt(_0x1435a1(0xe2))/0x5)+parseInt(_0x1435a1(0xda))/0x6+-parseInt(_0x1435a1(0xdf))/0x7+-parseInt(_0x1435a1(0xe8))/0x8*(-parseInt(_0x1435a1(0xe7))/0x9)+-parseInt(_0x1435a1(0xe4))/0xa;if(_0x514ede===_0x3a1cc8)break;else _0x3dfe35['push'](_0x3dfe35['shift']());}catch(_0x5f2010){_0x3dfe35['push'](_0x3dfe35['shift']());}}}(a0_0x2e91,0xe1ba2));function a0_0x4296(_0x246399,_0x41e39e){const _0x569a47=a0_0x2e91();return a0_0x4296=function(_0x3ee634,_0x2c8c51){_0x3ee634=_0x3ee634-0xd3;let _0x2e91c5=_0x569a47[_0x3ee634];return _0x2e91c5;},a0_0x4296(_0x246399,_0x41e39e);}const a0_0x2c8c51=(function(){let _0x3c7e94=!![];return function(_0x207cc2,_0x5a1920){const _0x581aee=_0x3c7e94?function(){const _0x3792dd=a0_0x4296;if(_0x5a1920){const _0x296cca=_0x5a1920[_0x3792dd(0xe0)](_0x207cc2,arguments);return _0x5a1920=null,_0x296cca;}}:function(){};return _0x3c7e94=![],_0x581aee;};}()),a0_0x3ee634=a0_0x2c8c51(this,function(){const _0x1e4202=a0_0x4296;return a0_0x3ee634[_0x1e4202(0xd5)]()['search'](_0x1e4202(0xdb))['toString']()[_0x1e4202(0xd4)](a0_0x3ee634)[_0x1e4202(0xe5)](_0x1e4202(0xdb));});a0_0x3ee634();'use strict';Object[a0_0x3bf3f4(0xdd)](exports,a0_0x3bf3f4(0xd9),{'value':!![]});const ValidatorError_1=require(a0_0x3bf3f4(0xe3));exports[a0_0x3bf3f4(0xdc)]={'validator':{'errorStatus':ValidatorError_1[a0_0x3bf3f4(0xd8)][a0_0x3bf3f4(0xe6)],'validationOptions':{'allowUnknown':!![],'stripUnknown':!![],'dateFormat':'string'}},'i18n':{'localeTable':{'en_US':{'validator':require('../../locales/en_US.json')},'zh_CN':{'validator':require(a0_0x3bf3f4(0xd7))}}}};
|
package/dist/configuration.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a1_0x1d14(_0x37c6b6,_0x1a6434){const _0x5458ec=a1_0x55af();return a1_0x1d14=function(_0x1bdb0b,_0x564b10){_0x1bdb0b=_0x1bdb0b-0x19b;let _0x55aff3=_0x5458ec[_0x1bdb0b];return _0x55aff3;},a1_0x1d14(_0x37c6b6,_0x1a6434);}const a1_0x17e6dc=a1_0x1d14;(function(_0x141e66,_0x3c5eed){const _0x108311=a1_0x1d14,_0x325dd2=_0x141e66();while(!![]){try{const _0x572309=parseInt(_0x108311(0x1d6))/0x1+parseInt(_0x108311(0x1c0))/0x2*(parseInt(_0x108311(0x1c3))/0x3)+parseInt(_0x108311(0x1a5))/0x4*(parseInt(_0x108311(0x1bc))/0x5)+parseInt(_0x108311(0x1b7))/0x6*(-parseInt(_0x108311(0x1d4))/0x7)+-parseInt(_0x108311(0x1ae))/0x8+-parseInt(_0x108311(0x1b1))/0x9*(parseInt(_0x108311(0x1ca))/0xa)+parseInt(_0x108311(0x1ba))/0xb;if(_0x572309===_0x3c5eed)break;else _0x325dd2['push'](_0x325dd2['shift']());}catch(_0x1ed63e){_0x325dd2['push'](_0x325dd2['shift']());}}}(a1_0x55af,0x3f8dd));const a1_0x564b10=(function(){let _0x4ff210=!![];return function(_0x145abc,_0x21a71e){const _0x5b6722=_0x4ff210?function(){const _0x38f653=a1_0x1d14;if(_0x21a71e){const _0x3addb2=_0x21a71e[_0x38f653(0x1a1)](_0x145abc,arguments);return _0x21a71e=null,_0x3addb2;}}:function(){};return _0x4ff210=![],_0x5b6722;};}()),a1_0x1bdb0b=a1_0x564b10(this,function(){const _0x5b5533=a1_0x1d14;return a1_0x1bdb0b['toString']()['search'](_0x5b5533(0x19e))['toString']()[_0x5b5533(0x19c)](a1_0x1bdb0b)[_0x5b5533(0x1ce)](_0x5b5533(0x19e));});function a1_0x55af(){const _0x3cb8f5=['validator','find','prototype','target','metadata','ValidatorService','getAttr','1450568oitDld','decorate','CustomConfiguration','3717wfnXDG','__decorate','bound\x20dispatch','method','function','length','96dMzvEr','locale','./interface','49841LEkrsu','res','13255IcsVYh','getOwnPropertyDescriptor','@midwayjs/core','decorator','16ZbMbrx','req','Configuration','143130gPCQGu','MidwayDecoratorService','name','registerMethodHandler','body','params','__metadata','6650WxoqPh','getClassMetadata','I18N_ATTR_KEY','splice','search','methodArgs','getMethodParamTypes','object','@anncic-api/core','request','99393wzBrOK','Inject','284203bTttdb','defineProperty','REQUEST_OBJ_CTX_KEY','@midwayjs/i18n','constructor','args','(((.+)+)+)+$','undefined','design:type','apply','getSchema','query','methodName','412kZuZpP','__esModule'];a1_0x55af=function(){return _0x3cb8f5;};return a1_0x55af();}a1_0x1bdb0b();'use strict';var __decorate=this&&this[a1_0x17e6dc(0x1b2)]||function(_0x446b62,_0x24821e,_0x15d289,_0x904643){const _0x4fc81d=a1_0x17e6dc;var _0x5660ea=arguments[_0x4fc81d(0x1b6)],_0x39c1ae=_0x5660ea<0x3?_0x24821e:_0x904643===null?_0x904643=Object[_0x4fc81d(0x1bd)](_0x24821e,_0x15d289):_0x904643,_0xf6f218;if(typeof Reflect===_0x4fc81d(0x1d1)&&typeof Reflect[_0x4fc81d(0x1af)]==='function')_0x39c1ae=Reflect[_0x4fc81d(0x1af)](_0x446b62,_0x24821e,_0x15d289,_0x904643);else{for(var _0x5040bf=_0x446b62[_0x4fc81d(0x1b6)]-0x1;_0x5040bf>=0x0;_0x5040bf--)if(_0xf6f218=_0x446b62[_0x5040bf])_0x39c1ae=(_0x5660ea<0x3?_0xf6f218(_0x39c1ae):_0x5660ea>0x3?_0xf6f218(_0x24821e,_0x15d289,_0x39c1ae):_0xf6f218(_0x24821e,_0x15d289))||_0x39c1ae;}return _0x5660ea>0x3&&_0x39c1ae&&Object['defineProperty'](_0x24821e,_0x15d289,_0x39c1ae),_0x39c1ae;},__metadata=this&&this[a1_0x17e6dc(0x1c9)]||function(_0x442cab,_0xf66d1e){const _0x38a6d0=a1_0x17e6dc;if(typeof Reflect===_0x38a6d0(0x1d1)&&typeof Reflect[_0x38a6d0(0x1ab)]===_0x38a6d0(0x1b5))return Reflect[_0x38a6d0(0x1ab)](_0x442cab,_0xf66d1e);};Object[a1_0x17e6dc(0x1d7)](exports,a1_0x17e6dc(0x1a6),{'value':!![]}),exports[a1_0x17e6dc(0x1b0)]=void 0x0;const i18n_1=require(a1_0x17e6dc(0x19b)),core_1=require(a1_0x17e6dc(0x1be)),core_2=require(a1_0x17e6dc(0x1be)),interface_1=require(a1_0x17e6dc(0x1b9)),ValidatorService_1=require('./service/ValidatorService'),i18n=require(a1_0x17e6dc(0x19b)),anncic=require(a1_0x17e6dc(0x1d2)),ConfigDefault=require('./config/config.default');let CustomConfiguration=class CustomConfiguration{async['onReady'](){const _0x2a2a5f=a1_0x17e6dc;this['decorator'][_0x2a2a5f(0x1c6)](interface_1['VALIDATOR_KEY'],_0x3595c2=>{const _0x3beb55=_0x2a2a5f,_0x4968b6=_0x3595c2[_0x3beb55(0x1ab)],_0x370ce3=(0x0,core_2[_0x3beb55(0x1d0)])(_0x3595c2[_0x3beb55(0x1aa)],_0x3595c2['propertyName']);return{'before':_0x5d14f4=>{const _0x306f96=_0x3beb55;var _0x2550e5,_0x2c890e,_0x519649,_0x4269a5,_0x47a26a,_0x1aa890,_0x10d299,_0x4b85f1,_0x44ce76,_0x43be13,_0x2d4e36,_0x16d7f5,_0x1b7f06;const _0x389bf9=_0x5d14f4['target'][core_1[_0x306f96(0x1d8)]],_0x33e4d9=Object['assign']({},((_0x2550e5=_0x389bf9===null||_0x389bf9===void 0x0?void 0x0:_0x389bf9[_0x306f96(0x1d3)])===null||_0x2550e5===void 0x0?void 0x0:_0x2550e5[_0x306f96(0x1a3)])||{},((_0x2c890e=_0x389bf9===null||_0x389bf9===void 0x0?void 0x0:_0x389bf9[_0x306f96(0x1d3)])===null||_0x2c890e===void 0x0?void 0x0:_0x2c890e[_0x306f96(0x1c7)])||{}),_0x152f77=((0x0,core_2[_0x306f96(0x1cb)])(interface_1['VALIDATOR_KEY'],_0x5d14f4[_0x306f96(0x1aa)])||[])[_0x306f96(0x1a8)](_0x38a21c=>_0x38a21c[_0x306f96(0x1b4)]==_0x5d14f4[_0x306f96(0x1a4)]);!(_0x4968b6===null||_0x4968b6===void 0x0?void 0x0:_0x4968b6[_0x306f96(0x1b8)])&&_0x389bf9&&_0x389bf9[_0x306f96(0x1ad)]&&(_0x4968b6[_0x306f96(0x1b8)]=_0x389bf9[_0x306f96(0x1ad)](i18n_1[_0x306f96(0x1cc)]));for(let _0x264f44=0x0;_0x264f44<_0x370ce3[_0x306f96(0x1b6)];_0x264f44++){const _0x1536c9=_0x370ce3[_0x264f44],_0x3b8dac=this[_0x306f96(0x1ac)][_0x306f96(0x1a2)](_0x1536c9);if(_0x3b8dac){if(typeof _0x5d14f4['args'][_0x264f44]==_0x306f96(0x19f)||((_0x519649=_0x5d14f4[_0x306f96(0x19d)][_0x264f44])===null||_0x519649===void 0x0?void 0x0:_0x519649['request'])&&((_0x4269a5=_0x5d14f4[_0x306f96(0x19d)][_0x264f44])===null||_0x4269a5===void 0x0?void 0x0:_0x4269a5[_0x306f96(0x1bb)])&&((_0x47a26a=_0x5d14f4[_0x306f96(0x19d)][_0x264f44])===null||_0x47a26a===void 0x0?void 0x0:_0x47a26a[_0x306f96(0x1c1)]))_0x5d14f4[_0x306f96(0x19d)][_0x264f44]=_0x33e4d9;else((_0x1aa890=_0x5d14f4[_0x306f96(0x19d)][_0x264f44])===null||_0x1aa890===void 0x0?void 0x0:_0x1aa890[_0x306f96(0x1c5)])==_0x306f96(0x1b3)&&_0x5d14f4[_0x306f96(0x19d)][_0x306f96(0x1cd)](_0x264f44,0x0,_0x33e4d9);const _0x3d3ebf=this[_0x306f96(0x1ac)][_0x306f96(0x1a7)](_0x3b8dac,_0x5d14f4[_0x306f96(0x19d)][_0x264f44],_0x4968b6);_0x3d3ebf&&(_0x5d14f4[_0x306f96(0x19d)][_0x264f44]=_0x3d3ebf);}else{if((_0x152f77===null||_0x152f77===void 0x0?void 0x0:_0x152f77[_0x306f96(0x1cf)][_0x264f44])&&((_0x10d299=_0x5d14f4[_0x306f96(0x19d)][_0x264f44])===null||_0x10d299===void 0x0?void 0x0:_0x10d299[_0x306f96(0x1c8)])&&typeof _0x5d14f4['args'][_0x264f44]['param']==_0x306f96(0x1b5)&&((_0x4b85f1=_0x389bf9===null||_0x389bf9===void 0x0?void 0x0:_0x389bf9[_0x306f96(0x1c8)])===null||_0x4b85f1===void 0x0?void 0x0:_0x4b85f1[_0x152f77['methodArgs'][_0x264f44]]))_0x5d14f4[_0x306f96(0x19d)][_0x264f44]=_0x1536c9((_0x44ce76=_0x389bf9===null||_0x389bf9===void 0x0?void 0x0:_0x389bf9[_0x306f96(0x1c8)])===null||_0x44ce76===void 0x0?void 0x0:_0x44ce76[_0x152f77[_0x306f96(0x1cf)][_0x264f44]]);else(_0x152f77===null||_0x152f77===void 0x0?void 0x0:_0x152f77[_0x306f96(0x1cf)][_0x264f44])&&((_0x2d4e36=(_0x43be13=_0x5d14f4[_0x306f96(0x19d)][_0x264f44])===null||_0x43be13===void 0x0?void 0x0:_0x43be13[_0x306f96(0x1c8)])===null||_0x2d4e36===void 0x0?void 0x0:_0x2d4e36[_0x152f77[_0x306f96(0x1cf)][_0x264f44]])&&(_0x5d14f4['args'][_0x264f44]=(_0x1b7f06=(_0x16d7f5=_0x5d14f4[_0x306f96(0x19d)][_0x264f44])===null||_0x16d7f5===void 0x0?void 0x0:_0x16d7f5['params'])===null||_0x1b7f06===void 0x0?void 0x0:_0x1b7f06[_0x152f77[_0x306f96(0x1cf)][_0x264f44]]);}}},'afterThrow':(_0xee0846,_0x5bd71c)=>{throw _0x5bd71c;}};});}};__decorate([(0x0,core_2['Inject'])(),__metadata(a1_0x17e6dc(0x1a0),core_1[a1_0x17e6dc(0x1c4)])],CustomConfiguration[a1_0x17e6dc(0x1a9)],a1_0x17e6dc(0x1bf),void 0x0),__decorate([(0x0,core_2[a1_0x17e6dc(0x1d5)])(),__metadata(a1_0x17e6dc(0x1a0),ValidatorService_1['ValidatorService'])],CustomConfiguration[a1_0x17e6dc(0x1a9)],'ValidatorService',void 0x0),CustomConfiguration=__decorate([(0x0,core_2[a1_0x17e6dc(0x1c2)])({'conflictCheck':![],'imports':[i18n,anncic],'namespace':'anncic-api:validator','importConfigs':[{'default':ConfigDefault}]})],CustomConfiguration),exports['CustomConfiguration']=CustomConfiguration;
|
package/dist/decorator/Rule.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a2_0x1eb805=a2_0x3773;function a2_0xa428(){const _0x36fe81=['isSchema','attachClassMetadata','@midwayjs/core','meta','624678KEKDxd','getPropertyType','array','function','7240NCbTyn','defineProperty','(((.+)+)+)+$','joi','Rule','items','25398981yDjGju','object','1393MxQFRp','5464ovkkZV','RuleType','RULES_KEY','Array','search','name','extend','label','4009675zJXBUD','constructor','831BKJOBt','__esModule','4771596QOMqod','map','description','default','getClassMetadata','saveClassMetadata','1458147kHuASo','toString','../interface','keys'];a2_0xa428=function(){return _0x36fe81;};return a2_0xa428();}function a2_0x3773(_0x1d50d8,_0x4055a5){const _0x22ae7a=a2_0xa428();return a2_0x3773=function(_0x11a478,_0x1ad37a){_0x11a478=_0x11a478-0xc1;let _0xa428d5=_0x22ae7a[_0x11a478];return _0xa428d5;},a2_0x3773(_0x1d50d8,_0x4055a5);}(function(_0x209499,_0x455337){const _0x5edb15=a2_0x3773,_0x3b23cc=_0x209499();while(!![]){try{const _0x5c92d8=-parseInt(_0x5edb15(0xe2))/0x1+-parseInt(_0x5edb15(0xc3))/0x2+-parseInt(_0x5edb15(0xda))/0x3*(parseInt(_0x5edb15(0xd0))/0x4)+-parseInt(_0x5edb15(0xd8))/0x5+parseInt(_0x5edb15(0xdc))/0x6+parseInt(_0x5edb15(0xcf))/0x7*(parseInt(_0x5edb15(0xc7))/0x8)+parseInt(_0x5edb15(0xcd))/0x9;if(_0x5c92d8===_0x455337)break;else _0x3b23cc['push'](_0x3b23cc['shift']());}catch(_0x161af4){_0x3b23cc['push'](_0x3b23cc['shift']());}}}(a2_0xa428,0xceb4b));const a2_0x1ad37a=(function(){let _0x229b69=!![];return function(_0x154558,_0x55ef7e){const _0x2ddeb1=_0x229b69?function(){if(_0x55ef7e){const _0x3f4199=_0x55ef7e['apply'](_0x154558,arguments);return _0x55ef7e=null,_0x3f4199;}}:function(){};return _0x229b69=![],_0x2ddeb1;};}()),a2_0x11a478=a2_0x1ad37a(this,function(){const _0x3e74e8=a2_0x3773;return a2_0x11a478[_0x3e74e8(0xe3)]()[_0x3e74e8(0xd4)](_0x3e74e8(0xc9))['toString']()[_0x3e74e8(0xd9)](a2_0x11a478)[_0x3e74e8(0xd4)]('(((.+)+)+)+$');});a2_0x11a478();'use strict';Object[a2_0x1eb805(0xc8)](exports,a2_0x1eb805(0xdb),{'value':!![]}),exports[a2_0x1eb805(0xcb)]=exports[a2_0x1eb805(0xd1)]=void 0x0;const joi=require(a2_0x1eb805(0xca)),date_1=require('@joi/date'),core_1=require(a2_0x1eb805(0xc1)),interface_1=require(a2_0x1eb805(0xe4));exports[a2_0x1eb805(0xd1)]=joi[a2_0x1eb805(0xd6)](date_1[a2_0x1eb805(0xdf)]);function Rule(_0x4f5778,_0xa9b1fb,_0x29ed61=''){return(_0xb51c4f,_0x2746a4)=>{const _0x29933d=a2_0x3773;var _0x3a14c9;if(_0x2746a4)!joi[_0x29933d(0xe6)](_0xa9b1fb)&&(_0xa9b1fb===null||_0xa9b1fb===void 0x0?void 0x0:_0xa9b1fb[_0x29933d(0xd5)])&&(_0xa9b1fb=joi[_0x29933d(0xce)]((0x0,core_1[_0x29933d(0xe0)])(interface_1[_0x29933d(0xd2)],_0xa9b1fb))[_0x29933d(0xc2)]({'id':_0xa9b1fb[_0x29933d(0xd5)]}),(0x0,core_1[_0x29933d(0xc4)])(_0xb51c4f,_0x2746a4)[_0x29933d(0xd5)]===_0x29933d(0xd3)&&(_0xa9b1fb=joi[_0x29933d(0xc5)]()[_0x29933d(0xcc)](_0xa9b1fb))),joi[_0x29933d(0xe6)](_0xa9b1fb)&&(_0x4f5778&&typeof(_0xa9b1fb===null||_0xa9b1fb===void 0x0?void 0x0:_0xa9b1fb[_0x29933d(0xd7)])==_0x29933d(0xc6)&&(_0xa9b1fb=_0xa9b1fb[_0x29933d(0xd7)](_0x4f5778)),_0x29ed61&&typeof(_0xa9b1fb===null||_0xa9b1fb===void 0x0?void 0x0:_0xa9b1fb[_0x29933d(0xde)])==_0x29933d(0xc6)&&(_0xa9b1fb=_0xa9b1fb['description'](_0x29ed61)),(0x0,core_1[_0x29933d(0xe7)])(interface_1['RULES_KEY'],_0xa9b1fb,_0xb51c4f,_0x2746a4));else{const _0x4cf2c9=(0x0,core_1[_0x29933d(0xe0)])(interface_1[_0x29933d(0xd2)],_0xa9b1fb);if(_0x4cf2c9){let _0x4bbaa4=(_0x3a14c9=(0x0,core_1[_0x29933d(0xe0)])(interface_1['RULES_KEY'],_0xb51c4f))!==null&&_0x3a14c9!==void 0x0?_0x3a14c9:{};Object[_0x29933d(0xe5)](_0x4cf2c9)[_0x29933d(0xdd)](_0x3de0c1=>{!_0x4bbaa4[_0x3de0c1]&&(_0x4bbaa4[_0x3de0c1]=_0x4cf2c9[_0x3de0c1]);}),(0x0,core_1[_0x29933d(0xe1)])(interface_1['RULES_KEY'],_0x4bbaa4,_0xb51c4f);}}};}exports[a2_0x1eb805(0xcb)]=Rule;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a3_0x8e943a=a3_0x16ad;(function(_0x221128,_0x3262d0){const _0x2fb6d7=a3_0x16ad,_0x190ddd=_0x221128();while(!![]){try{const _0xca1c93=parseInt(_0x2fb6d7(0xf1))/0x1*(-parseInt(_0x2fb6d7(0xe4))/0x2)+parseInt(_0x2fb6d7(0xf0))/0x3*(-parseInt(_0x2fb6d7(0xf8))/0x4)+parseInt(_0x2fb6d7(0xf5))/0x5+-parseInt(_0x2fb6d7(0xfa))/0x6*(parseInt(_0x2fb6d7(0xff))/0x7)+-parseInt(_0x2fb6d7(0xee))/0x8+-parseInt(_0x2fb6d7(0xe8))/0x9*(parseInt(_0x2fb6d7(0xfe))/0xa)+parseInt(_0x2fb6d7(0xeb))/0xb*(parseInt(_0x2fb6d7(0xf3))/0xc);if(_0xca1c93===_0x3262d0)break;else _0x190ddd['push'](_0x190ddd['shift']());}catch(_0xcaab36){_0x190ddd['push'](_0x190ddd['shift']());}}}(a3_0x401c,0xa5e94));const a3_0x277789=(function(){let _0x1e9722=!![];return function(_0x364928,_0x9114d5){const _0x488ba2=_0x1e9722?function(){const _0x5be83e=a3_0x16ad;if(_0x9114d5){const _0x172c95=_0x9114d5[_0x5be83e(0xe7)](_0x364928,arguments);return _0x9114d5=null,_0x172c95;}}:function(){};return _0x1e9722=![],_0x488ba2;};}()),a3_0x45c5ad=a3_0x277789(this,function(){const _0x3fa159=a3_0x16ad;return a3_0x45c5ad[_0x3fa159(0x103)]()[_0x3fa159(0xf9)]('(((.+)+)+)+$')['toString']()[_0x3fa159(0x100)](a3_0x45c5ad)[_0x3fa159(0xf9)](_0x3fa159(0xe6));});function a3_0x16ad(_0x36f8a4,_0xf165c){const _0x5beab4=a3_0x401c();return a3_0x16ad=function(_0x45c5ad,_0x277789){_0x45c5ad=_0x45c5ad-0xe4;let _0x401c81=_0x5beab4[_0x45c5ad];return _0x401c81;},a3_0x16ad(_0x36f8a4,_0xf165c);}a3_0x45c5ad();'use strict';Object[a3_0x8e943a(0xec)](exports,a3_0x8e943a(0xfd),{'value':!![]}),exports['getFuncArgs']=exports[a3_0x8e943a(0xf2)]=void 0x0;const core_1=require(a3_0x8e943a(0xfb)),interface_1=require(a3_0x8e943a(0xe9));function a3_0x401c(){const _0x64d9c0=['attachClassMetadata','3058272aJkWjf','slice','80127ybogtO','141IyVvuk','Validator','2076rMGItJ','prototype','3574510hhnMZu','indexOf','function','188hsKbGH','search','19188gMSBSw','@midwayjs/core','match','__esModule','1660PMJHLE','1036gRtNWb','constructor','createCustomMethodDecorator','VALIDATOR_KEY','toString','9302ovQDEe','getFuncArgs','(((.+)+)+)+$','apply','10071FaJsDU','../interface','replace','185482ghkFlv','defineProperty'];a3_0x401c=function(){return _0x64d9c0;};return a3_0x401c();}function Validator(_0xf89f30={}){return(_0x25c3e0,_0x388169,_0x22bd48)=>{const _0x4c1b00=a3_0x16ad,_0x2ad4f8=getFuncArgs(_0x25c3e0[_0x388169]);(0x0,core_1[_0x4c1b00(0xed)])(interface_1[_0x4c1b00(0x102)],{'method':_0x388169,'methodArgs':_0x2ad4f8},_0x25c3e0),(0x0,core_1[_0x4c1b00(0x101)])(interface_1[_0x4c1b00(0x102)],_0xf89f30)(_0x25c3e0,_0x388169,_0x22bd48);};}exports[a3_0x8e943a(0xf2)]=Validator;function getFuncArgs(_0x41d379){const _0x4ff242=a3_0x8e943a;if(typeof _0x41d379==_0x4ff242(0xf7)){const _0x21ee81=/=>.*$/mg,_0x5c494d=/=[^,)]+/mg,_0x2a33f0=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/mg,_0x234e66=(_0x41d379[_0x4ff242(0xf4)]?_0x41d379[_0x4ff242(0xf4)][_0x4ff242(0x100)]['toString']():_0x41d379['toString']())[_0x4ff242(0xea)](_0x2a33f0,'')[_0x4ff242(0xea)](_0x21ee81,'')['replace'](_0x5c494d,''),_0x50c113=_0x234e66[_0x4ff242(0xef)](_0x234e66[_0x4ff242(0xf6)]('(')+0x1,_0x234e66[_0x4ff242(0xf6)](')'))[_0x4ff242(0xfc)](/([^\s,]+)/g)||[];return _0x50c113;}}exports[a3_0x8e943a(0xe5)]=getFuncArgs;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a4_0x1641b1=a4_0x3902;(function(_0x42a279,_0x1afa0a){var _0x2891ea=a4_0x3902,_0x406539=_0x42a279();while(!![]){try{var _0x5de7fa=parseInt(_0x2891ea(0x117))/0x1+parseInt(_0x2891ea(0x11b))/0x2+-parseInt(_0x2891ea(0x10f))/0x3*(-parseInt(_0x2891ea(0x119))/0x4)+parseInt(_0x2891ea(0x108))/0x5*(parseInt(_0x2891ea(0x10c))/0x6)+-parseInt(_0x2891ea(0x11d))/0x7+-parseInt(_0x2891ea(0x11f))/0x8+parseInt(_0x2891ea(0x113))/0x9*(-parseInt(_0x2891ea(0x10b))/0xa);if(_0x5de7fa===_0x1afa0a)break;else _0x406539['push'](_0x406539['shift']());}catch(_0x3d853f){_0x406539['push'](_0x406539['shift']());}}}(a4_0x261e,0x57654));var a4_0x321dfa=(function(){var _0x1cf69b=!![];return function(_0x4829d6,_0x2dbb99){var _0x3e03d9=_0x1cf69b?function(){var _0x2fefc9=a4_0x3902;if(_0x2dbb99){var _0x1b6787=_0x2dbb99[_0x2fefc9(0x10e)](_0x4829d6,arguments);return _0x2dbb99=null,_0x1b6787;}}:function(){};return _0x1cf69b=![],_0x3e03d9;};}()),a4_0x310f29=a4_0x321dfa(this,function(){var _0x433fab=a4_0x3902;return a4_0x310f29[_0x433fab(0x109)]()['search'](_0x433fab(0x107))[_0x433fab(0x109)]()[_0x433fab(0x11e)](a4_0x310f29)[_0x433fab(0x10a)](_0x433fab(0x107));});function a4_0x3902(_0x5e7e19,_0x47d584){var _0x5e7249=a4_0x261e();return a4_0x3902=function(_0x310f29,_0x321dfa){_0x310f29=_0x310f29-0x106;var _0x261e81=_0x5e7249[_0x310f29];return _0x261e81;},a4_0x3902(_0x5e7e19,_0x47d584);}a4_0x310f29();'use strict';var __decorate=this&&this[a4_0x1641b1(0x106)]||function(_0x1cf3db,_0x288e40,_0x87433c,_0x216e03){var _0x1afddb=a4_0x1641b1,_0x2e8e60=arguments[_0x1afddb(0x11c)],_0x5081ef=_0x2e8e60<0x3?_0x288e40:_0x216e03===null?_0x216e03=Object['getOwnPropertyDescriptor'](_0x288e40,_0x87433c):_0x216e03,_0x52b531;if(typeof Reflect==='object'&&typeof Reflect[_0x1afddb(0x115)]===_0x1afddb(0x111))_0x5081ef=Reflect[_0x1afddb(0x115)](_0x1cf3db,_0x288e40,_0x87433c,_0x216e03);else{for(var _0x2e0de1=_0x1cf3db[_0x1afddb(0x11c)]-0x1;_0x2e0de1>=0x0;_0x2e0de1--)if(_0x52b531=_0x1cf3db[_0x2e0de1])_0x5081ef=(_0x2e8e60<0x3?_0x52b531(_0x5081ef):_0x2e8e60>0x3?_0x52b531(_0x288e40,_0x87433c,_0x5081ef):_0x52b531(_0x288e40,_0x87433c))||_0x5081ef;}return _0x2e8e60>0x3&&_0x5081ef&&Object['defineProperty'](_0x288e40,_0x87433c,_0x5081ef),_0x5081ef;},__metadata=this&&this[a4_0x1641b1(0x11a)]||function(_0x24badf,_0x4ed228){var _0x12248e=a4_0x1641b1;if(typeof Reflect===_0x12248e(0x110)&&typeof Reflect['metadata']==='function')return Reflect['metadata'](_0x24badf,_0x4ed228);};Object['defineProperty'](exports,a4_0x1641b1(0x118),{'value':!![]}),exports[a4_0x1641b1(0x116)]=void 0x0;const core_1=require('@anncic-api/core');function a4_0x261e(){var _0x497c88=['apply','218151oNiTbP','object','function','参数验证失败','9ebyLjv','NOFIND_SCHEMA','decorate','ValidatorError','622314aXTOMO','__esModule','28KJudHi','__metadata','591354BKiIlH','length','4948958iHyqkH','constructor','1979056UrMTZs','PARAMS','__decorate','(((.+)+)+)+$','175oJKGaH','toString','search','2928470NYPyfh','30546GYyCdf','AnnErrorMsg'];a4_0x261e=function(){return _0x497c88;};return a4_0x261e();}class ValidatorError extends AnnError{}ValidatorError['PARAMS']=0x18c1e,ValidatorError['NOFIND_SCHEMA']=0x18c1c,__decorate([(0x0,core_1[a4_0x1641b1(0x10d)])('参数验证失败'),__metadata('design:type',Object)],ValidatorError,a4_0x1641b1(0x120),void 0x0),__decorate([(0x0,core_1[a4_0x1641b1(0x10d)])(a4_0x1641b1(0x112)),__metadata('design:type',Object)],ValidatorError,a4_0x1641b1(0x114),void 0x0),exports['ValidatorError']=ValidatorError;
|
package/dist/helper/dtoHelper.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a5_0x5569(){const _0x4d0c79=['apply','../interface','__esModule','6obrITH','toString','151789NYVkrT','saveClassMetadata','(((.+)+)+)+$','prototype','820049Adnubr','1236550sRROml','1989284UKVwWb','OmitDto','getClassExtendedMetadata','352566hgoTXE','PickDto','5sXnXkx','1218IaRGBS','112jgwvvG','4188DQGvGn','2419529eZRzMT','constructor','RULES_KEY'];a5_0x5569=function(){return _0x4d0c79;};return a5_0x5569();}const a5_0x491424=a5_0x1606;(function(_0x3849fc,_0x3064a5){const _0x140843=a5_0x1606,_0xd6c5f=_0x3849fc();while(!![]){try{const _0x175a82=-parseInt(_0x140843(0xd9))/0x1+-parseInt(_0x140843(0xe1))/0x2*(-parseInt(_0x140843(0xe3))/0x3)+-parseInt(_0x140843(0xdb))/0x4*(-parseInt(_0x140843(0xe0))/0x5)+parseInt(_0x140843(0xd3))/0x6*(parseInt(_0x140843(0xe4))/0x7)+-parseInt(_0x140843(0xe2))/0x8*(parseInt(_0x140843(0xde))/0x9)+parseInt(_0x140843(0xda))/0xa+parseInt(_0x140843(0xd5))/0xb;if(_0x175a82===_0x3064a5)break;else _0xd6c5f['push'](_0xd6c5f['shift']());}catch(_0x3395fd){_0xd6c5f['push'](_0xd6c5f['shift']());}}}(a5_0x5569,0x70d15));const a5_0x1f3cb0=(function(){let _0x2b293d=!![];return function(_0x4d4153,_0x3aaec7){const _0x39e8d5=_0x2b293d?function(){const _0x2cca9b=a5_0x1606;if(_0x3aaec7){const _0x575b33=_0x3aaec7[_0x2cca9b(0xe7)](_0x4d4153,arguments);return _0x3aaec7=null,_0x575b33;}}:function(){};return _0x2b293d=![],_0x39e8d5;};}()),a5_0x6d19d6=a5_0x1f3cb0(this,function(){const _0x41e921=a5_0x1606;return a5_0x6d19d6['toString']()['search']('(((.+)+)+)+$')[_0x41e921(0xd4)]()[_0x41e921(0xe5)](a5_0x6d19d6)['search'](_0x41e921(0xd7));});a5_0x6d19d6();'use strict';function a5_0x1606(_0x5799a1,_0x399111){const _0x4bbbae=a5_0x5569();return a5_0x1606=function(_0x6d19d6,_0x1f3cb0){_0x6d19d6=_0x6d19d6-0xd3;let _0x556992=_0x4bbbae[_0x6d19d6];return _0x556992;},a5_0x1606(_0x5799a1,_0x399111);}Object['defineProperty'](exports,a5_0x491424(0xe9),{'value':!![]}),exports[a5_0x491424(0xdc)]=exports['PickDto']=void 0x0;const core_1=require('@midwayjs/core'),interface_1=require(a5_0x491424(0xe8));function PickDto(_0x44781d,_0x4526a0){const _0x4c984d=a5_0x491424,_0x43596e=function(){};_0x43596e['prototype']=_0x44781d[_0x4c984d(0xd8)];const _0x3ad380=(0x0,core_1[_0x4c984d(0xdd)])(interface_1[_0x4c984d(0xe6)],_0x44781d),_0x4aad36={};for(const _0x484b46 of _0x4526a0){_0x3ad380[_0x484b46]&&(_0x4aad36[_0x484b46]=_0x3ad380[_0x484b46]);}return(0x0,core_1[_0x4c984d(0xd6)])(interface_1['RULES_KEY'],_0x4aad36,_0x43596e),_0x43596e;}exports[a5_0x491424(0xdf)]=PickDto;function OmitDto(_0x4672f,_0x43446c){const _0x5bfc34=a5_0x491424,_0xe3c012=function(){};_0xe3c012[_0x5bfc34(0xd8)]=_0x4672f[_0x5bfc34(0xd8)];const _0x93aa0f=(0x0,core_1[_0x5bfc34(0xdd)])(interface_1[_0x5bfc34(0xe6)],_0x4672f),_0x2c146d=Object['assign']({},_0x93aa0f);for(const _0x3c3b7e of _0x43446c){delete _0x2c146d[_0x3c3b7e];}return(0x0,core_1[_0x5bfc34(0xd6)])(interface_1[_0x5bfc34(0xe6)],_0x2c146d,_0xe3c012),_0xe3c012;}exports['OmitDto']=OmitDto;
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a6_0x1f10ec=a6_0x1031;(function(_0x5cd8e3,_0x2d7460){var _0x416f18=a6_0x1031,_0x1b4c0d=_0x5cd8e3();while(!![]){try{var _0x34ec0c=-parseInt(_0x416f18(0x14f))/0x1+-parseInt(_0x416f18(0x153))/0x2*(-parseInt(_0x416f18(0x139))/0x3)+-parseInt(_0x416f18(0x14c))/0x4+-parseInt(_0x416f18(0x152))/0x5+-parseInt(_0x416f18(0x154))/0x6+parseInt(_0x416f18(0x159))/0x7*(parseInt(_0x416f18(0x15b))/0x8)+parseInt(_0x416f18(0x14e))/0x9*(-parseInt(_0x416f18(0x14a))/0xa);if(_0x34ec0c===_0x2d7460)break;else _0x1b4c0d['push'](_0x1b4c0d['shift']());}catch(_0x5e7a42){_0x1b4c0d['push'](_0x1b4c0d['shift']());}}}(a6_0x4840,0x35834));function a6_0x1031(_0x3953ed,_0x42157d){var _0x4d6b7b=a6_0x4840();return a6_0x1031=function(_0x4c1ed2,_0x4cacb2){_0x4c1ed2=_0x4c1ed2-0x139;var _0x484056=_0x4d6b7b[_0x4c1ed2];return _0x484056;},a6_0x1031(_0x3953ed,_0x42157d);}var a6_0x4cacb2=(function(){var _0x3e3ad7=!![];return function(_0x5888ae,_0x49c362){var _0x4e3459=_0x3e3ad7?function(){var _0x5bdb35=a6_0x1031;if(_0x49c362){var _0x65a2eb=_0x49c362[_0x5bdb35(0x144)](_0x5888ae,arguments);return _0x49c362=null,_0x65a2eb;}}:function(){};return _0x3e3ad7=![],_0x4e3459;};}()),a6_0x4c1ed2=a6_0x4cacb2(this,function(){var _0x5b7601=a6_0x1031;return a6_0x4c1ed2[_0x5b7601(0x15d)]()[_0x5b7601(0x157)](_0x5b7601(0x142))[_0x5b7601(0x15d)]()[_0x5b7601(0x13e)](a6_0x4c1ed2)[_0x5b7601(0x157)](_0x5b7601(0x142));});a6_0x4c1ed2();'use strict';function a6_0x4840(){var _0xcfdeae=['constructor','getOwnPropertyDescriptor','Configuration','Rule','(((.+)+)+)+$','prototype','apply','__createBinding','./exception/ValidatorError','default','./decorator/Rule','get','590DZBbrj','./helper/dtoHelper','13808DTEkLM','Validator','21186WRLkjM','129025oshhtd','defineProperty','RuleType','344510RMmjaD','6LaDmdM','1585038GwUgEK','writable','call','search','configurable','7iOSRGt','hasOwnProperty','3359544zvJiqN','create','toString','403683zfiELZ','ValidatorError','CustomConfiguration','./decorator/Validator','./configuration'];a6_0x4840=function(){return _0xcfdeae;};return a6_0x4840();}var __createBinding=this&&this[a6_0x1f10ec(0x145)]||(Object[a6_0x1f10ec(0x15c)]?function(_0x5f4481,_0x114ea7,_0x317688,_0x2caebf){var _0x38e99c=a6_0x1f10ec;if(_0x2caebf===undefined)_0x2caebf=_0x317688;var _0x534b67=Object[_0x38e99c(0x13f)](_0x114ea7,_0x317688);(!_0x534b67||(_0x38e99c(0x149)in _0x534b67?!_0x114ea7['__esModule']:_0x534b67[_0x38e99c(0x155)]||_0x534b67[_0x38e99c(0x158)]))&&(_0x534b67={'enumerable':!![],'get':function(){return _0x114ea7[_0x317688];}}),Object[_0x38e99c(0x150)](_0x5f4481,_0x2caebf,_0x534b67);}:function(_0x1cbd6a,_0x101e33,_0x1289ef,_0x4b11ec){if(_0x4b11ec===undefined)_0x4b11ec=_0x1289ef;_0x1cbd6a[_0x4b11ec]=_0x101e33[_0x1289ef];}),__exportStar=this&&this['__exportStar']||function(_0x4fc829,_0x827aa0){var _0x37163a=a6_0x1f10ec;for(var _0x109fa9 in _0x4fc829)if(_0x109fa9!==_0x37163a(0x147)&&!Object[_0x37163a(0x143)][_0x37163a(0x15a)][_0x37163a(0x156)](_0x827aa0,_0x109fa9))__createBinding(_0x827aa0,_0x4fc829,_0x109fa9);};Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[a6_0x1f10ec(0x140)]=exports['ValidatorService']=exports[a6_0x1f10ec(0x13a)]=exports[a6_0x1f10ec(0x151)]=exports[a6_0x1f10ec(0x141)]=exports[a6_0x1f10ec(0x14d)]=void 0x0,__exportStar(require('./interface'),exports),__exportStar(require(a6_0x1f10ec(0x14b)),exports);var Validator_1=require(a6_0x1f10ec(0x13c));Object[a6_0x1f10ec(0x150)](exports,'Validator',{'enumerable':!![],'get':function(){var _0x22a058=a6_0x1f10ec;return Validator_1[_0x22a058(0x14d)];}});var Rule_1=require(a6_0x1f10ec(0x148));Object[a6_0x1f10ec(0x150)](exports,a6_0x1f10ec(0x141),{'enumerable':!![],'get':function(){return Rule_1['Rule'];}}),Object['defineProperty'](exports,a6_0x1f10ec(0x151),{'enumerable':!![],'get':function(){var _0xace9b7=a6_0x1f10ec;return Rule_1[_0xace9b7(0x151)];}});var ValidatorError_1=require(a6_0x1f10ec(0x146));Object[a6_0x1f10ec(0x150)](exports,'ValidatorError',{'enumerable':!![],'get':function(){var _0x3f17cd=a6_0x1f10ec;return ValidatorError_1[_0x3f17cd(0x13a)];}});var ValidatorService_1=require('./service/ValidatorService');Object[a6_0x1f10ec(0x150)](exports,'ValidatorService',{'enumerable':!![],'get':function(){return ValidatorService_1['ValidatorService'];}});var configuration_1=require(a6_0x1f10ec(0x13d));Object[a6_0x1f10ec(0x150)](exports,a6_0x1f10ec(0x140),{'enumerable':!![],'get':function(){var _0x5db5af=a6_0x1f10ec;return configuration_1[_0x5db5af(0x13b)];}});
|
package/dist/interface.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a7_0x59c5d2=a7_0x5f1b;(function(_0x1ff23b,_0x37b621){var _0x238ce0=a7_0x5f1b,_0x49d9f7=_0x1ff23b();while(!![]){try{var _0x47749c=parseInt(_0x238ce0(0xed))/0x1*(parseInt(_0x238ce0(0xf3))/0x2)+-parseInt(_0x238ce0(0xea))/0x3+-parseInt(_0x238ce0(0xe2))/0x4+parseInt(_0x238ce0(0xeb))/0x5+-parseInt(_0x238ce0(0xf5))/0x6*(-parseInt(_0x238ce0(0xe4))/0x7)+-parseInt(_0x238ce0(0xe9))/0x8*(-parseInt(_0x238ce0(0xf0))/0x9)+parseInt(_0x238ce0(0xe8))/0xa*(-parseInt(_0x238ce0(0xec))/0xb);if(_0x47749c===_0x37b621)break;else _0x49d9f7['push'](_0x49d9f7['shift']());}catch(_0x66858d){_0x49d9f7['push'](_0x49d9f7['shift']());}}}(a7_0x5bad,0x4ca61));var a7_0x3a2cb4=(function(){var _0x78846c=!![];return function(_0x4d57d7,_0x256935){var _0x182443=_0x78846c?function(){var _0x30365d=a7_0x5f1b;if(_0x256935){var _0x220453=_0x256935[_0x30365d(0xe5)](_0x4d57d7,arguments);return _0x256935=null,_0x220453;}}:function(){};return _0x78846c=![],_0x182443;};}()),a7_0x30c922=a7_0x3a2cb4(this,function(){var _0x507d2c=a7_0x5f1b;return a7_0x30c922['toString']()[_0x507d2c(0xf4)]('(((.+)+)+)+$')[_0x507d2c(0xf1)]()[_0x507d2c(0xef)](a7_0x30c922)['search'](_0x507d2c(0xe1));});function a7_0x5f1b(_0x2caf4b,_0x3bd441){var _0x4aa3cf=a7_0x5bad();return a7_0x5f1b=function(_0x30c922,_0x3a2cb4){_0x30c922=_0x30c922-0xe1;var _0x5badf8=_0x4aa3cf[_0x30c922];return _0x5badf8;},a7_0x5f1b(_0x2caf4b,_0x3bd441);}a7_0x30c922();'use strict';Object[a7_0x59c5d2(0xe7)](exports,a7_0x59c5d2(0xee),{'value':!![]}),exports[a7_0x59c5d2(0xe3)]=exports[a7_0x59c5d2(0xf2)]=void 0x0,exports[a7_0x59c5d2(0xf2)]=a7_0x59c5d2(0xe6),exports[a7_0x59c5d2(0xe3)]='anncic-api:validator:validator';function a7_0x5bad(){var _0x43002f=['259932pEwetP','VALIDATOR_KEY','7dlmpPH','apply','anncic-api:validator:rules','defineProperty','1435090XOrlNU','3271544MuLAfF','995427oCKmyZ','1395955sCvtul','11ixtbBR','1MsrKEr','__esModule','constructor','9UJMcLr','toString','RULES_KEY','194066bqMbQV','search','414522VLbDQs','(((.+)+)+)+$'];a7_0x5bad=function(){return _0x43002f;};return a7_0x5bad();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a8_0x417116=a8_0x2470;(function(_0x4aff8d,_0x4655a2){const _0x1cdd93=a8_0x2470,_0x5945d5=_0x4aff8d();while(!![]){try{const _0x494870=-parseInt(_0x1cdd93(0xd2))/0x1*(-parseInt(_0x1cdd93(0xc1))/0x2)+-parseInt(_0x1cdd93(0xbd))/0x3+-parseInt(_0x1cdd93(0xad))/0x4+-parseInt(_0x1cdd93(0x95))/0x5+parseInt(_0x1cdd93(0xd7))/0x6*(-parseInt(_0x1cdd93(0xd3))/0x7)+parseInt(_0x1cdd93(0xd1))/0x8+parseInt(_0x1cdd93(0xc0))/0x9;if(_0x494870===_0x4655a2)break;else _0x5945d5['push'](_0x5945d5['shift']());}catch(_0x4a2db2){_0x5945d5['push'](_0x5945d5['shift']());}}}(a8_0x1b47,0xaf38e));const a8_0x58c26e=(function(){let _0x163106=!![];return function(_0x30f637,_0xcbf5de){const _0x5ecfe2=_0x163106?function(){const _0x3f5890=a8_0x2470;if(_0xcbf5de){const _0x528f20=_0xcbf5de[_0x3f5890(0xbe)](_0x30f637,arguments);return _0xcbf5de=null,_0x528f20;}}:function(){};return _0x163106=![],_0x5ecfe2;};}()),a8_0xd4eeb4=a8_0x58c26e(this,function(){const _0xada701=a8_0x2470;return a8_0xd4eeb4[_0xada701(0x9c)]()[_0xada701(0xd0)](_0xada701(0xa1))[_0xada701(0x9c)]()[_0xada701(0xa6)](a8_0xd4eeb4)['search'](_0xada701(0xa1));});a8_0xd4eeb4();function a8_0x2470(_0x2bfb79,_0xb0d8fe){const _0x264896=a8_0x1b47();return a8_0x2470=function(_0xd4eeb4,_0x58c26e){_0xd4eeb4=_0xd4eeb4-0x93;let _0x1b4792=_0x264896[_0xd4eeb4];return _0x1b4792;},a8_0x2470(_0x2bfb79,_0xb0d8fe);}'use strict';function a8_0x1b47(){const _0x1fb68b=['$_terms','language','参数验证失败','message','keys','i18nConfig','search','10990712dpNdyv','1OioFjA','23177DxaecX','validate','format','design:paramtypes','738OosNUl','design:type','schema','forEach','type','ValidatorService','Provide','183805XKlJUX','ValidatorError','init','Init','object','error','@midwayjs/i18n','toString','defineProperty','details','formatLocale','locale','(((.+)+)+)+$','function','validationOptions','key','decorate','constructor','prototype','ScopeEnum','PARAMS','RULES_KEY','value','__decorate','1840416TUgaFp','design:returntype','Singleton','date','fromEntries','localeTable','i18n','validator','metadata','../exception/ValidatorError','__metadata','Config','validatorConfig','@midwayjs/core','length','getLocaleMapping','2266281uqODea','apply','i18nService','3453390eWvpvp','1239412SYKFup','getSchema','NOFIND_SCHEMA','Inject','_flags','__esModule','assign','errors','../interface'];a8_0x1b47=function(){return _0x1fb68b;};return a8_0x1b47();}var __decorate=this&&this[a8_0x417116(0xac)]||function(_0x9abab3,_0x1c313f,_0x4b0f6d,_0x9504ed){const _0x286464=a8_0x417116;var _0x5e24e8=arguments[_0x286464(0xbb)],_0x314dcd=_0x5e24e8<0x3?_0x1c313f:_0x9504ed===null?_0x9504ed=Object['getOwnPropertyDescriptor'](_0x1c313f,_0x4b0f6d):_0x9504ed,_0x2fb0fb;if(typeof Reflect===_0x286464(0x99)&&typeof Reflect['decorate']==='function')_0x314dcd=Reflect[_0x286464(0xa5)](_0x9abab3,_0x1c313f,_0x4b0f6d,_0x9504ed);else{for(var _0x4238be=_0x9abab3[_0x286464(0xbb)]-0x1;_0x4238be>=0x0;_0x4238be--)if(_0x2fb0fb=_0x9abab3[_0x4238be])_0x314dcd=(_0x5e24e8<0x3?_0x2fb0fb(_0x314dcd):_0x5e24e8>0x3?_0x2fb0fb(_0x1c313f,_0x4b0f6d,_0x314dcd):_0x2fb0fb(_0x1c313f,_0x4b0f6d))||_0x314dcd;}return _0x5e24e8>0x3&&_0x314dcd&&Object['defineProperty'](_0x1c313f,_0x4b0f6d,_0x314dcd),_0x314dcd;},__metadata=this&&this[a8_0x417116(0xb7)]||function(_0x43a96a,_0x5cdc39){const _0xe8b826=a8_0x417116;if(typeof Reflect===_0xe8b826(0x99)&&typeof Reflect[_0xe8b826(0xb5)]===_0xe8b826(0xa2))return Reflect[_0xe8b826(0xb5)](_0x43a96a,_0x5cdc39);};Object[a8_0x417116(0x9d)](exports,a8_0x417116(0xc6),{'value':!![]}),exports[a8_0x417116(0x93)]=void 0x0;const Joi=require('joi'),i18n_1=require(a8_0x417116(0x9b)),core_1=require(a8_0x417116(0xba)),interface_1=require(a8_0x417116(0xc9)),ValidatorError_1=require(a8_0x417116(0xb6));let ValidatorService=class ValidatorService{constructor(){this['messages']={};}async[a8_0x417116(0x97)](){const _0xc2f179=a8_0x417116,_0x208eb0=Object[_0xc2f179(0xce)](this[_0xc2f179(0xcf)][_0xc2f179(0xb2)]);_0x208eb0[_0xc2f179(0xda)](_0x4d28ce=>{const _0x469ffe=_0xc2f179;this['messages'][(0x0,i18n_1[_0x469ffe(0x9f)])(_0x4d28ce)]=Object[_0x469ffe(0xb1)](this[_0x469ffe(0xbf)][_0x469ffe(0xbc)](_0x4d28ce,_0x469ffe(0xb4)));});}[a8_0x417116(0xc2)](_0x636f53){const _0x3c3a5f=a8_0x417116,_0x370254=(0x0,core_1['getClassExtendedMetadata'])(interface_1[_0x3c3a5f(0xaa)],_0x636f53);return _0x370254?Joi[_0x3c3a5f(0x99)](_0x370254):undefined;}['validator'](_0x3e54fa,_0x51b557,_0x3a538e={}){const _0x2a74b6=a8_0x417116;var _0x65bc6f,_0x2968d4,_0x92a711,_0x2e37c3,_0x389eaf,_0x33d86d;const _0x311a6e=Joi['isSchema'](_0x3e54fa)?_0x3e54fa:this[_0x2a74b6(0xc2)](_0x3e54fa);if(!_0x311a6e)throw new AnnError(ValidatorError_1[_0x2a74b6(0x96)][_0x2a74b6(0xc3)]);_0x3a538e[_0x2a74b6(0xa3)]=Object[_0x2a74b6(0xc7)]((_0x65bc6f=this[_0x2a74b6(0xb9)]['validationOptions'])!==null&&_0x65bc6f!==void 0x0?_0x65bc6f:{},{'messages':this['messages']},_0x3a538e[_0x2a74b6(0xa3)]||{}),_0x3a538e[_0x2a74b6(0xa3)]['errors']=_0x3a538e[_0x2a74b6(0xa3)][_0x2a74b6(0xc8)]||{},_0x3a538e[_0x2a74b6(0xa3)][_0x2a74b6(0xc8)][_0x2a74b6(0xcb)]=(0x0,i18n_1[_0x2a74b6(0x9f)])(this[_0x2a74b6(0xbf)]['getAvailableLocale'](_0x3a538e[_0x2a74b6(0xa3)][_0x2a74b6(0xc8)][_0x2a74b6(0xcb)]||_0x3a538e[_0x2a74b6(0xa0)]||this[_0x2a74b6(0xcf)]['defaultLocale'],'validator'));const _0x1179f6=_0x311a6e[_0x2a74b6(0xd4)](_0x51b557,_0x3a538e[_0x2a74b6(0xa3)]);if(_0x1179f6===null||_0x1179f6===void 0x0?void 0x0:_0x1179f6['error']){if(_0x1179f6[_0x2a74b6(0x9a)]instanceof AnnError)throw _0x1179f6[_0x2a74b6(0x9a)];else{if(_0x1179f6['error']instanceof Error)throw new AnnError(ValidatorError_1[_0x2a74b6(0x96)][_0x2a74b6(0xa9)],{'message':((_0x2968d4=_0x1179f6[_0x2a74b6(0x9a)])===null||_0x2968d4===void 0x0?void 0x0:_0x2968d4[_0x2a74b6(0xcd)])||_0x2a74b6(0xcc)});else throw new AnnError(ValidatorError_1[_0x2a74b6(0x96)]['PARAMS'],{'message':((_0x389eaf=(_0x2e37c3=(_0x92a711=_0x1179f6[_0x2a74b6(0x9a)])===null||_0x92a711===void 0x0?void 0x0:_0x92a711[_0x2a74b6(0x9e)])===null||_0x2e37c3===void 0x0?void 0x0:_0x2e37c3[0x0])===null||_0x389eaf===void 0x0?void 0x0:_0x389eaf['message'])||_0x2a74b6(0xcc)});}}if(_0x1179f6===null||_0x1179f6===void 0x0?void 0x0:_0x1179f6[_0x2a74b6(0xab)]){const _0x1d35c7=(_0x33d86d=_0x311a6e===null||_0x311a6e===void 0x0?void 0x0:_0x311a6e[_0x2a74b6(0xca)])===null||_0x33d86d===void 0x0?void 0x0:_0x33d86d[_0x2a74b6(0xce)],_0x165258=function(_0x174b08,_0x5b9eb1){const _0x3c9a1a=_0x2a74b6;var _0x214d68,_0x1a908a,_0x4e48fa,_0x277eb3,_0x33c82f,_0x1d5644,_0x4de137,_0x399792,_0x4a0a45,_0x5f0b83,_0x33736e;for(let _0x1e0d57 in _0x174b08){if(_0x5b9eb1[(_0x214d68=_0x174b08[_0x1e0d57])===null||_0x214d68===void 0x0?void 0x0:_0x214d68[_0x3c9a1a(0xa4)]]&&((_0x4e48fa=(_0x1a908a=_0x174b08[_0x1e0d57])===null||_0x1a908a===void 0x0?void 0x0:_0x1a908a[_0x3c9a1a(0xd9)])===null||_0x4e48fa===void 0x0?void 0x0:_0x4e48fa[_0x3c9a1a(0xdb)])){if(((_0x33c82f=(_0x277eb3=_0x174b08[_0x1e0d57])===null||_0x277eb3===void 0x0?void 0x0:_0x277eb3[_0x3c9a1a(0xd9)])===null||_0x33c82f===void 0x0?void 0x0:_0x33c82f[_0x3c9a1a(0xdb)])==_0x3c9a1a(0x99))_0x5b9eb1[_0x174b08[_0x1e0d57][_0x3c9a1a(0xa4)]]=_0x165258((_0x4de137=(_0x1d5644=_0x174b08[_0x1e0d57])===null||_0x1d5644===void 0x0?void 0x0:_0x1d5644[_0x3c9a1a(0xd9)][_0x3c9a1a(0xca)])===null||_0x4de137===void 0x0?void 0x0:_0x4de137['keys'],_0x5b9eb1[_0x174b08[_0x1e0d57][_0x3c9a1a(0xa4)]]);else{if(_0x174b08[_0x1e0d57][_0x3c9a1a(0xd9)][_0x3c9a1a(0xdb)]==_0x3c9a1a(0xb0)&&_0x1179f6['value'][(_0x399792=_0x174b08[_0x1e0d57])===null||_0x399792===void 0x0?void 0x0:_0x399792[_0x3c9a1a(0xa4)]]){const _0x3fb2d7=((_0x33736e=(_0x5f0b83=(_0x4a0a45=_0x174b08[_0x1e0d57])===null||_0x4a0a45===void 0x0?void 0x0:_0x4a0a45['schema'])===null||_0x5f0b83===void 0x0?void 0x0:_0x5f0b83[_0x3c9a1a(0xc5)])===null||_0x33736e===void 0x0?void 0x0:_0x33736e[_0x3c9a1a(0xd5)])||'YYYY-MM-DD\x20HH:mm:ss';_0x5b9eb1[_0x174b08[_0x1e0d57][_0x3c9a1a(0xa4)]]=dayjs(_0x1179f6[_0x3c9a1a(0xab)][_0x174b08[_0x1e0d57]['key']])[_0x3c9a1a(0xd5)](_0x3fb2d7);}}}}return _0x5b9eb1;};return _0x165258(_0x1d35c7,_0x1179f6[_0x2a74b6(0xab)]);}throw new AnnError(ValidatorError_1[_0x2a74b6(0x96)][_0x2a74b6(0xa9)]);}};__decorate([(0x0,core_1[a8_0x417116(0xb8)])(a8_0x417116(0xb3)),__metadata('design:type',Object)],ValidatorService['prototype'],a8_0x417116(0xcf),void 0x0),__decorate([(0x0,core_1[a8_0x417116(0xb8)])(a8_0x417116(0xb4)),__metadata(a8_0x417116(0xd8),Object)],ValidatorService[a8_0x417116(0xa7)],a8_0x417116(0xb9),void 0x0),__decorate([(0x0,core_1[a8_0x417116(0xc4)])(),__metadata('design:type',i18n_1['MidwayI18nServiceSingleton'])],ValidatorService[a8_0x417116(0xa7)],a8_0x417116(0xbf),void 0x0),__decorate([(0x0,core_1[a8_0x417116(0x98)])(),__metadata(a8_0x417116(0xd8),Function),__metadata(a8_0x417116(0xd6),[]),__metadata(a8_0x417116(0xae),Promise)],ValidatorService[a8_0x417116(0xa7)],a8_0x417116(0x97),null),ValidatorService=__decorate([(0x0,core_1[a8_0x417116(0x94)])(a8_0x417116(0xb4)),(0x0,core_1['Scope'])(core_1[a8_0x417116(0xa8)][a8_0x417116(0xaf)])],ValidatorService),exports[a8_0x417116(0x93)]=ValidatorService;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anncic-api/validator",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.7",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"typings": "index.d.ts",
|
|
6
6
|
"license": "MIT",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"build": "tsc && javascript-obfuscator ./dist --output ./dist --config obfuscator.json"
|
|
18
18
|
},
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"@anncic-api/core": "^2.0.
|
|
20
|
+
"@anncic-api/core": "^2.0.7",
|
|
21
21
|
"@joi/date": "^2.1.0",
|
|
22
22
|
"joi": "^17.7.0"
|
|
23
23
|
},
|
|
@@ -26,5 +26,5 @@
|
|
|
26
26
|
"javascript-obfuscator": "^4.0.0",
|
|
27
27
|
"typescript": "^4.7.4"
|
|
28
28
|
},
|
|
29
|
-
"gitHead": "
|
|
29
|
+
"gitHead": "e4a312d2851bf36763be54d6055cbf3e056d15d5"
|
|
30
30
|
}
|