@anncic-api/validator 3.2.18 → 3.2.21
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
|
-
const
|
|
1
|
+
const a0_0x4931fa=a0_0x95b8;(function(_0x1a100a,_0x523091){const _0x216465=a0_0x95b8,_0xf3b508=_0x1a100a();while(!![]){try{const _0x48f835=-parseInt(_0x216465(0x12f))/0x1*(-parseInt(_0x216465(0x12a))/0x2)+-parseInt(_0x216465(0x128))/0x3*(-parseInt(_0x216465(0x11f))/0x4)+-parseInt(_0x216465(0x127))/0x5*(-parseInt(_0x216465(0x11b))/0x6)+-parseInt(_0x216465(0x11e))/0x7*(parseInt(_0x216465(0x129))/0x8)+-parseInt(_0x216465(0x12d))/0x9*(parseInt(_0x216465(0x11c))/0xa)+-parseInt(_0x216465(0x121))/0xb+-parseInt(_0x216465(0x125))/0xc*(-parseInt(_0x216465(0x131))/0xd);if(_0x48f835===_0x523091)break;else _0xf3b508['push'](_0xf3b508['shift']());}catch(_0x5e2b3e){_0xf3b508['push'](_0xf3b508['shift']());}}}(a0_0x31b6,0x7cd1a));const a0_0x2d785f=(function(){let _0x2ea74d=!![];return function(_0x19510e,_0x23ca25){const _0x484fb7=_0x2ea74d?function(){const _0x36992f=a0_0x95b8;if(_0x23ca25){const _0x4feaa7=_0x23ca25[_0x36992f(0x123)](_0x19510e,arguments);return _0x23ca25=null,_0x4feaa7;}}:function(){};return _0x2ea74d=![],_0x484fb7;};}()),a0_0x5e746e=a0_0x2d785f(this,function(){const _0x2e8a07=a0_0x95b8;return a0_0x5e746e[_0x2e8a07(0x124)]()[_0x2e8a07(0x122)](_0x2e8a07(0x12b))[_0x2e8a07(0x124)]()[_0x2e8a07(0x11d)](a0_0x5e746e)[_0x2e8a07(0x122)](_0x2e8a07(0x12b));});function a0_0x95b8(_0x424856,_0x3a4386){const _0x2135f9=a0_0x31b6();return a0_0x95b8=function(_0x5e746e,_0x2d785f){_0x5e746e=_0x5e746e-0x11b;let _0x31b62b=_0x2135f9[_0x5e746e];return _0x31b62b;},a0_0x95b8(_0x424856,_0x3a4386);}a0_0x5e746e();'use strict';Object[a0_0x4931fa(0x126)](exports,'__esModule',{'value':!![]});const ValidatorError_1=require(a0_0x4931fa(0x12c));function a0_0x31b6(){const _0x30273c=['toString','13088652CVFykL','defineProperty','1944720fdVlef','145185CUzTJn','203584flOzXZ','456oZRrha','(((.+)+)+)+$','../exception/ValidatorError','12429bWRhah','../../locales/en_US.json','2381wOdKJU','PARAMS','13GotJhF','6mqAVoq','3430gogBDO','constructor','231KarbCY','44dVBKij','string','8031683ybiCLO','search','apply'];a0_0x31b6=function(){return _0x30273c;};return a0_0x31b6();}exports['default']={'validator':{'errorStatus':ValidatorError_1['ValidatorError'][a0_0x4931fa(0x130)],'validationOptions':{'allowUnknown':!![],'stripUnknown':!![],'dateFormat':a0_0x4931fa(0x120)}},'i18n':{'localeTable':{'en_US':{'validator':require(a0_0x4931fa(0x12e))},'zh_CN':{'validator':require('../../locales/zh_CN.json')}}}};
|
package/dist/configuration.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a1_0x1f4313=a1_0x43d8;(function(_0xafe5de,_0xab91c6){const _0xc6ef70=a1_0x43d8,_0x2fd6da=_0xafe5de();while(!![]){try{const _0x2209b0=-parseInt(_0xc6ef70(0x137))/0x1*(parseInt(_0xc6ef70(0x13b))/0x2)+-parseInt(_0xc6ef70(0x138))/0x3*(-parseInt(_0xc6ef70(0x13d))/0x4)+-parseInt(_0xc6ef70(0x12a))/0x5+-parseInt(_0xc6ef70(0x119))/0x6*(parseInt(_0xc6ef70(0x11c))/0x7)+-parseInt(_0xc6ef70(0x116))/0x8+parseInt(_0xc6ef70(0x11f))/0x9+parseInt(_0xc6ef70(0x120))/0xa;if(_0x2209b0===_0xab91c6)break;else _0x2fd6da['push'](_0x2fd6da['shift']());}catch(_0x3b35c5){_0x2fd6da['push'](_0x2fd6da['shift']());}}}(a1_0x2434,0xbedab));const a1_0x2ed653=(function(){let _0x3fbc88=!![];return function(_0x5f578a,_0x5e2bf7){const _0x51245e=_0x3fbc88?function(){const _0x22ef77=a1_0x43d8;if(_0x5e2bf7){const _0x1b6025=_0x5e2bf7[_0x22ef77(0x12b)](_0x5f578a,arguments);return _0x5e2bf7=null,_0x1b6025;}}:function(){};return _0x3fbc88=![],_0x51245e;};}()),a1_0x44159b=a1_0x2ed653(this,function(){const _0x53d280=a1_0x43d8;return a1_0x44159b[_0x53d280(0x130)]()['search'](_0x53d280(0x125))['toString']()['constructor'](a1_0x44159b)['search'](_0x53d280(0x125));});function a1_0x43d8(_0x1c32ab,_0x7b6bdd){const _0x56ab00=a1_0x2434();return a1_0x43d8=function(_0x44159b,_0x2ed653){_0x44159b=_0x44159b-0x115;let _0x24341d=_0x56ab00[_0x44159b];return _0x24341d;},a1_0x43d8(_0x1c32ab,_0x7b6bdd);}function a1_0x2434(){const _0x42de17=['@anncic-api/core','8gRUmUO','@midwayjs/i18n','design:type','methodName','./service/ValidatorService','onReady','args','@midwayjs/core','anncic-api:validator','undefined','__esModule','ValidatorService','body','CustomConfiguration','splice','defineProperty','prototype','REQUEST_OBJ_CTX_KEY','9100048fQPpgj','./config/config.default','getOwnPropertyDescriptor','120bqEPBZ','length','methodArgs','93373ZbwAPV','res','function','7098084WgSUdf','30319660XFbttp','decorator','object','params','decorate','(((.+)+)+)+$','VALIDATOR_KEY','Inject','__decorate','getMethodParamTypes','5368080ReSlHU','apply','registerMethodHandler','assign','bound\x20dispatch','Configuration','toString','validator','I18N_ATTR_KEY','query','metadata','request','target','1057363FkXhso','744543VwuWTN','name','param','2fOecVG'];a1_0x2434=function(){return _0x42de17;};return a1_0x2434();}a1_0x44159b();'use strict';var __decorate=this&&this[a1_0x1f4313(0x128)]||function(_0x597604,_0x300cc5,_0x494a65,_0x274be7){const _0x5dd3c9=a1_0x1f4313;var _0x2f8c0b=arguments[_0x5dd3c9(0x11a)],_0x49cd4a=_0x2f8c0b<0x3?_0x300cc5:_0x274be7===null?_0x274be7=Object[_0x5dd3c9(0x118)](_0x300cc5,_0x494a65):_0x274be7,_0x5d7923;if(typeof Reflect===_0x5dd3c9(0x122)&&typeof Reflect[_0x5dd3c9(0x124)]===_0x5dd3c9(0x11e))_0x49cd4a=Reflect['decorate'](_0x597604,_0x300cc5,_0x494a65,_0x274be7);else{for(var _0x59d95a=_0x597604[_0x5dd3c9(0x11a)]-0x1;_0x59d95a>=0x0;_0x59d95a--)if(_0x5d7923=_0x597604[_0x59d95a])_0x49cd4a=(_0x2f8c0b<0x3?_0x5d7923(_0x49cd4a):_0x2f8c0b>0x3?_0x5d7923(_0x300cc5,_0x494a65,_0x49cd4a):_0x5d7923(_0x300cc5,_0x494a65))||_0x49cd4a;}return _0x2f8c0b>0x3&&_0x49cd4a&&Object[_0x5dd3c9(0x14c)](_0x300cc5,_0x494a65,_0x49cd4a),_0x49cd4a;},__metadata=this&&this['__metadata']||function(_0x37f863,_0xfa9937){const _0x1b6f3e=a1_0x1f4313;if(typeof Reflect===_0x1b6f3e(0x122)&&typeof Reflect[_0x1b6f3e(0x134)]===_0x1b6f3e(0x11e))return Reflect[_0x1b6f3e(0x134)](_0x37f863,_0xfa9937);};Object[a1_0x1f4313(0x14c)](exports,a1_0x1f4313(0x147),{'value':!![]}),exports[a1_0x1f4313(0x14a)]=void 0x0;const i18n_1=require(a1_0x1f4313(0x13e)),core_1=require(a1_0x1f4313(0x144)),core_2=require('@midwayjs/core'),interface_1=require('./interface'),ValidatorService_1=require(a1_0x1f4313(0x141)),i18n=require(a1_0x1f4313(0x13e)),anncic=require(a1_0x1f4313(0x13c)),ConfigDefault=require(a1_0x1f4313(0x117));let CustomConfiguration=exports[a1_0x1f4313(0x14a)]=class CustomConfiguration{async[a1_0x1f4313(0x142)](){const _0x254819=a1_0x1f4313;this['decorator'][_0x254819(0x12c)](interface_1['VALIDATOR_KEY'],_0x2d592c=>{const _0x2dfc75=_0x254819,_0x59b508=_0x2d592c[_0x2dfc75(0x134)],_0x488082=(0x0,core_2[_0x2dfc75(0x129)])(_0x2d592c[_0x2dfc75(0x136)],_0x2d592c['propertyName']);return{'before':_0x5af4cf=>{const _0x1fe8fb=_0x2dfc75;var _0xfca7c,_0x905bba,_0x1b3858,_0x25274b,_0x5c93cc,_0x2f11b2,_0x3b030e,_0x43fce6,_0x3981c0,_0x4bc037,_0x4b04f0,_0x5a5b8c,_0x2616b1;const _0x54cf35=_0x5af4cf[_0x1fe8fb(0x136)][core_1[_0x1fe8fb(0x115)]],_0x22d925=Object[_0x1fe8fb(0x12d)]({},((_0xfca7c=_0x54cf35===null||_0x54cf35===void 0x0?void 0x0:_0x54cf35[_0x1fe8fb(0x135)])===null||_0xfca7c===void 0x0?void 0x0:_0xfca7c[_0x1fe8fb(0x133)])||{},((_0x905bba=_0x54cf35===null||_0x54cf35===void 0x0?void 0x0:_0x54cf35['request'])===null||_0x905bba===void 0x0?void 0x0:_0x905bba[_0x1fe8fb(0x149)])||{}),_0x4cc082=((0x0,core_2['getClassMetadata'])(interface_1[_0x1fe8fb(0x126)],_0x5af4cf[_0x1fe8fb(0x136)])||[])['find'](_0x46dc64=>_0x46dc64['method']==_0x5af4cf[_0x1fe8fb(0x140)]);!(_0x59b508===null||_0x59b508===void 0x0?void 0x0:_0x59b508['locale'])&&_0x54cf35&&_0x54cf35['getAttr']&&(_0x59b508['locale']=_0x54cf35['getAttr'](i18n_1[_0x1fe8fb(0x132)]));for(let _0x4f1ffe=0x0;_0x4f1ffe<_0x488082[_0x1fe8fb(0x11a)];_0x4f1ffe++){const _0x20721d=_0x488082[_0x4f1ffe],_0x547fe0=this['ValidatorService']['getSchema'](_0x20721d);if(_0x547fe0){if(typeof _0x5af4cf[_0x1fe8fb(0x143)][_0x4f1ffe]==_0x1fe8fb(0x146)||((_0x1b3858=_0x5af4cf[_0x1fe8fb(0x143)][_0x4f1ffe])===null||_0x1b3858===void 0x0?void 0x0:_0x1b3858[_0x1fe8fb(0x135)])&&((_0x25274b=_0x5af4cf[_0x1fe8fb(0x143)][_0x4f1ffe])===null||_0x25274b===void 0x0?void 0x0:_0x25274b[_0x1fe8fb(0x11d)])&&((_0x5c93cc=_0x5af4cf[_0x1fe8fb(0x143)][_0x4f1ffe])===null||_0x5c93cc===void 0x0?void 0x0:_0x5c93cc['req']))_0x5af4cf[_0x1fe8fb(0x143)][_0x4f1ffe]=_0x22d925;else((_0x2f11b2=_0x5af4cf[_0x1fe8fb(0x143)][_0x4f1ffe])===null||_0x2f11b2===void 0x0?void 0x0:_0x2f11b2[_0x1fe8fb(0x139)])==_0x1fe8fb(0x12e)&&_0x5af4cf[_0x1fe8fb(0x143)][_0x1fe8fb(0x14b)](_0x4f1ffe,0x0,_0x22d925);const _0x3d9298=this[_0x1fe8fb(0x148)][_0x1fe8fb(0x131)](_0x547fe0,_0x5af4cf['args'][_0x4f1ffe],_0x59b508);_0x3d9298&&(_0x5af4cf[_0x1fe8fb(0x143)][_0x4f1ffe]=_0x3d9298);}else{if((_0x4cc082===null||_0x4cc082===void 0x0?void 0x0:_0x4cc082[_0x1fe8fb(0x11b)][_0x4f1ffe])&&((_0x3b030e=_0x5af4cf['args'][_0x4f1ffe])===null||_0x3b030e===void 0x0?void 0x0:_0x3b030e[_0x1fe8fb(0x123)])&&typeof _0x5af4cf['args'][_0x4f1ffe][_0x1fe8fb(0x13a)]=='function'&&((_0x43fce6=_0x54cf35===null||_0x54cf35===void 0x0?void 0x0:_0x54cf35['params'])===null||_0x43fce6===void 0x0?void 0x0:_0x43fce6[_0x4cc082[_0x1fe8fb(0x11b)][_0x4f1ffe]]))_0x5af4cf[_0x1fe8fb(0x143)][_0x4f1ffe]=_0x20721d((_0x3981c0=_0x54cf35===null||_0x54cf35===void 0x0?void 0x0:_0x54cf35['params'])===null||_0x3981c0===void 0x0?void 0x0:_0x3981c0[_0x4cc082[_0x1fe8fb(0x11b)][_0x4f1ffe]]);else(_0x4cc082===null||_0x4cc082===void 0x0?void 0x0:_0x4cc082[_0x1fe8fb(0x11b)][_0x4f1ffe])&&((_0x4b04f0=(_0x4bc037=_0x5af4cf[_0x1fe8fb(0x143)][_0x4f1ffe])===null||_0x4bc037===void 0x0?void 0x0:_0x4bc037[_0x1fe8fb(0x123)])===null||_0x4b04f0===void 0x0?void 0x0:_0x4b04f0[_0x4cc082[_0x1fe8fb(0x11b)][_0x4f1ffe]])&&(_0x5af4cf[_0x1fe8fb(0x143)][_0x4f1ffe]=(_0x2616b1=(_0x5a5b8c=_0x5af4cf[_0x1fe8fb(0x143)][_0x4f1ffe])===null||_0x5a5b8c===void 0x0?void 0x0:_0x5a5b8c[_0x1fe8fb(0x123)])===null||_0x2616b1===void 0x0?void 0x0:_0x2616b1[_0x4cc082['methodArgs'][_0x4f1ffe]]);}}},'afterThrow':(_0x2fec04,_0x4ae76d)=>{throw _0x4ae76d;}};});}};__decorate([(0x0,core_2[a1_0x1f4313(0x127)])(),__metadata(a1_0x1f4313(0x13f),core_1['MidwayDecoratorService'])],CustomConfiguration['prototype'],a1_0x1f4313(0x121),void 0x0),__decorate([(0x0,core_2[a1_0x1f4313(0x127)])(),__metadata('design:type',ValidatorService_1[a1_0x1f4313(0x148)])],CustomConfiguration[a1_0x1f4313(0x14d)],a1_0x1f4313(0x148),void 0x0),exports[a1_0x1f4313(0x14a)]=CustomConfiguration=__decorate([(0x0,core_2[a1_0x1f4313(0x12f)])({'conflictCheck':![],'imports':[i18n,anncic],'namespace':a1_0x1f4313(0x145),'importConfigs':[{'default':ConfigDefault}]})],CustomConfiguration);
|
package/dist/decorator/Rule.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a2_0x1dc3f8=a2_0x1b29;(function(_0x1da5a5,_0x24af55){const _0x530141=a2_0x1b29,_0xf562b0=_0x1da5a5();while(!![]){try{const _0x443c68=-parseInt(_0x530141(0x16c))/0x1+parseInt(_0x530141(0x169))/0x2*(-parseInt(_0x530141(0x177))/0x3)+parseInt(_0x530141(0x15e))/0x4*(parseInt(_0x530141(0x16b))/0x5)+parseInt(_0x530141(0x17c))/0x6*(-parseInt(_0x530141(0x175))/0x7)+parseInt(_0x530141(0x174))/0x8+-parseInt(_0x530141(0x176))/0x9*(-parseInt(_0x530141(0x162))/0xa)+-parseInt(_0x530141(0x16a))/0xb*(parseInt(_0x530141(0x164))/0xc);if(_0x443c68===_0x24af55)break;else _0xf562b0['push'](_0xf562b0['shift']());}catch(_0x28a191){_0xf562b0['push'](_0xf562b0['shift']());}}}(a2_0x24d7,0x2fb7e));const a2_0x46f3e6=(function(){let _0x2ab05d=!![];return function(_0xe9bf64,_0x1b727b){const _0x512ec6=_0x2ab05d?function(){const _0x11eaea=a2_0x1b29;if(_0x1b727b){const _0x57dd2b=_0x1b727b[_0x11eaea(0x173)](_0xe9bf64,arguments);return _0x1b727b=null,_0x57dd2b;}}:function(){};return _0x2ab05d=![],_0x512ec6;};}()),a2_0x261afa=a2_0x46f3e6(this,function(){const _0x43d0d4=a2_0x1b29;return a2_0x261afa[_0x43d0d4(0x168)]()[_0x43d0d4(0x163)]('(((.+)+)+)+$')[_0x43d0d4(0x168)]()['constructor'](a2_0x261afa)[_0x43d0d4(0x163)](_0x43d0d4(0x15f));});a2_0x261afa();'use strict';Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[a2_0x1dc3f8(0x15d)]=exports[a2_0x1dc3f8(0x17d)]=void 0x0;function a2_0x1b29(_0x4686ae,_0x1690b5){const _0x258444=a2_0x24d7();return a2_0x1b29=function(_0x261afa,_0x46f3e6){_0x261afa=_0x261afa-0x15c;let _0x24d7d2=_0x258444[_0x261afa];return _0x24d7d2;},a2_0x1b29(_0x4686ae,_0x1690b5);}const joi=require(a2_0x1dc3f8(0x178)),date_1=require(a2_0x1dc3f8(0x161)),core_1=require(a2_0x1dc3f8(0x166)),interface_1=require(a2_0x1dc3f8(0x16e));exports[a2_0x1dc3f8(0x17d)]=joi['extend'](date_1[a2_0x1dc3f8(0x171)]);function Rule(_0x3b6750,_0x1ce451,_0x216ac1=''){return(_0x9207c1,_0x51115a)=>{const _0x1032a9=a2_0x1b29;var _0x57f6cf;if(_0x51115a)!joi[_0x1032a9(0x16f)](_0x1ce451)&&(_0x1ce451===null||_0x1ce451===void 0x0?void 0x0:_0x1ce451[_0x1032a9(0x15c)])&&(_0x1ce451=joi[_0x1032a9(0x16d)]((0x0,core_1[_0x1032a9(0x167)])(interface_1[_0x1032a9(0x179)],_0x1ce451))['meta']({'id':_0x1ce451['name']}),(0x0,core_1['getPropertyType'])(_0x9207c1,_0x51115a)[_0x1032a9(0x15c)]==='Array'&&(_0x1ce451=joi['array']()['items'](_0x1ce451))),joi[_0x1032a9(0x16f)](_0x1ce451)&&(_0x3b6750&&typeof(_0x1ce451===null||_0x1ce451===void 0x0?void 0x0:_0x1ce451[_0x1032a9(0x170)])==_0x1032a9(0x160)&&(_0x1ce451=_0x1ce451[_0x1032a9(0x170)](_0x3b6750)),_0x216ac1&&typeof(_0x1ce451===null||_0x1ce451===void 0x0?void 0x0:_0x1ce451[_0x1032a9(0x172)])==_0x1032a9(0x160)&&(_0x1ce451=_0x1ce451[_0x1032a9(0x172)](_0x216ac1)),(0x0,core_1[_0x1032a9(0x165)])(interface_1[_0x1032a9(0x179)],_0x1ce451,_0x9207c1,_0x51115a));else{const _0x49fb38=(0x0,core_1['getClassMetadata'])(interface_1[_0x1032a9(0x179)],_0x1ce451);if(_0x49fb38){let _0x30fe02=(_0x57f6cf=(0x0,core_1[_0x1032a9(0x167)])(interface_1[_0x1032a9(0x179)],_0x9207c1))!==null&&_0x57f6cf!==void 0x0?_0x57f6cf:{};Object['keys'](_0x49fb38)[_0x1032a9(0x17b)](_0x360fa1=>{!_0x30fe02[_0x360fa1]&&(_0x30fe02[_0x360fa1]=_0x49fb38[_0x360fa1]);}),(0x0,core_1[_0x1032a9(0x17a)])(interface_1['RULES_KEY'],_0x30fe02,_0x9207c1);}}};}function a2_0x24d7(){const _0x2681bd=['RULES_KEY','saveClassMetadata','map','478524LCJMBM','RuleType','name','Rule','88WZVoVx','(((.+)+)+)+$','function','@joi/date','10pbXARf','search','24OpoFec','attachClassMetadata','@midwayjs/core','getClassMetadata','toString','542wGnioO','1433795IinXlT','52330tuwchs','64974gEosqL','object','../interface','isSchema','label','default','description','apply','2854160lKpohD','14ItwzvP','1813158RcbCnD','1194HQLLmb','joi'];a2_0x24d7=function(){return _0x2681bd;};return a2_0x24d7();}exports[a2_0x1dc3f8(0x15d)]=Rule;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a3_0x479063=a3_0x4450;function a3_0x1988(){const _0x140fb8=['7TCuPpv','constructor','../interface','indexOf','16fxZsbv','replace','createCustomMethodDecorator','defineProperty','VALIDATOR_KEY','search','2148348VosOuV','Validator','36478360ZWKhrd','slice','apply','(((.+)+)+)+$','3316955UDUAAI','prototype','getFuncArgs','2WVNzPd','toString','455529naqryO','attachClassMetadata','1774895QlmPLS','14850984FAltmM','11017017wRjAYJ','__esModule'];a3_0x1988=function(){return _0x140fb8;};return a3_0x1988();}(function(_0x155e3f,_0x4995e9){const _0x4cd59b=a3_0x4450,_0x25b372=_0x155e3f();while(!![]){try{const _0x50eb89=-parseInt(_0x4cd59b(0x15c))/0x1*(parseInt(_0x4cd59b(0x158))/0x2)+parseInt(_0x4cd59b(0x15a))/0x3*(-parseInt(_0x4cd59b(0x164))/0x4)+parseInt(_0x4cd59b(0x155))/0x5+-parseInt(_0x4cd59b(0x14f))/0x6+-parseInt(_0x4cd59b(0x160))/0x7*(parseInt(_0x4cd59b(0x15d))/0x8)+parseInt(_0x4cd59b(0x15e))/0x9+parseInt(_0x4cd59b(0x151))/0xa;if(_0x50eb89===_0x4995e9)break;else _0x25b372['push'](_0x25b372['shift']());}catch(_0x134289){_0x25b372['push'](_0x25b372['shift']());}}}(a3_0x1988,0xe5292));const a3_0x1ce5b4=(function(){let _0x124595=!![];return function(_0x38d6ab,_0x20d29c){const _0x9e0933=_0x124595?function(){const _0x21e2b6=a3_0x4450;if(_0x20d29c){const _0x38d8a5=_0x20d29c[_0x21e2b6(0x153)](_0x38d6ab,arguments);return _0x20d29c=null,_0x38d8a5;}}:function(){};return _0x124595=![],_0x9e0933;};}()),a3_0x497c43=a3_0x1ce5b4(this,function(){const _0x1eb79f=a3_0x4450;return a3_0x497c43['toString']()[_0x1eb79f(0x14e)](_0x1eb79f(0x154))[_0x1eb79f(0x159)]()[_0x1eb79f(0x161)](a3_0x497c43)[_0x1eb79f(0x14e)](_0x1eb79f(0x154));});a3_0x497c43();'use strict';Object[a3_0x479063(0x14c)](exports,a3_0x479063(0x15f),{'value':!![]}),exports[a3_0x479063(0x157)]=exports[a3_0x479063(0x150)]=void 0x0;function a3_0x4450(_0x1fac64,_0x498062){const _0x3932b4=a3_0x1988();return a3_0x4450=function(_0x497c43,_0x1ce5b4){_0x497c43=_0x497c43-0x14a;let _0x198844=_0x3932b4[_0x497c43];return _0x198844;},a3_0x4450(_0x1fac64,_0x498062);}const core_1=require('@midwayjs/core'),interface_1=require(a3_0x479063(0x162));function Validator(_0x468c4e={}){return(_0xe258d4,_0x22b1fe,_0x5d77e1)=>{const _0x3a0b00=a3_0x4450,_0x4f953b=getFuncArgs(_0xe258d4[_0x22b1fe]);(0x0,core_1[_0x3a0b00(0x15b)])(interface_1[_0x3a0b00(0x14d)],{'method':_0x22b1fe,'methodArgs':_0x4f953b},_0xe258d4),(0x0,core_1[_0x3a0b00(0x14b)])(interface_1['VALIDATOR_KEY'],_0x468c4e)(_0xe258d4,_0x22b1fe,_0x5d77e1);};}exports[a3_0x479063(0x150)]=Validator;function getFuncArgs(_0x21b36d){const _0x840855=a3_0x479063;if(typeof _0x21b36d=='function'){const _0x5e52b7=/=>.*$/mg,_0xeda0e7=/=[^,)]+/mg,_0x4e48f1=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/mg,_0x2ac88b=(_0x21b36d['prototype']?_0x21b36d[_0x840855(0x156)][_0x840855(0x161)][_0x840855(0x159)]():_0x21b36d['toString']())['replace'](_0x4e48f1,'')[_0x840855(0x14a)](_0x5e52b7,'')[_0x840855(0x14a)](_0xeda0e7,''),_0x25723f=_0x2ac88b[_0x840855(0x152)](_0x2ac88b[_0x840855(0x163)]('(')+0x1,_0x2ac88b[_0x840855(0x163)](')'))['match'](/([^\s,]+)/g)||[];return _0x25723f;}}exports[a3_0x479063(0x157)]=getFuncArgs;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a4_0x278ac1=a4_0x3e06;(function(_0x402cab,_0x96fd10){var _0x18ca93=a4_0x3e06,_0x425083=_0x402cab();while(!![]){try{var _0xb06dab=parseInt(_0x18ca93(0xcc))/0x1+-parseInt(_0x18ca93(0xba))/0x2*(-parseInt(_0x18ca93(0xc1))/0x3)+-parseInt(_0x18ca93(0xc3))/0x4*(parseInt(_0x18ca93(0xb8))/0x5)+-parseInt(_0x18ca93(0xbd))/0x6+-parseInt(_0x18ca93(0xb7))/0x7+parseInt(_0x18ca93(0xc0))/0x8*(parseInt(_0x18ca93(0xce))/0x9)+parseInt(_0x18ca93(0xbe))/0xa;if(_0xb06dab===_0x96fd10)break;else _0x425083['push'](_0x425083['shift']());}catch(_0x665d54){_0x425083['push'](_0x425083['shift']());}}}(a4_0x1d22,0x57f06));var a4_0x10fad8=(function(){var _0x2ab79a=!![];return function(_0x8c0de8,_0x34e2ce){var _0x325717=_0x2ab79a?function(){var _0x43188d=a4_0x3e06;if(_0x34e2ce){var _0x2411d7=_0x34e2ce[_0x43188d(0xcb)](_0x8c0de8,arguments);return _0x34e2ce=null,_0x2411d7;}}:function(){};return _0x2ab79a=![],_0x325717;};}()),a4_0x2f4902=a4_0x10fad8(this,function(){var _0x38de01=a4_0x3e06;return a4_0x2f4902['toString']()[_0x38de01(0xc6)](_0x38de01(0xc2))[_0x38de01(0xc8)]()[_0x38de01(0xc7)](a4_0x2f4902)[_0x38de01(0xc6)](_0x38de01(0xc2));});a4_0x2f4902();'use strict';var __decorate=this&&this[a4_0x278ac1(0xc4)]||function(_0x9fe6dd,_0x2037d8,_0x56f3e3,_0x108754){var _0x398aa7=a4_0x278ac1,_0x3eae63=arguments[_0x398aa7(0xbb)],_0x567dd7=_0x3eae63<0x3?_0x2037d8:_0x108754===null?_0x108754=Object[_0x398aa7(0xb6)](_0x2037d8,_0x56f3e3):_0x108754,_0x5cf00e;if(typeof Reflect===_0x398aa7(0xc5)&&typeof Reflect['decorate']===_0x398aa7(0xbf))_0x567dd7=Reflect[_0x398aa7(0xd0)](_0x9fe6dd,_0x2037d8,_0x56f3e3,_0x108754);else{for(var _0x3cb490=_0x9fe6dd[_0x398aa7(0xbb)]-0x1;_0x3cb490>=0x0;_0x3cb490--)if(_0x5cf00e=_0x9fe6dd[_0x3cb490])_0x567dd7=(_0x3eae63<0x3?_0x5cf00e(_0x567dd7):_0x3eae63>0x3?_0x5cf00e(_0x2037d8,_0x56f3e3,_0x567dd7):_0x5cf00e(_0x2037d8,_0x56f3e3))||_0x567dd7;}return _0x3eae63>0x3&&_0x567dd7&&Object['defineProperty'](_0x2037d8,_0x56f3e3,_0x567dd7),_0x567dd7;},__metadata=this&&this[a4_0x278ac1(0xca)]||function(_0x8209d1,_0x3c9549){var _0x2d0089=a4_0x278ac1;if(typeof Reflect===_0x2d0089(0xc5)&&typeof Reflect[_0x2d0089(0xbc)]===_0x2d0089(0xbf))return Reflect['metadata'](_0x8209d1,_0x3c9549);};Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports['ValidatorError']=void 0x0;const core_1=require(a4_0x278ac1(0xd2));function a4_0x1d22(){var _0x1544a5=['design:type','decorate','参数验证失败','@anncic-api/core','getOwnPropertyDescriptor','3049277POMzEE','5nIXTui','NOFIND_SCHEMA','16868AWJfJI','length','metadata','2288712uXCDkd','1396620dezepI','function','8MKyWWE','132uLyIOK','(((.+)+)+)+$','1345664woaPPi','__decorate','object','search','constructor','toString','PARAMS','__metadata','apply','365520cfefxx','ValidatorError','5736591dPBblo'];a4_0x1d22=function(){return _0x1544a5;};return a4_0x1d22();}function a4_0x3e06(_0x50968f,_0x2a2389){var _0x368df2=a4_0x1d22();return a4_0x3e06=function(_0x2f4902,_0x10fad8){_0x2f4902=_0x2f4902-0xb6;var _0x1d22f9=_0x368df2[_0x2f4902];return _0x1d22f9;},a4_0x3e06(_0x50968f,_0x2a2389);}class ValidatorError extends AnnError{}exports[a4_0x278ac1(0xcd)]=ValidatorError,ValidatorError[a4_0x278ac1(0xc9)]=0x18c1e,ValidatorError[a4_0x278ac1(0xb9)]=0x18c1c,__decorate([(0x0,core_1['AnnErrorMsg'])(a4_0x278ac1(0xd1)),__metadata(a4_0x278ac1(0xcf),Object)],ValidatorError,a4_0x278ac1(0xc9),void 0x0),__decorate([(0x0,core_1['AnnErrorMsg'])(a4_0x278ac1(0xd1)),__metadata(a4_0x278ac1(0xcf),Object)],ValidatorError,a4_0x278ac1(0xb9),void 0x0);
|
package/dist/helper/dtoHelper.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a5_0xef3d2f=a5_0x6f44;(function(_0x3ae153,_0x18d00e){const _0x52b043=a5_0x6f44,_0x281e17=_0x3ae153();while(!![]){try{const _0x519241=parseInt(_0x52b043(0x10c))/0x1+parseInt(_0x52b043(0x115))/0x2*(-parseInt(_0x52b043(0x118))/0x3)+parseInt(_0x52b043(0x121))/0x4+parseInt(_0x52b043(0x11d))/0x5*(-parseInt(_0x52b043(0x117))/0x6)+parseInt(_0x52b043(0x11c))/0x7+parseInt(_0x52b043(0x111))/0x8+-parseInt(_0x52b043(0x120))/0x9;if(_0x519241===_0x18d00e)break;else _0x281e17['push'](_0x281e17['shift']());}catch(_0x40e08a){_0x281e17['push'](_0x281e17['shift']());}}}(a5_0x7d0a,0xa05d9));const a5_0x5a15eb=(function(){let _0x345c1b=!![];return function(_0x3721f8,_0x175a9f){const _0x55808d=_0x345c1b?function(){const _0x3d7a74=a5_0x6f44;if(_0x175a9f){const _0x597f90=_0x175a9f[_0x3d7a74(0x10e)](_0x3721f8,arguments);return _0x175a9f=null,_0x597f90;}}:function(){};return _0x345c1b=![],_0x55808d;};}()),a5_0x34afbe=a5_0x5a15eb(this,function(){const _0x145223=a5_0x6f44;return a5_0x34afbe[_0x145223(0x119)]()[_0x145223(0x10d)]('(((.+)+)+)+$')[_0x145223(0x119)]()[_0x145223(0x110)](a5_0x34afbe)['search'](_0x145223(0x10f));});a5_0x34afbe();function a5_0x7d0a(){const _0xd345df=['apply','(((.+)+)+)+$','constructor','3769416FliBud','RULES_KEY','getClassExtendedMetadata','OmitDto','2beJLDA','assign','156aHehnA','2037954trIVbA','toString','saveClassMetadata','defineProperty','4766111gXqPjF','139700clSGhp','PickDto','prototype','2925135TGGbmO','3317824ThFqkE','__esModule','406124FjEOJy','search'];a5_0x7d0a=function(){return _0xd345df;};return a5_0x7d0a();}'use strict';Object[a5_0xef3d2f(0x11b)](exports,a5_0xef3d2f(0x122),{'value':!![]}),exports[a5_0xef3d2f(0x114)]=exports[a5_0xef3d2f(0x11e)]=void 0x0;const core_1=require('@midwayjs/core'),interface_1=require('../interface');function PickDto(_0x10728c,_0x265a3f){const _0x13debe=a5_0xef3d2f,_0x5dff65=function(){};_0x5dff65[_0x13debe(0x11f)]=_0x10728c['prototype'];const _0x233d95=(0x0,core_1['getClassExtendedMetadata'])(interface_1[_0x13debe(0x112)],_0x10728c),_0x54bd76={};for(const _0x26c154 of _0x265a3f){_0x233d95[_0x26c154]&&(_0x54bd76[_0x26c154]=_0x233d95[_0x26c154]);}return(0x0,core_1[_0x13debe(0x11a)])(interface_1[_0x13debe(0x112)],_0x54bd76,_0x5dff65),_0x5dff65;}exports[a5_0xef3d2f(0x11e)]=PickDto;function OmitDto(_0x4b253d,_0x3f44d5){const _0x362e43=a5_0xef3d2f,_0xa6280e=function(){};_0xa6280e[_0x362e43(0x11f)]=_0x4b253d[_0x362e43(0x11f)];const _0x547c23=(0x0,core_1[_0x362e43(0x113)])(interface_1[_0x362e43(0x112)],_0x4b253d),_0x4d139f=Object[_0x362e43(0x116)]({},_0x547c23);for(const _0x4cdef6 of _0x3f44d5){delete _0x4d139f[_0x4cdef6];}return(0x0,core_1[_0x362e43(0x11a)])(interface_1['RULES_KEY'],_0x4d139f,_0xa6280e),_0xa6280e;}function a5_0x6f44(_0x13e221,_0xba6ab3){const _0x4e7b38=a5_0x7d0a();return a5_0x6f44=function(_0x34afbe,_0x5a15eb){_0x34afbe=_0x34afbe-0x10c;let _0x7d0a5b=_0x4e7b38[_0x34afbe];return _0x7d0a5b;},a5_0x6f44(_0x13e221,_0xba6ab3);}exports['OmitDto']=OmitDto;
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a6_0x5cf627=a6_0x3a38;(function(_0x21c07f,_0x34c4a0){var _0xba2cd5=a6_0x3a38,_0x4ccfb6=_0x21c07f();while(!![]){try{var _0x331e41=parseInt(_0xba2cd5(0x84))/0x1+-parseInt(_0xba2cd5(0x90))/0x2+parseInt(_0xba2cd5(0x79))/0x3+parseInt(_0xba2cd5(0x9a))/0x4*(parseInt(_0xba2cd5(0x8f))/0x5)+parseInt(_0xba2cd5(0x82))/0x6+-parseInt(_0xba2cd5(0x92))/0x7*(parseInt(_0xba2cd5(0x87))/0x8)+-parseInt(_0xba2cd5(0x8b))/0x9*(parseInt(_0xba2cd5(0x86))/0xa);if(_0x331e41===_0x34c4a0)break;else _0x4ccfb6['push'](_0x4ccfb6['shift']());}catch(_0x37e1a1){_0x4ccfb6['push'](_0x4ccfb6['shift']());}}}(a6_0x21bd,0x47afc));var a6_0x203835=(function(){var _0x198644=!![];return function(_0x41f5b2,_0x2a13c6){var _0x218712=_0x198644?function(){var _0x4b2315=a6_0x3a38;if(_0x2a13c6){var _0x2122f9=_0x2a13c6[_0x4b2315(0x89)](_0x41f5b2,arguments);return _0x2a13c6=null,_0x2122f9;}}:function(){};return _0x198644=![],_0x218712;};}()),a6_0xb5676f=a6_0x203835(this,function(){var _0x418678=a6_0x3a38;return a6_0xb5676f[_0x418678(0x7e)]()['search'](_0x418678(0x7b))['toString']()['constructor'](a6_0xb5676f)['search'](_0x418678(0x7b));});a6_0xb5676f();function a6_0x21bd(){var _0x2264e4=['default','1627577soTdob','get','prototype','ValidatorError','__exportStar','./service/ValidatorService','__createBinding','Configuration','8mHAWMG','Rule','102360Brlagm','getOwnPropertyDescriptor','(((.+)+)+)+$','call','./configuration','toString','__esModule','Validator','./decorator/Validator','1071954XcxGwj','defineProperty','279802KKnyFe','RuleType','30cfVAYu','8IxNyZF','./interface','apply','ValidatorService','554382qvqUoQ','create','writable','configurable','840195tMaWXS','235452MmiBJt'];a6_0x21bd=function(){return _0x2264e4;};return a6_0x21bd();}'use strict';var __createBinding=this&&this[a6_0x5cf627(0x98)]||(Object[a6_0x5cf627(0x8c)]?function(_0xf9f1d0,_0x2621ce,_0x4d6966,_0x2a551e){var _0x2db3df=a6_0x5cf627;if(_0x2a551e===undefined)_0x2a551e=_0x4d6966;var _0x19498a=Object[_0x2db3df(0x7a)](_0x2621ce,_0x4d6966);(!_0x19498a||(_0x2db3df(0x93)in _0x19498a?!_0x2621ce[_0x2db3df(0x7f)]:_0x19498a[_0x2db3df(0x8d)]||_0x19498a[_0x2db3df(0x8e)]))&&(_0x19498a={'enumerable':!![],'get':function(){return _0x2621ce[_0x4d6966];}}),Object['defineProperty'](_0xf9f1d0,_0x2a551e,_0x19498a);}:function(_0x4f8bd7,_0x47bca8,_0x550a8b,_0xe2b819){if(_0xe2b819===undefined)_0xe2b819=_0x550a8b;_0x4f8bd7[_0xe2b819]=_0x47bca8[_0x550a8b];}),__exportStar=this&&this[a6_0x5cf627(0x96)]||function(_0xe06268,_0x417ccb){var _0x52b0c1=a6_0x5cf627;for(var _0x477706 in _0xe06268)if(_0x477706!==_0x52b0c1(0x91)&&!Object[_0x52b0c1(0x94)]['hasOwnProperty'][_0x52b0c1(0x7c)](_0x417ccb,_0x477706))__createBinding(_0x417ccb,_0xe06268,_0x477706);};Object['defineProperty'](exports,a6_0x5cf627(0x7f),{'value':!![]}),exports[a6_0x5cf627(0x99)]=exports[a6_0x5cf627(0x8a)]=exports[a6_0x5cf627(0x95)]=exports[a6_0x5cf627(0x85)]=exports[a6_0x5cf627(0x9b)]=exports[a6_0x5cf627(0x80)]=void 0x0,__exportStar(require(a6_0x5cf627(0x88)),exports),__exportStar(require('./helper/dtoHelper'),exports);var Validator_1=require(a6_0x5cf627(0x81));Object[a6_0x5cf627(0x83)](exports,a6_0x5cf627(0x80),{'enumerable':!![],'get':function(){var _0xeb8936=a6_0x5cf627;return Validator_1[_0xeb8936(0x80)];}});var Rule_1=require('./decorator/Rule');Object[a6_0x5cf627(0x83)](exports,a6_0x5cf627(0x9b),{'enumerable':!![],'get':function(){var _0x31efe8=a6_0x5cf627;return Rule_1[_0x31efe8(0x9b)];}}),Object[a6_0x5cf627(0x83)](exports,a6_0x5cf627(0x85),{'enumerable':!![],'get':function(){return Rule_1['RuleType'];}});var ValidatorError_1=require('./exception/ValidatorError');Object[a6_0x5cf627(0x83)](exports,a6_0x5cf627(0x95),{'enumerable':!![],'get':function(){var _0x43c258=a6_0x5cf627;return ValidatorError_1[_0x43c258(0x95)];}});var ValidatorService_1=require(a6_0x5cf627(0x97));Object[a6_0x5cf627(0x83)](exports,a6_0x5cf627(0x8a),{'enumerable':!![],'get':function(){return ValidatorService_1['ValidatorService'];}});var configuration_1=require(a6_0x5cf627(0x7d));function a6_0x3a38(_0x3758fb,_0x170f08){var _0x6d9bb9=a6_0x21bd();return a6_0x3a38=function(_0xb5676f,_0x203835){_0xb5676f=_0xb5676f-0x79;var _0x21bd57=_0x6d9bb9[_0xb5676f];return _0x21bd57;},a6_0x3a38(_0x3758fb,_0x170f08);}Object[a6_0x5cf627(0x83)](exports,a6_0x5cf627(0x99),{'enumerable':!![],'get':function(){return configuration_1['CustomConfiguration'];}});
|
package/dist/interface.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a7_0x1c3a6d=a7_0x80eb;(function(_0xba5c43,_0x52a0c2){var _0x5be846=a7_0x80eb,_0x218334=_0xba5c43();while(!![]){try{var _0x4b5152=-parseInt(_0x5be846(0x1aa))/0x1*(-parseInt(_0x5be846(0x1a9))/0x2)+-parseInt(_0x5be846(0x1ab))/0x3+-parseInt(_0x5be846(0x1ad))/0x4*(parseInt(_0x5be846(0x1ae))/0x5)+parseInt(_0x5be846(0x1b5))/0x6+parseInt(_0x5be846(0x1b3))/0x7+-parseInt(_0x5be846(0x1b1))/0x8+parseInt(_0x5be846(0x1b8))/0x9*(parseInt(_0x5be846(0x1af))/0xa);if(_0x4b5152===_0x52a0c2)break;else _0x218334['push'](_0x218334['shift']());}catch(_0xd4abdc){_0x218334['push'](_0x218334['shift']());}}}(a7_0x5bb1,0xeffdd));var a7_0x1bbd53=(function(){var _0x135754=!![];return function(_0x2f425e,_0x51d735){var _0x2e4c62=_0x135754?function(){if(_0x51d735){var _0x44d622=_0x51d735['apply'](_0x2f425e,arguments);return _0x51d735=null,_0x44d622;}}:function(){};return _0x135754=![],_0x2e4c62;};}()),a7_0x1fcbe3=a7_0x1bbd53(this,function(){var _0x38ea65=a7_0x80eb;return a7_0x1fcbe3[_0x38ea65(0x1b4)]()['search']('(((.+)+)+)+$')['toString']()[_0x38ea65(0x1b7)](a7_0x1fcbe3)['search'](_0x38ea65(0x1b6));});a7_0x1fcbe3();function a7_0x80eb(_0x2943e8,_0x3b1414){var _0x5f32aa=a7_0x5bb1();return a7_0x80eb=function(_0x1fcbe3,_0x1bbd53){_0x1fcbe3=_0x1fcbe3-0x1a9;var _0x5bb128=_0x5f32aa[_0x1fcbe3];return _0x5bb128;},a7_0x80eb(_0x2943e8,_0x3b1414);}'use strict';Object[a7_0x1c3a6d(0x1b0)](exports,a7_0x1c3a6d(0x1b9),{'value':!![]}),exports[a7_0x1c3a6d(0x1b2)]=exports[a7_0x1c3a6d(0x1ac)]=void 0x0,exports[a7_0x1c3a6d(0x1ac)]='anncic-api:validator:rules',exports[a7_0x1c3a6d(0x1b2)]='anncic-api:validator:validator';function a7_0x5bb1(){var _0x479626=['10564752bUNrIg','VALIDATOR_KEY','710619HEIKSX','toString','11556948iDZUAK','(((.+)+)+)+$','constructor','1521brFNmX','__esModule','58xWJgPw','30829SXjpwT','2718195hHKdxL','RULES_KEY','12tBGHww','2390270YLeygF','101900zawSsi','defineProperty'];a7_0x5bb1=function(){return _0x479626;};return a7_0x5bb1();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a8_0x4fa9(_0x258ab6,_0xfc1e95){const _0x38088a=a8_0x2594();return a8_0x4fa9=function(_0x1e1f0e,_0x558520){_0x1e1f0e=_0x1e1f0e-0x127;let _0x259493=_0x38088a[_0x1e1f0e];return _0x259493;},a8_0x4fa9(_0x258ab6,_0xfc1e95);}const a8_0x247977=a8_0x4fa9;(function(_0x5545c2,_0x1f4d4b){const _0x4b3b64=a8_0x4fa9,_0x1ded72=_0x5545c2();while(!![]){try{const _0x1fc89b=-parseInt(_0x4b3b64(0x130))/0x1+parseInt(_0x4b3b64(0x132))/0x2*(-parseInt(_0x4b3b64(0x131))/0x3)+parseInt(_0x4b3b64(0x12b))/0x4+-parseInt(_0x4b3b64(0x137))/0x5+parseInt(_0x4b3b64(0x135))/0x6+-parseInt(_0x4b3b64(0x152))/0x7*(-parseInt(_0x4b3b64(0x166))/0x8)+parseInt(_0x4b3b64(0x140))/0x9;if(_0x1fc89b===_0x1f4d4b)break;else _0x1ded72['push'](_0x1ded72['shift']());}catch(_0x555945){_0x1ded72['push'](_0x1ded72['shift']());}}}(a8_0x2594,0xca736));const a8_0x558520=(function(){let _0x24ad41=!![];return function(_0x550131,_0x18f141){const _0xd85c93=_0x24ad41?function(){const _0x17878f=a8_0x4fa9;if(_0x18f141){const _0x329864=_0x18f141[_0x17878f(0x15b)](_0x550131,arguments);return _0x18f141=null,_0x329864;}}:function(){};return _0x24ad41=![],_0xd85c93;};}()),a8_0x1e1f0e=a8_0x558520(this,function(){const _0x17251a=a8_0x4fa9;return a8_0x1e1f0e[_0x17251a(0x15a)]()[_0x17251a(0x16d)]('(((.+)+)+)+$')['toString']()[_0x17251a(0x138)](a8_0x1e1f0e)['search'](_0x17251a(0x167));});a8_0x1e1f0e();'use strict';function a8_0x2594(){const _0x1b2786=['Config','validator','../interface','forEach','参数验证失败','getLocaleMapping','toString','apply','prototype','format','validatorConfig','__decorate','__metadata','getClassExtendedMetadata','keys','length','decorate','isSchema','9734560JAqezX','(((.+)+)+)+$','messages','formatLocale','ValidatorError','error','key','search','ValidatorService','PARAMS','type','design:type','3104744kQrQPp','assign','Init','init','metadata','1198584IbLeBB','77397jAGIqY','68BnogCF','../exception/ValidatorError','__esModule','1633452WKHTVU','_flags','2036035QeJHdr','constructor','fromEntries','Provide','locale','Scope','$_terms','Singleton','getSchema','9422523gjAAOJ','i18nConfig','RULES_KEY','function','message','errors','defineProperty','validationOptions','details','@midwayjs/core','schema','object','language','i18nService','getAvailableLocale','defaultLocale','@midwayjs/i18n','design:returntype','7CmWgcw','value'];a8_0x2594=function(){return _0x1b2786;};return a8_0x2594();}var __decorate=this&&this[a8_0x247977(0x15f)]||function(_0x1bd977,_0x424ba0,_0x12d75c,_0x1c05d1){const _0x215cd0=a8_0x247977;var _0x9e9943=arguments[_0x215cd0(0x163)],_0x272670=_0x9e9943<0x3?_0x424ba0:_0x1c05d1===null?_0x1c05d1=Object['getOwnPropertyDescriptor'](_0x424ba0,_0x12d75c):_0x1c05d1,_0x1a9108;if(typeof Reflect===_0x215cd0(0x14b)&&typeof Reflect[_0x215cd0(0x164)]===_0x215cd0(0x143))_0x272670=Reflect['decorate'](_0x1bd977,_0x424ba0,_0x12d75c,_0x1c05d1);else{for(var _0x53e005=_0x1bd977[_0x215cd0(0x163)]-0x1;_0x53e005>=0x0;_0x53e005--)if(_0x1a9108=_0x1bd977[_0x53e005])_0x272670=(_0x9e9943<0x3?_0x1a9108(_0x272670):_0x9e9943>0x3?_0x1a9108(_0x424ba0,_0x12d75c,_0x272670):_0x1a9108(_0x424ba0,_0x12d75c))||_0x272670;}return _0x9e9943>0x3&&_0x272670&&Object['defineProperty'](_0x424ba0,_0x12d75c,_0x272670),_0x272670;},__metadata=this&&this[a8_0x247977(0x160)]||function(_0x6732bf,_0x46448f){const _0x500de3=a8_0x247977;if(typeof Reflect===_0x500de3(0x14b)&&typeof Reflect[_0x500de3(0x12f)]==='function')return Reflect[_0x500de3(0x12f)](_0x6732bf,_0x46448f);};Object[a8_0x247977(0x146)](exports,a8_0x247977(0x134),{'value':!![]}),exports[a8_0x247977(0x127)]=void 0x0;const Joi=require('joi'),i18n_1=require(a8_0x247977(0x150)),core_1=require(a8_0x247977(0x149)),interface_1=require(a8_0x247977(0x156)),ValidatorError_1=require(a8_0x247977(0x133));let ValidatorService=exports[a8_0x247977(0x127)]=class ValidatorService{constructor(){this['messages']={};}async[a8_0x247977(0x12e)](){const _0x31f87c=a8_0x247977,_0x4aa5ba=Object['keys'](this[_0x31f87c(0x141)]['localeTable']);_0x4aa5ba[_0x31f87c(0x157)](_0x4575b9=>{const _0x46cc62=_0x31f87c;this[_0x46cc62(0x168)][(0x0,i18n_1['formatLocale'])(_0x4575b9)]=Object[_0x46cc62(0x139)](this['i18nService'][_0x46cc62(0x159)](_0x4575b9,_0x46cc62(0x155)));});}[a8_0x247977(0x13f)](_0x54ba9e){const _0x4c0b7d=a8_0x247977,_0x300086=(0x0,core_1[_0x4c0b7d(0x161)])(interface_1[_0x4c0b7d(0x142)],_0x54ba9e);return _0x300086?Joi[_0x4c0b7d(0x14b)](_0x300086):undefined;}[a8_0x247977(0x155)](_0x49b556,_0x120256,_0x42483b={}){const _0x482f38=a8_0x247977;var _0x4f4eb4,_0x45050f,_0x2ffb89,_0x3bafe5,_0x4a86cc,_0x851c3f;const _0x5d7ac3=Joi[_0x482f38(0x165)](_0x49b556)?_0x49b556:this[_0x482f38(0x13f)](_0x49b556);if(!_0x5d7ac3)throw new AnnError(ValidatorError_1['ValidatorError']['NOFIND_SCHEMA']);_0x42483b[_0x482f38(0x147)]=Object[_0x482f38(0x12c)]((_0x4f4eb4=this[_0x482f38(0x15e)][_0x482f38(0x147)])!==null&&_0x4f4eb4!==void 0x0?_0x4f4eb4:{},{'messages':this[_0x482f38(0x168)]},_0x42483b['validationOptions']||{}),_0x42483b['validationOptions']['errors']=_0x42483b[_0x482f38(0x147)][_0x482f38(0x145)]||{},_0x42483b[_0x482f38(0x147)][_0x482f38(0x145)][_0x482f38(0x14c)]=(0x0,i18n_1[_0x482f38(0x169)])(this[_0x482f38(0x14d)][_0x482f38(0x14e)](_0x42483b[_0x482f38(0x147)][_0x482f38(0x145)]['language']||_0x42483b[_0x482f38(0x13b)]||this[_0x482f38(0x141)][_0x482f38(0x14f)],_0x482f38(0x155)));const _0x2b6be0=_0x5d7ac3['validate'](_0x120256,_0x42483b[_0x482f38(0x147)]);if(_0x2b6be0===null||_0x2b6be0===void 0x0?void 0x0:_0x2b6be0[_0x482f38(0x16b)]){if(_0x2b6be0[_0x482f38(0x16b)]instanceof AnnError)throw _0x2b6be0[_0x482f38(0x16b)];else{if(_0x2b6be0[_0x482f38(0x16b)]instanceof Error)throw new AnnError(ValidatorError_1['ValidatorError'][_0x482f38(0x128)],{'message':((_0x45050f=_0x2b6be0[_0x482f38(0x16b)])===null||_0x45050f===void 0x0?void 0x0:_0x45050f[_0x482f38(0x144)])||'参数验证失败'});else throw new AnnError(ValidatorError_1[_0x482f38(0x16a)][_0x482f38(0x128)],{'message':((_0x4a86cc=(_0x3bafe5=(_0x2ffb89=_0x2b6be0['error'])===null||_0x2ffb89===void 0x0?void 0x0:_0x2ffb89[_0x482f38(0x148)])===null||_0x3bafe5===void 0x0?void 0x0:_0x3bafe5[0x0])===null||_0x4a86cc===void 0x0?void 0x0:_0x4a86cc[_0x482f38(0x144)])||_0x482f38(0x158)});}}if(_0x2b6be0===null||_0x2b6be0===void 0x0?void 0x0:_0x2b6be0[_0x482f38(0x153)]){const _0x52effc=(_0x851c3f=_0x5d7ac3===null||_0x5d7ac3===void 0x0?void 0x0:_0x5d7ac3[_0x482f38(0x13d)])===null||_0x851c3f===void 0x0?void 0x0:_0x851c3f[_0x482f38(0x162)],_0x4f736c=function(_0x3ae5e1,_0x19ad0c){const _0x2008d6=_0x482f38;var _0x4266d0,_0x376b0b,_0x3693b6,_0x37c17f,_0x55217f,_0x2a1667,_0x2b84f3,_0x5c3e7e,_0x533f5f,_0x5df944,_0x244537;for(let _0x47b96b in _0x3ae5e1){if(_0x19ad0c[(_0x4266d0=_0x3ae5e1[_0x47b96b])===null||_0x4266d0===void 0x0?void 0x0:_0x4266d0[_0x2008d6(0x16c)]]&&((_0x3693b6=(_0x376b0b=_0x3ae5e1[_0x47b96b])===null||_0x376b0b===void 0x0?void 0x0:_0x376b0b[_0x2008d6(0x14a)])===null||_0x3693b6===void 0x0?void 0x0:_0x3693b6['type'])){if(((_0x55217f=(_0x37c17f=_0x3ae5e1[_0x47b96b])===null||_0x37c17f===void 0x0?void 0x0:_0x37c17f[_0x2008d6(0x14a)])===null||_0x55217f===void 0x0?void 0x0:_0x55217f['type'])==_0x2008d6(0x14b))_0x19ad0c[_0x3ae5e1[_0x47b96b][_0x2008d6(0x16c)]]=_0x4f736c((_0x2b84f3=(_0x2a1667=_0x3ae5e1[_0x47b96b])===null||_0x2a1667===void 0x0?void 0x0:_0x2a1667[_0x2008d6(0x14a)][_0x2008d6(0x13d)])===null||_0x2b84f3===void 0x0?void 0x0:_0x2b84f3['keys'],_0x19ad0c[_0x3ae5e1[_0x47b96b]['key']]);else{if(_0x3ae5e1[_0x47b96b][_0x2008d6(0x14a)][_0x2008d6(0x129)]=='date'&&_0x2b6be0[_0x2008d6(0x153)][(_0x5c3e7e=_0x3ae5e1[_0x47b96b])===null||_0x5c3e7e===void 0x0?void 0x0:_0x5c3e7e['key']]){const _0x14e812=((_0x244537=(_0x5df944=(_0x533f5f=_0x3ae5e1[_0x47b96b])===null||_0x533f5f===void 0x0?void 0x0:_0x533f5f[_0x2008d6(0x14a)])===null||_0x5df944===void 0x0?void 0x0:_0x5df944[_0x2008d6(0x136)])===null||_0x244537===void 0x0?void 0x0:_0x244537[_0x2008d6(0x15d)])||'YYYY-MM-DD\x20HH:mm:ss';_0x19ad0c[_0x3ae5e1[_0x47b96b][_0x2008d6(0x16c)]]=dayjs(_0x2b6be0[_0x2008d6(0x153)][_0x3ae5e1[_0x47b96b][_0x2008d6(0x16c)]])[_0x2008d6(0x15d)](_0x14e812);}}}}return _0x19ad0c;};return _0x4f736c(_0x52effc,_0x2b6be0[_0x482f38(0x153)]);}throw new AnnError(ValidatorError_1[_0x482f38(0x16a)][_0x482f38(0x128)]);}};__decorate([(0x0,core_1[a8_0x247977(0x154)])('i18n'),__metadata(a8_0x247977(0x12a),Object)],ValidatorService['prototype'],'i18nConfig',void 0x0),__decorate([(0x0,core_1['Config'])(a8_0x247977(0x155)),__metadata(a8_0x247977(0x12a),Object)],ValidatorService[a8_0x247977(0x15c)],a8_0x247977(0x15e),void 0x0),__decorate([(0x0,core_1['Inject'])(),__metadata(a8_0x247977(0x12a),i18n_1['MidwayI18nServiceSingleton'])],ValidatorService[a8_0x247977(0x15c)],'i18nService',void 0x0),__decorate([(0x0,core_1[a8_0x247977(0x12d)])(),__metadata(a8_0x247977(0x12a),Function),__metadata('design:paramtypes',[]),__metadata(a8_0x247977(0x151),Promise)],ValidatorService['prototype'],a8_0x247977(0x12e),null),exports['ValidatorService']=ValidatorService=__decorate([(0x0,core_1[a8_0x247977(0x13a)])(a8_0x247977(0x155)),(0x0,core_1[a8_0x247977(0x13c)])(core_1['ScopeEnum'][a8_0x247977(0x13e)])],ValidatorService);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anncic-api/validator",
|
|
3
|
-
"version": "3.2.
|
|
3
|
+
"version": "3.2.21",
|
|
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.2.
|
|
20
|
+
"@anncic-api/core": "^3.2.21",
|
|
21
21
|
"@joi/date": "^2.1.0",
|
|
22
22
|
"joi": "^17.9.2"
|
|
23
23
|
},
|
|
@@ -26,5 +26,5 @@
|
|
|
26
26
|
"javascript-obfuscator": "^4.0.2",
|
|
27
27
|
"typescript": "^5.1.3"
|
|
28
28
|
},
|
|
29
|
-
"gitHead": "
|
|
29
|
+
"gitHead": "6ba3d00746f6d744cde95ac6e3b2d1660b54f592"
|
|
30
30
|
}
|