@anncic-api/validator 1.5.14 → 1.5.16
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_0x6a56f0=a0_0x5498;(function(_0x51e028,_0x4ea49b){const _0x4a7c52=a0_0x5498,_0x470812=_0x51e028();while(!![]){try{const _0x390a58=parseInt(_0x4a7c52(0xc5))/0x1*(parseInt(_0x4a7c52(0xc2))/0x2)+-parseInt(_0x4a7c52(0xbc))/0x3+-parseInt(_0x4a7c52(0xc8))/0x4*(parseInt(_0x4a7c52(0xbe))/0x5)+parseInt(_0x4a7c52(0xc6))/0x6+parseInt(_0x4a7c52(0xc4))/0x7+-parseInt(_0x4a7c52(0xbb))/0x8+parseInt(_0x4a7c52(0xbd))/0x9;if(_0x390a58===_0x4ea49b)break;else _0x470812['push'](_0x470812['shift']());}catch(_0x1f4240){_0x470812['push'](_0x470812['shift']());}}}(a0_0x3652,0xdd073));const a0_0x4a37f0=(function(){let _0x2c001d=!![];return function(_0x186d5f,_0x1b21e2){const _0x101301=_0x2c001d?function(){const _0x80a992=a0_0x5498;if(_0x1b21e2){const _0xaca320=_0x1b21e2[_0x80a992(0xbf)](_0x186d5f,arguments);return _0x1b21e2=null,_0xaca320;}}:function(){};return _0x2c001d=![],_0x101301;};}()),a0_0x43b668=a0_0x4a37f0(this,function(){const _0x593eff=a0_0x5498;return a0_0x43b668['toString']()[_0x593eff(0xc1)](_0x593eff(0xcd))['toString']()[_0x593eff(0xc3)](a0_0x43b668)[_0x593eff(0xc1)]('(((.+)+)+)+$');});a0_0x43b668();'use strict';Object[a0_0x6a56f0(0xc7)](exports,a0_0x6a56f0(0xc0),{'value':!![]});const ValidatorError_1=require('../exception/ValidatorError');function a0_0x3652(){const _0x11ff15=['../../locales/en_US.json','(((.+)+)+)+$','PARAMS','984912pvgQxp','1862916ZkvHTm','2610891HtXzue','1675595izQFYr','apply','__esModule','search','1574ZMUrVz','constructor','2880535zoqNKV','919kpcpEf','5368788jhllAf','defineProperty','8ifizVb','default','../../locales/zh_CN.json','ValidatorError'];a0_0x3652=function(){return _0x11ff15;};return a0_0x3652();}function a0_0x5498(_0x1b355d,_0x22c526){const _0x113827=a0_0x3652();return a0_0x5498=function(_0x43b668,_0x4a37f0){_0x43b668=_0x43b668-0xba;let _0x365264=_0x113827[_0x43b668];return _0x365264;},a0_0x5498(_0x1b355d,_0x22c526);}exports[a0_0x6a56f0(0xc9)]={'validator':{'errorStatus':ValidatorError_1[a0_0x6a56f0(0xcb)][a0_0x6a56f0(0xba)],'validationOptions':{'allowUnknown':!![],'stripUnknown':!![],'dateFormat':'string'}},'i18n':{'localeTable':{'en_US':{'validator':require(a0_0x6a56f0(0xcc))},'zh_CN':{'validator':require(a0_0x6a56f0(0xca))}}}};
|
package/dist/configuration.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a1_0x525ecf=a1_0x15a5;(function(_0x276b40,_0x4f6f01){const _0x5787d2=a1_0x15a5,_0x413cc=_0x276b40();while(!![]){try{const _0x1f3517=-parseInt(_0x5787d2(0x1f5))/0x1*(parseInt(_0x5787d2(0x214))/0x2)+parseInt(_0x5787d2(0x1f9))/0x3*(parseInt(_0x5787d2(0x219))/0x4)+parseInt(_0x5787d2(0x1e2))/0x5+parseInt(_0x5787d2(0x1f2))/0x6*(-parseInt(_0x5787d2(0x1fb))/0x7)+-parseInt(_0x5787d2(0x1f7))/0x8*(-parseInt(_0x5787d2(0x211))/0x9)+parseInt(_0x5787d2(0x20e))/0xa+parseInt(_0x5787d2(0x212))/0xb*(parseInt(_0x5787d2(0x203))/0xc);if(_0x1f3517===_0x4f6f01)break;else _0x413cc['push'](_0x413cc['shift']());}catch(_0x32e311){_0x413cc['push'](_0x413cc['shift']());}}}(a1_0x5a6e,0x982dc));const a1_0x1714e6=(function(){let _0x26bea7=!![];return function(_0x18eef4,_0x3a4645){const _0x12c5c1=_0x26bea7?function(){const _0x13ce9c=a1_0x15a5;if(_0x3a4645){const _0x3a8b87=_0x3a4645[_0x13ce9c(0x1eb)](_0x18eef4,arguments);return _0x3a4645=null,_0x3a8b87;}}:function(){};return _0x26bea7=![],_0x12c5c1;};}()),a1_0x35e5ed=a1_0x1714e6(this,function(){const _0x4bf741=a1_0x15a5;return a1_0x35e5ed[_0x4bf741(0x210)]()[_0x4bf741(0x20d)](_0x4bf741(0x20a))[_0x4bf741(0x210)]()[_0x4bf741(0x215)](a1_0x35e5ed)[_0x4bf741(0x20d)](_0x4bf741(0x20a));});a1_0x35e5ed();'use strict';var __decorate=this&&this[a1_0x525ecf(0x1e9)]||function(_0x4ebbbd,_0x38a5fd,_0x5415a6,_0x18cd53){const _0x1ef853=a1_0x525ecf;var _0x5e8899=arguments[_0x1ef853(0x21c)],_0x281a3a=_0x5e8899<0x3?_0x38a5fd:_0x18cd53===null?_0x18cd53=Object[_0x1ef853(0x1ef)](_0x38a5fd,_0x5415a6):_0x18cd53,_0x3e0bbe;if(typeof Reflect===_0x1ef853(0x1f0)&&typeof Reflect[_0x1ef853(0x1ed)]===_0x1ef853(0x217))_0x281a3a=Reflect[_0x1ef853(0x1ed)](_0x4ebbbd,_0x38a5fd,_0x5415a6,_0x18cd53);else{for(var _0x121f38=_0x4ebbbd[_0x1ef853(0x21c)]-0x1;_0x121f38>=0x0;_0x121f38--)if(_0x3e0bbe=_0x4ebbbd[_0x121f38])_0x281a3a=(_0x5e8899<0x3?_0x3e0bbe(_0x281a3a):_0x5e8899>0x3?_0x3e0bbe(_0x38a5fd,_0x5415a6,_0x281a3a):_0x3e0bbe(_0x38a5fd,_0x5415a6))||_0x281a3a;}return _0x5e8899>0x3&&_0x281a3a&&Object[_0x1ef853(0x1f4)](_0x38a5fd,_0x5415a6,_0x281a3a),_0x281a3a;},__metadata=this&&this[a1_0x525ecf(0x1e7)]||function(_0x20c7f3,_0xa10d9f){const _0x1785fe=a1_0x525ecf;if(typeof Reflect===_0x1785fe(0x1f0)&&typeof Reflect[_0x1785fe(0x200)]===_0x1785fe(0x217))return Reflect[_0x1785fe(0x200)](_0x20c7f3,_0xa10d9f);};function a1_0x5a6e(){const _0x3a7f34=['length','params','find','args','query','getAttr','348630iGZmbt','anncic-api:validator','./service/ValidatorService','request','@midwayjs/i18n','__metadata','Configuration','__decorate','onReady','apply','./config/config.default','decorate','./interface','getOwnPropertyDescriptor','object','MidwayDecoratorService','12WrAyzs','splice','defineProperty','160829PIhmin','REQUEST_OBJ_CTX_KEY','96tldEWl','I18N_ATTR_KEY','100668GIZKYx','@midwayjs/core','2106090mRLAOj','propertyName','target','ValidatorService','CustomConfiguration','metadata','methodName','methodArgs','1622508TUTiRe','getSchema','bound\x20dispatch','req','locale','getMethodParamTypes','assign','(((.+)+)+)+$','undefined','design:type','search','3858590rNuYSi','res','toString','589473hJiIdm','22SHmjnH','registerMethodHandler','14IdjruR','constructor','getClassMetadata','function','Inject','100NbnwIq','validator','decorator'];a1_0x5a6e=function(){return _0x3a7f34;};return a1_0x5a6e();}Object[a1_0x525ecf(0x1f4)](exports,'__esModule',{'value':!![]}),exports['CustomConfiguration']=void 0x0;const i18n_1=require(a1_0x525ecf(0x1e6)),core_1=require('@midwayjs/core'),core_2=require(a1_0x525ecf(0x1fa)),interface_1=require(a1_0x525ecf(0x1ee)),ValidatorService_1=require(a1_0x525ecf(0x1e4)),i18n=require(a1_0x525ecf(0x1e6)),anncic=require('@anncic-api/core'),ConfigDefault=require(a1_0x525ecf(0x1ec));let CustomConfiguration=class CustomConfiguration{async[a1_0x525ecf(0x1ea)](){const _0x5c8d3c=a1_0x525ecf;this[_0x5c8d3c(0x21b)][_0x5c8d3c(0x213)](interface_1['VALIDATOR_KEY'],_0x3fb04c=>{const _0x1731f1=_0x5c8d3c,_0xd9bad9=_0x3fb04c['metadata'],_0x4f73cb=(0x0,core_2[_0x1731f1(0x208)])(_0x3fb04c[_0x1731f1(0x1fd)],_0x3fb04c[_0x1731f1(0x1fc)]);return{'before':_0x412e46=>{const _0x510c93=_0x1731f1;var _0x64c031,_0x1d9e3f,_0x4e65b7,_0x38fff6,_0x52999f,_0x1f8d74,_0x2e515a,_0x364e4f,_0x41f8ba,_0x52b9a9,_0x4dcb5b,_0x2a50d9,_0x562ee1;const _0x23d632=_0x412e46['target'][core_1[_0x510c93(0x1f6)]],_0x38b054=Object[_0x510c93(0x209)]({},((_0x64c031=_0x23d632===null||_0x23d632===void 0x0?void 0x0:_0x23d632['request'])===null||_0x64c031===void 0x0?void 0x0:_0x64c031[_0x510c93(0x220)])||{},((_0x1d9e3f=_0x23d632===null||_0x23d632===void 0x0?void 0x0:_0x23d632[_0x510c93(0x1e5)])===null||_0x1d9e3f===void 0x0?void 0x0:_0x1d9e3f['body'])||{}),_0x5ae113=((0x0,core_2[_0x510c93(0x216)])(interface_1['VALIDATOR_KEY'],_0x412e46[_0x510c93(0x1fd)])||[])[_0x510c93(0x21e)](_0x4039dd=>_0x4039dd['method']==_0x412e46[_0x510c93(0x201)]);!(_0xd9bad9===null||_0xd9bad9===void 0x0?void 0x0:_0xd9bad9[_0x510c93(0x207)])&&_0x23d632&&_0x23d632[_0x510c93(0x1e1)]&&(_0xd9bad9[_0x510c93(0x207)]=_0x23d632[_0x510c93(0x1e1)](i18n_1[_0x510c93(0x1f8)]));for(let _0x286b82=0x0;_0x286b82<_0x4f73cb[_0x510c93(0x21c)];_0x286b82++){const _0x253639=_0x4f73cb[_0x286b82],_0xd91d38=this[_0x510c93(0x1fe)][_0x510c93(0x204)](_0x253639);if(_0xd91d38){if(typeof _0x412e46[_0x510c93(0x21f)][_0x286b82]==_0x510c93(0x20b)||((_0x4e65b7=_0x412e46[_0x510c93(0x21f)][_0x286b82])===null||_0x4e65b7===void 0x0?void 0x0:_0x4e65b7[_0x510c93(0x1e5)])&&((_0x38fff6=_0x412e46[_0x510c93(0x21f)][_0x286b82])===null||_0x38fff6===void 0x0?void 0x0:_0x38fff6[_0x510c93(0x20f)])&&((_0x52999f=_0x412e46[_0x510c93(0x21f)][_0x286b82])===null||_0x52999f===void 0x0?void 0x0:_0x52999f[_0x510c93(0x206)]))_0x412e46[_0x510c93(0x21f)][_0x286b82]=_0x38b054;else((_0x1f8d74=_0x412e46[_0x510c93(0x21f)][_0x286b82])===null||_0x1f8d74===void 0x0?void 0x0:_0x1f8d74['name'])==_0x510c93(0x205)&&_0x412e46[_0x510c93(0x21f)][_0x510c93(0x1f3)](_0x286b82,0x0,_0x38b054);const _0x34989c=this[_0x510c93(0x1fe)][_0x510c93(0x21a)](_0xd91d38,_0x412e46['args'][_0x286b82],_0xd9bad9);_0x34989c&&(_0x412e46[_0x510c93(0x21f)][_0x286b82]=_0x34989c);}else{if((_0x5ae113===null||_0x5ae113===void 0x0?void 0x0:_0x5ae113[_0x510c93(0x202)][_0x286b82])&&((_0x2e515a=_0x412e46[_0x510c93(0x21f)][_0x286b82])===null||_0x2e515a===void 0x0?void 0x0:_0x2e515a[_0x510c93(0x21d)])&&typeof _0x412e46['args'][_0x286b82]['param']==_0x510c93(0x217)&&((_0x364e4f=_0x23d632===null||_0x23d632===void 0x0?void 0x0:_0x23d632[_0x510c93(0x21d)])===null||_0x364e4f===void 0x0?void 0x0:_0x364e4f[_0x5ae113[_0x510c93(0x202)][_0x286b82]]))_0x412e46[_0x510c93(0x21f)][_0x286b82]=_0x253639((_0x41f8ba=_0x23d632===null||_0x23d632===void 0x0?void 0x0:_0x23d632['params'])===null||_0x41f8ba===void 0x0?void 0x0:_0x41f8ba[_0x5ae113['methodArgs'][_0x286b82]]);else(_0x5ae113===null||_0x5ae113===void 0x0?void 0x0:_0x5ae113[_0x510c93(0x202)][_0x286b82])&&((_0x4dcb5b=(_0x52b9a9=_0x412e46[_0x510c93(0x21f)][_0x286b82])===null||_0x52b9a9===void 0x0?void 0x0:_0x52b9a9[_0x510c93(0x21d)])===null||_0x4dcb5b===void 0x0?void 0x0:_0x4dcb5b[_0x5ae113['methodArgs'][_0x286b82]])&&(_0x412e46['args'][_0x286b82]=(_0x562ee1=(_0x2a50d9=_0x412e46[_0x510c93(0x21f)][_0x286b82])===null||_0x2a50d9===void 0x0?void 0x0:_0x2a50d9[_0x510c93(0x21d)])===null||_0x562ee1===void 0x0?void 0x0:_0x562ee1[_0x5ae113[_0x510c93(0x202)][_0x286b82]]);}}},'afterThrow':(_0x29ed25,_0x5568d9)=>{throw _0x5568d9;}};});}};function a1_0x15a5(_0x4f6c1a,_0x41b155){const _0x426254=a1_0x5a6e();return a1_0x15a5=function(_0x35e5ed,_0x1714e6){_0x35e5ed=_0x35e5ed-0x1e1;let _0x5a6ec7=_0x426254[_0x35e5ed];return _0x5a6ec7;},a1_0x15a5(_0x4f6c1a,_0x41b155);}__decorate([(0x0,core_2[a1_0x525ecf(0x218)])(),__metadata(a1_0x525ecf(0x20c),core_1[a1_0x525ecf(0x1f1)])],CustomConfiguration['prototype'],a1_0x525ecf(0x21b),void 0x0),__decorate([(0x0,core_2[a1_0x525ecf(0x218)])(),__metadata(a1_0x525ecf(0x20c),ValidatorService_1[a1_0x525ecf(0x1fe)])],CustomConfiguration['prototype'],a1_0x525ecf(0x1fe),void 0x0),CustomConfiguration=__decorate([(0x0,core_2[a1_0x525ecf(0x1e8)])({'conflictCheck':![],'imports':[i18n,anncic],'namespace':a1_0x525ecf(0x1e3),'importConfigs':[{'default':ConfigDefault}]})],CustomConfiguration),exports[a1_0x525ecf(0x1ff)]=CustomConfiguration;
|
package/dist/decorator/Rule.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a2_0xe9c4(){const _0x2ea9f6=['3182307mLDiHU','1420060mRYMWJ','joi','(((.+)+)+)+$','meta','4535694HBPKSu','label','RuleType','defineProperty','extend','name','apply','getPropertyType','../interface','search','constructor','description','toString','function','6963432XUXmCq','RULES_KEY','28ZlXDtQ','558941YnXhMY','@midwayjs/core','map','50934257rqsgHD','object','4CAoLnW','default','925116MQWuIU','isSchema','30WWcJFH','__esModule','saveClassMetadata','Array','array','items','getClassMetadata','4ITefpv','Rule','attachClassMetadata','@joi/date'];a2_0xe9c4=function(){return _0x2ea9f6;};return a2_0xe9c4();}const a2_0x1bbba1=a2_0x4021;(function(_0x34f3ce,_0x219a98){const _0x390217=a2_0x4021,_0x226a7f=_0x34f3ce();while(!![]){try{const _0x10fd48=-parseInt(_0x390217(0xd8))/0x1*(parseInt(_0x390217(0xbe))/0x2)+-parseInt(_0x390217(0xc2))/0x3*(parseInt(_0x390217(0xdd))/0x4)+-parseInt(_0x390217(0xc3))/0x5+parseInt(_0x390217(0xdf))/0x6*(-parseInt(_0x390217(0xd7))/0x7)+parseInt(_0x390217(0xd5))/0x8+parseInt(_0x390217(0xc7))/0x9*(-parseInt(_0x390217(0xe1))/0xa)+parseInt(_0x390217(0xdb))/0xb;if(_0x10fd48===_0x219a98)break;else _0x226a7f['push'](_0x226a7f['shift']());}catch(_0x4db51a){_0x226a7f['push'](_0x226a7f['shift']());}}}(a2_0xe9c4,0xde0c7));const a2_0x3f8731=(function(){let _0x2f9620=!![];return function(_0x36891e,_0x40c765){const _0x253419=_0x2f9620?function(){const _0x54f37a=a2_0x4021;if(_0x40c765){const _0x551139=_0x40c765[_0x54f37a(0xcd)](_0x36891e,arguments);return _0x40c765=null,_0x551139;}}:function(){};return _0x2f9620=![],_0x253419;};}()),a2_0x248c24=a2_0x3f8731(this,function(){const _0x58b929=a2_0x4021;return a2_0x248c24[_0x58b929(0xd3)]()[_0x58b929(0xd0)](_0x58b929(0xc5))[_0x58b929(0xd3)]()[_0x58b929(0xd1)](a2_0x248c24)[_0x58b929(0xd0)](_0x58b929(0xc5));});a2_0x248c24();'use strict';function a2_0x4021(_0x20934b,_0x29b470){const _0x281c2c=a2_0xe9c4();return a2_0x4021=function(_0x248c24,_0x3f8731){_0x248c24=_0x248c24-0xbc;let _0xe9c47d=_0x281c2c[_0x248c24];return _0xe9c47d;},a2_0x4021(_0x20934b,_0x29b470);}Object[a2_0x1bbba1(0xca)](exports,a2_0x1bbba1(0xe2),{'value':!![]}),exports[a2_0x1bbba1(0xbf)]=exports[a2_0x1bbba1(0xc9)]=void 0x0;const joi=require(a2_0x1bbba1(0xc4)),date_1=require(a2_0x1bbba1(0xc1)),core_1=require(a2_0x1bbba1(0xd9)),interface_1=require(a2_0x1bbba1(0xcf));exports[a2_0x1bbba1(0xc9)]=joi[a2_0x1bbba1(0xcb)](date_1[a2_0x1bbba1(0xde)]);function Rule(_0x3eb8c4,_0x45439a,_0x5e5934=''){return(_0x1dd9bf,_0x50dacf)=>{const _0x1b6d73=a2_0x4021;var _0x33700a;if(_0x50dacf)!joi[_0x1b6d73(0xe0)](_0x45439a)&&(_0x45439a===null||_0x45439a===void 0x0?void 0x0:_0x45439a[_0x1b6d73(0xcc)])&&(_0x45439a=joi[_0x1b6d73(0xdc)]((0x0,core_1[_0x1b6d73(0xbd)])(interface_1[_0x1b6d73(0xd6)],_0x45439a))[_0x1b6d73(0xc6)]({'id':_0x45439a['name']}),(0x0,core_1[_0x1b6d73(0xce)])(_0x1dd9bf,_0x50dacf)['name']===_0x1b6d73(0xe4)&&(_0x45439a=joi[_0x1b6d73(0xe5)]()[_0x1b6d73(0xbc)](_0x45439a))),joi[_0x1b6d73(0xe0)](_0x45439a)&&(_0x3eb8c4&&typeof(_0x45439a===null||_0x45439a===void 0x0?void 0x0:_0x45439a[_0x1b6d73(0xc8)])==_0x1b6d73(0xd4)&&(_0x45439a=_0x45439a[_0x1b6d73(0xc8)](_0x3eb8c4)),_0x5e5934&&typeof(_0x45439a===null||_0x45439a===void 0x0?void 0x0:_0x45439a[_0x1b6d73(0xd2)])==_0x1b6d73(0xd4)&&(_0x45439a=_0x45439a[_0x1b6d73(0xd2)](_0x5e5934)),(0x0,core_1[_0x1b6d73(0xc0)])(interface_1['RULES_KEY'],_0x45439a,_0x1dd9bf,_0x50dacf));else{const _0x5f21c4=(0x0,core_1[_0x1b6d73(0xbd)])(interface_1[_0x1b6d73(0xd6)],_0x45439a);if(_0x5f21c4){let _0x2d6bbc=(_0x33700a=(0x0,core_1[_0x1b6d73(0xbd)])(interface_1['RULES_KEY'],_0x1dd9bf))!==null&&_0x33700a!==void 0x0?_0x33700a:{};Object['keys'](_0x5f21c4)[_0x1b6d73(0xda)](_0x2eaae0=>{!_0x2d6bbc[_0x2eaae0]&&(_0x2d6bbc[_0x2eaae0]=_0x5f21c4[_0x2eaae0]);}),(0x0,core_1[_0x1b6d73(0xe3)])(interface_1[_0x1b6d73(0xd6)],_0x2d6bbc,_0x1dd9bf);}}};}exports[a2_0x1bbba1(0xbf)]=Rule;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a3_0x3dc842=a3_0x4cce;(function(_0x3add7c,_0x31cb5b){const _0x2a5a21=a3_0x4cce,_0x1a804b=_0x3add7c();while(!![]){try{const _0x4254d0=parseInt(_0x2a5a21(0x13e))/0x1+-parseInt(_0x2a5a21(0x141))/0x2*(-parseInt(_0x2a5a21(0x142))/0x3)+parseInt(_0x2a5a21(0x13b))/0x4+-parseInt(_0x2a5a21(0x150))/0x5+-parseInt(_0x2a5a21(0x155))/0x6*(-parseInt(_0x2a5a21(0x14e))/0x7)+-parseInt(_0x2a5a21(0x14b))/0x8*(-parseInt(_0x2a5a21(0x13f))/0x9)+-parseInt(_0x2a5a21(0x14d))/0xa;if(_0x4254d0===_0x31cb5b)break;else _0x1a804b['push'](_0x1a804b['shift']());}catch(_0x499448){_0x1a804b['push'](_0x1a804b['shift']());}}}(a3_0x3c04,0x8d3a6));const a3_0x388fc4=(function(){let _0x23c2cf=!![];return function(_0x3c9b4f,_0x115696){const _0x77e27=_0x23c2cf?function(){const _0x2273c6=a3_0x4cce;if(_0x115696){const _0x3b0bbc=_0x115696[_0x2273c6(0x14f)](_0x3c9b4f,arguments);return _0x115696=null,_0x3b0bbc;}}:function(){};return _0x23c2cf=![],_0x77e27;};}()),a3_0x5af0fa=a3_0x388fc4(this,function(){const _0x12115f=a3_0x4cce;return a3_0x5af0fa[_0x12115f(0x143)]()[_0x12115f(0x146)](_0x12115f(0x145))[_0x12115f(0x143)]()['constructor'](a3_0x5af0fa)[_0x12115f(0x146)]('(((.+)+)+)+$');});a3_0x5af0fa();'use strict';function a3_0x3c04(){const _0x2dee9c=['18BxkRPn','235869WetrMj','toString','prototype','(((.+)+)+)+$','search','attachClassMetadata','match','function','@midwayjs/core','38632BxDaoW','VALIDATOR_KEY','22404370PtpqNe','14PGDxwB','apply','5000750hPrDOF','indexOf','createCustomMethodDecorator','__esModule','Validator','2733420pcRpjd','slice','3038888kGujnA','constructor','replace','450643WqgGUi','1845QRjedz','getFuncArgs'];a3_0x3c04=function(){return _0x2dee9c;};return a3_0x3c04();}function a3_0x4cce(_0x2b0cb5,_0x505974){const _0x249a49=a3_0x3c04();return a3_0x4cce=function(_0x5af0fa,_0x388fc4){_0x5af0fa=_0x5af0fa-0x13a;let _0x3c0434=_0x249a49[_0x5af0fa];return _0x3c0434;},a3_0x4cce(_0x2b0cb5,_0x505974);}Object['defineProperty'](exports,a3_0x3dc842(0x153),{'value':!![]}),exports[a3_0x3dc842(0x140)]=exports['Validator']=void 0x0;const core_1=require(a3_0x3dc842(0x14a)),interface_1=require('../interface');function Validator(_0x30c23b={}){return(_0x248623,_0x2cf462,_0x385e73)=>{const _0x5a30cf=a3_0x4cce,_0x31cc19=getFuncArgs(_0x248623[_0x2cf462]);(0x0,core_1[_0x5a30cf(0x147)])(interface_1[_0x5a30cf(0x14c)],{'method':_0x2cf462,'methodArgs':_0x31cc19},_0x248623),(0x0,core_1[_0x5a30cf(0x152)])(interface_1[_0x5a30cf(0x14c)],_0x30c23b)(_0x248623,_0x2cf462,_0x385e73);};}exports[a3_0x3dc842(0x154)]=Validator;function getFuncArgs(_0x3eb1c9){const _0x20a2c8=a3_0x3dc842;if(typeof _0x3eb1c9==_0x20a2c8(0x149)){const _0x31dde7=/=>.*$/mg,_0x4aa8e8=/=[^,)]+/mg,_0x3eb5db=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/mg,_0xaa3842=(_0x3eb1c9[_0x20a2c8(0x144)]?_0x3eb1c9[_0x20a2c8(0x144)][_0x20a2c8(0x13c)]['toString']():_0x3eb1c9[_0x20a2c8(0x143)]())['replace'](_0x3eb5db,'')[_0x20a2c8(0x13d)](_0x31dde7,'')[_0x20a2c8(0x13d)](_0x4aa8e8,''),_0x377ed1=_0xaa3842[_0x20a2c8(0x13a)](_0xaa3842[_0x20a2c8(0x151)]('(')+0x1,_0xaa3842[_0x20a2c8(0x151)](')'))[_0x20a2c8(0x148)](/([^\s,]+)/g)||[];return _0x377ed1;}}exports[a3_0x3dc842(0x140)]=getFuncArgs;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a4_0x5b7c5e=a4_0x1793;function a4_0x3512(){var _0x36364d=['length','ValidatorError','PARAMS','toString','3816075cCIfrn','function','constructor','metadata','2801580QvlHVQ','getOwnPropertyDescriptor','NOFIND_SCHEMA','__esModule','(((.+)+)+)+$','9QKGBZU','decorate','__metadata','AnnErrorMsg','1107461ymwaMB','3624zSHfpG','3919264nEsRGP','9243535FxiduC','defineProperty','3808DjBJwk','291836JkWPRl','search','参数验证失败','object','design:type'];a4_0x3512=function(){return _0x36364d;};return a4_0x3512();}(function(_0x2016fb,_0x14dc6d){var _0x27af97=a4_0x1793,_0x1331bb=_0x2016fb();while(!![]){try{var _0x2fec3c=-parseInt(_0x27af97(0x1b8))/0x1+parseInt(_0x27af97(0x1be))/0x2+-parseInt(_0x27af97(0x1b9))/0x3*(-parseInt(_0x27af97(0x1bd))/0x4)+-parseInt(_0x27af97(0x1c7))/0x5+parseInt(_0x27af97(0x1cb))/0x6+parseInt(_0x27af97(0x1bb))/0x7+parseInt(_0x27af97(0x1ba))/0x8*(-parseInt(_0x27af97(0x1d0))/0x9);if(_0x2fec3c===_0x14dc6d)break;else _0x1331bb['push'](_0x1331bb['shift']());}catch(_0x24f8f0){_0x1331bb['push'](_0x1331bb['shift']());}}}(a4_0x3512,0xb0761));var a4_0x3d1d21=(function(){var _0xce2ef3=!![];return function(_0x424413,_0xd967b1){var _0x53ee65=_0xce2ef3?function(){if(_0xd967b1){var _0x3983a9=_0xd967b1['apply'](_0x424413,arguments);return _0xd967b1=null,_0x3983a9;}}:function(){};return _0xce2ef3=![],_0x53ee65;};}()),a4_0x319119=a4_0x3d1d21(this,function(){var _0x3fafa0=a4_0x1793;return a4_0x319119[_0x3fafa0(0x1c6)]()[_0x3fafa0(0x1bf)](_0x3fafa0(0x1cf))[_0x3fafa0(0x1c6)]()[_0x3fafa0(0x1c9)](a4_0x319119)['search']('(((.+)+)+)+$');});a4_0x319119();'use strict';var __decorate=this&&this['__decorate']||function(_0x1166fc,_0x3e6eca,_0xe1e213,_0x10634f){var _0x47eab9=a4_0x1793,_0x4bf640=arguments['length'],_0x1bd158=_0x4bf640<0x3?_0x3e6eca:_0x10634f===null?_0x10634f=Object[_0x47eab9(0x1cc)](_0x3e6eca,_0xe1e213):_0x10634f,_0x1f9812;if(typeof Reflect==='object'&&typeof Reflect['decorate']===_0x47eab9(0x1c8))_0x1bd158=Reflect[_0x47eab9(0x1d1)](_0x1166fc,_0x3e6eca,_0xe1e213,_0x10634f);else{for(var _0x20ca47=_0x1166fc[_0x47eab9(0x1c3)]-0x1;_0x20ca47>=0x0;_0x20ca47--)if(_0x1f9812=_0x1166fc[_0x20ca47])_0x1bd158=(_0x4bf640<0x3?_0x1f9812(_0x1bd158):_0x4bf640>0x3?_0x1f9812(_0x3e6eca,_0xe1e213,_0x1bd158):_0x1f9812(_0x3e6eca,_0xe1e213))||_0x1bd158;}return _0x4bf640>0x3&&_0x1bd158&&Object[_0x47eab9(0x1bc)](_0x3e6eca,_0xe1e213,_0x1bd158),_0x1bd158;},__metadata=this&&this[a4_0x5b7c5e(0x1b6)]||function(_0x2b2ab1,_0xae046){var _0x1d0d7c=a4_0x5b7c5e;if(typeof Reflect===_0x1d0d7c(0x1c1)&&typeof Reflect[_0x1d0d7c(0x1ca)]===_0x1d0d7c(0x1c8))return Reflect[_0x1d0d7c(0x1ca)](_0x2b2ab1,_0xae046);};Object[a4_0x5b7c5e(0x1bc)](exports,a4_0x5b7c5e(0x1ce),{'value':!![]}),exports[a4_0x5b7c5e(0x1c4)]=void 0x0;function a4_0x1793(_0x883eb6,_0x35d05d){var _0x12b881=a4_0x3512();return a4_0x1793=function(_0x319119,_0x3d1d21){_0x319119=_0x319119-0x1b6;var _0x3512a1=_0x12b881[_0x319119];return _0x3512a1;},a4_0x1793(_0x883eb6,_0x35d05d);}const core_1=require('@anncic-api/core');class ValidatorError{}ValidatorError[a4_0x5b7c5e(0x1c5)]=0x3df374,ValidatorError[a4_0x5b7c5e(0x1cd)]=0x3df36a,__decorate([(0x0,core_1[a4_0x5b7c5e(0x1b7)])(a4_0x5b7c5e(0x1c0)),__metadata(a4_0x5b7c5e(0x1c2),Object)],ValidatorError,a4_0x5b7c5e(0x1c5),void 0x0),__decorate([(0x0,core_1[a4_0x5b7c5e(0x1b7)])(a4_0x5b7c5e(0x1c0)),__metadata(a4_0x5b7c5e(0x1c2),Object)],ValidatorError,a4_0x5b7c5e(0x1cd),void 0x0),exports[a4_0x5b7c5e(0x1c4)]=ValidatorError;
|
package/dist/helper/dtoHelper.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a5_0x5e32e7=a5_0xaa11;(function(_0x4eba21,_0x595572){const _0x20b9cd=a5_0xaa11,_0x3f764e=_0x4eba21();while(!![]){try{const _0x1453bb=-parseInt(_0x20b9cd(0x1c6))/0x1+parseInt(_0x20b9cd(0x1be))/0x2+-parseInt(_0x20b9cd(0x1c7))/0x3*(parseInt(_0x20b9cd(0x1cf))/0x4)+parseInt(_0x20b9cd(0x1c9))/0x5*(parseInt(_0x20b9cd(0x1ce))/0x6)+parseInt(_0x20b9cd(0x1bf))/0x7+parseInt(_0x20b9cd(0x1cc))/0x8+-parseInt(_0x20b9cd(0x1c2))/0x9*(parseInt(_0x20b9cd(0x1d5))/0xa);if(_0x1453bb===_0x595572)break;else _0x3f764e['push'](_0x3f764e['shift']());}catch(_0x41d927){_0x3f764e['push'](_0x3f764e['shift']());}}}(a5_0x5cdc,0xdb417));function a5_0x5cdc(){const _0x48b471=['toString','12410144ledPxn','constructor','90CvbtAH','228MefzPT','(((.+)+)+)+$','__esModule','defineProperty','OmitDto','prototype','2110rJHCEu','../interface','3263766DDKqTT','1858094JHdjBY','getClassExtendedMetadata','@midwayjs/core','124461sGCisF','PickDto','assign','RULES_KEY','875425IDkfmx','20157FtSgIn','search','541935MVYZvE','saveClassMetadata'];a5_0x5cdc=function(){return _0x48b471;};return a5_0x5cdc();}const a5_0x514b7f=(function(){let _0x2346a2=!![];return function(_0x3531b7,_0x21efb2){const _0x3f419a=_0x2346a2?function(){if(_0x21efb2){const _0x41a903=_0x21efb2['apply'](_0x3531b7,arguments);return _0x21efb2=null,_0x41a903;}}:function(){};return _0x2346a2=![],_0x3f419a;};}()),a5_0x4d90be=a5_0x514b7f(this,function(){const _0x46702c=a5_0xaa11;return a5_0x4d90be[_0x46702c(0x1cb)]()[_0x46702c(0x1c8)](_0x46702c(0x1d0))[_0x46702c(0x1cb)]()[_0x46702c(0x1cd)](a5_0x4d90be)['search']('(((.+)+)+)+$');});a5_0x4d90be();'use strict';function a5_0xaa11(_0x5822aa,_0x178387){const _0x51ff29=a5_0x5cdc();return a5_0xaa11=function(_0x4d90be,_0x514b7f){_0x4d90be=_0x4d90be-0x1bd;let _0x5cdc6c=_0x51ff29[_0x4d90be];return _0x5cdc6c;},a5_0xaa11(_0x5822aa,_0x178387);}Object[a5_0x5e32e7(0x1d2)](exports,a5_0x5e32e7(0x1d1),{'value':!![]}),exports[a5_0x5e32e7(0x1d3)]=exports[a5_0x5e32e7(0x1c3)]=void 0x0;const core_1=require(a5_0x5e32e7(0x1c1)),interface_1=require(a5_0x5e32e7(0x1bd));function PickDto(_0x806bc,_0x143240){const _0x52368c=a5_0x5e32e7,_0x53515d=function(){};_0x53515d[_0x52368c(0x1d4)]=_0x806bc[_0x52368c(0x1d4)];const _0x1b7cf3=(0x0,core_1[_0x52368c(0x1c0)])(interface_1['RULES_KEY'],_0x806bc),_0x1fa2e3={};for(const _0x1379d8 of _0x143240){_0x1b7cf3[_0x1379d8]&&(_0x1fa2e3[_0x1379d8]=_0x1b7cf3[_0x1379d8]);}return(0x0,core_1[_0x52368c(0x1ca)])(interface_1[_0x52368c(0x1c5)],_0x1fa2e3,_0x53515d),_0x53515d;}exports['PickDto']=PickDto;function OmitDto(_0x664795,_0x5ceca8){const _0x46125e=a5_0x5e32e7,_0x1f1590=function(){};_0x1f1590['prototype']=_0x664795[_0x46125e(0x1d4)];const _0x5026bc=(0x0,core_1['getClassExtendedMetadata'])(interface_1[_0x46125e(0x1c5)],_0x664795),_0x59c89d=Object[_0x46125e(0x1c4)]({},_0x5026bc);for(const _0xfd294b of _0x5ceca8){delete _0x59c89d[_0xfd294b];}return(0x0,core_1[_0x46125e(0x1ca)])(interface_1[_0x46125e(0x1c5)],_0x59c89d,_0x1f1590),_0x1f1590;}exports[a5_0x5e32e7(0x1d3)]=OmitDto;
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a6_0x347f06=a6_0x345f;(function(_0xafca2a,_0x5c5a2c){var _0x1832ea=a6_0x345f,_0x153d60=_0xafca2a();while(!![]){try{var _0x7b465=-parseInt(_0x1832ea(0x1f7))/0x1*(parseInt(_0x1832ea(0x20d))/0x2)+parseInt(_0x1832ea(0x1ec))/0x3*(-parseInt(_0x1832ea(0x1f2))/0x4)+parseInt(_0x1832ea(0x1eb))/0x5*(parseInt(_0x1832ea(0x203))/0x6)+parseInt(_0x1832ea(0x1f0))/0x7*(parseInt(_0x1832ea(0x1f9))/0x8)+parseInt(_0x1832ea(0x207))/0x9*(-parseInt(_0x1832ea(0x1f3))/0xa)+-parseInt(_0x1832ea(0x209))/0xb*(-parseInt(_0x1832ea(0x1f5))/0xc)+parseInt(_0x1832ea(0x205))/0xd;if(_0x7b465===_0x5c5a2c)break;else _0x153d60['push'](_0x153d60['shift']());}catch(_0x2f8fea){_0x153d60['push'](_0x153d60['shift']());}}}(a6_0x32ef,0xde013));var a6_0x43631b=(function(){var _0x194c4b=!![];return function(_0x23e693,_0x2bd96b){var _0x115524=_0x194c4b?function(){var _0x528efd=a6_0x345f;if(_0x2bd96b){var _0x5ba7ee=_0x2bd96b[_0x528efd(0x208)](_0x23e693,arguments);return _0x2bd96b=null,_0x5ba7ee;}}:function(){};return _0x194c4b=![],_0x115524;};}()),a6_0x3bd9bc=a6_0x43631b(this,function(){var _0x51ab1b=a6_0x345f;return a6_0x3bd9bc['toString']()['search'](_0x51ab1b(0x1f4))[_0x51ab1b(0x20c)]()[_0x51ab1b(0x1f6)](a6_0x3bd9bc)[_0x51ab1b(0x20a)](_0x51ab1b(0x1f4));});a6_0x3bd9bc();'use strict';var __createBinding=this&&this['__createBinding']||(Object[a6_0x347f06(0x1fa)]?function(_0x3e7fcd,_0x3b92a4,_0x5bf212,_0x129229){var _0x50450e=a6_0x347f06;if(_0x129229===undefined)_0x129229=_0x5bf212;var _0x4fa54c=Object[_0x50450e(0x1fb)](_0x3b92a4,_0x5bf212);(!_0x4fa54c||('get'in _0x4fa54c?!_0x3b92a4[_0x50450e(0x1f1)]:_0x4fa54c[_0x50450e(0x1f8)]||_0x4fa54c[_0x50450e(0x1ed)]))&&(_0x4fa54c={'enumerable':!![],'get':function(){return _0x3b92a4[_0x5bf212];}}),Object[_0x50450e(0x1ef)](_0x3e7fcd,_0x129229,_0x4fa54c);}:function(_0x45b64f,_0x271804,_0xcffef8,_0x37d591){if(_0x37d591===undefined)_0x37d591=_0xcffef8;_0x45b64f[_0x37d591]=_0x271804[_0xcffef8];}),__exportStar=this&&this['__exportStar']||function(_0xe37fb4,_0x2fc670){var _0x43b86b=a6_0x347f06;for(var _0x14d9a9 in _0xe37fb4)if(_0x14d9a9!==_0x43b86b(0x20b)&&!Object[_0x43b86b(0x204)][_0x43b86b(0x1ee)]['call'](_0x2fc670,_0x14d9a9))__createBinding(_0x2fc670,_0xe37fb4,_0x14d9a9);};Object['defineProperty'](exports,a6_0x347f06(0x1f1),{'value':!![]}),exports['Configuration']=exports[a6_0x347f06(0x200)]=exports[a6_0x347f06(0x1e8)]=exports[a6_0x347f06(0x1ea)]=exports['Rule']=exports[a6_0x347f06(0x1fe)]=void 0x0,__exportStar(require(a6_0x347f06(0x206)),exports),__exportStar(require(a6_0x347f06(0x1fc)),exports);function a6_0x32ef(){var _0x4b40a5=['7HbKzXw','__esModule','98276LMPYSj','19280IHezGP','(((.+)+)+)+$','11232084khyQTS','constructor','827ADIKLr','writable','3396296dDAbKu','create','getOwnPropertyDescriptor','./helper/dtoHelper','Configuration','Validator','./decorator/Validator','ValidatorService','Rule','./configuration','219228wMAjnu','prototype','4139928svHNuO','./interface','603LMXvot','apply','11oKsKYV','search','default','toString','62TLfADB','ValidatorError','./service/ValidatorService','RuleType','10QLoFJU','84ubWRJg','configurable','hasOwnProperty','defineProperty'];a6_0x32ef=function(){return _0x4b40a5;};return a6_0x32ef();}var Validator_1=require(a6_0x347f06(0x1ff));Object['defineProperty'](exports,a6_0x347f06(0x1fe),{'enumerable':!![],'get':function(){var _0x4fc58c=a6_0x347f06;return Validator_1[_0x4fc58c(0x1fe)];}});var Rule_1=require('./decorator/Rule');Object[a6_0x347f06(0x1ef)](exports,a6_0x347f06(0x201),{'enumerable':!![],'get':function(){return Rule_1['Rule'];}}),Object[a6_0x347f06(0x1ef)](exports,a6_0x347f06(0x1ea),{'enumerable':!![],'get':function(){return Rule_1['RuleType'];}});var ValidatorError_1=require('./exception/ValidatorError');function a6_0x345f(_0x50dc43,_0x5b0865){var _0x471776=a6_0x32ef();return a6_0x345f=function(_0x3bd9bc,_0x43631b){_0x3bd9bc=_0x3bd9bc-0x1e8;var _0x32ef48=_0x471776[_0x3bd9bc];return _0x32ef48;},a6_0x345f(_0x50dc43,_0x5b0865);}Object[a6_0x347f06(0x1ef)](exports,a6_0x347f06(0x1e8),{'enumerable':!![],'get':function(){var _0x40375a=a6_0x347f06;return ValidatorError_1[_0x40375a(0x1e8)];}});var ValidatorService_1=require(a6_0x347f06(0x1e9));Object['defineProperty'](exports,'ValidatorService',{'enumerable':!![],'get':function(){var _0x5d555e=a6_0x347f06;return ValidatorService_1[_0x5d555e(0x200)];}});var configuration_1=require(a6_0x347f06(0x202));Object[a6_0x347f06(0x1ef)](exports,a6_0x347f06(0x1fd),{'enumerable':!![],'get':function(){return configuration_1['CustomConfiguration'];}});
|
package/dist/interface.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a7_0x1184e2=a7_0x3fb4;(function(_0x47fd34,_0x4d256c){var _0x1c00e0=a7_0x3fb4,_0x25dcc6=_0x47fd34();while(!![]){try{var _0x3ef43d=-parseInt(_0x1c00e0(0x12d))/0x1*(parseInt(_0x1c00e0(0x12e))/0x2)+-parseInt(_0x1c00e0(0x12c))/0x3+-parseInt(_0x1c00e0(0x136))/0x4*(-parseInt(_0x1c00e0(0x128))/0x5)+-parseInt(_0x1c00e0(0x126))/0x6+-parseInt(_0x1c00e0(0x125))/0x7*(parseInt(_0x1c00e0(0x133))/0x8)+-parseInt(_0x1c00e0(0x134))/0x9*(parseInt(_0x1c00e0(0x127))/0xa)+parseInt(_0x1c00e0(0x129))/0xb;if(_0x3ef43d===_0x4d256c)break;else _0x25dcc6['push'](_0x25dcc6['shift']());}catch(_0x3c92fd){_0x25dcc6['push'](_0x25dcc6['shift']());}}}(a7_0x2a22,0x517e6));var a7_0x35b319=(function(){var _0x2f87ff=!![];return function(_0x338097,_0x548fd5){var _0x24ae1e=_0x2f87ff?function(){var _0x1f43b3=a7_0x3fb4;if(_0x548fd5){var _0x4d03c9=_0x548fd5[_0x1f43b3(0x130)](_0x338097,arguments);return _0x548fd5=null,_0x4d03c9;}}:function(){};return _0x2f87ff=![],_0x24ae1e;};}()),a7_0x1b5a9c=a7_0x35b319(this,function(){var _0xd3026c=a7_0x3fb4;return a7_0x1b5a9c['toString']()[_0xd3026c(0x12b)](_0xd3026c(0x12a))[_0xd3026c(0x124)]()[_0xd3026c(0x132)](a7_0x1b5a9c)['search'](_0xd3026c(0x12a));});a7_0x1b5a9c();'use strict';Object['defineProperty'](exports,a7_0x1184e2(0x12f),{'value':!![]}),exports[a7_0x1184e2(0x123)]=exports['RULES_KEY']=void 0x0,exports[a7_0x1184e2(0x135)]='anncic-api:validator:rules',exports['VALIDATOR_KEY']=a7_0x1184e2(0x131);function a7_0x3fb4(_0x4294ab,_0x1a6819){var _0x4ddf30=a7_0x2a22();return a7_0x3fb4=function(_0x1b5a9c,_0x35b319){_0x1b5a9c=_0x1b5a9c-0x123;var _0x2a2222=_0x4ddf30[_0x1b5a9c];return _0x2a2222;},a7_0x3fb4(_0x4294ab,_0x1a6819);}function a7_0x2a22(){var _0x387362=['(((.+)+)+)+$','search','1147743LxXOkO','965HncOiQ','1322pxjDMc','__esModule','apply','anncic-api:validator:validator','constructor','27152KWVeOh','45711mNzSxj','RULES_KEY','49416IpWDKN','VALIDATOR_KEY','toString','882JXwvJN','3287070vSSGzX','1150jCwlUk','215NscUkA','26208556eGLxqj'];a7_0x2a22=function(){return _0x387362;};return a7_0x2a22();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a8_0x4888d9=a8_0x41e9;function a8_0x3bfb(){const _0x68761f=['3158829GzgqdB','参数验证失败','metadata','error','toString','Init','YYYY-MM-DD\x20HH:mm:ss','function','formatLocale','object','6drAlFQ','__esModule','(((.+)+)+)+$','message','69jejnqU','fromEntries','defineProperty','locale','_flags','../interface','key','Singleton','getAvailableLocale','8ZjVSJA','value','ValidatorError','getClassExtendedMetadata','301786dUEiNg','30574xzbylX','15468520zUdWOp','assign','Config','ValidatorService','i18nConfig','getSchema','errors','validator','__metadata','keys','23695oElCPx','init','Scope','schema','isSchema','$_terms','search','i18nService','Inject','date','defaultLocale','design:type','2117155KNiBqw','design:paramtypes','forEach','length','validationOptions','getLocaleMapping','language','prototype','validatorConfig','format','constructor','453292ZTOSIC','Provide','NOFIND_SCHEMA','PARAMS','type','getOwnPropertyDescriptor'];a8_0x3bfb=function(){return _0x68761f;};return a8_0x3bfb();}function a8_0x41e9(_0x36e606,_0xe37738){const _0x5ce4ad=a8_0x3bfb();return a8_0x41e9=function(_0x4f1584,_0x1390f2){_0x4f1584=_0x4f1584-0x1a8;let _0x3bfbeb=_0x5ce4ad[_0x4f1584];return _0x3bfbeb;},a8_0x41e9(_0x36e606,_0xe37738);}(function(_0x557638,_0x297d89){const _0x5369f7=a8_0x41e9,_0x2aa144=_0x557638();while(!![]){try{const _0x2efde8=-parseInt(_0x5369f7(0x1ad))/0x1+parseInt(_0x5369f7(0x1ae))/0x2*(-parseInt(_0x5369f7(0x1e4))/0x3)+parseInt(_0x5369f7(0x1d0))/0x4+-parseInt(_0x5369f7(0x1c5))/0x5*(parseInt(_0x5369f7(0x1e0))/0x6)+-parseInt(_0x5369f7(0x1b9))/0x7+-parseInt(_0x5369f7(0x1a9))/0x8*(parseInt(_0x5369f7(0x1d6))/0x9)+parseInt(_0x5369f7(0x1af))/0xa;if(_0x2efde8===_0x297d89)break;else _0x2aa144['push'](_0x2aa144['shift']());}catch(_0x2bbbe2){_0x2aa144['push'](_0x2aa144['shift']());}}}(a8_0x3bfb,0x37e7f));const a8_0x1390f2=(function(){let _0x3b0442=!![];return function(_0x17fc6f,_0xf7dfb9){const _0x5a8368=_0x3b0442?function(){if(_0xf7dfb9){const _0x57f5a7=_0xf7dfb9['apply'](_0x17fc6f,arguments);return _0xf7dfb9=null,_0x57f5a7;}}:function(){};return _0x3b0442=![],_0x5a8368;};}()),a8_0x4f1584=a8_0x1390f2(this,function(){const _0x284f94=a8_0x41e9;return a8_0x4f1584[_0x284f94(0x1da)]()['search'](_0x284f94(0x1e2))[_0x284f94(0x1da)]()[_0x284f94(0x1cf)](a8_0x4f1584)[_0x284f94(0x1bf)](_0x284f94(0x1e2));});a8_0x4f1584();'use strict';var __decorate=this&&this['__decorate']||function(_0x337880,_0x1ea155,_0x31b899,_0x1ad4d5){const _0xf8f6e4=a8_0x41e9;var _0x577b38=arguments['length'],_0x21909e=_0x577b38<0x3?_0x1ea155:_0x1ad4d5===null?_0x1ad4d5=Object[_0xf8f6e4(0x1d5)](_0x1ea155,_0x31b899):_0x1ad4d5,_0x39cbd8;if(typeof Reflect===_0xf8f6e4(0x1df)&&typeof Reflect['decorate']===_0xf8f6e4(0x1dd))_0x21909e=Reflect['decorate'](_0x337880,_0x1ea155,_0x31b899,_0x1ad4d5);else{for(var _0x3f17d7=_0x337880[_0xf8f6e4(0x1c8)]-0x1;_0x3f17d7>=0x0;_0x3f17d7--)if(_0x39cbd8=_0x337880[_0x3f17d7])_0x21909e=(_0x577b38<0x3?_0x39cbd8(_0x21909e):_0x577b38>0x3?_0x39cbd8(_0x1ea155,_0x31b899,_0x21909e):_0x39cbd8(_0x1ea155,_0x31b899))||_0x21909e;}return _0x577b38>0x3&&_0x21909e&&Object[_0xf8f6e4(0x1e6)](_0x1ea155,_0x31b899,_0x21909e),_0x21909e;},__metadata=this&&this[a8_0x4888d9(0x1b7)]||function(_0x14982b,_0x4804dc){const _0x1d24e4=a8_0x4888d9;if(typeof Reflect===_0x1d24e4(0x1df)&&typeof Reflect[_0x1d24e4(0x1d8)]==='function')return Reflect[_0x1d24e4(0x1d8)](_0x14982b,_0x4804dc);};Object[a8_0x4888d9(0x1e6)](exports,a8_0x4888d9(0x1e1),{'value':!![]}),exports[a8_0x4888d9(0x1b2)]=void 0x0;const Joi=require('joi'),i18n_1=require('@midwayjs/i18n'),core_1=require('@midwayjs/core'),interface_1=require(a8_0x4888d9(0x1e9)),ValidatorError_1=require('../exception/ValidatorError');let ValidatorService=class ValidatorService{constructor(){this['messages']={};}async[a8_0x4888d9(0x1ba)](){const _0x553091=a8_0x4888d9,_0x16e714=Object[_0x553091(0x1b8)](this[_0x553091(0x1b3)]['localeTable']);_0x16e714[_0x553091(0x1c7)](_0x29ea42=>{const _0x51eaf2=_0x553091;this['messages'][(0x0,i18n_1[_0x51eaf2(0x1de)])(_0x29ea42)]=Object[_0x51eaf2(0x1e5)](this['i18nService'][_0x51eaf2(0x1ca)](_0x29ea42,_0x51eaf2(0x1b6)));});}[a8_0x4888d9(0x1b4)](_0x42b922){const _0x56c471=a8_0x4888d9,_0x36bc2f=(0x0,core_1[_0x56c471(0x1ac)])(interface_1['RULES_KEY'],_0x42b922);return _0x36bc2f?Joi['object'](_0x36bc2f):undefined;}[a8_0x4888d9(0x1b6)](_0x471629,_0x548f01,_0xec7355={}){const _0x655826=a8_0x4888d9;var _0x21973f,_0x1083ac,_0x3da434,_0x4c6f38,_0x428a78,_0x439d95;const _0x37b8b6=Joi[_0x655826(0x1bd)](_0x471629)?_0x471629:this[_0x655826(0x1b4)](_0x471629);if(!_0x37b8b6)throw new AnnError(ValidatorError_1[_0x655826(0x1ab)][_0x655826(0x1d2)]);_0xec7355[_0x655826(0x1c9)]=Object[_0x655826(0x1b0)]((_0x21973f=this['validatorConfig'][_0x655826(0x1c9)])!==null&&_0x21973f!==void 0x0?_0x21973f:{},{'messages':this['messages']},_0xec7355[_0x655826(0x1c9)]||{}),_0xec7355['validationOptions'][_0x655826(0x1b5)]=_0xec7355['validationOptions']['errors']||{},_0xec7355['validationOptions'][_0x655826(0x1b5)]['language']=(0x0,i18n_1[_0x655826(0x1de)])(this['i18nService'][_0x655826(0x1a8)](_0xec7355[_0x655826(0x1c9)]['errors'][_0x655826(0x1cb)]||_0xec7355[_0x655826(0x1e7)]||this['i18nConfig'][_0x655826(0x1c3)],'validator'));const _0x3bbbde=_0x37b8b6['validate'](_0x548f01,_0xec7355[_0x655826(0x1c9)]);if(_0x3bbbde===null||_0x3bbbde===void 0x0?void 0x0:_0x3bbbde[_0x655826(0x1d9)]){if(_0x3bbbde[_0x655826(0x1d9)]instanceof AnnError)throw _0x3bbbde[_0x655826(0x1d9)];else{if(_0x3bbbde[_0x655826(0x1d9)]instanceof Error)throw new AnnError(ValidatorError_1[_0x655826(0x1ab)][_0x655826(0x1d3)],{'message':((_0x1083ac=_0x3bbbde['error'])===null||_0x1083ac===void 0x0?void 0x0:_0x1083ac[_0x655826(0x1e3)])||'参数验证失败'});else throw new AnnError(ValidatorError_1['ValidatorError'][_0x655826(0x1d3)],{'message':((_0x428a78=(_0x4c6f38=(_0x3da434=_0x3bbbde[_0x655826(0x1d9)])===null||_0x3da434===void 0x0?void 0x0:_0x3da434['details'])===null||_0x4c6f38===void 0x0?void 0x0:_0x4c6f38[0x0])===null||_0x428a78===void 0x0?void 0x0:_0x428a78[_0x655826(0x1e3)])||_0x655826(0x1d7)});}}if(_0x3bbbde===null||_0x3bbbde===void 0x0?void 0x0:_0x3bbbde[_0x655826(0x1aa)]){const _0x4f914d=(_0x439d95=_0x37b8b6===null||_0x37b8b6===void 0x0?void 0x0:_0x37b8b6[_0x655826(0x1be)])===null||_0x439d95===void 0x0?void 0x0:_0x439d95[_0x655826(0x1b8)],_0x74d29=function(_0x6238ba,_0x5db54b){const _0x3f29aa=_0x655826;var _0x244307,_0x4a8f54,_0xbfa0c1,_0x215218,_0x5e102b,_0x342512,_0x24f388,_0x445360,_0x1510dd,_0x18ed4b,_0x5a341a;for(let _0x55b450 in _0x6238ba){if(_0x5db54b[(_0x244307=_0x6238ba[_0x55b450])===null||_0x244307===void 0x0?void 0x0:_0x244307[_0x3f29aa(0x1ea)]]&&((_0xbfa0c1=(_0x4a8f54=_0x6238ba[_0x55b450])===null||_0x4a8f54===void 0x0?void 0x0:_0x4a8f54[_0x3f29aa(0x1bc)])===null||_0xbfa0c1===void 0x0?void 0x0:_0xbfa0c1[_0x3f29aa(0x1d4)])){if(((_0x5e102b=(_0x215218=_0x6238ba[_0x55b450])===null||_0x215218===void 0x0?void 0x0:_0x215218[_0x3f29aa(0x1bc)])===null||_0x5e102b===void 0x0?void 0x0:_0x5e102b['type'])=='object')_0x5db54b[_0x6238ba[_0x55b450][_0x3f29aa(0x1ea)]]=_0x74d29((_0x24f388=(_0x342512=_0x6238ba[_0x55b450])===null||_0x342512===void 0x0?void 0x0:_0x342512[_0x3f29aa(0x1bc)]['$_terms'])===null||_0x24f388===void 0x0?void 0x0:_0x24f388[_0x3f29aa(0x1b8)],_0x5db54b[_0x6238ba[_0x55b450]['key']]);else{if(_0x6238ba[_0x55b450][_0x3f29aa(0x1bc)][_0x3f29aa(0x1d4)]==_0x3f29aa(0x1c2)&&_0x3bbbde['value'][(_0x445360=_0x6238ba[_0x55b450])===null||_0x445360===void 0x0?void 0x0:_0x445360[_0x3f29aa(0x1ea)]]){const _0x2a738f=((_0x5a341a=(_0x18ed4b=(_0x1510dd=_0x6238ba[_0x55b450])===null||_0x1510dd===void 0x0?void 0x0:_0x1510dd[_0x3f29aa(0x1bc)])===null||_0x18ed4b===void 0x0?void 0x0:_0x18ed4b[_0x3f29aa(0x1e8)])===null||_0x5a341a===void 0x0?void 0x0:_0x5a341a[_0x3f29aa(0x1ce)])||_0x3f29aa(0x1dc);_0x5db54b[_0x6238ba[_0x55b450][_0x3f29aa(0x1ea)]]=dayjs(_0x3bbbde[_0x3f29aa(0x1aa)][_0x6238ba[_0x55b450]['key']])['format'](_0x2a738f);}}}}return _0x5db54b;};return _0x74d29(_0x4f914d,_0x3bbbde[_0x655826(0x1aa)]);}throw new AnnError(ValidatorError_1['ValidatorError'][_0x655826(0x1d3)]);}};__decorate([(0x0,core_1['Config'])('i18n'),__metadata(a8_0x4888d9(0x1c4),Object)],ValidatorService[a8_0x4888d9(0x1cc)],a8_0x4888d9(0x1b3),void 0x0),__decorate([(0x0,core_1[a8_0x4888d9(0x1b1)])(a8_0x4888d9(0x1b6)),__metadata(a8_0x4888d9(0x1c4),Object)],ValidatorService[a8_0x4888d9(0x1cc)],a8_0x4888d9(0x1cd),void 0x0),__decorate([(0x0,core_1[a8_0x4888d9(0x1c1)])(),__metadata(a8_0x4888d9(0x1c4),i18n_1['MidwayI18nServiceSingleton'])],ValidatorService[a8_0x4888d9(0x1cc)],a8_0x4888d9(0x1c0),void 0x0),__decorate([(0x0,core_1[a8_0x4888d9(0x1db)])(),__metadata(a8_0x4888d9(0x1c4),Function),__metadata(a8_0x4888d9(0x1c6),[]),__metadata('design:returntype',Promise)],ValidatorService[a8_0x4888d9(0x1cc)],a8_0x4888d9(0x1ba),null),ValidatorService=__decorate([(0x0,core_1[a8_0x4888d9(0x1d1)])(a8_0x4888d9(0x1b6)),(0x0,core_1[a8_0x4888d9(0x1bb)])(core_1['ScopeEnum'][a8_0x4888d9(0x1eb)])],ValidatorService),exports['ValidatorService']=ValidatorService;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anncic-api/validator",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.16",
|
|
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": "^1.5.
|
|
20
|
+
"@anncic-api/core": "^1.5.15",
|
|
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": "85a10bb3c26779cb853c2bf0158ccaa08e24388c"
|
|
30
30
|
}
|