@anncic-api/validator 3.4.59 → 3.4.64
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_0x163bf0=a0_0x4785;(function(_0x174499,_0x2a636e){const _0x808c75=a0_0x4785,_0x55d257=_0x174499();while(!![]){try{const _0x24339f=parseInt(_0x808c75(0x1db))/0x1+-parseInt(_0x808c75(0x1d7))/0x2+parseInt(_0x808c75(0x1e0))/0x3+-parseInt(_0x808c75(0x1da))/0x4*(-parseInt(_0x808c75(0x1d3))/0x5)+-parseInt(_0x808c75(0x1dc))/0x6*(-parseInt(_0x808c75(0x1de))/0x7)+-parseInt(_0x808c75(0x1e1))/0x8*(parseInt(_0x808c75(0x1d4))/0x9)+-parseInt(_0x808c75(0x1e3))/0xa;if(_0x24339f===_0x2a636e)break;else _0x55d257['push'](_0x55d257['shift']());}catch(_0x1d2bdf){_0x55d257['push'](_0x55d257['shift']());}}}(a0_0x4f4c,0x18d55));function a0_0x4f4c(){const _0x399f28=['apply','2914820JVtRTn','defineProperty','ValidatorError','constructor','2590CoIeot','18ZspeAr','toString','../exception/ValidatorError','111936zylhtM','PARAMS','(((.+)+)+)+$','1484oPTgOT','74964BdJayk','12gxPkop','../../locales/en_US.json','443947vLfpDd','../../locales/zh_CN.json','447645qHIPSN','376128UCosEC'];a0_0x4f4c=function(){return _0x399f28;};return a0_0x4f4c();}const a0_0x13e968=(function(){let _0x3a8ce8=!![];return function(_0x39188d,_0x32348b){const _0x2ae2a8=_0x3a8ce8?function(){const _0x2db62b=a0_0x4785;if(_0x32348b){const _0xa57f40=_0x32348b[_0x2db62b(0x1e2)](_0x39188d,arguments);return _0x32348b=null,_0xa57f40;}}:function(){};return _0x3a8ce8=![],_0x2ae2a8;};}()),a0_0x2ad5d1=a0_0x13e968(this,function(){const _0x326802=a0_0x4785;return a0_0x2ad5d1['toString']()['search']('(((.+)+)+)+$')[_0x326802(0x1d5)]()[_0x326802(0x1d2)](a0_0x2ad5d1)['search'](_0x326802(0x1d9));});a0_0x2ad5d1();'use strict';function a0_0x4785(_0xcb0f97,_0x1dccfe){const _0x42961f=a0_0x4f4c();return a0_0x4785=function(_0x2ad5d1,_0x13e968){_0x2ad5d1=_0x2ad5d1-0x1d1;let _0x4f4c26=_0x42961f[_0x2ad5d1];return _0x4f4c26;},a0_0x4785(_0xcb0f97,_0x1dccfe);}Object[a0_0x163bf0(0x1e4)](exports,'__esModule',{'value':!![]});const ValidatorError_1=require(a0_0x163bf0(0x1d6));exports['default']={'validator':{'errorStatus':ValidatorError_1[a0_0x163bf0(0x1d1)][a0_0x163bf0(0x1d8)],'validationOptions':{'allowUnknown':!![],'stripUnknown':!![],'dateFormat':'string'}},'i18n':{'localeTable':{'en_US':{'validator':require(a0_0x163bf0(0x1dd))},'zh_CN':{'validator':require(a0_0x163bf0(0x1df))}}}};
|
package/dist/configuration.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a1_0x2a35f0=a1_0x1875;(function(_0x53c9a5,_0x2d336d){const _0x1cf98e=a1_0x1875,_0x32bf15=_0x53c9a5();while(!![]){try{const _0x163a5d=-parseInt(_0x1cf98e(0x131))/0x1+-parseInt(_0x1cf98e(0x150))/0x2*(-parseInt(_0x1cf98e(0x140))/0x3)+-parseInt(_0x1cf98e(0x136))/0x4*(parseInt(_0x1cf98e(0x153))/0x5)+parseInt(_0x1cf98e(0x135))/0x6*(-parseInt(_0x1cf98e(0x15e))/0x7)+parseInt(_0x1cf98e(0x161))/0x8+-parseInt(_0x1cf98e(0x152))/0x9*(-parseInt(_0x1cf98e(0x158))/0xa)+-parseInt(_0x1cf98e(0x14f))/0xb*(-parseInt(_0x1cf98e(0x130))/0xc);if(_0x163a5d===_0x2d336d)break;else _0x32bf15['push'](_0x32bf15['shift']());}catch(_0x59d8f8){_0x32bf15['push'](_0x32bf15['shift']());}}}(a1_0x1247,0xb0f2b));const a1_0x46b401=(function(){let _0xf938fa=!![];return function(_0x4c6654,_0x51043a){const _0x4fcca7=_0xf938fa?function(){if(_0x51043a){const _0x575a3e=_0x51043a['apply'](_0x4c6654,arguments);return _0x51043a=null,_0x575a3e;}}:function(){};return _0xf938fa=![],_0x4fcca7;};}()),a1_0x152aeb=a1_0x46b401(this,function(){const _0x215f7b=a1_0x1875;return a1_0x152aeb[_0x215f7b(0x151)]()[_0x215f7b(0x141)]('(((.+)+)+)+$')['toString']()[_0x215f7b(0x15b)](a1_0x152aeb)[_0x215f7b(0x141)](_0x215f7b(0x12e));});a1_0x152aeb();'use strict';var __decorate=this&&this[a1_0x2a35f0(0x127)]||function(_0x51b9cc,_0x38794a,_0x3f801c,_0x1bc1ad){const _0x23cc0b=a1_0x2a35f0;var _0x203e89=arguments['length'],_0x492607=_0x203e89<0x3?_0x38794a:_0x1bc1ad===null?_0x1bc1ad=Object[_0x23cc0b(0x14a)](_0x38794a,_0x3f801c):_0x1bc1ad,_0x20ca53;if(typeof Reflect===_0x23cc0b(0x14e)&&typeof Reflect[_0x23cc0b(0x129)]===_0x23cc0b(0x15a))_0x492607=Reflect[_0x23cc0b(0x129)](_0x51b9cc,_0x38794a,_0x3f801c,_0x1bc1ad);else{for(var _0x26f132=_0x51b9cc[_0x23cc0b(0x134)]-0x1;_0x26f132>=0x0;_0x26f132--)if(_0x20ca53=_0x51b9cc[_0x26f132])_0x492607=(_0x203e89<0x3?_0x20ca53(_0x492607):_0x203e89>0x3?_0x20ca53(_0x38794a,_0x3f801c,_0x492607):_0x20ca53(_0x38794a,_0x3f801c))||_0x492607;}return _0x203e89>0x3&&_0x492607&&Object[_0x23cc0b(0x13e)](_0x38794a,_0x3f801c,_0x492607),_0x492607;},__metadata=this&&this[a1_0x2a35f0(0x12c)]||function(_0x41c59a,_0x1746d4){const _0xe3fa97=a1_0x2a35f0;if(typeof Reflect===_0xe3fa97(0x14e)&&typeof Reflect[_0xe3fa97(0x13b)]===_0xe3fa97(0x15a))return Reflect[_0xe3fa97(0x13b)](_0x41c59a,_0x1746d4);};Object[a1_0x2a35f0(0x13e)](exports,a1_0x2a35f0(0x148),{'value':!![]}),exports['CustomConfiguration']=void 0x0;function a1_0x1247(){const _0x3caacd=['onReady','splice','metadata','CustomConfiguration','body','defineProperty','@midwayjs/i18n','145398OExqDe','search','Configuration','bound\x20dispatch','propertyName','method','ValidatorService','locale','__esModule','prototype','getOwnPropertyDescriptor','req','I18N_ATTR_KEY','request','object','19426AeZsJz','32clXjXs','toString','3407661vgtUXp','7570sWpkqF','getAttr','design:type','methodArgs','target','30zSShlG','getSchema','function','constructor','./service/ValidatorService','@midwayjs/core','14nhMFlA','Inject','./config/config.default','1782424YOxEjk','getMethodParamTypes','decorator','./interface','methodName','REQUEST_OBJ_CTX_KEY','find','name','__decorate','assign','decorate','query','res','__metadata','getClassMetadata','(((.+)+)+)+$','VALIDATOR_KEY','4380GKqlhF','320793cYUupj','args','registerMethodHandler','length','2619636emdZka','2272cGMxas','params','param'];a1_0x1247=function(){return _0x3caacd;};return a1_0x1247();}const i18n_1=require(a1_0x2a35f0(0x13f)),core_1=require(a1_0x2a35f0(0x15d)),core_2=require(a1_0x2a35f0(0x15d)),interface_1=require(a1_0x2a35f0(0x164)),ValidatorService_1=require(a1_0x2a35f0(0x15c)),i18n=require(a1_0x2a35f0(0x13f)),anncic=require('@anncic-api/core'),ConfigDefault=require(a1_0x2a35f0(0x160));function a1_0x1875(_0x84b86f,_0x3ad22a){const _0x21decd=a1_0x1247();return a1_0x1875=function(_0x152aeb,_0x46b401){_0x152aeb=_0x152aeb-0x126;let _0x1247fe=_0x21decd[_0x152aeb];return _0x1247fe;},a1_0x1875(_0x84b86f,_0x3ad22a);}let CustomConfiguration=class CustomConfiguration{async[a1_0x2a35f0(0x139)](){const _0x2b2aa0=a1_0x2a35f0;this[_0x2b2aa0(0x163)][_0x2b2aa0(0x133)](interface_1[_0x2b2aa0(0x12f)],_0xe0fdcf=>{const _0x533c8b=_0x2b2aa0,_0x3ccc41=_0xe0fdcf['metadata'],_0xf59814=(0x0,core_2[_0x533c8b(0x162)])(_0xe0fdcf['target'],_0xe0fdcf[_0x533c8b(0x144)]);return{'before':_0x304faf=>{const _0x373593=_0x533c8b;var _0x1601f6,_0xd1b300,_0x34b748,_0x1a6f59,_0x190bb6,_0x427fac,_0x3728d8,_0x926ee,_0x509e1e,_0x3c14e0,_0x22e403,_0x51d5bb,_0x22a53e;const _0x3f80e7=_0x304faf[_0x373593(0x157)][core_1[_0x373593(0x166)]],_0x502a64=Object[_0x373593(0x128)]({},((_0x1601f6=_0x3f80e7===null||_0x3f80e7===void 0x0?void 0x0:_0x3f80e7[_0x373593(0x14d)])===null||_0x1601f6===void 0x0?void 0x0:_0x1601f6[_0x373593(0x12a)])||{},((_0xd1b300=_0x3f80e7===null||_0x3f80e7===void 0x0?void 0x0:_0x3f80e7[_0x373593(0x14d)])===null||_0xd1b300===void 0x0?void 0x0:_0xd1b300[_0x373593(0x13d)])||{}),_0xef8c6c=((0x0,core_2[_0x373593(0x12d)])(interface_1[_0x373593(0x12f)],_0x304faf[_0x373593(0x157)])||[])[_0x373593(0x167)](_0x103862=>_0x103862[_0x373593(0x145)]==_0x304faf[_0x373593(0x165)]);!(_0x3ccc41===null||_0x3ccc41===void 0x0?void 0x0:_0x3ccc41[_0x373593(0x147)])&&_0x3f80e7&&_0x3f80e7[_0x373593(0x154)]&&(_0x3ccc41[_0x373593(0x147)]=_0x3f80e7[_0x373593(0x154)](i18n_1[_0x373593(0x14c)]));for(let _0x40450b=0x0;_0x40450b<_0xf59814[_0x373593(0x134)];_0x40450b++){const _0x107fee=_0xf59814[_0x40450b],_0x495f89=this[_0x373593(0x146)][_0x373593(0x159)](_0x107fee);if(_0x495f89){if(typeof _0x304faf[_0x373593(0x132)][_0x40450b]=='undefined'||((_0x34b748=_0x304faf[_0x373593(0x132)][_0x40450b])===null||_0x34b748===void 0x0?void 0x0:_0x34b748[_0x373593(0x14d)])&&((_0x1a6f59=_0x304faf[_0x373593(0x132)][_0x40450b])===null||_0x1a6f59===void 0x0?void 0x0:_0x1a6f59[_0x373593(0x12b)])&&((_0x190bb6=_0x304faf['args'][_0x40450b])===null||_0x190bb6===void 0x0?void 0x0:_0x190bb6[_0x373593(0x14b)]))_0x304faf[_0x373593(0x132)][_0x40450b]=_0x502a64;else((_0x427fac=_0x304faf[_0x373593(0x132)][_0x40450b])===null||_0x427fac===void 0x0?void 0x0:_0x427fac[_0x373593(0x126)])==_0x373593(0x143)&&_0x304faf['args'][_0x373593(0x13a)](_0x40450b,0x0,_0x502a64);const _0x3f8d34=this[_0x373593(0x146)]['validator'](_0x495f89,_0x304faf['args'][_0x40450b],_0x3ccc41);_0x3f8d34&&(_0x304faf[_0x373593(0x132)][_0x40450b]=_0x3f8d34);}else{if((_0xef8c6c===null||_0xef8c6c===void 0x0?void 0x0:_0xef8c6c[_0x373593(0x156)][_0x40450b])&&((_0x3728d8=_0x304faf['args'][_0x40450b])===null||_0x3728d8===void 0x0?void 0x0:_0x3728d8['params'])&&typeof _0x304faf['args'][_0x40450b][_0x373593(0x138)]==_0x373593(0x15a)&&((_0x926ee=_0x3f80e7===null||_0x3f80e7===void 0x0?void 0x0:_0x3f80e7['params'])===null||_0x926ee===void 0x0?void 0x0:_0x926ee[_0xef8c6c[_0x373593(0x156)][_0x40450b]]))_0x304faf['args'][_0x40450b]=_0x107fee((_0x509e1e=_0x3f80e7===null||_0x3f80e7===void 0x0?void 0x0:_0x3f80e7['params'])===null||_0x509e1e===void 0x0?void 0x0:_0x509e1e[_0xef8c6c[_0x373593(0x156)][_0x40450b]]);else(_0xef8c6c===null||_0xef8c6c===void 0x0?void 0x0:_0xef8c6c[_0x373593(0x156)][_0x40450b])&&((_0x22e403=(_0x3c14e0=_0x304faf[_0x373593(0x132)][_0x40450b])===null||_0x3c14e0===void 0x0?void 0x0:_0x3c14e0['params'])===null||_0x22e403===void 0x0?void 0x0:_0x22e403[_0xef8c6c[_0x373593(0x156)][_0x40450b]])&&(_0x304faf[_0x373593(0x132)][_0x40450b]=(_0x22a53e=(_0x51d5bb=_0x304faf[_0x373593(0x132)][_0x40450b])===null||_0x51d5bb===void 0x0?void 0x0:_0x51d5bb[_0x373593(0x137)])===null||_0x22a53e===void 0x0?void 0x0:_0x22a53e[_0xef8c6c[_0x373593(0x156)][_0x40450b]]);}}},'afterThrow':(_0x12a81d,_0x4d8a98)=>{throw _0x4d8a98;}};});}};exports[a1_0x2a35f0(0x13c)]=CustomConfiguration,__decorate([(0x0,core_2[a1_0x2a35f0(0x15f)])(),__metadata(a1_0x2a35f0(0x155),core_1['MidwayDecoratorService'])],CustomConfiguration[a1_0x2a35f0(0x149)],a1_0x2a35f0(0x163),void 0x0),__decorate([(0x0,core_2[a1_0x2a35f0(0x15f)])(),__metadata(a1_0x2a35f0(0x155),ValidatorService_1[a1_0x2a35f0(0x146)])],CustomConfiguration[a1_0x2a35f0(0x149)],a1_0x2a35f0(0x146),void 0x0),exports['CustomConfiguration']=CustomConfiguration=__decorate([(0x0,core_2[a1_0x2a35f0(0x142)])({'conflictCheck':![],'imports':[i18n,anncic],'namespace':'anncic-api:validator','importConfigs':[{'default':ConfigDefault}]})],CustomConfiguration);
|
package/dist/decorator/Rule.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a2_0x4875d9=a2_0x2076;function a2_0x452e(){const _0x28b30f=['10bIQXDb','32ZzbrRk','35JCfopL','joi','apply','search','defineProperty','(((.+)+)+)+$','saveClassMetadata','attachClassMetadata','40QqtHtn','RULES_KEY','meta','name','Array','60UfojxV','419466hKoNeG','function','583805TVzVvF','24057nMPZnS','toString','getClassMetadata','RuleType','keys','map','Rule','759880ofyVPH','items','default','label','description','1189323BbWCvh','extend','@joi/date','95046zvkdBn','14392608WPDGWB','@midwayjs/core'];a2_0x452e=function(){return _0x28b30f;};return a2_0x452e();}(function(_0x1666c4,_0x13d4e5){const _0x2739ba=a2_0x2076,_0x21b056=_0x1666c4();while(!![]){try{const _0x2a157b=parseInt(_0x2739ba(0x95))/0x1*(-parseInt(_0x2739ba(0x98))/0x2)+-parseInt(_0x2739ba(0xab))/0x3*(-parseInt(_0x2739ba(0xa7))/0x4)+-parseInt(_0x2739ba(0xaa))/0x5+parseInt(_0x2739ba(0xa8))/0x6*(parseInt(_0x2739ba(0x9a))/0x7)+-parseInt(_0x2739ba(0x99))/0x8*(parseInt(_0x2739ba(0x92))/0x9)+-parseInt(_0x2739ba(0xa2))/0xa*(parseInt(_0x2739ba(0xb2))/0xb)+parseInt(_0x2739ba(0x96))/0xc;if(_0x2a157b===_0x13d4e5)break;else _0x21b056['push'](_0x21b056['shift']());}catch(_0x26a0f8){_0x21b056['push'](_0x21b056['shift']());}}}(a2_0x452e,0x427c5));const a2_0x146b3d=(function(){let _0x5ed80c=!![];return function(_0xcfcbca,_0x19e2cd){const _0x468bb7=_0x5ed80c?function(){const _0x568210=a2_0x2076;if(_0x19e2cd){const _0x396fa9=_0x19e2cd[_0x568210(0x9c)](_0xcfcbca,arguments);return _0x19e2cd=null,_0x396fa9;}}:function(){};return _0x5ed80c=![],_0x468bb7;};}()),a2_0x3bd0a8=a2_0x146b3d(this,function(){const _0x497f10=a2_0x2076;return a2_0x3bd0a8[_0x497f10(0xac)]()[_0x497f10(0x9d)](_0x497f10(0x9f))['toString']()['constructor'](a2_0x3bd0a8)[_0x497f10(0x9d)](_0x497f10(0x9f));});a2_0x3bd0a8();'use strict';Object[a2_0x4875d9(0x9e)](exports,'__esModule',{'value':!![]}),exports[a2_0x4875d9(0xae)]=void 0x0,exports[a2_0x4875d9(0xb1)]=Rule;const joi=require(a2_0x4875d9(0x9b)),date_1=require(a2_0x4875d9(0x94)),core_1=require(a2_0x4875d9(0x97)),interface_1=require('../interface');exports[a2_0x4875d9(0xae)]=joi[a2_0x4875d9(0x93)](date_1[a2_0x4875d9(0x8f)]);function a2_0x2076(_0x32d398,_0x3014ca){const _0x5153c9=a2_0x452e();return a2_0x2076=function(_0x3bd0a8,_0x146b3d){_0x3bd0a8=_0x3bd0a8-0x8e;let _0x452e49=_0x5153c9[_0x3bd0a8];return _0x452e49;},a2_0x2076(_0x32d398,_0x3014ca);}function Rule(_0xe2ce29,_0x51848a,_0x28f7ff=''){return(_0x4e4c3,_0x5e6c83)=>{const _0x2aeea0=a2_0x2076;var _0x19166c;if(_0x5e6c83)!joi['isSchema'](_0x51848a)&&(_0x51848a===null||_0x51848a===void 0x0?void 0x0:_0x51848a[_0x2aeea0(0xa5)])&&(_0x51848a=joi['object']((0x0,core_1[_0x2aeea0(0xad)])(interface_1[_0x2aeea0(0xa3)],_0x51848a))[_0x2aeea0(0xa4)]({'id':_0x51848a[_0x2aeea0(0xa5)]}),(0x0,core_1['getPropertyType'])(_0x4e4c3,_0x5e6c83)['name']===_0x2aeea0(0xa6)&&(_0x51848a=joi['array']()[_0x2aeea0(0x8e)](_0x51848a))),joi['isSchema'](_0x51848a)&&(_0xe2ce29&&typeof(_0x51848a===null||_0x51848a===void 0x0?void 0x0:_0x51848a[_0x2aeea0(0x90)])==_0x2aeea0(0xa9)&&(_0x51848a=_0x51848a[_0x2aeea0(0x90)](_0xe2ce29)),_0x28f7ff&&typeof(_0x51848a===null||_0x51848a===void 0x0?void 0x0:_0x51848a[_0x2aeea0(0x91)])==_0x2aeea0(0xa9)&&(_0x51848a=_0x51848a['description'](_0x28f7ff)),(0x0,core_1[_0x2aeea0(0xa1)])(interface_1[_0x2aeea0(0xa3)],_0x51848a,_0x4e4c3,_0x5e6c83));else{const _0x2f1a2c=(0x0,core_1[_0x2aeea0(0xad)])(interface_1[_0x2aeea0(0xa3)],_0x51848a);if(_0x2f1a2c){let _0x4c2eaf=(_0x19166c=(0x0,core_1[_0x2aeea0(0xad)])(interface_1[_0x2aeea0(0xa3)],_0x4e4c3))!==null&&_0x19166c!==void 0x0?_0x19166c:{};Object[_0x2aeea0(0xaf)](_0x2f1a2c)[_0x2aeea0(0xb0)](_0x1d6ddb=>{!_0x4c2eaf[_0x1d6ddb]&&(_0x4c2eaf[_0x1d6ddb]=_0x2f1a2c[_0x1d6ddb]);}),(0x0,core_1[_0x2aeea0(0xa0)])(interface_1[_0x2aeea0(0xa3)],_0x4c2eaf,_0x4e4c3);}}};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a3_0x1a283c=a3_0x2ef5;(function(_0x5717cf,_0x4d80b2){const _0xc91556=a3_0x2ef5,_0x48cfa0=_0x5717cf();while(!![]){try{const _0x2a7b2c=-parseInt(_0xc91556(0x1d0))/0x1*(parseInt(_0xc91556(0x1e0))/0x2)+-parseInt(_0xc91556(0x1e2))/0x3*(parseInt(_0xc91556(0x1ce))/0x4)+-parseInt(_0xc91556(0x1d9))/0x5+-parseInt(_0xc91556(0x1e4))/0x6*(-parseInt(_0xc91556(0x1d5))/0x7)+-parseInt(_0xc91556(0x1db))/0x8*(parseInt(_0xc91556(0x1d4))/0x9)+-parseInt(_0xc91556(0x1de))/0xa*(parseInt(_0xc91556(0x1dd))/0xb)+parseInt(_0xc91556(0x1d2))/0xc;if(_0x2a7b2c===_0x4d80b2)break;else _0x48cfa0['push'](_0x48cfa0['shift']());}catch(_0x3bf1a2){_0x48cfa0['push'](_0x48cfa0['shift']());}}}(a3_0x1fc8,0xecb96));const a3_0x3c0e94=(function(){let _0x6e67fe=!![];return function(_0x217799,_0x384b86){const _0x3a301f=_0x6e67fe?function(){const _0x1bf57a=a3_0x2ef5;if(_0x384b86){const _0x26c366=_0x384b86[_0x1bf57a(0x1dc)](_0x217799,arguments);return _0x384b86=null,_0x26c366;}}:function(){};return _0x6e67fe=![],_0x3a301f;};}()),a3_0x1b8ce7=a3_0x3c0e94(this,function(){const _0x2aa906=a3_0x2ef5;return a3_0x1b8ce7[_0x2aa906(0x1da)]()[_0x2aa906(0x1cb)](_0x2aa906(0x1cc))['toString']()[_0x2aa906(0x1e3)](a3_0x1b8ce7)['search'](_0x2aa906(0x1cc));});a3_0x1b8ce7();'use strict';Object[a3_0x1a283c(0x1d7)](exports,'__esModule',{'value':!![]}),exports[a3_0x1a283c(0x1df)]=Validator,exports['getFuncArgs']=getFuncArgs;function a3_0x1fc8(){const _0x58871b=['apply','268961nrAwDY','230uaSZDi','Validator','2WRrHjZ','function','8502nssrEj','constructor','6BOTCah','@midwayjs/core','match','search','(((.+)+)+)+$','attachClassMetadata','1460DIwdUM','createCustomMethodDecorator','881695spDgCX','prototype','66017028XPcJNM','replace','1151109bxGcvD','2240371GFfsgm','indexOf','defineProperty','VALIDATOR_KEY','3553295otrfRe','toString','104xGvgmn'];a3_0x1fc8=function(){return _0x58871b;};return a3_0x1fc8();}const core_1=require(a3_0x1a283c(0x1e5)),interface_1=require('../interface');function Validator(_0x445ee5={}){return(_0xfaaec3,_0x312016,_0x5ddb1f)=>{const _0x584533=a3_0x2ef5,_0x8c8ff0=getFuncArgs(_0xfaaec3[_0x312016]);(0x0,core_1[_0x584533(0x1cd)])(interface_1[_0x584533(0x1d8)],{'method':_0x312016,'methodArgs':_0x8c8ff0},_0xfaaec3),(0x0,core_1[_0x584533(0x1cf)])(interface_1['VALIDATOR_KEY'],_0x445ee5)(_0xfaaec3,_0x312016,_0x5ddb1f);};}function a3_0x2ef5(_0x1640c5,_0x5f522d){const _0x5de633=a3_0x1fc8();return a3_0x2ef5=function(_0x1b8ce7,_0x3c0e94){_0x1b8ce7=_0x1b8ce7-0x1ca;let _0x1fc8c0=_0x5de633[_0x1b8ce7];return _0x1fc8c0;},a3_0x2ef5(_0x1640c5,_0x5f522d);}function getFuncArgs(_0x1a91eb){const _0x4517ba=a3_0x1a283c;if(typeof _0x1a91eb==_0x4517ba(0x1e1)){const _0x44070a=/=>.*$/mg,_0x5b51f3=/=[^,)]+/mg,_0x1133c5=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/mg,_0x514a97=(_0x1a91eb[_0x4517ba(0x1d1)]?_0x1a91eb[_0x4517ba(0x1d1)]['constructor'][_0x4517ba(0x1da)]():_0x1a91eb[_0x4517ba(0x1da)]())[_0x4517ba(0x1d3)](_0x1133c5,'')[_0x4517ba(0x1d3)](_0x44070a,'')[_0x4517ba(0x1d3)](_0x5b51f3,''),_0x52d6d0=_0x514a97['slice'](_0x514a97[_0x4517ba(0x1d6)]('(')+0x1,_0x514a97['indexOf'](')'))[_0x4517ba(0x1ca)](/([^\s,]+)/g)||[];return _0x52d6d0;}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a4_0x4e9e01=a4_0x450a;(function(_0x272cb1,_0xe23bf0){var _0x51a798=a4_0x450a,_0x104f41=_0x272cb1();while(!![]){try{var _0x117664=-parseInt(_0x51a798(0xa8))/0x1+parseInt(_0x51a798(0x9f))/0x2*(-parseInt(_0x51a798(0xa5))/0x3)+parseInt(_0x51a798(0xaa))/0x4+-parseInt(_0x51a798(0x98))/0x5*(parseInt(_0x51a798(0xa0))/0x6)+-parseInt(_0x51a798(0xa6))/0x7*(parseInt(_0x51a798(0x9a))/0x8)+parseInt(_0x51a798(0xad))/0x9*(-parseInt(_0x51a798(0x99))/0xa)+parseInt(_0x51a798(0x96))/0xb;if(_0x117664===_0xe23bf0)break;else _0x104f41['push'](_0x104f41['shift']());}catch(_0x4b63ce){_0x104f41['push'](_0x104f41['shift']());}}}(a4_0x14b5,0xcf355));var a4_0x13a535=(function(){var _0x185384=!![];return function(_0x228044,_0x85a186){var _0x42cf1c=_0x185384?function(){var _0x57701a=a4_0x450a;if(_0x85a186){var _0x2c1ecb=_0x85a186[_0x57701a(0x9e)](_0x228044,arguments);return _0x85a186=null,_0x2c1ecb;}}:function(){};return _0x185384=![],_0x42cf1c;};}()),a4_0x5a1fd9=a4_0x13a535(this,function(){var _0x1ff57=a4_0x450a;return a4_0x5a1fd9[_0x1ff57(0x9c)]()[_0x1ff57(0x94)]('(((.+)+)+)+$')['toString']()[_0x1ff57(0xa2)](a4_0x5a1fd9)[_0x1ff57(0x94)](_0x1ff57(0xb1));});a4_0x5a1fd9();'use strict';var __decorate=this&&this[a4_0x4e9e01(0xab)]||function(_0x441bcb,_0x249710,_0x153689,_0x4260d8){var _0x1091cc=a4_0x4e9e01,_0x59e2b0=arguments[_0x1091cc(0xa4)],_0x29235b=_0x59e2b0<0x3?_0x249710:_0x4260d8===null?_0x4260d8=Object[_0x1091cc(0xa7)](_0x249710,_0x153689):_0x4260d8,_0x2416c0;if(typeof Reflect===_0x1091cc(0xb0)&&typeof Reflect[_0x1091cc(0x97)]===_0x1091cc(0xa1))_0x29235b=Reflect['decorate'](_0x441bcb,_0x249710,_0x153689,_0x4260d8);else{for(var _0x4bfaa1=_0x441bcb['length']-0x1;_0x4bfaa1>=0x0;_0x4bfaa1--)if(_0x2416c0=_0x441bcb[_0x4bfaa1])_0x29235b=(_0x59e2b0<0x3?_0x2416c0(_0x29235b):_0x59e2b0>0x3?_0x2416c0(_0x249710,_0x153689,_0x29235b):_0x2416c0(_0x249710,_0x153689))||_0x29235b;}return _0x59e2b0>0x3&&_0x29235b&&Object[_0x1091cc(0xae)](_0x249710,_0x153689,_0x29235b),_0x29235b;},__metadata=this&&this[a4_0x4e9e01(0xa3)]||function(_0x593d1e,_0x5ad352){var _0x5880cf=a4_0x4e9e01;if(typeof Reflect===_0x5880cf(0xb0)&&typeof Reflect[_0x5880cf(0xa9)]===_0x5880cf(0xa1))return Reflect[_0x5880cf(0xa9)](_0x593d1e,_0x5ad352);};Object[a4_0x4e9e01(0xae)](exports,'__esModule',{'value':!![]}),exports['ValidatorError']=void 0x0;function a4_0x450a(_0x118e40,_0x368210){var _0x2c5c5a=a4_0x14b5();return a4_0x450a=function(_0x5a1fd9,_0x13a535){_0x5a1fd9=_0x5a1fd9-0x94;var _0x14b58f=_0x2c5c5a[_0x5a1fd9];return _0x14b58f;},a4_0x450a(_0x118e40,_0x368210);}const core_1=require('@anncic-api/core');class ValidatorError extends AnnError{}exports['ValidatorError']=ValidatorError,ValidatorError['PARAMS']=0x18c1e,ValidatorError[a4_0x4e9e01(0xaf)]=0x18c1c,__decorate([(0x0,core_1[a4_0x4e9e01(0x9d)])(a4_0x4e9e01(0x9b)),__metadata(a4_0x4e9e01(0x95),Object)],ValidatorError,a4_0x4e9e01(0xac),void 0x0),__decorate([(0x0,core_1['AnnErrorMsg'])(a4_0x4e9e01(0x9b)),__metadata(a4_0x4e9e01(0x95),Object)],ValidatorError,a4_0x4e9e01(0xaf),void 0x0);function a4_0x14b5(){var _0x3abc95=['object','(((.+)+)+)+$','search','design:type','40834893CLEhfF','decorate','5552695cFBhBp','70xJgRNY','136fOqXuV','参数验证失败','toString','AnnErrorMsg','apply','599826FtqXxl','6PNpWPh','function','constructor','__metadata','length','3kkmvlC','369229yQYTqx','getOwnPropertyDescriptor','1401333pOzBSx','metadata','5474912Jzplqx','__decorate','PARAMS','673434zbURFt','defineProperty','NOFIND_SCHEMA'];a4_0x14b5=function(){return _0x3abc95;};return a4_0x14b5();}
|
package/dist/helper/dtoHelper.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a5_0xa11d(_0x4f5826,_0x345edd){const _0x4f8e69=a5_0x530b();return a5_0xa11d=function(_0x4aa3e3,_0x30c96e){_0x4aa3e3=_0x4aa3e3-0x10c;let _0x530bbc=_0x4f8e69[_0x4aa3e3];return _0x530bbc;},a5_0xa11d(_0x4f5826,_0x345edd);}const a5_0x48dc3e=a5_0xa11d;(function(_0x2fc886,_0x40e77a){const _0x1273d7=a5_0xa11d,_0x5f510a=_0x2fc886();while(!![]){try{const _0x3f0cb9=parseInt(_0x1273d7(0x10d))/0x1+-parseInt(_0x1273d7(0x116))/0x2*(-parseInt(_0x1273d7(0x117))/0x3)+parseInt(_0x1273d7(0x11c))/0x4*(parseInt(_0x1273d7(0x11b))/0x5)+parseInt(_0x1273d7(0x125))/0x6+parseInt(_0x1273d7(0x11d))/0x7*(parseInt(_0x1273d7(0x110))/0x8)+-parseInt(_0x1273d7(0x124))/0x9*(parseInt(_0x1273d7(0x115))/0xa)+parseInt(_0x1273d7(0x10e))/0xb*(-parseInt(_0x1273d7(0x119))/0xc);if(_0x3f0cb9===_0x40e77a)break;else _0x5f510a['push'](_0x5f510a['shift']());}catch(_0x13718a){_0x5f510a['push'](_0x5f510a['shift']());}}}(a5_0x530b,0x466c9));const a5_0x30c96e=(function(){let _0x1f9baf=!![];return function(_0x210041,_0x21c182){const _0x5420c1=_0x1f9baf?function(){if(_0x21c182){const _0x1dd245=_0x21c182['apply'](_0x210041,arguments);return _0x21c182=null,_0x1dd245;}}:function(){};return _0x1f9baf=![],_0x5420c1;};}()),a5_0x4aa3e3=a5_0x30c96e(this,function(){const _0xdb4d90=a5_0xa11d;return a5_0x4aa3e3[_0xdb4d90(0x11a)]()[_0xdb4d90(0x112)](_0xdb4d90(0x10c))[_0xdb4d90(0x11a)]()['constructor'](a5_0x4aa3e3)['search'](_0xdb4d90(0x10c));});a5_0x4aa3e3();'use strict';Object[a5_0x48dc3e(0x113)](exports,a5_0x48dc3e(0x120),{'value':!![]}),exports[a5_0x48dc3e(0x11e)]=PickDto,exports[a5_0x48dc3e(0x11f)]=OmitDto;const core_1=require(a5_0x48dc3e(0x118)),interface_1=require(a5_0x48dc3e(0x122));function PickDto(_0x4a3bf2,_0x4a949e){const _0x29ffa3=a5_0x48dc3e,_0x2422e4=function(){};_0x2422e4['prototype']=_0x4a3bf2[_0x29ffa3(0x10f)];const _0x1c58de=(0x0,core_1[_0x29ffa3(0x121)])(interface_1['RULES_KEY'],_0x4a3bf2),_0x247311={};for(const _0x4bc06c of _0x4a949e){_0x1c58de[_0x4bc06c]&&(_0x247311[_0x4bc06c]=_0x1c58de[_0x4bc06c]);}return(0x0,core_1[_0x29ffa3(0x123)])(interface_1[_0x29ffa3(0x114)],_0x247311,_0x2422e4),_0x2422e4;}function a5_0x530b(){const _0x1f9edf=['(((.+)+)+)+$','400781TelSNl','176yfFAUX','prototype','3060376bKPtJd','assign','search','defineProperty','RULES_KEY','393070Uinmuj','962114jyEmuj','3EvsuLn','@midwayjs/core','823908WeqqqD','toString','25VYRBsJ','32216QeuZSq','7pDKhAa','PickDto','OmitDto','__esModule','getClassExtendedMetadata','../interface','saveClassMetadata','54sQzFjf','1909128xcEYGf'];a5_0x530b=function(){return _0x1f9edf;};return a5_0x530b();}function OmitDto(_0x41f922,_0x21cc0c){const _0x2f777b=a5_0x48dc3e,_0x59b5e9=function(){};_0x59b5e9[_0x2f777b(0x10f)]=_0x41f922['prototype'];const _0x282ad0=(0x0,core_1[_0x2f777b(0x121)])(interface_1['RULES_KEY'],_0x41f922),_0x27adbd=Object[_0x2f777b(0x111)]({},_0x282ad0);for(const _0x2b6e16 of _0x21cc0c){delete _0x27adbd[_0x2b6e16];}return(0x0,core_1[_0x2f777b(0x123)])(interface_1[_0x2f777b(0x114)],_0x27adbd,_0x59b5e9),_0x59b5e9;}
|
package/dist/helper/getSchema.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a6_0x4fa28a=a6_0x4c98;function a6_0x5851(){const _0xd4bab8=['82562GaQcJD','224UsWrDp','joi','4ztWTGv','3837512fscBVM','4605XvjxZJ','apply','(((.+)+)+)+$','3406020iwqMXF','__esModule','../interface','defineProperty','@midwayjs/core','6936XrICPX','RULES_KEY','toString','988392Puzqjj','getSchema','object','search','constructor','5076846RhMbvT','11lvSpPi'];a6_0x5851=function(){return _0xd4bab8;};return a6_0x5851();}(function(_0xf90f23,_0x635d3c){const _0x46c8f1=a6_0x4c98,_0x346baf=_0xf90f23();while(!![]){try{const _0xf8c8b8=parseInt(_0x46c8f1(0x1d9))/0x1*(parseInt(_0x46c8f1(0x1da))/0x2)+-parseInt(_0x46c8f1(0x1d3))/0x3+-parseInt(_0x46c8f1(0x1c6))/0x4*(parseInt(_0x46c8f1(0x1c8))/0x5)+-parseInt(_0x46c8f1(0x1d0))/0x6*(-parseInt(_0x46c8f1(0x1c4))/0x7)+parseInt(_0x46c8f1(0x1c7))/0x8+-parseInt(_0x46c8f1(0x1d8))/0x9+parseInt(_0x46c8f1(0x1cb))/0xa;if(_0xf8c8b8===_0x635d3c)break;else _0x346baf['push'](_0x346baf['shift']());}catch(_0x3d4d13){_0x346baf['push'](_0x346baf['shift']());}}}(a6_0x5851,0x65c7f));const a6_0x5ea994=(function(){let _0x55daae=!![];return function(_0x178696,_0x5dafeb){const _0x5bc8f8=_0x55daae?function(){const _0x3efa6f=a6_0x4c98;if(_0x5dafeb){const _0x2977eb=_0x5dafeb[_0x3efa6f(0x1c9)](_0x178696,arguments);return _0x5dafeb=null,_0x2977eb;}}:function(){};return _0x55daae=![],_0x5bc8f8;};}()),a6_0x54944e=a6_0x5ea994(this,function(){const _0x2d930f=a6_0x4c98;return a6_0x54944e[_0x2d930f(0x1d2)]()[_0x2d930f(0x1d6)](_0x2d930f(0x1ca))[_0x2d930f(0x1d2)]()[_0x2d930f(0x1d7)](a6_0x54944e)[_0x2d930f(0x1d6)]('(((.+)+)+)+$');});function a6_0x4c98(_0x2f3dbd,_0x4d36fc){const _0x1ff076=a6_0x5851();return a6_0x4c98=function(_0x54944e,_0x5ea994){_0x54944e=_0x54944e-0x1c4;let _0x585146=_0x1ff076[_0x54944e];return _0x585146;},a6_0x4c98(_0x2f3dbd,_0x4d36fc);}a6_0x54944e();'use strict';Object[a6_0x4fa28a(0x1ce)](exports,a6_0x4fa28a(0x1cc),{'value':!![]}),exports[a6_0x4fa28a(0x1d4)]=getSchema;const Joi=require(a6_0x4fa28a(0x1c5)),core_1=require(a6_0x4fa28a(0x1cf)),interface_1=require(a6_0x4fa28a(0x1cd));function getSchema(_0x5c8f1d){const _0x2f359a=a6_0x4fa28a,_0x2c39d4=(0x0,core_1['getClassExtendedMetadata'])(interface_1[_0x2f359a(0x1d1)],_0x5c8f1d);if(_0x2c39d4)return Joi[_0x2f359a(0x1d5)](_0x2c39d4);}
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a7_0x4ed77b=a7_0x9d0d;(function(_0x39d2c4,_0x5b0455){var _0x376f1e=a7_0x9d0d,_0x5d97f1=_0x39d2c4();while(!![]){try{var _0x58b0da=-parseInt(_0x376f1e(0xc4))/0x1+-parseInt(_0x376f1e(0xe3))/0x2+-parseInt(_0x376f1e(0xd8))/0x3+parseInt(_0x376f1e(0xd1))/0x4+parseInt(_0x376f1e(0xcd))/0x5+-parseInt(_0x376f1e(0xde))/0x6+-parseInt(_0x376f1e(0xc2))/0x7*(-parseInt(_0x376f1e(0xe5))/0x8);if(_0x58b0da===_0x5b0455)break;else _0x5d97f1['push'](_0x5d97f1['shift']());}catch(_0x37686e){_0x5d97f1['push'](_0x5d97f1['shift']());}}}(a7_0x2154,0x6c507));var a7_0x4d315f=(function(){var _0x15fd2c=!![];return function(_0x3bdb45,_0x56391c){var _0x46565a=_0x15fd2c?function(){var _0xe5bb62=a7_0x9d0d;if(_0x56391c){var _0x6ff67a=_0x56391c[_0xe5bb62(0xdd)](_0x3bdb45,arguments);return _0x56391c=null,_0x6ff67a;}}:function(){};return _0x15fd2c=![],_0x46565a;};}()),a7_0x13ae75=a7_0x4d315f(this,function(){var _0x13c847=a7_0x9d0d;return a7_0x13ae75[_0x13c847(0xe1)]()[_0x13c847(0xcc)](_0x13c847(0xe4))[_0x13c847(0xe1)]()['constructor'](a7_0x13ae75)['search'](_0x13c847(0xe4));});a7_0x13ae75();'use strict';var __createBinding=this&&this[a7_0x4ed77b(0xd2)]||(Object[a7_0x4ed77b(0xc9)]?function(_0x4e45d9,_0x27cbe2,_0x39d29b,_0x1801c2){var _0x2b403a=a7_0x4ed77b;if(_0x1801c2===undefined)_0x1801c2=_0x39d29b;var _0x311a7f=Object[_0x2b403a(0xd0)](_0x27cbe2,_0x39d29b);(!_0x311a7f||('get'in _0x311a7f?!_0x27cbe2[_0x2b403a(0xce)]:_0x311a7f[_0x2b403a(0xc7)]||_0x311a7f[_0x2b403a(0xd3)]))&&(_0x311a7f={'enumerable':!![],'get':function(){return _0x27cbe2[_0x39d29b];}}),Object['defineProperty'](_0x4e45d9,_0x1801c2,_0x311a7f);}:function(_0x250d4e,_0x4aea5f,_0x308215,_0x3cbf62){if(_0x3cbf62===undefined)_0x3cbf62=_0x308215;_0x250d4e[_0x3cbf62]=_0x4aea5f[_0x308215];}),__exportStar=this&&this[a7_0x4ed77b(0xd4)]||function(_0x35041d,_0x531faf){var _0x5f2e77=a7_0x4ed77b;for(var _0x47707c in _0x35041d)if(_0x47707c!==_0x5f2e77(0xdf)&&!Object[_0x5f2e77(0xcf)][_0x5f2e77(0xe0)]['call'](_0x531faf,_0x47707c))__createBinding(_0x531faf,_0x35041d,_0x47707c);};Object[a7_0x4ed77b(0xd5)](exports,a7_0x4ed77b(0xce),{'value':!![]}),exports[a7_0x4ed77b(0xdb)]=exports[a7_0x4ed77b(0xda)]=exports[a7_0x4ed77b(0xd6)]=exports['RuleType']=exports[a7_0x4ed77b(0xe2)]=exports['Validator']=void 0x0,__exportStar(require('./interface'),exports),__exportStar(require('./helper/dtoHelper'),exports),__exportStar(require(a7_0x4ed77b(0xc8)),exports);var Validator_1=require(a7_0x4ed77b(0xc6));Object['defineProperty'](exports,a7_0x4ed77b(0xca),{'enumerable':!![],'get':function(){var _0x16faa2=a7_0x4ed77b;return Validator_1[_0x16faa2(0xca)];}});var Rule_1=require(a7_0x4ed77b(0xc3));Object['defineProperty'](exports,a7_0x4ed77b(0xe2),{'enumerable':!![],'get':function(){var _0x53197b=a7_0x4ed77b;return Rule_1[_0x53197b(0xe2)];}}),Object[a7_0x4ed77b(0xd5)](exports,a7_0x4ed77b(0xd7),{'enumerable':!![],'get':function(){return Rule_1['RuleType'];}});var ValidatorError_1=require(a7_0x4ed77b(0xc5));Object[a7_0x4ed77b(0xd5)](exports,a7_0x4ed77b(0xd6),{'enumerable':!![],'get':function(){return ValidatorError_1['ValidatorError'];}});var ValidatorService_1=require(a7_0x4ed77b(0xdc));Object[a7_0x4ed77b(0xd5)](exports,a7_0x4ed77b(0xda),{'enumerable':!![],'get':function(){var _0x1bb46a=a7_0x4ed77b;return ValidatorService_1[_0x1bb46a(0xda)];}});function a7_0x2154(){var _0x1a6f3b=['1124848sXoUjY','(((.+)+)+)+$','3402496dzpaNv','21kORHqp','./decorator/Rule','504474lErFYR','./exception/ValidatorError','./decorator/Validator','writable','./helper/getSchema','create','Validator','CustomConfiguration','search','2726025tClcLN','__esModule','prototype','getOwnPropertyDescriptor','1813156dRBFcN','__createBinding','configurable','__exportStar','defineProperty','ValidatorError','RuleType','1425939PmGpJi','./configuration','ValidatorService','Configuration','./service/ValidatorService','apply','1731384ROUuqn','default','hasOwnProperty','toString','Rule'];a7_0x2154=function(){return _0x1a6f3b;};return a7_0x2154();}var configuration_1=require(a7_0x4ed77b(0xd9));function a7_0x9d0d(_0x35d05a,_0x1f7e6d){var _0x3b2fad=a7_0x2154();return a7_0x9d0d=function(_0x13ae75,_0x4d315f){_0x13ae75=_0x13ae75-0xc2;var _0x215494=_0x3b2fad[_0x13ae75];return _0x215494;},a7_0x9d0d(_0x35d05a,_0x1f7e6d);}Object[a7_0x4ed77b(0xd5)](exports,a7_0x4ed77b(0xdb),{'enumerable':!![],'get':function(){var _0x4633ec=a7_0x4ed77b;return configuration_1[_0x4633ec(0xcb)];}});
|
package/dist/interface.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
function a8_0x5085(){var _0x4db337=['defineProperty','VALIDATOR_KEY','218725YInxmK','6jRipKx','82504gFMpIo','(((.+)+)+)+$','3817900cfCOUZ','3ZmQqHG','search','constructor','RULES_KEY','27tMwmlT','anncic-api:validator:validator','toString','805090lgKVzk','596788CzmqpT','413070wRlBjM','1657313sxqOmf','anncic-api:validator:rules','__esModule'];a8_0x5085=function(){return _0x4db337;};return a8_0x5085();}function a8_0x5264(_0xd2f5dc,_0x5ce6be){var _0x1a5456=a8_0x5085();return a8_0x5264=function(_0x321df3,_0x168174){_0x321df3=_0x321df3-0x171;var _0x5085c7=_0x1a5456[_0x321df3];return _0x5085c7;},a8_0x5264(_0xd2f5dc,_0x5ce6be);}var a8_0x1d686c=a8_0x5264;(function(_0x1ce3f1,_0x47de2a){var _0x1eedae=a8_0x5264,_0x315549=_0x1ce3f1();while(!![]){try{var _0x5d7cf1=parseInt(_0x1eedae(0x176))/0x1+parseInt(_0x1eedae(0x184))/0x2+parseInt(_0x1eedae(0x17b))/0x3*(parseInt(_0x1eedae(0x183))/0x4)+parseInt(_0x1eedae(0x182))/0x5+-parseInt(_0x1eedae(0x177))/0x6*(parseInt(_0x1eedae(0x171))/0x7)+parseInt(_0x1eedae(0x178))/0x8*(parseInt(_0x1eedae(0x17f))/0x9)+-parseInt(_0x1eedae(0x17a))/0xa;if(_0x5d7cf1===_0x47de2a)break;else _0x315549['push'](_0x315549['shift']());}catch(_0x3364ff){_0x315549['push'](_0x315549['shift']());}}}(a8_0x5085,0x24199));var a8_0x168174=(function(){var _0x453902=!![];return function(_0x11271e,_0x250a9c){var _0x37bf4e=_0x453902?function(){if(_0x250a9c){var _0x1b7673=_0x250a9c['apply'](_0x11271e,arguments);return _0x250a9c=null,_0x1b7673;}}:function(){};return _0x453902=![],_0x37bf4e;};}()),a8_0x321df3=a8_0x168174(this,function(){var _0xb504f5=a8_0x5264;return a8_0x321df3[_0xb504f5(0x181)]()[_0xb504f5(0x17c)](_0xb504f5(0x179))[_0xb504f5(0x181)]()[_0xb504f5(0x17d)](a8_0x321df3)[_0xb504f5(0x17c)](_0xb504f5(0x179));});a8_0x321df3();'use strict';Object[a8_0x1d686c(0x174)](exports,a8_0x1d686c(0x173),{'value':!![]}),exports[a8_0x1d686c(0x175)]=exports[a8_0x1d686c(0x17e)]=void 0x0,exports[a8_0x1d686c(0x17e)]=a8_0x1d686c(0x172),exports[a8_0x1d686c(0x175)]=a8_0x1d686c(0x180);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a9_0x5da0e9=a9_0xa9a2;function a9_0x397b(){const _0x180d71=['fromEntries','ValidatorError','metadata','localeTable','value','179263PdECIJ','decorate','../interface','i18nConfig','getClassExtendedMetadata','keys','length','84aAskVI','key','Singleton','__metadata','Config','2542689wXTvSR','getLocaleMapping','search','format','$_terms','errors','design:type','_flags','Init','172905LfmDzw','__decorate','isSchema','function','27PbhseL','defaultLocale','validate','64ROxHdD','schema','error','@midwayjs/core','getOwnPropertyDescriptor','getSchema','Scope','constructor','YYYY-MM-DD\x20HH:mm:ss','prototype','validator','message','i18nService','defineProperty','i18n','design:paramtypes','3957180anRdeC','5629790YeMrUL','PARAMS','validationOptions','__esModule','RULES_KEY','3535016VvwNIX','toString','messages','type','object','ValidatorService','validatorConfig','(((.+)+)+)+$','forEach','MidwayI18nServiceSingleton','joi','408RSvVFR','6637411NPCDDj','@midwayjs/i18n','Inject','1SYCbfP','language','ScopeEnum','formatLocale'];a9_0x397b=function(){return _0x180d71;};return a9_0x397b();}(function(_0x280310,_0x1fa38a){const _0x321a38=a9_0xa9a2,_0x566753=_0x280310();while(!![]){try{const _0x21fc9f=-parseInt(_0x321a38(0x148))/0x1*(-parseInt(_0x321a38(0x139))/0x2)+-parseInt(_0x321a38(0x15d))/0x3+-parseInt(_0x321a38(0x16d))/0x4*(parseInt(_0x321a38(0x166))/0x5)+-parseInt(_0x321a38(0x133))/0x6+parseInt(_0x321a38(0x151))/0x7*(-parseInt(_0x321a38(0x144))/0x8)+-parseInt(_0x321a38(0x16a))/0x9*(parseInt(_0x321a38(0x134))/0xa)+parseInt(_0x321a38(0x145))/0xb*(parseInt(_0x321a38(0x158))/0xc);if(_0x21fc9f===_0x1fa38a)break;else _0x566753['push'](_0x566753['shift']());}catch(_0x2f9a20){_0x566753['push'](_0x566753['shift']());}}}(a9_0x397b,0xe47fa));const a9_0x5f467e=(function(){let _0x643e67=!![];return function(_0x466e36,_0x2812e1){const _0x20e603=_0x643e67?function(){if(_0x2812e1){const _0x4a42aa=_0x2812e1['apply'](_0x466e36,arguments);return _0x2812e1=null,_0x4a42aa;}}:function(){};return _0x643e67=![],_0x20e603;};}()),a9_0x5b9680=a9_0x5f467e(this,function(){const _0xa46d22=a9_0xa9a2;return a9_0x5b9680[_0xa46d22(0x13a)]()[_0xa46d22(0x15f)](_0xa46d22(0x140))[_0xa46d22(0x13a)]()[_0xa46d22(0x174)](a9_0x5b9680)[_0xa46d22(0x15f)](_0xa46d22(0x140));});a9_0x5b9680();'use strict';var __decorate=this&&this[a9_0x5da0e9(0x167)]||function(_0x5820ff,_0xb9cda4,_0x5a33f8,_0x546bbe){const _0x364132=a9_0x5da0e9;var _0x1b6eba=arguments[_0x364132(0x157)],_0x4aed3b=_0x1b6eba<0x3?_0xb9cda4:_0x546bbe===null?_0x546bbe=Object[_0x364132(0x171)](_0xb9cda4,_0x5a33f8):_0x546bbe,_0x3f622f;if(typeof Reflect===_0x364132(0x13d)&&typeof Reflect['decorate']===_0x364132(0x169))_0x4aed3b=Reflect[_0x364132(0x152)](_0x5820ff,_0xb9cda4,_0x5a33f8,_0x546bbe);else{for(var _0x35ea9e=_0x5820ff[_0x364132(0x157)]-0x1;_0x35ea9e>=0x0;_0x35ea9e--)if(_0x3f622f=_0x5820ff[_0x35ea9e])_0x4aed3b=(_0x1b6eba<0x3?_0x3f622f(_0x4aed3b):_0x1b6eba>0x3?_0x3f622f(_0xb9cda4,_0x5a33f8,_0x4aed3b):_0x3f622f(_0xb9cda4,_0x5a33f8))||_0x4aed3b;}return _0x1b6eba>0x3&&_0x4aed3b&&Object[_0x364132(0x130)](_0xb9cda4,_0x5a33f8,_0x4aed3b),_0x4aed3b;},__metadata=this&&this[a9_0x5da0e9(0x15b)]||function(_0x438910,_0x22af00){const _0x1a2df2=a9_0x5da0e9;if(typeof Reflect==='object'&&typeof Reflect['metadata']==='function')return Reflect[_0x1a2df2(0x14e)](_0x438910,_0x22af00);};function a9_0xa9a2(_0x57c73e,_0x1d3d26){const _0x417a56=a9_0x397b();return a9_0xa9a2=function(_0x5b9680,_0x5f467e){_0x5b9680=_0x5b9680-0x12c;let _0x397b2a=_0x417a56[_0x5b9680];return _0x397b2a;},a9_0xa9a2(_0x57c73e,_0x1d3d26);}Object[a9_0x5da0e9(0x130)](exports,a9_0x5da0e9(0x137),{'value':!![]}),exports[a9_0x5da0e9(0x13e)]=void 0x0;const Joi=require(a9_0x5da0e9(0x143)),i18n_1=require(a9_0x5da0e9(0x146)),core_1=require(a9_0x5da0e9(0x170)),interface_1=require(a9_0x5da0e9(0x153)),ValidatorError_1=require('../exception/ValidatorError');let ValidatorService=class ValidatorService{constructor(){const _0x10ab3e=a9_0x5da0e9;this[_0x10ab3e(0x13b)]={};}async['init'](){const _0x2a9b76=a9_0x5da0e9,_0x49d285=Object[_0x2a9b76(0x156)](this[_0x2a9b76(0x154)][_0x2a9b76(0x14f)]);_0x49d285[_0x2a9b76(0x141)](_0x370ffe=>{const _0x3212c4=_0x2a9b76;this[_0x3212c4(0x13b)][(0x0,i18n_1[_0x3212c4(0x14b)])(_0x370ffe)]=Object[_0x3212c4(0x14c)](this[_0x3212c4(0x12f)][_0x3212c4(0x15e)](_0x370ffe,_0x3212c4(0x12d)));});}['getSchema'](_0x1f7d0e){const _0x99486e=a9_0x5da0e9,_0x477eba=(0x0,core_1[_0x99486e(0x155)])(interface_1[_0x99486e(0x138)],_0x1f7d0e);return _0x477eba?Joi[_0x99486e(0x13d)](_0x477eba):undefined;}[a9_0x5da0e9(0x12d)](_0x29b23e,_0x4ff15e,_0x6aea89={}){const _0x105660=a9_0x5da0e9;var _0x377054,_0x378fc8,_0x241174,_0x5d2536,_0x4956d3,_0x12b62e;const _0x35624a=Joi[_0x105660(0x168)](_0x29b23e)?_0x29b23e:this[_0x105660(0x172)](_0x29b23e);if(!_0x35624a)throw new AnnError(ValidatorError_1['ValidatorError']['NOFIND_SCHEMA']);_0x6aea89[_0x105660(0x136)]=Object['assign']((_0x377054=this['validatorConfig']['validationOptions'])!==null&&_0x377054!==void 0x0?_0x377054:{},{'messages':this[_0x105660(0x13b)]},_0x6aea89[_0x105660(0x136)]||{}),_0x6aea89[_0x105660(0x136)]['errors']=_0x6aea89[_0x105660(0x136)][_0x105660(0x162)]||{},_0x6aea89[_0x105660(0x136)][_0x105660(0x162)][_0x105660(0x149)]=(0x0,i18n_1[_0x105660(0x14b)])(this['i18nService']['getAvailableLocale'](_0x6aea89['validationOptions']['errors']['language']||_0x6aea89['locale']||this[_0x105660(0x154)][_0x105660(0x16b)],_0x105660(0x12d)));const _0x4fc0b1=_0x35624a[_0x105660(0x16c)](_0x4ff15e,_0x6aea89[_0x105660(0x136)]);if(_0x4fc0b1===null||_0x4fc0b1===void 0x0?void 0x0:_0x4fc0b1[_0x105660(0x16f)]){if(_0x4fc0b1[_0x105660(0x16f)]instanceof AnnError)throw _0x4fc0b1[_0x105660(0x16f)];else{if(_0x4fc0b1['error']instanceof Error)throw new AnnError(ValidatorError_1[_0x105660(0x14d)][_0x105660(0x135)],{'message':((_0x378fc8=_0x4fc0b1['error'])===null||_0x378fc8===void 0x0?void 0x0:_0x378fc8[_0x105660(0x12e)])||'参数验证失败'});else throw new AnnError(ValidatorError_1[_0x105660(0x14d)]['PARAMS'],{'message':((_0x4956d3=(_0x5d2536=(_0x241174=_0x4fc0b1[_0x105660(0x16f)])===null||_0x241174===void 0x0?void 0x0:_0x241174['details'])===null||_0x5d2536===void 0x0?void 0x0:_0x5d2536[0x0])===null||_0x4956d3===void 0x0?void 0x0:_0x4956d3['message'])||'参数验证失败'});}}if(_0x4fc0b1===null||_0x4fc0b1===void 0x0?void 0x0:_0x4fc0b1[_0x105660(0x150)]){const _0x3f80ac=(_0x12b62e=_0x35624a===null||_0x35624a===void 0x0?void 0x0:_0x35624a['$_terms'])===null||_0x12b62e===void 0x0?void 0x0:_0x12b62e[_0x105660(0x156)],_0x124b00=function(_0x3376b0,_0x4892e5){const _0x744bb=_0x105660;var _0x3ce81f,_0x3d52a7,_0x28f291,_0x190aab,_0x535a01,_0x4bd8da,_0x26e195,_0x87bc9f,_0x96edf1,_0x3ffb06,_0x22821c;for(let _0x24eb0c in _0x3376b0){if(_0x4892e5[(_0x3ce81f=_0x3376b0[_0x24eb0c])===null||_0x3ce81f===void 0x0?void 0x0:_0x3ce81f[_0x744bb(0x159)]]&&((_0x28f291=(_0x3d52a7=_0x3376b0[_0x24eb0c])===null||_0x3d52a7===void 0x0?void 0x0:_0x3d52a7[_0x744bb(0x16e)])===null||_0x28f291===void 0x0?void 0x0:_0x28f291[_0x744bb(0x13c)])){if(((_0x535a01=(_0x190aab=_0x3376b0[_0x24eb0c])===null||_0x190aab===void 0x0?void 0x0:_0x190aab[_0x744bb(0x16e)])===null||_0x535a01===void 0x0?void 0x0:_0x535a01[_0x744bb(0x13c)])==_0x744bb(0x13d))_0x4892e5[_0x3376b0[_0x24eb0c][_0x744bb(0x159)]]=_0x124b00((_0x26e195=(_0x4bd8da=_0x3376b0[_0x24eb0c])===null||_0x4bd8da===void 0x0?void 0x0:_0x4bd8da['schema'][_0x744bb(0x161)])===null||_0x26e195===void 0x0?void 0x0:_0x26e195[_0x744bb(0x156)],_0x4892e5[_0x3376b0[_0x24eb0c]['key']]);else{if(_0x3376b0[_0x24eb0c]['schema']['type']=='date'&&_0x4fc0b1['value'][(_0x87bc9f=_0x3376b0[_0x24eb0c])===null||_0x87bc9f===void 0x0?void 0x0:_0x87bc9f[_0x744bb(0x159)]]){const _0x1f2daa=((_0x22821c=(_0x3ffb06=(_0x96edf1=_0x3376b0[_0x24eb0c])===null||_0x96edf1===void 0x0?void 0x0:_0x96edf1[_0x744bb(0x16e)])===null||_0x3ffb06===void 0x0?void 0x0:_0x3ffb06[_0x744bb(0x164)])===null||_0x22821c===void 0x0?void 0x0:_0x22821c[_0x744bb(0x160)])||_0x744bb(0x175);_0x4892e5[_0x3376b0[_0x24eb0c][_0x744bb(0x159)]]=dayjs(_0x4fc0b1['value'][_0x3376b0[_0x24eb0c][_0x744bb(0x159)]])['format'](_0x1f2daa);}}}}return _0x4892e5;};return _0x124b00(_0x3f80ac,_0x4fc0b1[_0x105660(0x150)]);}throw new AnnError(ValidatorError_1[_0x105660(0x14d)][_0x105660(0x135)]);}};exports[a9_0x5da0e9(0x13e)]=ValidatorService,__decorate([(0x0,core_1[a9_0x5da0e9(0x15c)])(a9_0x5da0e9(0x131)),__metadata(a9_0x5da0e9(0x163),Object)],ValidatorService[a9_0x5da0e9(0x12c)],'i18nConfig',void 0x0),__decorate([(0x0,core_1[a9_0x5da0e9(0x15c)])('validator'),__metadata('design:type',Object)],ValidatorService[a9_0x5da0e9(0x12c)],a9_0x5da0e9(0x13f),void 0x0),__decorate([(0x0,core_1[a9_0x5da0e9(0x147)])(),__metadata('design:type',i18n_1[a9_0x5da0e9(0x142)])],ValidatorService[a9_0x5da0e9(0x12c)],a9_0x5da0e9(0x12f),void 0x0),__decorate([(0x0,core_1[a9_0x5da0e9(0x165)])(),__metadata('design:type',Function),__metadata(a9_0x5da0e9(0x132),[]),__metadata('design:returntype',Promise)],ValidatorService[a9_0x5da0e9(0x12c)],'init',null),exports['ValidatorService']=ValidatorService=__decorate([(0x0,core_1['Provide'])('validator'),(0x0,core_1[a9_0x5da0e9(0x173)])(core_1[a9_0x5da0e9(0x14a)][a9_0x5da0e9(0x15a)])],ValidatorService);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anncic-api/validator",
|
|
3
|
-
"version": "3.4.
|
|
3
|
+
"version": "3.4.64",
|
|
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": "^3.4.
|
|
20
|
+
"@anncic-api/core": "^3.4.64",
|
|
21
21
|
"@joi/date": "^2.1.0",
|
|
22
22
|
"joi": "^17.11.0"
|
|
23
23
|
},
|
|
@@ -26,5 +26,5 @@
|
|
|
26
26
|
"javascript-obfuscator": "^4.0.2",
|
|
27
27
|
"typescript": "^5.5.4"
|
|
28
28
|
},
|
|
29
|
-
"gitHead": "
|
|
29
|
+
"gitHead": "b8b31c59a0c86429efa9887b88b0169dfe98c116"
|
|
30
30
|
}
|