@anncic-api/typeorm 3.7.4 → 3.7.6
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/configuration.js +1 -1
- package/dist/decorator/InjectEntity.js +1 -1
- package/dist/decorator/InjectRepository.js +1 -1
- package/dist/decorator/ProvideEntity.d.ts +2 -0
- package/dist/decorator/ProvideEntity.js +1 -1
- package/dist/decorator/ProvideObserve.js +1 -1
- package/dist/decorator/ProvideRepository.js +1 -1
- package/dist/decorator/ProvideSearch.js +1 -1
- package/dist/decorator/VirtualColumn.js +1 -1
- package/dist/definition/Repository.js +1 -1
- package/dist/helper/getDataSourceEntity.js +1 -1
- package/dist/helper/getProvideObserve.js +1 -1
- package/dist/helper/preCreateShardingTables.d.ts +1 -0
- package/dist/helper/preCreateShardingTables.js +1 -0
- package/dist/helper/sleep.js +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -1
- package/dist/interface.d.ts +3 -0
- package/dist/interface.js +1 -1
- package/dist/interfaceSharding.d.ts +22 -0
- package/dist/interfaceSharding.js +1 -0
- package/package.json +2 -2
package/dist/configuration.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a0_0x52c19f=a0_0x2b45;(function(_0x5442ad,_0x2d5340){const _0x2918b4=a0_0x2b45,_0x17ba9a=_0x5442ad();while(!![]){try{const _0x225f43=parseInt(_0x2918b4(0x173))/0x1+-parseInt(_0x2918b4(0x17d))/0x2+-parseInt(_0x2918b4(0x17a))/0x3+-parseInt(_0x2918b4(0x172))/0x4*(parseInt(_0x2918b4(0x184))/0x5)+parseInt(_0x2918b4(0x167))/0x6+parseInt(_0x2918b4(0x16d))/0x7*(-parseInt(_0x2918b4(0x164))/0x8)+parseInt(_0x2918b4(0x177))/0x9;if(_0x225f43===_0x2d5340)break;else _0x17ba9a['push'](_0x17ba9a['shift']());}catch(_0x1f0046){_0x17ba9a['push'](_0x17ba9a['shift']());}}}(a0_0x9bf5,0x66de4));const a0_0x24b099=(function(){let _0x249e99=!![];return function(_0x4d4aa4,_0x581445){const _0x2aed71=_0x249e99?function(){const _0x52d86a=a0_0x2b45;if(_0x581445){const _0x396217=_0x581445[_0x52d86a(0x170)](_0x4d4aa4,arguments);return _0x581445=null,_0x396217;}}:function(){};return _0x249e99=![],_0x2aed71;};}()),a0_0x2d3330=a0_0x24b099(this,function(){const _0x16937d=a0_0x2b45;return a0_0x2d3330[_0x16937d(0x15f)]()['search']('(((.+)+)+)+$')[_0x16937d(0x15f)]()[_0x16937d(0x166)](a0_0x2d3330)[_0x16937d(0x185)](_0x16937d(0x17c));});a0_0x2d3330();'use strict';function a0_0x9bf5(){const _0x32bdb2=['CustomConfiguration','handlercache','typeorm\x20Error\x20','__esModule','get','toString','set','MidwayDecoratorService','design:type','function','424Fdrpba','decorator','constructor','2678910yPeeFb','MidwayConfigService','getRepository','Repository','__metadata','@midwayjs/core','66031CrkaAl','TypeORMDataSourceManager','ENTIFY_KEY','apply','getClassMetadata','20AQdaCu','526476RMtfri','Configuration','getDataSource','\x20is\x20not\x20ProvideRepository\x20Entify','10419255mZVcDR','@midwayjs/typeorm','REPOSITORY_KEY','1028619AVgYCo','decorate','(((.+)+)+)+$','1016852qwgNJs','registerPropertyHandler','anncic-api:typeorm','length','Inject','defineProperty','metadata','358060EfYvBe','search','object','has','prototype','getDataSourceNameByModel'];a0_0x9bf5=function(){return _0x32bdb2;};return a0_0x9bf5();}var __decorate=this&&this['__decorate']||function(_0x28816e,_0x16faa3,_0x599fb2,_0x1320e8){const _0xf2eae0=a0_0x2b45;var _0xba56a9=arguments['length'],_0x281834=_0xba56a9<0x3?_0x16faa3:_0x1320e8===null?_0x1320e8=Object['getOwnPropertyDescriptor'](_0x16faa3,_0x599fb2):_0x1320e8,_0x13b1af;if(typeof Reflect===_0xf2eae0(0x186)&&typeof Reflect[_0xf2eae0(0x17b)]===_0xf2eae0(0x163))_0x281834=Reflect[_0xf2eae0(0x17b)](_0x28816e,_0x16faa3,_0x599fb2,_0x1320e8);else{for(var _0x36e20f=_0x28816e[_0xf2eae0(0x180)]-0x1;_0x36e20f>=0x0;_0x36e20f--)if(_0x13b1af=_0x28816e[_0x36e20f])_0x281834=(_0xba56a9<0x3?_0x13b1af(_0x281834):_0xba56a9>0x3?_0x13b1af(_0x16faa3,_0x599fb2,_0x281834):_0x13b1af(_0x16faa3,_0x599fb2))||_0x281834;}return _0xba56a9>0x3&&_0x281834&&Object[_0xf2eae0(0x182)](_0x16faa3,_0x599fb2,_0x281834),_0x281834;},__metadata=this&&this[a0_0x52c19f(0x16b)]||function(_0x464f06,_0x5c6cd6){const _0x131a41=a0_0x52c19f;if(typeof Reflect===_0x131a41(0x186)&&typeof Reflect[_0x131a41(0x183)]===_0x131a41(0x163))return Reflect[_0x131a41(0x183)](_0x464f06,_0x5c6cd6);};Object[a0_0x52c19f(0x182)](exports,a0_0x52c19f(0x18d),{'value':!![]}),exports['CustomConfiguration']=void 0x0;const typeorm_1=require(a0_0x52c19f(0x178)),core_1=require(a0_0x52c19f(0x16c)),core_2=require(a0_0x52c19f(0x16c)),Repository_1=require('./definition/Repository'),interface_1=require('./interface'),typeorm=require(a0_0x52c19f(0x178));function a0_0x2b45(_0x139170,_0xc091a){const _0x5e08c6=a0_0x9bf5();return a0_0x2b45=function(_0x2d3330,_0x24b099){_0x2d3330=_0x2d3330-0x15f;let _0x9bf561=_0x5e08c6[_0x2d3330];return _0x9bf561;},a0_0x2b45(_0x139170,_0xc091a);}let CustomConfiguration=class CustomConfiguration{constructor(){const _0x4f93b8=a0_0x52c19f;this[_0x4f93b8(0x18b)]=new Map();}async['onReady'](_0x17fe06,_0x514bfe){const _0x51b4dd=a0_0x52c19f,_0x1c8504=await _0x17fe06['getAsync'](typeorm_1[_0x51b4dd(0x16e)]);this[_0x51b4dd(0x165)][_0x51b4dd(0x17e)](interface_1[_0x51b4dd(0x16f)],(_0x78d518,{entity:_0x5a6ffb,connection:_0x29105f})=>{const _0x547b44=_0x51b4dd;if(!this[_0x547b44(0x18b)]['has'](_0x5a6ffb)){const _0x3d9bcc=_0x17fe06['get'](Repository_1[_0x547b44(0x16a)],[_0x514bfe,_0x17fe06,_0x1c8504[_0x547b44(0x175)](_0x29105f||_0x1c8504[_0x547b44(0x189)](_0x5a6ffb))[_0x547b44(0x169)](_0x5a6ffb)]);this[_0x547b44(0x18b)][_0x547b44(0x160)](_0x5a6ffb,_0x3d9bcc);}return this[_0x547b44(0x18b)]['get'](_0x5a6ffb);}),this['decorator'][_0x51b4dd(0x17e)](interface_1[_0x51b4dd(0x179)],(_0x47786a,{repository:_0x3d4256,connection:_0x15308c})=>{const _0x8cf0d2=_0x51b4dd;if(!_0x3d4256)throw new Error('typeorm\x20Error\x20propertyName\x20is\x20not\x20InjectRepository\x20repository');const {entity:_0x2a2b2d}=(0x0,core_1[_0x8cf0d2(0x171)])(interface_1[_0x8cf0d2(0x179)],_0x3d4256)||{};if(!_0x2a2b2d)throw new Error(_0x8cf0d2(0x18c)+((_0x3d4256===null||_0x3d4256===void 0x0?void 0x0:_0x3d4256['name'])||_0x3d4256)+_0x8cf0d2(0x176));if(!this[_0x8cf0d2(0x18b)][_0x8cf0d2(0x187)](_0x3d4256)){const _0x415f22=_0x17fe06[_0x8cf0d2(0x18e)](_0x3d4256,[_0x514bfe,_0x17fe06,_0x1c8504[_0x8cf0d2(0x175)](_0x15308c||_0x1c8504[_0x8cf0d2(0x189)](_0x2a2b2d))[_0x8cf0d2(0x169)](_0x2a2b2d)]);this['handlercache'][_0x8cf0d2(0x160)](_0x3d4256,_0x415f22);}return this[_0x8cf0d2(0x18b)]['get'](_0x3d4256);});}};exports['CustomConfiguration']=CustomConfiguration,__decorate([(0x0,core_1['Inject'])(),__metadata(a0_0x52c19f(0x162),core_2[a0_0x52c19f(0x168)])],CustomConfiguration[a0_0x52c19f(0x188)],'config',void 0x0),__decorate([(0x0,core_1[a0_0x52c19f(0x181)])(),__metadata(a0_0x52c19f(0x162),core_2[a0_0x52c19f(0x161)])],CustomConfiguration['prototype'],a0_0x52c19f(0x165),void 0x0),exports[a0_0x52c19f(0x18a)]=CustomConfiguration=__decorate([(0x0,core_1[a0_0x52c19f(0x174)])({'imports':[typeorm],'conflictCheck':![],'namespace':a0_0x52c19f(0x17f)})],CustomConfiguration);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a1_0x28d338=a1_0x10ca;function a1_0x10ca(_0x8fddf4,_0x53302a){const _0x583cf5=a1_0xd52b();return a1_0x10ca=function(_0x3c347d,_0x5bf76f){_0x3c347d=_0x3c347d-0x1c7;let _0xd52be4=_0x583cf5[_0x3c347d];return _0xd52be4;},a1_0x10ca(_0x8fddf4,_0x53302a);}(function(_0x42ad74,_0x558017){const _0x5d5b64=a1_0x10ca,_0x32f948=_0x42ad74();while(!![]){try{const _0x15a503=-parseInt(_0x5d5b64(0x1d5))/0x1+-parseInt(_0x5d5b64(0x1d1))/0x2+-parseInt(_0x5d5b64(0x1d3))/0x3*(-parseInt(_0x5d5b64(0x1c9))/0x4)+parseInt(_0x5d5b64(0x1da))/0x5*(-parseInt(_0x5d5b64(0x1db))/0x6)+parseInt(_0x5d5b64(0x1d9))/0x7*(-parseInt(_0x5d5b64(0x1dc))/0x8)+parseInt(_0x5d5b64(0x1d0))/0x9*(-parseInt(_0x5d5b64(0x1d8))/0xa)+-parseInt(_0x5d5b64(0x1c8))/0xb*(-parseInt(_0x5d5b64(0x1ca))/0xc);if(_0x15a503===_0x558017)break;else _0x32f948['push'](_0x32f948['shift']());}catch(_0x561f10){_0x32f948['push'](_0x32f948['shift']());}}}(a1_0xd52b,0xec3e6));const a1_0x5bf76f=(function(){let _0xb91fd8=!![];return function(_0x4578a9,_0x57a84c){const _0x1418aa=_0xb91fd8?function(){const _0x2aeba0=a1_0x10ca;if(_0x57a84c){const _0x29372c=_0x57a84c[_0x2aeba0(0x1ce)](_0x4578a9,arguments);return _0x57a84c=null,_0x29372c;}}:function(){};return _0xb91fd8=![],_0x1418aa;};}()),a1_0x3c347d=a1_0x5bf76f(this,function(){const _0x22f4e6=a1_0x10ca;return a1_0x3c347d[_0x22f4e6(0x1d2)]()['search']('(((.+)+)+)+$')[_0x22f4e6(0x1d2)]()['constructor'](a1_0x3c347d)[_0x22f4e6(0x1d4)](_0x22f4e6(0x1c7));});a1_0x3c347d();'use strict';function a1_0xd52b(){const _0x2eaecf=['1128MQlXMK','createCustomPropertyDecorator','defineProperty','__esModule','apply','default','6777arPPAX','3379024UXKXHY','toString','444IAANHc','search','82748zMPujE','ENTIFY_KEY','InjectEntity','1810aLXhpZ','7qvYslm','54160tYZHHp','54TMkBeN','7783528kxaYVC','(((.+)+)+)+$','313346nqyCIp','34296TzqTvK'];a1_0xd52b=function(){return _0x2eaecf;};return a1_0xd52b();}Object[a1_0x28d338(0x1cc)](exports,a1_0x28d338(0x1cd),{'value':!![]}),exports[a1_0x28d338(0x1d7)]=InjectEntity;const core_1=require('@midwayjs/core'),interface_1=require('../interface');function InjectEntity(_0x482f14,_0x584980=a1_0x28d338(0x1cf)){const _0x541e64=a1_0x28d338;return(0x0,core_1[_0x541e64(0x1cb)])(interface_1[_0x541e64(0x1d6)],{'entity':_0x482f14,'connection':_0x584980});}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a2_0x2c88f6=a2_0x54a0;(function(_0x26ef41,_0x1a66d2){const _0x5f29f2=a2_0x54a0,_0x49b134=_0x26ef41();while(!![]){try{const _0x216505=-parseInt(_0x5f29f2(0x1f9))/0x1+parseInt(_0x5f29f2(0x1ea))/0x2+parseInt(_0x5f29f2(0x1fd))/0x3*(parseInt(_0x5f29f2(0x1eb))/0x4)+parseInt(_0x5f29f2(0x1ef))/0x5+-parseInt(_0x5f29f2(0x1fb))/0x6*(parseInt(_0x5f29f2(0x1f7))/0x7)+parseInt(_0x5f29f2(0x1f8))/0x8+parseInt(_0x5f29f2(0x1ed))/0x9*(-parseInt(_0x5f29f2(0x1fa))/0xa);if(_0x216505===_0x1a66d2)break;else _0x49b134['push'](_0x49b134['shift']());}catch(_0x6e1ab3){_0x49b134['push'](_0x49b134['shift']());}}}(a2_0x571b,0x20ef7));function a2_0x54a0(_0x1618b4,_0x21b1b1){const _0xb5a7b4=a2_0x571b();return a2_0x54a0=function(_0x4fd544,_0x1db786){_0x4fd544=_0x4fd544-0x1ea;let _0x571bc6=_0xb5a7b4[_0x4fd544];return _0x571bc6;},a2_0x54a0(_0x1618b4,_0x21b1b1);}const a2_0x1db786=(function(){let _0x347290=!![];return function(_0x412d89,_0x15e9e4){const _0xfc6eb0=_0x347290?function(){if(_0x15e9e4){const _0x1819a7=_0x15e9e4['apply'](_0x412d89,arguments);return _0x15e9e4=null,_0x1819a7;}}:function(){};return _0x347290=![],_0xfc6eb0;};}()),a2_0x4fd544=a2_0x1db786(this,function(){const _0x4483e3=a2_0x54a0;return a2_0x4fd544[_0x4483e3(0x1ee)]()[_0x4483e3(0x1f4)](_0x4483e3(0x1f2))['toString']()[_0x4483e3(0x1fc)](a2_0x4fd544)[_0x4483e3(0x1f4)](_0x4483e3(0x1f2));});a2_0x4fd544();'use strict';Object['defineProperty'](exports,a2_0x2c88f6(0x1f5),{'value':!![]}),exports['InjectRepository']=InjectRepository;const core_1=require(a2_0x2c88f6(0x1f0)),interface_1=require(a2_0x2c88f6(0x1f6));function a2_0x571b(){const _0x9db308=['756dayHzt','default','1360341IPrgbt','toString','705pbfxDL','@midwayjs/core','REPOSITORY_KEY','(((.+)+)+)+$','createCustomPropertyDecorator','search','__esModule','../interface','401275wSqvkA','1989496ENNDSS','91461bGxcPZ','30sliKBA','6zkQJev','constructor','4281DytyQW','437210QIblFp'];a2_0x571b=function(){return _0x9db308;};return a2_0x571b();}function InjectRepository(_0x14233a,_0x3d49f5=a2_0x2c88f6(0x1ec)){const _0x209696=a2_0x2c88f6;return(0x0,core_1[_0x209696(0x1f3)])(interface_1[_0x209696(0x1f1)],{'repository':_0x14233a,'connection':_0x3d49f5});}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { EntityOptions } from "typeorm";
|
|
2
|
+
import { ShardingStrategy } from '../interface';
|
|
2
3
|
export declare function ProvideEntity(table: {
|
|
3
4
|
tableName: string;
|
|
4
5
|
dataSource?: string | string[];
|
|
6
|
+
sharding?: typeof ShardingStrategy;
|
|
5
7
|
}, option?: EntityOptions): ClassDecorator;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a3_0x2aea0f=a3_0x58e1;(function(_0x5629ab,_0x1f8fac){const _0x16e3b7=a3_0x58e1,_0x346ad1=_0x5629ab();while(!![]){try{const _0x46aad9=parseInt(_0x16e3b7(0x1e3))/0x1*(-parseInt(_0x16e3b7(0x1e4))/0x2)+-parseInt(_0x16e3b7(0x1e9))/0x3+-parseInt(_0x16e3b7(0x1ef))/0x4*(parseInt(_0x16e3b7(0x1ea))/0x5)+-parseInt(_0x16e3b7(0x1e1))/0x6*(parseInt(_0x16e3b7(0x1e6))/0x7)+parseInt(_0x16e3b7(0x1eb))/0x8*(parseInt(_0x16e3b7(0x1e7))/0x9)+parseInt(_0x16e3b7(0x1f2))/0xa+parseInt(_0x16e3b7(0x1df))/0xb*(parseInt(_0x16e3b7(0x1d4))/0xc);if(_0x46aad9===_0x1f8fac)break;else _0x346ad1['push'](_0x346ad1['shift']());}catch(_0x546419){_0x346ad1['push'](_0x346ad1['shift']());}}}(a3_0x2395,0xef01c));const a3_0x1ca20e=(function(){let _0x2c5f5a=!![];return function(_0x4a2696,_0x52312a){const _0x43e71c=_0x2c5f5a?function(){const _0x401091=a3_0x58e1;if(_0x52312a){const _0xea5499=_0x52312a[_0x401091(0x1f1)](_0x4a2696,arguments);return _0x52312a=null,_0xea5499;}}:function(){};return _0x2c5f5a=![],_0x43e71c;};}()),a3_0xa0d6ac=a3_0x1ca20e(this,function(){const _0x1fee32=a3_0x58e1;return a3_0xa0d6ac[_0x1fee32(0x1e5)]()[_0x1fee32(0x1d3)]('(((.+)+)+)+$')['toString']()[_0x1fee32(0x1d6)](a3_0xa0d6ac)[_0x1fee32(0x1d3)](_0x1fee32(0x1d5));});a3_0xa0d6ac();'use strict';function a3_0x2395(){const _0x5446fa=['search','12IQIaDG','(((.+)+)+)+$','constructor','../interface','push','default','dataSource','isArray','ENTIFY_MODULE_SOURCE','@midwayjs/core','tableName','26261202zbsoGM','saveModule','1675896LBisNs','saveClassMetadata','1khQxRM','1130838MuwHAB','toString','7gejxAh','9BgJBZx','typeorm','3890400CcayiG','6208945NrBnBs','3446216AbjJdI','ProvideEntity','name','sharding','4JsVQZx','string','apply','15441370erHxrY','ENTIFY_SHARDING_KEY'];a3_0x2395=function(){return _0x5446fa;};return a3_0x2395();}Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[a3_0x2aea0f(0x1ec)]=ProvideEntity;const typeorm_1=require(a3_0x2aea0f(0x1e8)),core_1=require(a3_0x2aea0f(0x1dd)),interface_1=require(a3_0x2aea0f(0x1d7));function a3_0x58e1(_0x3e8e7b,_0x292d54){const _0x2d7d31=a3_0x2395();return a3_0x58e1=function(_0xa0d6ac,_0x1ca20e){_0xa0d6ac=_0xa0d6ac-0x1d2;let _0x239521=_0x2d7d31[_0xa0d6ac];return _0x239521;},a3_0x58e1(_0x3e8e7b,_0x292d54);}function ProvideEntity(_0x5dec96,_0xbd516={}){return _0x36c586=>{const _0x40fc13=a3_0x58e1;_0xbd516[_0x40fc13(0x1ed)]=_0x5dec96[_0x40fc13(0x1de)];const _0x706155=[];if(!(_0x5dec96===null||_0x5dec96===void 0x0?void 0x0:_0x5dec96[_0x40fc13(0x1da)]))_0x706155['push'](_0x40fc13(0x1d9));else{if(typeof(_0x5dec96===null||_0x5dec96===void 0x0?void 0x0:_0x5dec96['dataSource'])==_0x40fc13(0x1f0))_0x706155[_0x40fc13(0x1d8)](_0x5dec96===null||_0x5dec96===void 0x0?void 0x0:_0x5dec96[_0x40fc13(0x1da)]);else{if(Array[_0x40fc13(0x1db)](_0x5dec96===null||_0x5dec96===void 0x0?void 0x0:_0x5dec96[_0x40fc13(0x1da)]))for(let _0x22d09b of _0x5dec96[_0x40fc13(0x1da)]||[_0x40fc13(0x1d9)]){_0x706155[_0x40fc13(0x1d8)](_0x22d09b);}}}(0x0,core_1[_0x40fc13(0x1e0)])(interface_1['ENTIFY_MODULE'],_0x36c586),(0x0,core_1['saveClassMetadata'])(interface_1[_0x40fc13(0x1dc)],{'tableName':_0x5dec96['tableName'],'dataSource':_0x706155},_0x36c586),_0x5dec96['sharding']&&(0x0,core_1[_0x40fc13(0x1e2)])(interface_1[_0x40fc13(0x1d2)],{'strategy':_0x5dec96[_0x40fc13(0x1ee)]},_0x36c586),(0x0,typeorm_1['Entity'])(_0x5dec96[_0x40fc13(0x1de)],_0xbd516)(_0x36c586);};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a4_0x2ac5c5=a4_0x1e35;(function(_0x15a80a,_0x1a53a2){const _0x5c5332=a4_0x1e35,_0x2aec5f=_0x15a80a();while(!![]){try{const _0xb57290=-parseInt(_0x5c5332(0x1c6))/0x1+-parseInt(_0x5c5332(0x1c8))/0x2+parseInt(_0x5c5332(0x1d8))/0x3*(parseInt(_0x5c5332(0x1c3))/0x4)+parseInt(_0x5c5332(0x1d6))/0x5+-parseInt(_0x5c5332(0x1d0))/0x6+parseInt(_0x5c5332(0x1d4))/0x7+parseInt(_0x5c5332(0x1c4))/0x8;if(_0xb57290===_0x1a53a2)break;else _0x2aec5f['push'](_0x2aec5f['shift']());}catch(_0x499964){_0x2aec5f['push'](_0x2aec5f['shift']());}}}(a4_0xd193,0xadc23));const a4_0x29a1f7=(function(){let _0x6d2195=!![];return function(_0x1f1804,_0x58471d){const _0x5c0e26=_0x6d2195?function(){const _0x4be304=a4_0x1e35;if(_0x58471d){const _0x5185ec=_0x58471d[_0x4be304(0x1c9)](_0x1f1804,arguments);return _0x58471d=null,_0x5185ec;}}:function(){};return _0x6d2195=![],_0x5c0e26;};}()),a4_0x68ba07=a4_0x29a1f7(this,function(){const _0x20e3d6=a4_0x1e35;return a4_0x68ba07[_0x20e3d6(0x1d3)]()['search'](_0x20e3d6(0x1cf))[_0x20e3d6(0x1d3)]()[_0x20e3d6(0x1cc)](a4_0x68ba07)[_0x20e3d6(0x1ca)](_0x20e3d6(0x1cf));});function a4_0xd193(){const _0x15aca1=['6112745aVxxgL','__esModule','31521UaJjsU','EventSubscriber','240RyuPVV','1975056BmuPOX','Scope','19046hOeAOs','prototype','2189678UOeWon','apply','search','../interface','constructor','ScopeEnum','Singleton','(((.+)+)+)+$','3611502blVkhi','ProvideObserve','undefined','toString','2293662giISRt','defineProperty'];a4_0xd193=function(){return _0x15aca1;};return a4_0xd193();}a4_0x68ba07();'use strict';Object[a4_0x2ac5c5(0x1d5)](exports,a4_0x2ac5c5(0x1d7),{'value':!![]}),exports[a4_0x2ac5c5(0x1d1)]=ProvideObserve;const typeorm_1=require('typeorm'),core_1=require('@midwayjs/core'),interface_1=require(a4_0x2ac5c5(0x1cb));function a4_0x1e35(_0x5eedf7,_0x4b55c7){const _0x425e52=a4_0xd193();return a4_0x1e35=function(_0x68ba07,_0x29a1f7){_0x68ba07=_0x68ba07-0x1c2;let _0xd193f9=_0x425e52[_0x68ba07];return _0xd193f9;},a4_0x1e35(_0x5eedf7,_0x4b55c7);}function ProvideObserve(_0x3f999d){return _0x39022e=>{const _0xa77a8b=a4_0x1e35;_0x3f999d&&typeof _0x39022e[_0xa77a8b(0x1c7)]['listenTo']==_0xa77a8b(0x1d2)&&(_0x39022e['prototype']['listenTo']=()=>_0x3f999d),(0x0,typeorm_1[_0xa77a8b(0x1c2)])()(_0x39022e),(0x0,core_1['saveModule'])(interface_1['REPOSITORY_OBSERVE_KEY'],_0x39022e),((0x0,core_1['Provide'])()(_0x39022e),(0x0,core_1[_0xa77a8b(0x1c5)])(core_1[_0xa77a8b(0x1cd)][_0xa77a8b(0x1ce)])(_0x39022e));};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a5_0x3e6358=a5_0x29eb;(function(_0x4f95fb,_0x3393c6){const _0x5bce5f=a5_0x29eb,_0x240a3f=_0x4f95fb();while(!![]){try{const _0x22e728=parseInt(_0x5bce5f(0x151))/0x1+-parseInt(_0x5bce5f(0x152))/0x2+-parseInt(_0x5bce5f(0x14a))/0x3+parseInt(_0x5bce5f(0x154))/0x4*(parseInt(_0x5bce5f(0x153))/0x5)+-parseInt(_0x5bce5f(0x155))/0x6*(-parseInt(_0x5bce5f(0x157))/0x7)+parseInt(_0x5bce5f(0x150))/0x8+-parseInt(_0x5bce5f(0x156))/0x9;if(_0x22e728===_0x3393c6)break;else _0x240a3f['push'](_0x240a3f['shift']());}catch(_0x4ef955){_0x240a3f['push'](_0x240a3f['shift']());}}}(a5_0x5821,0x65aea));const a5_0x303311=(function(){let _0x563ca5=!![];return function(_0x3bfe6a,_0xd9aa83){const _0x431267=_0x563ca5?function(){const _0x1f7266=a5_0x29eb;if(_0xd9aa83){const _0x3851c1=_0xd9aa83[_0x1f7266(0x14e)](_0x3bfe6a,arguments);return _0xd9aa83=null,_0x3851c1;}}:function(){};return _0x563ca5=![],_0x431267;};}()),a5_0x4563ad=a5_0x303311(this,function(){const _0x521087=a5_0x29eb;return a5_0x4563ad['toString']()[_0x521087(0x148)]('(((.+)+)+)+$')['toString']()['constructor'](a5_0x4563ad)['search']('(((.+)+)+)+$');});function a5_0x5821(){const _0x5bf9e2=['Scope','2483384aGlFBu','2726RjUfmj','512912qDMvnA','10HNDlfu','954748LGZBcc','284322GKiWSL','2362815fgzdFA','28XgUQUs','Request','search','saveClassMetadata','133770fAiyXX','__esModule','defineProperty','ScopeEnum','apply'];a5_0x5821=function(){return _0x5bf9e2;};return a5_0x5821();}a5_0x4563ad();function a5_0x29eb(_0x451dec,_0x3bba51){const _0x1fd66d=a5_0x5821();return a5_0x29eb=function(_0x4563ad,_0x303311){_0x4563ad=_0x4563ad-0x147;let _0x58214e=_0x1fd66d[_0x4563ad];return _0x58214e;},a5_0x29eb(_0x451dec,_0x3bba51);}'use strict';Object[a5_0x3e6358(0x14c)](exports,a5_0x3e6358(0x14b),{'value':!![]}),exports['ProvideRepository']=ProvideRepository;const core_1=require('@midwayjs/core'),interface_1=require('../interface');function ProvideRepository(_0x3ea323){return _0x1ddb4e=>{const _0x2ba17b=a5_0x29eb;(0x0,core_1[_0x2ba17b(0x14f)])(core_1[_0x2ba17b(0x14d)][_0x2ba17b(0x147)],{'allowDowngrade':!![]})(_0x1ddb4e),((0x0,core_1['Provide'])()(_0x1ddb4e),(0x0,core_1[_0x2ba17b(0x149)])(interface_1['REPOSITORY_KEY'],{'entity':_0x3ea323},_0x1ddb4e));};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a6_0x465021=a6_0x3287;(function(_0x5d4a74,_0x40cf1e){const _0x375f64=a6_0x3287,_0x1c1212=_0x5d4a74();while(!![]){try{const _0x9cbef9=parseInt(_0x375f64(0x1bf))/0x1*(-parseInt(_0x375f64(0x1c4))/0x2)+parseInt(_0x375f64(0x1c0))/0x3*(-parseInt(_0x375f64(0x1bc))/0x4)+parseInt(_0x375f64(0x1bb))/0x5*(-parseInt(_0x375f64(0x1c9))/0x6)+-parseInt(_0x375f64(0x1cd))/0x7+parseInt(_0x375f64(0x1c6))/0x8+parseInt(_0x375f64(0x1c1))/0x9+parseInt(_0x375f64(0x1c3))/0xa;if(_0x9cbef9===_0x40cf1e)break;else _0x1c1212['push'](_0x1c1212['shift']());}catch(_0x3d94cb){_0x1c1212['push'](_0x1c1212['shift']());}}}(a6_0x3fc4,0x7d4ac));const a6_0x4eed4f=(function(){let _0x1d7682=!![];return function(_0xb53301,_0x14beb6){const _0xb7362=_0x1d7682?function(){if(_0x14beb6){const _0x5a100a=_0x14beb6['apply'](_0xb53301,arguments);return _0x14beb6=null,_0x5a100a;}}:function(){};return _0x1d7682=![],_0xb7362;};}()),a6_0x2b01aa=a6_0x4eed4f(this,function(){const _0x2377c8=a6_0x3287;return a6_0x2b01aa[_0x2377c8(0x1c2)]()[_0x2377c8(0x1bd)](_0x2377c8(0x1c8))[_0x2377c8(0x1c2)]()['constructor'](a6_0x2b01aa)[_0x2377c8(0x1bd)](_0x2377c8(0x1c8));});a6_0x2b01aa();'use strict';function a6_0x3fc4(){const _0x560c4b=['2974132vqMSrO','Search','attachClassMetadata','SearchScope','MODEL_SEARCH_SCOPE_KEY','saveModule','MODEL_SEARCH_KEY','ProvideSearch','ScopeEnum','17610fRNMmo','175324UxDWeQ','search','Scope','2FxdPNf','3VfnzwL','4472181wJOWCh','toString','12140810gIgCal','996686mLrlPX','@midwayjs/core','3521416SmYpFi','Singleton','(((.+)+)+)+$','294BpnKyc','MODEL_KEY','defineProperty','../interface'];a6_0x3fc4=function(){return _0x560c4b;};return a6_0x3fc4();}Object[a6_0x465021(0x1cb)](exports,'__esModule',{'value':!![]}),exports[a6_0x465021(0x1b9)]=ProvideSearch,exports[a6_0x465021(0x1b3)]=Search,exports[a6_0x465021(0x1b5)]=SearchScope;const core_1=require(a6_0x465021(0x1c5)),interface_1=require(a6_0x465021(0x1cc));function ProvideSearch(_0xc02533){return _0x18eb76=>{const _0x41201a=a6_0x3287;(0x0,core_1[_0x41201a(0x1b7)])(interface_1[_0x41201a(0x1ca)],_0x18eb76),(0x0,core_1[_0x41201a(0x1be)])(core_1[_0x41201a(0x1ba)][_0x41201a(0x1c7)])(_0x18eb76),(0x0,core_1[_0x41201a(0x1b4)])(interface_1[_0x41201a(0x1ca)],_0xc02533,_0x18eb76);};}function Search(_0x480657,_0x474bb0){return(_0x102211,_0x5c91b6,_0x3fd70e)=>{const _0x228c08=a6_0x3287;(0x0,core_1[_0x228c08(0x1b4)])(interface_1[_0x228c08(0x1b8)],{'field':_0x480657,'comment':_0x474bb0,'target':_0x102211,'methodName':_0x5c91b6,'descriptor':_0x3fd70e},_0x102211);};}function a6_0x3287(_0x169831,_0x1c0518){const _0xe553f2=a6_0x3fc4();return a6_0x3287=function(_0x2b01aa,_0x4eed4f){_0x2b01aa=_0x2b01aa-0x1b3;let _0x3fc45e=_0xe553f2[_0x2b01aa];return _0x3fc45e;},a6_0x3287(_0x169831,_0x1c0518);}function SearchScope(_0x3b66fe,_0x35785b){return(_0x4aacb5,_0x43a3a3,_0x45e18a)=>{const _0x564984=a6_0x3287;(0x0,core_1[_0x564984(0x1b4)])(interface_1[_0x564984(0x1b6)],{'scope':_0x3b66fe,'comment':_0x35785b,'target':_0x4aacb5,'methodName':_0x43a3a3,'descriptor':_0x45e18a},_0x4aacb5);};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a7_0x328164=a7_0x591a;(function(_0x4f59be,_0x4435a8){const _0x28fccb=a7_0x591a,_0x339d3f=_0x4f59be();while(!![]){try{const _0x22d378=-parseInt(_0x28fccb(0x17f))/0x1+parseInt(_0x28fccb(0x188))/0x2*(parseInt(_0x28fccb(0x17c))/0x3)+-parseInt(_0x28fccb(0x18d))/0x4*(-parseInt(_0x28fccb(0x18a))/0x5)+parseInt(_0x28fccb(0x189))/0x6+-parseInt(_0x28fccb(0x180))/0x7*(-parseInt(_0x28fccb(0x17d))/0x8)+parseInt(_0x28fccb(0x17a))/0x9+parseInt(_0x28fccb(0x178))/0xa*(-parseInt(_0x28fccb(0x186))/0xb);if(_0x22d378===_0x4435a8)break;else _0x339d3f['push'](_0x339d3f['shift']());}catch(_0x423ab3){_0x339d3f['push'](_0x339d3f['shift']());}}}(a7_0x2810,0x4ab96));const a7_0x55b807=(function(){let _0x57d546=!![];return function(_0x5c766f,_0x2f1803){const _0xef6192=_0x57d546?function(){if(_0x2f1803){const _0x5c41e7=_0x2f1803['apply'](_0x5c766f,arguments);return _0x2f1803=null,_0x5c41e7;}}:function(){};return _0x57d546=![],_0xef6192;};}()),a7_0x1c4edb=a7_0x55b807(this,function(){const _0x335e09=a7_0x591a;return a7_0x1c4edb['toString']()[_0x335e09(0x182)](_0x335e09(0x187))[_0x335e09(0x183)]()[_0x335e09(0x181)](a7_0x1c4edb)[_0x335e09(0x182)]('(((.+)+)+)+$');});a7_0x1c4edb();'use strict';Object['defineProperty'](exports,a7_0x328164(0x185),{'value':!![]}),exports[a7_0x328164(0x18b)]=VirtualColumn;function a7_0x591a(_0x4b35a9,_0x16d42f){const _0x3ced11=a7_0x2810();return a7_0x591a=function(_0x1c4edb,_0x55b807){_0x1c4edb=_0x1c4edb-0x178;let _0x28102c=_0x3ced11[_0x1c4edb];return _0x28102c;},a7_0x591a(_0x4b35a9,_0x16d42f);}function a7_0x2810(){const _0x5e75a5=['2407120vfIWGe','@midwayjs/core','781389IswsOB','getClassMetadata','130527tBDynV','21544XORmJd','saveClassMetadata','52288drcBcv','147IaMqbh','constructor','search','toString','../interface','__esModule','22xjkAuw','(((.+)+)+)+$','6WmnAQT','2542554nbIIym','355305jAuvGk','VirtualColumn','ENTITY_VIRTUAL_COLUMN_KEY','8tguNOQ'];a7_0x2810=function(){return _0x5e75a5;};return a7_0x2810();}const core_1=require(a7_0x328164(0x179)),interface_1=require(a7_0x328164(0x184));function VirtualColumn(_0xa013f8,_0x61d9ee){return(_0x48e389,_0x80a28)=>{const _0x3cc1d7=a7_0x591a,_0x5a319d=(0x0,core_1[_0x3cc1d7(0x17b)])(interface_1[_0x3cc1d7(0x18c)],_0x48e389)||{};_0x5a319d[_0x80a28]={'comment':_0xa013f8,..._0x61d9ee},(0x0,core_1[_0x3cc1d7(0x17e)])(interface_1[_0x3cc1d7(0x18c)],_0x5a319d,_0x48e389);};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function a8_0x249e(_0x4563cb,_0x13f31b){const _0x2f63e8=a8_0x44d1();return a8_0x249e=function(_0x1be9a6,_0x45c13b){_0x1be9a6=_0x1be9a6-0xc7;let _0x44d1dd=_0x2f63e8[_0x1be9a6];return _0x44d1dd;},a8_0x249e(_0x4563cb,_0x13f31b);}function a8_0x44d1(){const _0x56cadd=['transaction','getDirty','manager','length','createSave','_page','merge','DESC','model','hasOwnProperty','abs','limit','search','defineProperty','_isreverse','\x20IN(:..._auto_','searchScopes','typeorm','app','field','_order','update','type','bind','1\x20=\x202','findColumnWithPropertyName','methodName','SERIALIZABLE','orderBy','metadata','modelSearchs','isPrimary','toLowerCase','getClassMetadata','493465uaENpy','NOT\x20LIKE','BETWEEN','safeUpdate','string','split','2658966SNrOtZ','29769KTqpyI','(((.+)+)+)+$','426355bsbxtt','146384xFCWAJ','queryRunner','703480ymtpWZ','undefined','includes','\x20AND\x20:','skip','isDirty','24yJtSLm','getApplicationContext','toUpperCase','random','indexOf','Repository','apply','affected','function','_auto_','ISNULL','NOT\x20ISNULL','\x20=\x20:_auto_','__esModule','container','MODEL_KEY','pageType','ASC','target','condition','scope','../interface','mergeSave','getAsync','ceil','name','trim','alias','@midwayjs/core','toString','andWhere','excess','save','operator','isArray','212JYPSIP','修改失败','\x20like\x20:_auto_','__initialize','push','searchs','2842722KZtFsv','NOT\x20FIND\x20IN\x20SET','create','2ZVhRLu','assign','NOT\x20IN','_size'];a8_0x44d1=function(){return _0x56cadd;};return a8_0x44d1();}const a8_0xa29c8=a8_0x249e;(function(_0xf9be7,_0x3b9928){const _0x3a76b0=a8_0x249e,_0x4e30fc=_0xf9be7();while(!![]){try{const _0x3a4223=parseInt(_0x3a76b0(0xf4))/0x1*(parseInt(_0x3a76b0(0x129))/0x2)+-parseInt(_0x3a76b0(0xf2))/0x3*(-parseInt(_0x3a76b0(0x120))/0x4)+parseInt(_0x3a76b0(0xeb))/0x5+-parseInt(_0x3a76b0(0xf1))/0x6+-parseInt(_0x3a76b0(0xf5))/0x7*(-parseInt(_0x3a76b0(0xfd))/0x8)+-parseInt(_0x3a76b0(0x126))/0x9+-parseInt(_0x3a76b0(0xf7))/0xa;if(_0x3a4223===_0x3b9928)break;else _0x4e30fc['push'](_0x4e30fc['shift']());}catch(_0x47da8a){_0x4e30fc['push'](_0x4e30fc['shift']());}}}(a8_0x44d1,0x456b0));const a8_0x45c13b=(function(){let _0x55a4d8=!![];return function(_0x479ae7,_0x4e90c4){const _0x2d1f45=_0x55a4d8?function(){const _0x445eca=a8_0x249e;if(_0x4e90c4){const _0x18b2a5=_0x4e90c4[_0x445eca(0x103)](_0x479ae7,arguments);return _0x4e90c4=null,_0x18b2a5;}}:function(){};return _0x55a4d8=![],_0x2d1f45;};}()),a8_0x1be9a6=a8_0x45c13b(this,function(){const _0x2d4af6=a8_0x249e;return a8_0x1be9a6['toString']()[_0x2d4af6(0xd5)](_0x2d4af6(0xf3))[_0x2d4af6(0x11a)]()['constructor'](a8_0x1be9a6)['search']('(((.+)+)+)+$');});a8_0x1be9a6();'use strict';Object[a8_0xa29c8(0xd6)](exports,a8_0xa29c8(0x10a),{'value':!![]}),exports[a8_0xa29c8(0x102)]=void 0x0;const core_1=require(a8_0xa29c8(0x119)),typeorm_1=require(a8_0xa29c8(0xda)),interface_1=require(a8_0xa29c8(0x112));class Repository extends typeorm_1['Repository']{async[a8_0xa29c8(0xd5)](_0x5823b9,_0x1e546f,_0x42922e={}){const _0x83c62e=a8_0xa29c8;var _0x517c91,_0x125900,_0x2b92b7,_0x3375c4,_0x194855,_0x4cd51b;const _0x26e103=this['createQueryBuilder'](undefined,_0x42922e===null||_0x42922e===void 0x0?void 0x0:_0x42922e['queryRunner']),_0xcbcac1=[];for(const _0x5a0fc1 of this[_0x83c62e(0xe7)]){if(_0x5a0fc1===null||_0x5a0fc1===void 0x0?void 0x0:_0x5a0fc1[_0x83c62e(0xd1)]){const _0xbf30a2=await this['app'][_0x83c62e(0xfe)]()[_0x83c62e(0x114)](_0x5a0fc1[_0x83c62e(0xd1)]);if(_0xbf30a2){typeof _0xbf30a2[_0x83c62e(0x123)]==_0x83c62e(0x105)&&await _0xbf30a2['__initialize']['bind'](_0xbf30a2)(_0x26e103,_0x5823b9,{'app':this['app'],'container':this[_0x83c62e(0x10b)],'paginate':_0x1e546f,'queryRunner':_0x42922e===null||_0x42922e===void 0x0?void 0x0:_0x42922e['queryRunner']});if(_0x42922e===null||_0x42922e===void 0x0?void 0x0:_0x42922e[_0x83c62e(0x111)]){const _0x4f09df=Array[_0x83c62e(0x11f)](_0x42922e[_0x83c62e(0x111)])?_0x42922e[_0x83c62e(0x111)]:[_0x42922e[_0x83c62e(0x111)]];for(const _0x5ec3f4 of(_0x5a0fc1===null||_0x5a0fc1===void 0x0?void 0x0:_0x5a0fc1[_0x83c62e(0xd9)])||[]){(_0x5ec3f4===null||_0x5ec3f4===void 0x0?void 0x0:_0x5ec3f4[_0x83c62e(0x111)])&&_0x4f09df[_0x83c62e(0x101)](_0x5ec3f4[_0x83c62e(0x111)])!=-0x1&&(_0x5ec3f4===null||_0x5ec3f4===void 0x0?void 0x0:_0x5ec3f4['methodName'])&&typeof _0xbf30a2[_0x5ec3f4[_0x83c62e(0xe3)]]==_0x83c62e(0x105)&&await _0xbf30a2[_0x5ec3f4[_0x83c62e(0xe3)]]['bind'](_0xbf30a2)(_0x26e103,_0x5823b9,{'app':this['app'],'container':this[_0x83c62e(0x10b)],'paginate':_0x1e546f,'queryRunner':_0x42922e===null||_0x42922e===void 0x0?void 0x0:_0x42922e[_0x83c62e(0xf6)]});}}if(_0x5823b9)for(const _0x4ca6d2 of(_0x5a0fc1===null||_0x5a0fc1===void 0x0?void 0x0:_0x5a0fc1[_0x83c62e(0x125)])||[]){(_0x4ca6d2===null||_0x4ca6d2===void 0x0?void 0x0:_0x4ca6d2['field'])&&(_0x4ca6d2===null||_0x4ca6d2===void 0x0?void 0x0:_0x4ca6d2['methodName'])&&typeof _0xbf30a2[_0x4ca6d2[_0x83c62e(0xe3)]]=='function'&&(typeof(_0x5823b9===null||_0x5823b9===void 0x0?void 0x0:_0x5823b9[_0x4ca6d2['field']])!=_0x83c62e(0xf8)&&!((_0x517c91=_0x5823b9===null||_0x5823b9===void 0x0?void 0x0:_0x5823b9[_0x4ca6d2['field']])===null||_0x517c91===void 0x0?void 0x0:_0x517c91[_0x83c62e(0xd2)](_0x83c62e(0x11e)))&&(_0xcbcac1[_0x83c62e(0x101)](_0x4ca6d2['field'])==-0x1&&_0xcbcac1[_0x83c62e(0x124)](_0x4ca6d2[_0x83c62e(0xdc)]),await _0xbf30a2[_0x4ca6d2[_0x83c62e(0xe3)]][_0x83c62e(0xe0)](_0xbf30a2)(_0x26e103,_0x5823b9[_0x4ca6d2['field']],_0x5823b9,{'app':this['app'],'container':this[_0x83c62e(0x10b)],'paginate':_0x1e546f,'queryRunner':_0x42922e===null||_0x42922e===void 0x0?void 0x0:_0x42922e['queryRunner']})));}}}}for(const _0x31852f in _0x5823b9){if(typeof _0x5823b9[_0x31852f]=='undefined')continue;if(_0xcbcac1[_0x83c62e(0x101)](_0x31852f)!=-0x1)continue;const _0x1619c7=this[_0x83c62e(0xe6)][_0x83c62e(0xe2)](_0x31852f);if(!_0x1619c7)continue;if((_0x125900=_0x5823b9===null||_0x5823b9===void 0x0?void 0x0:_0x5823b9[_0x31852f])===null||_0x125900===void 0x0?void 0x0:_0x125900[_0x83c62e(0xd2)](_0x83c62e(0x11e))){const _0x1f4f01=(_0x2b92b7=_0x5823b9[_0x31852f])===null||_0x2b92b7===void 0x0?void 0x0:_0x2b92b7[_0x83c62e(0x110)],_0x4913f4=(_0x3375c4=_0x5823b9[_0x31852f])===null||_0x3375c4===void 0x0?void 0x0:_0x3375c4['operator'][_0x83c62e(0x117)]()[_0x83c62e(0xff)](),_0x32d48a=_0x83c62e(0x106)+_0x31852f+'_'+Math[_0x83c62e(0x115)](Math[_0x83c62e(0x100)]()*0xa)+Math[_0x83c62e(0x115)](Math['random']()*0xa)+Math[_0x83c62e(0x115)](Math[_0x83c62e(0x100)]()*0xa)+Math['ceil'](Math[_0x83c62e(0x100)]()*0xa);if(['=','!=','<>','>','>=','<','<=','LIKE',_0x83c62e(0xec)]['indexOf'](_0x4913f4)!=-0x1)typeof _0x1f4f01!=_0x83c62e(0xf8)&&_0x26e103[_0x83c62e(0x11b)](_0x26e103[_0x83c62e(0x118)]+'.'+_0x31852f+'\x20'+_0x4913f4+'\x20:'+_0x32d48a,{[_0x32d48a]:_0x1f4f01});else{if(['IN',_0x83c62e(0xc7)][_0x83c62e(0x101)](_0x4913f4)!=-0x1){if(typeof _0x1f4f01!=_0x83c62e(0xf8)){const _0x42ea6e=Array[_0x83c62e(0x11f)](_0x1f4f01)?_0x1f4f01:typeof _0x1f4f01=='string'?_0x1f4f01[_0x83c62e(0xf0)](','):[_0x1f4f01];_0x42ea6e[_0x83c62e(0xcc)]==0x0?_0x26e103[_0x83c62e(0x11b)]('1\x20=\x202'):_0x26e103[_0x83c62e(0x11b)](_0x26e103[_0x83c62e(0x118)]+'.'+_0x31852f+'\x20'+_0x4913f4+'(:...'+_0x32d48a+')',{[_0x32d48a]:_0x42ea6e});}else _0x26e103[_0x83c62e(0x11b)](_0x83c62e(0xe1));}else{if(['FIND\x20IN\x20SET',_0x83c62e(0x127)]['indexOf'](_0x4913f4)!=-0x1)typeof _0x1f4f01!=_0x83c62e(0xf8)&&_0x26e103['andWhere'](_0x4913f4+'(:'+_0x32d48a+','+_0x26e103[_0x83c62e(0x118)]+'.'+_0x31852f+')',{[_0x32d48a]:_0x1f4f01});else{if([_0x83c62e(0xed),'NOT\x20BETWEEN'][_0x83c62e(0x101)](_0x4913f4)!=-0x1){if(typeof _0x1f4f01!=_0x83c62e(0xf8)){const _0x100709=Array[_0x83c62e(0x11f)](_0x1f4f01)?_0x1f4f01:typeof _0x1f4f01=='string'?_0x1f4f01[_0x83c62e(0xf0)](','):[_0x1f4f01];_0x100709['length']>0x1&&_0x26e103[_0x83c62e(0x11b)](_0x26e103[_0x83c62e(0x118)]+'.'+_0x31852f+'\x20'+_0x4913f4+'\x20:'+_0x32d48a+_0x83c62e(0xfa)+_0x32d48a+'_2',{[''+_0x32d48a]:_0x100709[0x0],[_0x32d48a+'_2']:_0x100709[0x1]});}}else[_0x83c62e(0x107),_0x83c62e(0x108)][_0x83c62e(0x101)](_0x4913f4)!=-0x1&&_0x26e103[_0x83c62e(0x11b)](_0x4913f4+'('+_0x26e103['alias']+'.'+_0x31852f+')');}}}}else{const _0x1dd59b=((_0x4cd51b=typeof _0x1619c7[_0x83c62e(0xdf)]==_0x83c62e(0x105)?(_0x194855=_0x1619c7===null||_0x1619c7===void 0x0?void 0x0:_0x1619c7['type'])===null||_0x194855===void 0x0?void 0x0:_0x194855[_0x83c62e(0x116)]:_0x1619c7[_0x83c62e(0xdf)]['toString']())===null||_0x4cd51b===void 0x0?void 0x0:_0x4cd51b[_0x83c62e(0xe9)]())||undefined;if(_0x1dd59b){if(Array[_0x83c62e(0x11f)](_0x5823b9[_0x31852f]))_0x5823b9[_0x31852f][_0x83c62e(0xcc)]==0x0?_0x26e103['andWhere'](_0x83c62e(0xe1)):_0x26e103[_0x83c62e(0x11b)](_0x26e103['alias']+'.'+_0x31852f+_0x83c62e(0xd8)+_0x31852f+')',{['_auto_'+_0x31852f]:_0x5823b9[_0x31852f]});else _0x1dd59b==_0x83c62e(0xef)&&!_0x1619c7[_0x83c62e(0xe8)]?_0x26e103[_0x83c62e(0x11b)](_0x26e103['alias']+'.'+_0x31852f+_0x83c62e(0x122)+_0x31852f,{[_0x83c62e(0x106)+_0x31852f]:'%'+_0x5823b9[_0x31852f]+'%'}):_0x26e103[_0x83c62e(0x11b)](_0x26e103[_0x83c62e(0x118)]+'.'+_0x31852f+_0x83c62e(0x109)+_0x31852f,{[_0x83c62e(0x106)+_0x31852f]:_0x5823b9[_0x31852f]});}}}if(_0x1e546f===null||_0x1e546f===void 0x0?void 0x0:_0x1e546f[_0x83c62e(0xdd)]){if(_0x1e546f[_0x83c62e(0xdd)]['indexOf']('.')!==-0x1)_0x26e103[_0x83c62e(0xe5)](''+_0x1e546f[_0x83c62e(0xdd)],(_0x1e546f===null||_0x1e546f===void 0x0?void 0x0:_0x1e546f[_0x83c62e(0xd7)])?'ASC':_0x83c62e(0xd0));else this[_0x83c62e(0xe6)][_0x83c62e(0xe2)](_0x1e546f['_order'])&&_0x26e103[_0x83c62e(0xe5)](_0x26e103[_0x83c62e(0x118)]+'.'+_0x1e546f['_order'],(_0x1e546f===null||_0x1e546f===void 0x0?void 0x0:_0x1e546f[_0x83c62e(0xd7)])?_0x83c62e(0x10e):_0x83c62e(0xd0));}return(_0x42922e===null||_0x42922e===void 0x0?void 0x0:_0x42922e[_0x83c62e(0x10d)])==_0x83c62e(0xd4)?((_0x1e546f===null||_0x1e546f===void 0x0?void 0x0:_0x1e546f[_0x83c62e(0xc8)])&&_0x26e103[_0x83c62e(0xd4)](_0x1e546f===null||_0x1e546f===void 0x0?void 0x0:_0x1e546f['_size']),(_0x1e546f===null||_0x1e546f===void 0x0?void 0x0:_0x1e546f[_0x83c62e(0xce)])&&(_0x1e546f===null||_0x1e546f===void 0x0?void 0x0:_0x1e546f[_0x83c62e(0xc8)])&&_0x26e103['offset']((Math[_0x83c62e(0xd3)](_0x1e546f[_0x83c62e(0xce)])-0x1)*Math[_0x83c62e(0xd3)](_0x1e546f['_size']))):((_0x1e546f===null||_0x1e546f===void 0x0?void 0x0:_0x1e546f[_0x83c62e(0xc8)])&&_0x26e103['take'](Math[_0x83c62e(0xd3)](_0x1e546f[_0x83c62e(0xc8)])),(_0x1e546f===null||_0x1e546f===void 0x0?void 0x0:_0x1e546f[_0x83c62e(0xce)])&&(_0x1e546f===null||_0x1e546f===void 0x0?void 0x0:_0x1e546f[_0x83c62e(0xc8)])&&_0x26e103[_0x83c62e(0xfb)]((Math['abs'](_0x1e546f[_0x83c62e(0xce)])-0x1)*Math[_0x83c62e(0xd3)](_0x1e546f[_0x83c62e(0xc8)]))),typeof(_0x42922e===null||_0x42922e===void 0x0?void 0x0:_0x42922e[_0x83c62e(0x11c)])==_0x83c62e(0x105)&&await(_0x42922e===null||_0x42922e===void 0x0?void 0x0:_0x42922e[_0x83c62e(0x11c)](_0x26e103)),_0x26e103;}async[a8_0xa29c8(0xee)](_0x50e4dd,_0x37a43b,_0x397f9d=0x0){const _0x5acc85=a8_0xa29c8;let _0x3e0ebf=0x0;while(!![]){const _0x57d299=await this[_0x5acc85(0xde)](_0x50e4dd,_0x37a43b);if((_0x57d299===null||_0x57d299===void 0x0?void 0x0:_0x57d299[_0x5acc85(0x104)])>0x0)return _0x57d299;if(_0x397f9d>0x0&&_0x3e0ebf>=_0x397f9d)throw new Error(_0x5acc85(0x121));_0x3e0ebf++;}}async[a8_0xa29c8(0x113)](_0x2b9eb4,..._0x4afa8d){const _0x52ab97=this['merge'](_0x2b9eb4,..._0x4afa8d);return await this['save'](_0x52ab97);}async[a8_0xa29c8(0xcd)](_0x497f91,..._0x4783ab){const _0x42794a=a8_0xa29c8,_0x59ff4b=this[_0x42794a(0xcf)](this[_0x42794a(0x128)](_0x497f91),..._0x4783ab);return await this[_0x42794a(0x11d)](_0x59ff4b);}async[a8_0xa29c8(0xc9)](_0x1daac6,_0x5ed359){const _0x3c58d7=a8_0xa29c8;return typeof _0x1daac6==_0x3c58d7(0x105)?this[_0x3c58d7(0xcb)]['transaction'](_0x3c58d7(0xe4),_0x1daac6):this['manager'][_0x3c58d7(0xc9)](_0x1daac6,_0x5ed359);}[a8_0xa29c8(0xfc)](_0x429874,_0xd56d8b,_0x1674ed=[]){const _0x579588=a8_0xa29c8,_0x581bd3=Object[_0x579588(0x12a)]({},{..._0x429874},{..._0xd56d8b});for(const _0x17f43d in _0x581bd3){if(_0x1674ed[_0x579588(0xf9)](_0x17f43d))continue;if((_0x581bd3===null||_0x581bd3===void 0x0?void 0x0:_0x581bd3[_0x17f43d])!=(_0x429874===null||_0x429874===void 0x0?void 0x0:_0x429874[_0x17f43d]))return!![];if((_0x581bd3===null||_0x581bd3===void 0x0?void 0x0:_0x581bd3[_0x17f43d])!=(_0xd56d8b===null||_0xd56d8b===void 0x0?void 0x0:_0xd56d8b[_0x17f43d]))return!![];}return![];}[a8_0xa29c8(0xca)](_0x53ac9b,_0xb2f629,_0x319453=[]){const _0x5aa1de={},_0x363050=Object['assign']({},{..._0x53ac9b},{..._0xb2f629});for(const _0x4e4724 in _0x363050){if(_0x319453['includes'](_0x4e4724))continue;(_0x363050===null||_0x363050===void 0x0?void 0x0:_0x363050[_0x4e4724])!=(_0x53ac9b===null||_0x53ac9b===void 0x0?void 0x0:_0x53ac9b[_0x4e4724])&&(_0x5aa1de[_0x4e4724]=_0x363050[_0x4e4724]);}return _0x5aa1de;}constructor(_0x484fb7,_0x5e14ea,_0x53cf1d){const _0x39e1fc=a8_0xa29c8;super(_0x53cf1d[_0x39e1fc(0x10f)],_0x53cf1d[_0x39e1fc(0xcb)],_0x53cf1d['queryRunner']),this[_0x39e1fc(0xe7)]=[];for(const _0x3fa06f of(0x0,core_1[_0x39e1fc(0xea)])(interface_1[_0x39e1fc(0x10c)],this[_0x39e1fc(0x10f)])||[]){const _0x25032b={'model':_0x3fa06f,'searchs':[],'searchScopes':[]};for(const _0x1d185e of(0x0,core_1[_0x39e1fc(0xea)])(interface_1['MODEL_SEARCH_KEY'],_0x3fa06f)||[]){_0x25032b[_0x39e1fc(0x125)][_0x39e1fc(0x124)](_0x1d185e);}for(const _0x4a6815 of(0x0,core_1['getClassMetadata'])(interface_1['MODEL_SEARCH_SCOPE_KEY'],_0x3fa06f)||[]){_0x25032b[_0x39e1fc(0xd9)][_0x39e1fc(0x124)](_0x4a6815);}this[_0x39e1fc(0xe7)]['push'](_0x25032b);}this[_0x39e1fc(0xdb)]=_0x484fb7,this[_0x39e1fc(0x10b)]=_0x5e14ea;}}exports[a8_0xa29c8(0x102)]=Repository;
|
|
1
|
+
const a8_0x4c274c=a8_0x151c;(function(_0x1fe33b,_0x3b11d2){const _0x472b63=a8_0x151c,_0x193098=_0x1fe33b();while(!![]){try{const _0x57d824=-parseInt(_0x472b63(0x8f))/0x1+-parseInt(_0x472b63(0x9d))/0x2+parseInt(_0x472b63(0x79))/0x3+parseInt(_0x472b63(0x89))/0x4*(-parseInt(_0x472b63(0x9a))/0x5)+-parseInt(_0x472b63(0xc0))/0x6*(parseInt(_0x472b63(0xc3))/0x7)+-parseInt(_0x472b63(0x75))/0x8+parseInt(_0x472b63(0x91))/0x9*(parseInt(_0x472b63(0x72))/0xa);if(_0x57d824===_0x3b11d2)break;else _0x193098['push'](_0x193098['shift']());}catch(_0x347194){_0x193098['push'](_0x193098['shift']());}}}(a8_0x1702,0x5700f));const a8_0x1f6913=(function(){let _0x1883d5=!![];return function(_0x2ba3e3,_0xa5eb3a){const _0xab607e=_0x1883d5?function(){const _0x28975a=a8_0x151c;if(_0xa5eb3a){const _0x4db7fb=_0xa5eb3a[_0x28975a(0x96)](_0x2ba3e3,arguments);return _0xa5eb3a=null,_0x4db7fb;}}:function(){};return _0x1883d5=![],_0xab607e;};}()),a8_0x4c0bc4=a8_0x1f6913(this,function(){const _0x52db35=a8_0x151c;return a8_0x4c0bc4[_0x52db35(0x71)]()[_0x52db35(0xcb)]('(((.+)+)+)+$')[_0x52db35(0x71)]()[_0x52db35(0xbf)](a8_0x4c0bc4)[_0x52db35(0xcb)](_0x52db35(0xbc));});a8_0x4c0bc4();'use strict';Object[a8_0x4c274c(0xa3)](exports,'__esModule',{'value':!![]}),exports[a8_0x4c274c(0x97)]=void 0x0;function a8_0x151c(_0x5938c3,_0x5e2b38){const _0x3d3d20=a8_0x1702();return a8_0x151c=function(_0x4c0bc4,_0x1f6913){_0x4c0bc4=_0x4c0bc4-0x6f;let _0x1702ab=_0x3d3d20[_0x4c0bc4];return _0x1702ab;},a8_0x151c(_0x5938c3,_0x5e2b38);}const core_1=require(a8_0x4c274c(0x8d)),typeorm_1=require(a8_0x4c274c(0x77)),interface_1=require(a8_0x4c274c(0xb7));class Repository extends typeorm_1['Repository']{async[a8_0x4c274c(0xcb)](_0x3f1f4b,_0x1873c5,_0x283530={}){const _0xf22db0=a8_0x4c274c;var _0x10783b,_0x252a5e,_0x52f214,_0x1c8190,_0x11c041,_0x4d472f;const _0x3950b8=this[_0xf22db0(0x98)](undefined,_0x283530===null||_0x283530===void 0x0?void 0x0:_0x283530['queryRunner']),_0x202a70=[];for(const _0x496309 of this[_0xf22db0(0xab)]){if(_0x496309===null||_0x496309===void 0x0?void 0x0:_0x496309[_0xf22db0(0x7e)]){const _0xc6f5be=await this[_0xf22db0(0x85)][_0xf22db0(0x92)]()[_0xf22db0(0xa2)](_0x496309[_0xf22db0(0x7e)]);if(_0xc6f5be){typeof _0xc6f5be[_0xf22db0(0xa4)]==_0xf22db0(0xbd)&&await _0xc6f5be[_0xf22db0(0xa4)][_0xf22db0(0xb6)](_0xc6f5be)(_0x3950b8,_0x3f1f4b,{'app':this[_0xf22db0(0x85)],'container':this['container'],'paginate':_0x1873c5,'queryRunner':_0x283530===null||_0x283530===void 0x0?void 0x0:_0x283530[_0xf22db0(0x76)]});if(_0x283530===null||_0x283530===void 0x0?void 0x0:_0x283530[_0xf22db0(0x9b)]){const _0x2cde07=Array[_0xf22db0(0xb1)](_0x283530['scope'])?_0x283530[_0xf22db0(0x9b)]:[_0x283530[_0xf22db0(0x9b)]];for(const _0x397163 of(_0x496309===null||_0x496309===void 0x0?void 0x0:_0x496309['searchScopes'])||[]){(_0x397163===null||_0x397163===void 0x0?void 0x0:_0x397163[_0xf22db0(0x9b)])&&_0x2cde07[_0xf22db0(0xca)](_0x397163[_0xf22db0(0x9b)])!=-0x1&&(_0x397163===null||_0x397163===void 0x0?void 0x0:_0x397163[_0xf22db0(0xac)])&&typeof _0xc6f5be[_0x397163[_0xf22db0(0xac)]]==_0xf22db0(0xbd)&&await _0xc6f5be[_0x397163['methodName']][_0xf22db0(0xb6)](_0xc6f5be)(_0x3950b8,_0x3f1f4b,{'app':this[_0xf22db0(0x85)],'container':this[_0xf22db0(0xa0)],'paginate':_0x1873c5,'queryRunner':_0x283530===null||_0x283530===void 0x0?void 0x0:_0x283530[_0xf22db0(0x76)]});}}if(_0x3f1f4b)for(const _0x1cf471 of(_0x496309===null||_0x496309===void 0x0?void 0x0:_0x496309[_0xf22db0(0xc8)])||[]){(_0x1cf471===null||_0x1cf471===void 0x0?void 0x0:_0x1cf471[_0xf22db0(0x80)])&&(_0x1cf471===null||_0x1cf471===void 0x0?void 0x0:_0x1cf471[_0xf22db0(0xac)])&&typeof _0xc6f5be[_0x1cf471[_0xf22db0(0xac)]]==_0xf22db0(0xbd)&&(typeof(_0x3f1f4b===null||_0x3f1f4b===void 0x0?void 0x0:_0x3f1f4b[_0x1cf471[_0xf22db0(0x80)]])!=_0xf22db0(0xa1)&&!((_0x10783b=_0x3f1f4b===null||_0x3f1f4b===void 0x0?void 0x0:_0x3f1f4b[_0x1cf471['field']])===null||_0x10783b===void 0x0?void 0x0:_0x10783b[_0xf22db0(0xad)](_0xf22db0(0x8a)))&&(_0x202a70[_0xf22db0(0xca)](_0x1cf471[_0xf22db0(0x80)])==-0x1&&_0x202a70[_0xf22db0(0xc5)](_0x1cf471[_0xf22db0(0x80)]),await _0xc6f5be[_0x1cf471[_0xf22db0(0xac)]][_0xf22db0(0xb6)](_0xc6f5be)(_0x3950b8,_0x3f1f4b[_0x1cf471[_0xf22db0(0x80)]],_0x3f1f4b,{'app':this['app'],'container':this[_0xf22db0(0xa0)],'paginate':_0x1873c5,'queryRunner':_0x283530===null||_0x283530===void 0x0?void 0x0:_0x283530[_0xf22db0(0x76)]})));}}}}for(const _0x5ef42a in _0x3f1f4b){if(typeof _0x3f1f4b[_0x5ef42a]=='undefined')continue;if(_0x202a70['indexOf'](_0x5ef42a)!=-0x1)continue;const _0x3d8855=this['metadata'][_0xf22db0(0xb0)](_0x5ef42a);if(!_0x3d8855)continue;if((_0x252a5e=_0x3f1f4b===null||_0x3f1f4b===void 0x0?void 0x0:_0x3f1f4b[_0x5ef42a])===null||_0x252a5e===void 0x0?void 0x0:_0x252a5e[_0xf22db0(0xad)](_0xf22db0(0x8a))){const _0x33db96=(_0x52f214=_0x3f1f4b[_0x5ef42a])===null||_0x52f214===void 0x0?void 0x0:_0x52f214['condition'],_0x3f291d=(_0x1c8190=_0x3f1f4b[_0x5ef42a])===null||_0x1c8190===void 0x0?void 0x0:_0x1c8190[_0xf22db0(0x8a)][_0xf22db0(0x70)]()['toUpperCase'](),_0x4e491f=_0xf22db0(0xc9)+_0x5ef42a+'_'+Math['ceil'](Math[_0xf22db0(0xb4)]()*0xa)+Math[_0xf22db0(0x99)](Math[_0xf22db0(0xb4)]()*0xa)+Math['ceil'](Math[_0xf22db0(0xb4)]()*0xa)+Math[_0xf22db0(0x99)](Math[_0xf22db0(0xb4)]()*0xa);if(['=','!=','<>','>','>=','<','<=','LIKE',_0xf22db0(0xa6)]['indexOf'](_0x3f291d)!=-0x1)typeof _0x33db96!=_0xf22db0(0xa1)&&_0x3950b8[_0xf22db0(0xae)](_0x3950b8[_0xf22db0(0x88)]+'.'+_0x5ef42a+'\x20'+_0x3f291d+'\x20:'+_0x4e491f,{[_0x4e491f]:_0x33db96});else{if(['IN',_0xf22db0(0x86)][_0xf22db0(0xca)](_0x3f291d)!=-0x1){if(typeof _0x33db96!='undefined'){const _0x308b3e=Array['isArray'](_0x33db96)?_0x33db96:typeof _0x33db96==_0xf22db0(0xa9)?_0x33db96[_0xf22db0(0x7c)](','):[_0x33db96];_0x308b3e[_0xf22db0(0xcd)]==0x0?_0x3950b8[_0xf22db0(0xae)](_0xf22db0(0xba)):_0x3950b8['andWhere'](_0x3950b8['alias']+'.'+_0x5ef42a+'\x20'+_0x3f291d+_0xf22db0(0xc4)+_0x4e491f+')',{[_0x4e491f]:_0x308b3e});}else _0x3950b8[_0xf22db0(0xae)](_0xf22db0(0xba));}else{if([_0xf22db0(0x94),_0xf22db0(0x93)][_0xf22db0(0xca)](_0x3f291d)!=-0x1)typeof _0x33db96!=_0xf22db0(0xa1)&&_0x3950b8[_0xf22db0(0xae)](_0x3f291d+'(:'+_0x4e491f+','+_0x3950b8[_0xf22db0(0x88)]+'.'+_0x5ef42a+')',{[_0x4e491f]:_0x33db96});else{if([_0xf22db0(0x95),_0xf22db0(0xa8)][_0xf22db0(0xca)](_0x3f291d)!=-0x1){if(typeof _0x33db96!=_0xf22db0(0xa1)){const _0x51d3e4=Array[_0xf22db0(0xb1)](_0x33db96)?_0x33db96:typeof _0x33db96=='string'?_0x33db96[_0xf22db0(0x7c)](','):[_0x33db96];_0x51d3e4[_0xf22db0(0xcd)]>0x1&&_0x3950b8[_0xf22db0(0xae)](_0x3950b8[_0xf22db0(0x88)]+'.'+_0x5ef42a+'\x20'+_0x3f291d+'\x20:'+_0x4e491f+_0xf22db0(0x9c)+_0x4e491f+'_2',{[''+_0x4e491f]:_0x51d3e4[0x0],[_0x4e491f+'_2']:_0x51d3e4[0x1]});}}else['ISNULL',_0xf22db0(0xa7)][_0xf22db0(0xca)](_0x3f291d)!=-0x1&&_0x3950b8[_0xf22db0(0xae)](_0x3f291d+'('+_0x3950b8[_0xf22db0(0x88)]+'.'+_0x5ef42a+')');}}}}else{const _0x4051b1=((_0x4d472f=typeof _0x3d8855[_0xf22db0(0x7a)]==_0xf22db0(0xbd)?(_0x11c041=_0x3d8855===null||_0x3d8855===void 0x0?void 0x0:_0x3d8855['type'])===null||_0x11c041===void 0x0?void 0x0:_0x11c041['name']:_0x3d8855['type']['toString']())===null||_0x4d472f===void 0x0?void 0x0:_0x4d472f[_0xf22db0(0xbe)]())||undefined;if(_0x4051b1){if(Array[_0xf22db0(0xb1)](_0x3f1f4b[_0x5ef42a]))_0x3f1f4b[_0x5ef42a]['length']==0x0?_0x3950b8[_0xf22db0(0xae)](_0xf22db0(0xba)):_0x3950b8[_0xf22db0(0xae)](_0x3950b8[_0xf22db0(0x88)]+'.'+_0x5ef42a+_0xf22db0(0xbb)+_0x5ef42a+')',{[_0xf22db0(0xc9)+_0x5ef42a]:_0x3f1f4b[_0x5ef42a]});else _0x4051b1=='string'&&!_0x3d8855[_0xf22db0(0xcc)]?_0x3950b8[_0xf22db0(0xae)](_0x3950b8['alias']+'.'+_0x5ef42a+'\x20like\x20:_auto_'+_0x5ef42a,{[_0xf22db0(0xc9)+_0x5ef42a]:'%'+_0x3f1f4b[_0x5ef42a]+'%'}):_0x3950b8['andWhere'](_0x3950b8[_0xf22db0(0x88)]+'.'+_0x5ef42a+_0xf22db0(0x7d)+_0x5ef42a,{['_auto_'+_0x5ef42a]:_0x3f1f4b[_0x5ef42a]});}}}if(_0x1873c5===null||_0x1873c5===void 0x0?void 0x0:_0x1873c5['_order']){if(_0x1873c5[_0xf22db0(0x84)][_0xf22db0(0xca)]('.')!==-0x1)_0x3950b8[_0xf22db0(0x8c)](''+_0x1873c5[_0xf22db0(0x84)],(_0x1873c5===null||_0x1873c5===void 0x0?void 0x0:_0x1873c5[_0xf22db0(0x73)])?_0xf22db0(0xb2):_0xf22db0(0xc2));else this['metadata'][_0xf22db0(0xb0)](_0x1873c5['_order'])&&_0x3950b8['orderBy'](_0x3950b8[_0xf22db0(0x88)]+'.'+_0x1873c5[_0xf22db0(0x84)],(_0x1873c5===null||_0x1873c5===void 0x0?void 0x0:_0x1873c5['_isreverse'])?'ASC':_0xf22db0(0xc2));}return(_0x283530===null||_0x283530===void 0x0?void 0x0:_0x283530[_0xf22db0(0xaf)])=='limit'?((_0x1873c5===null||_0x1873c5===void 0x0?void 0x0:_0x1873c5['_size'])&&_0x3950b8[_0xf22db0(0x87)](_0x1873c5===null||_0x1873c5===void 0x0?void 0x0:_0x1873c5[_0xf22db0(0x8b)]),(_0x1873c5===null||_0x1873c5===void 0x0?void 0x0:_0x1873c5['_page'])&&(_0x1873c5===null||_0x1873c5===void 0x0?void 0x0:_0x1873c5[_0xf22db0(0x8b)])&&_0x3950b8['offset']((Math[_0xf22db0(0xaa)](_0x1873c5[_0xf22db0(0xb5)])-0x1)*Math[_0xf22db0(0xaa)](_0x1873c5[_0xf22db0(0x8b)]))):((_0x1873c5===null||_0x1873c5===void 0x0?void 0x0:_0x1873c5[_0xf22db0(0x8b)])&&_0x3950b8[_0xf22db0(0xc7)](Math['abs'](_0x1873c5[_0xf22db0(0x8b)])),(_0x1873c5===null||_0x1873c5===void 0x0?void 0x0:_0x1873c5[_0xf22db0(0xb5)])&&(_0x1873c5===null||_0x1873c5===void 0x0?void 0x0:_0x1873c5[_0xf22db0(0x8b)])&&_0x3950b8[_0xf22db0(0x8e)]((Math['abs'](_0x1873c5['_page'])-0x1)*Math['abs'](_0x1873c5[_0xf22db0(0x8b)]))),typeof(_0x283530===null||_0x283530===void 0x0?void 0x0:_0x283530['excess'])=='function'&&await(_0x283530===null||_0x283530===void 0x0?void 0x0:_0x283530['excess'](_0x3950b8)),_0x3950b8;}async[a8_0x4c274c(0x82)](_0x1b36e3,_0x1c7b2f,_0x3dae8b=0x0){const _0x5a79c6=a8_0x4c274c;let _0x296280=0x0;while(!![]){const _0x11e8ea=await this['update'](_0x1b36e3,_0x1c7b2f);if((_0x11e8ea===null||_0x11e8ea===void 0x0?void 0x0:_0x11e8ea[_0x5a79c6(0xc6)])>0x0)return _0x11e8ea;if(_0x3dae8b>0x0&&_0x296280>=_0x3dae8b)throw new Error(_0x5a79c6(0xb9));_0x296280++;}}async[a8_0x4c274c(0x83)](_0x870ecf,..._0x7bbf81){const _0x577b42=a8_0x4c274c,_0x9e4923=this[_0x577b42(0xb8)](_0x870ecf,..._0x7bbf81);return await this[_0x577b42(0xc1)](_0x9e4923);}async['createSave'](_0x2b3bc9,..._0x59fdc2){const _0x13ec45=a8_0x4c274c,_0x6e58c6=this['merge'](this[_0x13ec45(0x81)](_0x2b3bc9),..._0x59fdc2);return await this[_0x13ec45(0xc1)](_0x6e58c6);}async[a8_0x4c274c(0x90)](_0x972969,_0x41775c){const _0x57ffe4=a8_0x4c274c;return typeof _0x972969=='function'?this['manager'][_0x57ffe4(0x90)](_0x57ffe4(0x7f),_0x972969):this[_0x57ffe4(0x9f)]['transaction'](_0x972969,_0x41775c);}['isDirty'](_0x2b6d7c,_0x176d37,_0x340352=[]){const _0x2d91fc=a8_0x4c274c,_0x52da04=Object['assign']({},{..._0x2b6d7c},{..._0x176d37});for(const _0x492096 in _0x52da04){if(_0x340352[_0x2d91fc(0xa5)](_0x492096))continue;if((_0x52da04===null||_0x52da04===void 0x0?void 0x0:_0x52da04[_0x492096])!=(_0x2b6d7c===null||_0x2b6d7c===void 0x0?void 0x0:_0x2b6d7c[_0x492096]))return!![];if((_0x52da04===null||_0x52da04===void 0x0?void 0x0:_0x52da04[_0x492096])!=(_0x176d37===null||_0x176d37===void 0x0?void 0x0:_0x176d37[_0x492096]))return!![];}return![];}[a8_0x4c274c(0x74)](_0x6d370a,_0x29f11f,_0x2cdd87=[]){const _0x20067a=a8_0x4c274c,_0x10cd41={},_0x6e74cc=Object[_0x20067a(0x78)]({},{..._0x6d370a},{..._0x29f11f});for(const _0x3efeb5 in _0x6e74cc){if(_0x2cdd87[_0x20067a(0xa5)](_0x3efeb5))continue;(_0x6e74cc===null||_0x6e74cc===void 0x0?void 0x0:_0x6e74cc[_0x3efeb5])!=(_0x6d370a===null||_0x6d370a===void 0x0?void 0x0:_0x6d370a[_0x3efeb5])&&(_0x10cd41[_0x3efeb5]=_0x6e74cc[_0x3efeb5]);}return _0x10cd41;}constructor(_0x45304d,_0x583185,_0x1a593f){const _0x2e32cb=a8_0x4c274c;super(_0x1a593f['target'],_0x1a593f[_0x2e32cb(0x9f)],_0x1a593f[_0x2e32cb(0x76)]),this[_0x2e32cb(0xab)]=[];for(const _0x53114c of(0x0,core_1['getClassMetadata'])(interface_1[_0x2e32cb(0x9e)],this['target'])||[]){const _0x55717c={'model':_0x53114c,'searchs':[],'searchScopes':[]};for(const _0x3bd936 of(0x0,core_1[_0x2e32cb(0x6f)])(interface_1['MODEL_SEARCH_KEY'],_0x53114c)||[]){_0x55717c[_0x2e32cb(0xc8)][_0x2e32cb(0xc5)](_0x3bd936);}for(const _0x526457 of(0x0,core_1['getClassMetadata'])(interface_1[_0x2e32cb(0x7b)],_0x53114c)||[]){_0x55717c[_0x2e32cb(0xb3)][_0x2e32cb(0xc5)](_0x526457);}this[_0x2e32cb(0xab)][_0x2e32cb(0xc5)](_0x55717c);}this[_0x2e32cb(0x85)]=_0x45304d,this[_0x2e32cb(0xa0)]=_0x583185;}}function a8_0x1702(){const _0xff10a4=['transaction','18DEJqQY','getApplicationContext','NOT\x20FIND\x20IN\x20SET','FIND\x20IN\x20SET','BETWEEN','apply','Repository','createQueryBuilder','ceil','2015xniQZm','scope','\x20AND\x20:','80150tHliPE','MODEL_KEY','manager','container','undefined','getAsync','defineProperty','__initialize','includes','NOT\x20LIKE','NOT\x20ISNULL','NOT\x20BETWEEN','string','abs','modelSearchs','methodName','hasOwnProperty','andWhere','pageType','findColumnWithPropertyName','isArray','ASC','searchScopes','random','_page','bind','../interface','merge','修改失败','1\x20=\x202','\x20IN(:..._auto_','(((.+)+)+)+$','function','toLowerCase','constructor','1026XLyZAK','save','DESC','27517ZeXIBZ','(:...','push','affected','take','searchs','_auto_','indexOf','search','isPrimary','length','getClassMetadata','trim','toString','8655730RKwkZY','_isreverse','getDirty','4399064SnsiXO','queryRunner','typeorm','assign','753054mNfkSS','type','MODEL_SEARCH_SCOPE_KEY','split','\x20=\x20:_auto_','model','SERIALIZABLE','field','create','safeUpdate','mergeSave','_order','app','NOT\x20IN','limit','alias','2252neLOub','operator','_size','orderBy','@midwayjs/core','skip','136749mklhXw'];a8_0x1702=function(){return _0xff10a4;};return a8_0x1702();}exports[a8_0x4c274c(0x97)]=Repository;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a9_0x536da6=a9_0x4fac;(function(_0x4b27b2,_0x35a075){const _0x1a4759=a9_0x4fac,_0xe2f548=_0x4b27b2();while(!![]){try{const _0x15d981=parseInt(_0x1a4759(0x16b))/0x1*(parseInt(_0x1a4759(0x168))/0x2)+parseInt(_0x1a4759(0x15c))/0x3*(-parseInt(_0x1a4759(0x157))/0x4)+-parseInt(_0x1a4759(0x170))/0x5*(-parseInt(_0x1a4759(0x160))/0x6)+parseInt(_0x1a4759(0x15e))/0x7+-parseInt(_0x1a4759(0x164))/0x8*(-parseInt(_0x1a4759(0x158))/0x9)+parseInt(_0x1a4759(0x16d))/0xa*(-parseInt(_0x1a4759(0x162))/0xb)+-parseInt(_0x1a4759(0x159))/0xc;if(_0x15d981===_0x35a075)break;else _0xe2f548['push'](_0xe2f548['shift']());}catch(_0x451fbd){_0xe2f548['push'](_0xe2f548['shift']());}}}(a9_0x44d1,0x7cb9d));const a9_0x4b1ef6=(function(){let _0x2368f5=!![];return function(_0x553494,_0x17a692){const _0x1a96ac=_0x2368f5?function(){const _0x2b6c08=a9_0x4fac;if(_0x17a692){const _0x3ed103=_0x17a692[_0x2b6c08(0x15f)](_0x553494,arguments);return _0x17a692=null,_0x3ed103;}}:function(){};return _0x2368f5=![],_0x1a96ac;};}()),a9_0x52460c=a9_0x4b1ef6(this,function(){const _0x7e0a5e=a9_0x4fac;return a9_0x52460c[_0x7e0a5e(0x163)]()[_0x7e0a5e(0x166)](_0x7e0a5e(0x171))[_0x7e0a5e(0x163)]()['constructor'](a9_0x52460c)[_0x7e0a5e(0x166)](_0x7e0a5e(0x171));});a9_0x52460c();'use strict';Object[a9_0x536da6(0x16e)](exports,a9_0x536da6(0x167),{'value':!![]}),exports[a9_0x536da6(0x165)]=getDataSourceEntity;const core_1=require('@midwayjs/core'),interface_1=require(a9_0x536da6(0x15b));function getDataSourceEntity(_0x457d60='default'){const _0x5530c3=a9_0x536da6;var _0x500963;const _0x25d566=[];for(const _0x4001c1 of(0x0,core_1[_0x5530c3(0x161)])(interface_1[_0x5530c3(0x16a)])){const _0x153500=(0x0,core_1[_0x5530c3(0x169)])(interface_1[_0x5530c3(0x15d)],_0x4001c1);((_0x500963=_0x153500===null||_0x153500===void 0x0?void 0x0:_0x153500[_0x5530c3(0x16c)])===null||_0x500963===void 0x0?void 0x0:_0x500963[_0x5530c3(0x16f)](_0x5d4e0d=>_0x5d4e0d==_0x457d60))&&_0x25d566[_0x5530c3(0x15a)](_0x4001c1);}return _0x25d566;}function a9_0x4fac(_0x35761d,_0x3700df){const _0x10d9b7=a9_0x44d1();return a9_0x4fac=function(_0x52460c,_0x4b1ef6){_0x52460c=_0x52460c-0x157;let _0x44d100=_0x10d9b7[_0x52460c];return _0x44d100;},a9_0x4fac(_0x35761d,_0x3700df);}function a9_0x44d1(){const _0x354fbd=['(((.+)+)+)+$','10932DsowfX','81AwVaQe','18625092iualxd','push','../interface','72wUCOsd','ENTIFY_MODULE_SOURCE','1678887LqiqAq','apply','1217202ThUvVL','listModule','442783GZEtWM','toString','895752pvifKe','getDataSourceEntity','search','__esModule','21842JvRsUU','getClassMetadata','ENTIFY_MODULE','36SXbfZH','dataSource','30MTeFMI','defineProperty','find','15ujvFqT'];a9_0x44d1=function(){return _0x354fbd;};return a9_0x44d1();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a10_0x293547=a10_0x1149;function a10_0x1149(_0x4b967b,_0x7d73d5){const _0x2febe4=a10_0x5815();return a10_0x1149=function(_0x2ad5b9,_0xd4943c){_0x2ad5b9=_0x2ad5b9-0x1ce;let _0x581589=_0x2febe4[_0x2ad5b9];return _0x581589;},a10_0x1149(_0x4b967b,_0x7d73d5);}(function(_0x235c8e,_0x5aa0a0){const _0x5ac555=a10_0x1149,_0x369c67=_0x235c8e();while(!![]){try{const _0x226ea5=parseInt(_0x5ac555(0x1d3))/0x1+-parseInt(_0x5ac555(0x1dc))/0x2*(parseInt(_0x5ac555(0x1d4))/0x3)+parseInt(_0x5ac555(0x1d8))/0x4+-parseInt(_0x5ac555(0x1da))/0x5*(parseInt(_0x5ac555(0x1d2))/0x6)+-parseInt(_0x5ac555(0x1d1))/0x7+-parseInt(_0x5ac555(0x1cf))/0x8*(-parseInt(_0x5ac555(0x1dd))/0x9)+parseInt(_0x5ac555(0x1d6))/0xa;if(_0x226ea5===_0x5aa0a0)break;else _0x369c67['push'](_0x369c67['shift']());}catch(_0x3b015b){_0x369c67['push'](_0x369c67['shift']());}}}(a10_0x5815,0x1c6da));const a10_0xd4943c=(function(){let _0x16d85e=!![];return function(_0x340737,_0x3bb50d){const _0x37380e=_0x16d85e?function(){if(_0x3bb50d){const _0x3b5693=_0x3bb50d['apply'](_0x340737,arguments);return _0x3bb50d=null,_0x3b5693;}}:function(){};return _0x16d85e=![],_0x37380e;};}()),a10_0x2ad5b9=a10_0xd4943c(this,function(){const _0x2e41d0=a10_0x1149;return a10_0x2ad5b9[_0x2e41d0(0x1d7)]()['search'](_0x2e41d0(0x1ce))['toString']()['constructor'](a10_0x2ad5b9)[_0x2e41d0(0x1df)]('(((.+)+)+)+$');});a10_0x2ad5b9();function a10_0x5815(){const _0x3a3568=['../interface','298QYexLR','27MTKLsF','__esModule','search','(((.+)+)+)+$','191144XAeyjz','getProvideObserve','581553DOjCuT','1282230kxScTv','43737Sgxdch','1239DwBZDi','@midwayjs/core','1593190gdCqAS','toString','800112vMDnQc','defineProperty','5midxFH'];a10_0x5815=function(){return _0x3a3568;};return a10_0x5815();}'use strict';Object[a10_0x293547(0x1d9)](exports,a10_0x293547(0x1de),{'value':!![]}),exports[a10_0x293547(0x1d0)]=getProvideObserve;const core_1=require(a10_0x293547(0x1d5)),interface_1=require(a10_0x293547(0x1db));function getProvideObserve(){return(0x0,core_1['listModule'])(interface_1['REPOSITORY_OBSERVE_KEY'])||[];}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function preCreateShardingTables(dataSourceName?: string): Promise<void>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const a11_0x3b2992=a11_0x4b90;function a11_0x4b90(_0x259ea2,_0x3965b0){const _0x28eddc=a11_0x105d();return a11_0x4b90=function(_0x52c561,_0x5cb544){_0x52c561=_0x52c561-0x158;let _0x105d96=_0x28eddc[_0x52c561];return _0x105d96;},a11_0x4b90(_0x259ea2,_0x3965b0);}function a11_0x105d(){const _0x5108c1=['784611HlWnJO','(((.+)+)+)+$','strategy','getCurrentApplicationContext','878260fpMpuQ','1tRuHiH','__esModule','1040931SFmwEv','default','search','204113QUcyuk','@midwayjs/core','tableName','4MAUsOp','224741gcanpX','getMetadata','\x22\x20not\x20found','getClassMetadata','getPreCreateTableNames','defineProperty','1068aBHbaz','length','includes','30MKSDFv','preCreateTables','getAsync','apply','3938632MiinCK','66xtFGel','toString','constructor','[Sharding]\x20Application\x20context\x20not\x20available','495218joXMUC','manager'];a11_0x105d=function(){return _0x5108c1;};return a11_0x105d();}(function(_0x35e574,_0x56ea35){const _0x7a7bf2=a11_0x4b90,_0x3cc0dd=_0x35e574();while(!![]){try{const _0x251103=parseInt(_0x7a7bf2(0x167))/0x1*(-parseInt(_0x7a7bf2(0x160))/0x2)+-parseInt(_0x7a7bf2(0x162))/0x3+-parseInt(_0x7a7bf2(0x16f))/0x4*(-parseInt(_0x7a7bf2(0x166))/0x5)+-parseInt(_0x7a7bf2(0x15c))/0x6*(parseInt(_0x7a7bf2(0x16c))/0x7)+-parseInt(_0x7a7bf2(0x15b))/0x8+parseInt(_0x7a7bf2(0x169))/0x9*(-parseInt(_0x7a7bf2(0x179))/0xa)+-parseInt(_0x7a7bf2(0x170))/0xb*(-parseInt(_0x7a7bf2(0x176))/0xc);if(_0x251103===_0x56ea35)break;else _0x3cc0dd['push'](_0x3cc0dd['shift']());}catch(_0x160b37){_0x3cc0dd['push'](_0x3cc0dd['shift']());}}}(a11_0x105d,0x4f4ca));const a11_0x5cb544=(function(){let _0x5a90d1=!![];return function(_0x2663db,_0x6f9793){const _0xcc6c3a=_0x5a90d1?function(){const _0x584425=a11_0x4b90;if(_0x6f9793){const _0x2b2f97=_0x6f9793[_0x584425(0x15a)](_0x2663db,arguments);return _0x6f9793=null,_0x2b2f97;}}:function(){};return _0x5a90d1=![],_0xcc6c3a;};}()),a11_0x52c561=a11_0x5cb544(this,function(){const _0x2d1fae=a11_0x4b90;return a11_0x52c561[_0x2d1fae(0x15d)]()[_0x2d1fae(0x16b)](_0x2d1fae(0x163))['toString']()[_0x2d1fae(0x15e)](a11_0x52c561)['search'](_0x2d1fae(0x163));});a11_0x52c561();'use strict';Object[a11_0x3b2992(0x175)](exports,a11_0x3b2992(0x168),{'value':!![]}),exports['preCreateShardingTables']=preCreateShardingTables;const core_1=require(a11_0x3b2992(0x16d)),interface_1=require('../interface');async function preCreateShardingTables(_0x5d355d=a11_0x3b2992(0x16a)){const _0x1e5b86=a11_0x3b2992;var _0x16770d;const _0xdb7034=(0x0,core_1[_0x1e5b86(0x165)])();if(!_0xdb7034)throw new Error(_0x1e5b86(0x15f));const _0x2e2ab6=await _0xdb7034[_0x1e5b86(0x159)]('dataSource:'+_0x5d355d);if(!_0x2e2ab6)throw new Error('[Sharding]\x20DataSource\x20\x22'+_0x5d355d+_0x1e5b86(0x172));for(const _0x338b50 of(0x0,core_1['listModule'])(interface_1['ENTIFY_MODULE'])){const _0x116481=(0x0,core_1[_0x1e5b86(0x173)])(interface_1['ENTIFY_MODULE_SOURCE'],_0x338b50);if(!((_0x16770d=_0x116481===null||_0x116481===void 0x0?void 0x0:_0x116481['dataSource'])===null||_0x16770d===void 0x0?void 0x0:_0x16770d[_0x1e5b86(0x178)](_0x5d355d)))continue;const _0x1f0fa5=(0x0,core_1[_0x1e5b86(0x173)])(interface_1['ENTIFY_SHARDING_KEY'],_0x338b50);if(!(_0x1f0fa5===null||_0x1f0fa5===void 0x0?void 0x0:_0x1f0fa5[_0x1e5b86(0x164)]))continue;const _0x55b982=await _0xdb7034['getAsync'](_0x1f0fa5['strategy']);if(!(_0x55b982===null||_0x55b982===void 0x0?void 0x0:_0x55b982[_0x1e5b86(0x174)]))continue;const _0xb00abf=_0x116481[_0x1e5b86(0x16e)],_0x4d8333=await _0x55b982['getPreCreateTableNames'](_0xb00abf);if(!(_0x4d8333===null||_0x4d8333===void 0x0?void 0x0:_0x4d8333[_0x1e5b86(0x177)]))continue;const _0x2b6c08={'entity':_0x338b50,'baseTableName':_0xb00abf,'dataSource':_0x2e2ab6,'entityMetadata':_0x2e2ab6[_0x1e5b86(0x171)](_0x338b50),'manager':_0x2e2ab6[_0x1e5b86(0x161)]};await _0x55b982[_0x1e5b86(0x158)](_0x2b6c08,_0x4d8333);}}
|
package/dist/helper/sleep.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a12_0x38e40e=a12_0x3277;(function(_0x28f25e,_0x5e5012){var _0x4e98d0=a12_0x3277,_0x2d4f63=_0x28f25e();while(!![]){try{var _0x96f0cf=parseInt(_0x4e98d0(0xf3))/0x1*(-parseInt(_0x4e98d0(0xf2))/0x2)+-parseInt(_0x4e98d0(0xfb))/0x3+parseInt(_0x4e98d0(0xf9))/0x4*(parseInt(_0x4e98d0(0xfd))/0x5)+parseInt(_0x4e98d0(0xfe))/0x6+parseInt(_0x4e98d0(0xf1))/0x7*(-parseInt(_0x4e98d0(0xfc))/0x8)+parseInt(_0x4e98d0(0xf8))/0x9*(-parseInt(_0x4e98d0(0xfa))/0xa)+-parseInt(_0x4e98d0(0x101))/0xb*(-parseInt(_0x4e98d0(0x100))/0xc);if(_0x96f0cf===_0x5e5012)break;else _0x2d4f63['push'](_0x2d4f63['shift']());}catch(_0x664bbd){_0x2d4f63['push'](_0x2d4f63['shift']());}}}(a12_0x4dc7,0xc016f));var a12_0xdf988c=(function(){var _0x31ef69=!![];return function(_0x4b8acb,_0x362a6e){var _0x2ea66b=_0x31ef69?function(){var _0x23d43=a12_0x3277;if(_0x362a6e){var _0x39a0fe=_0x362a6e[_0x23d43(0xf7)](_0x4b8acb,arguments);return _0x362a6e=null,_0x39a0fe;}}:function(){};return _0x31ef69=![],_0x2ea66b;};}()),a12_0x2257aa=a12_0xdf988c(this,function(){var _0x465d96=a12_0x3277;return a12_0x2257aa[_0x465d96(0xf6)]()['search'](_0x465d96(0xf5))['toString']()[_0x465d96(0xff)](a12_0x2257aa)[_0x465d96(0x102)](_0x465d96(0xf5));});function a12_0x3277(_0x4a05bc,_0x433711){var _0xd6c800=a12_0x4dc7();return a12_0x3277=function(_0x2257aa,_0xdf988c){_0x2257aa=_0x2257aa-0xf1;var _0x4dc78b=_0xd6c800[_0x2257aa];return _0x4dc78b;},a12_0x3277(_0x4a05bc,_0x433711);}a12_0x2257aa();'use strict';Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[a12_0x38e40e(0xf4)]=sleep;function a12_0x4dc7(){var _0x380932=['search','1462419CNkTnq','434bZvkiR','7121mrWQSg','sleep','(((.+)+)+)+$','toString','apply','9aoZhjC','1551236dnnsKN','2736170yyLXDo','2591085zPnnYH','8zzMGZO','20BPBRVZ','5605782wACwDC','constructor','1301184jazzvw','121mvGdgm'];a12_0x4dc7=function(){return _0x380932;};return a12_0x4dc7();}function sleep(_0x3cc0db=0xc8){return new Promise(_0xc669f2=>setTimeout(_0xc669f2,_0x3cc0db));}
|
package/dist/index.d.ts
CHANGED
|
@@ -10,5 +10,6 @@ export { ProvideRepository } from './decorator/ProvideRepository';
|
|
|
10
10
|
export { ProvideSearch, Search, SearchScope } from "./decorator/ProvideSearch";
|
|
11
11
|
export { getProvideObserve } from './helper/getProvideObserve';
|
|
12
12
|
export { getDataSourceEntity } from './helper/getDataSourceEntity';
|
|
13
|
+
export { preCreateShardingTables } from './helper/preCreateShardingTables';
|
|
13
14
|
export { CustomConfiguration as Configuration } from './configuration';
|
|
14
15
|
export { Provide, Inject, Scope, ScopeEnum } from "@midwayjs/core";
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var a13_0x47cc7=a13_0x11d1;(function(_0x440a05,_0x2990a6){var _0xb687ea=a13_0x11d1,_0x21b4d2=_0x440a05();while(!![]){try{var _0x15a68c=-parseInt(_0xb687ea(0x80))/0x1+-parseInt(_0xb687ea(0x69))/0x2*(parseInt(_0xb687ea(0x6d))/0x3)+-parseInt(_0xb687ea(0x90))/0x4+-parseInt(_0xb687ea(0x74))/0x5+parseInt(_0xb687ea(0x65))/0x6+-parseInt(_0xb687ea(0x97))/0x7*(-parseInt(_0xb687ea(0x94))/0x8)+parseInt(_0xb687ea(0x8a))/0x9;if(_0x15a68c===_0x2990a6)break;else _0x21b4d2['push'](_0x21b4d2['shift']());}catch(_0x3eeb42){_0x21b4d2['push'](_0x21b4d2['shift']());}}}(a13_0x238d,0xae05e));var a13_0x2e19ab=(function(){var _0x18bae8=!![];return function(_0x37d69e,_0x418f7a){var _0x47f8ec=_0x18bae8?function(){var _0x4a32d7=a13_0x11d1;if(_0x418f7a){var _0x517ee6=_0x418f7a[_0x4a32d7(0x73)](_0x37d69e,arguments);return _0x418f7a=null,_0x517ee6;}}:function(){};return _0x18bae8=![],_0x47f8ec;};}()),a13_0x1a489d=a13_0x2e19ab(this,function(){var _0x52c5ed=a13_0x11d1;return a13_0x1a489d['toString']()[_0x52c5ed(0x7c)](_0x52c5ed(0x78))[_0x52c5ed(0x70)]()['constructor'](a13_0x1a489d)[_0x52c5ed(0x7c)](_0x52c5ed(0x78));});a13_0x1a489d();'use strict';var __createBinding=this&&this[a13_0x47cc7(0x85)]||(Object['create']?function(_0x510ff6,_0x1a6bb1,_0x15bdff,_0x1d92d7){var _0x50cf1f=a13_0x47cc7;if(_0x1d92d7===undefined)_0x1d92d7=_0x15bdff;var _0x565ab1=Object[_0x50cf1f(0x7b)](_0x1a6bb1,_0x15bdff);(!_0x565ab1||('get'in _0x565ab1?!_0x1a6bb1[_0x50cf1f(0x81)]:_0x565ab1['writable']||_0x565ab1[_0x50cf1f(0x67)]))&&(_0x565ab1={'enumerable':!![],'get':function(){return _0x1a6bb1[_0x15bdff];}}),Object[_0x50cf1f(0x92)](_0x510ff6,_0x1d92d7,_0x565ab1);}:function(_0x295aba,_0x4b9d5f,_0x5ab8c1,_0x152c47){if(_0x152c47===undefined)_0x152c47=_0x5ab8c1;_0x295aba[_0x152c47]=_0x4b9d5f[_0x5ab8c1];}),__exportStar=this&&this[a13_0x47cc7(0x8d)]||function(_0x2aa6e4,_0xd345dc){var _0x3968f5=a13_0x47cc7;for(var _0x1003c6 in _0x2aa6e4)if(_0x1003c6!==_0x3968f5(0x8b)&&!Object[_0x3968f5(0x93)][_0x3968f5(0x6b)]['call'](_0xd345dc,_0x1003c6))__createBinding(_0xd345dc,_0x2aa6e4,_0x1003c6);};Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[a13_0x47cc7(0x89)]=exports[a13_0x47cc7(0x6e)]=exports[a13_0x47cc7(0x71)]=exports['Provide']=exports[a13_0x47cc7(0x7a)]=exports['preCreateShardingTables']=exports['getDataSourceEntity']=exports[a13_0x47cc7(0x96)]=exports[a13_0x47cc7(0x91)]=exports['Search']=exports[a13_0x47cc7(0x6a)]=exports[a13_0x47cc7(0x83)]=exports['ProvideObserve']=exports['ProvideEntity']=exports['InjectRepository']=exports[a13_0x47cc7(0x8e)]=exports['VirtualColumn']=exports[a13_0x47cc7(0x95)]=void 0x0,__exportStar(require('typeorm'),exports),__exportStar(require(a13_0x47cc7(0x7d)),exports);var Repository_1=require(a13_0x47cc7(0x87));Object['defineProperty'](exports,a13_0x47cc7(0x95),{'enumerable':!![],'get':function(){var _0x318a57=a13_0x47cc7;return Repository_1[_0x318a57(0x95)];}});var VirtualColumn_1=require(a13_0x47cc7(0x7e));Object['defineProperty'](exports,a13_0x47cc7(0x8c),{'enumerable':!![],'get':function(){var _0x2100ce=a13_0x47cc7;return VirtualColumn_1[_0x2100ce(0x8c)];}});var InjectEntity_1=require(a13_0x47cc7(0x86));function a13_0x11d1(_0x5c06a5,_0x4d920d){var _0x2c7313=a13_0x238d();return a13_0x11d1=function(_0x1a489d,_0x2e19ab){_0x1a489d=_0x1a489d-0x64;var _0x238dea=_0x2c7313[_0x1a489d];return _0x238dea;},a13_0x11d1(_0x5c06a5,_0x4d920d);}Object[a13_0x47cc7(0x92)](exports,a13_0x47cc7(0x8e),{'enumerable':!![],'get':function(){var _0x231ea8=a13_0x47cc7;return InjectEntity_1[_0x231ea8(0x8e)];}});var InjectRepository_1=require('./decorator/InjectRepository');Object[a13_0x47cc7(0x92)](exports,a13_0x47cc7(0x77),{'enumerable':!![],'get':function(){var _0x587c3e=a13_0x47cc7;return InjectRepository_1[_0x587c3e(0x77)];}});var ProvideEntity_1=require(a13_0x47cc7(0x98));Object[a13_0x47cc7(0x92)](exports,a13_0x47cc7(0x6f),{'enumerable':!![],'get':function(){var _0x1bdef5=a13_0x47cc7;return ProvideEntity_1[_0x1bdef5(0x6f)];}});var ProvideObserve_1=require(a13_0x47cc7(0x6c));Object[a13_0x47cc7(0x92)](exports,a13_0x47cc7(0x75),{'enumerable':!![],'get':function(){var _0x306045=a13_0x47cc7;return ProvideObserve_1[_0x306045(0x75)];}});var ProvideRepository_1=require('./decorator/ProvideRepository');Object[a13_0x47cc7(0x92)](exports,a13_0x47cc7(0x83),{'enumerable':!![],'get':function(){var _0x50ada6=a13_0x47cc7;return ProvideRepository_1[_0x50ada6(0x83)];}});var ProvideSearch_1=require(a13_0x47cc7(0x8f));Object[a13_0x47cc7(0x92)](exports,a13_0x47cc7(0x6a),{'enumerable':!![],'get':function(){var _0x2db2a8=a13_0x47cc7;return ProvideSearch_1[_0x2db2a8(0x6a)];}}),Object[a13_0x47cc7(0x92)](exports,a13_0x47cc7(0x76),{'enumerable':!![],'get':function(){var _0x1e2d97=a13_0x47cc7;return ProvideSearch_1[_0x1e2d97(0x76)];}}),Object['defineProperty'](exports,'SearchScope',{'enumerable':!![],'get':function(){var _0x3aed52=a13_0x47cc7;return ProvideSearch_1[_0x3aed52(0x91)];}});var getProvideObserve_1=require(a13_0x47cc7(0x82));Object[a13_0x47cc7(0x92)](exports,a13_0x47cc7(0x96),{'enumerable':!![],'get':function(){var _0x20232b=a13_0x47cc7;return getProvideObserve_1[_0x20232b(0x96)];}});var getDataSourceEntity_1=require(a13_0x47cc7(0x72));function a13_0x238d(){var _0x35264b=['getProvideObserve','7iXrBlK','./decorator/ProvideEntity','./configuration','7661484VohrDT','getDataSourceEntity','configurable','CustomConfiguration','40192HRTNxg','ProvideSearch','hasOwnProperty','./decorator/ProvideObserve','42cKBuSh','Scope','ProvideEntity','toString','Inject','./helper/getDataSourceEntity','apply','3189195wgcgME','ProvideObserve','Search','InjectRepository','(((.+)+)+)+$','./helper/preCreateShardingTables','Configuration','getOwnPropertyDescriptor','search','./interface','./decorator/VirtualColumn','@midwayjs/core','781437rIHNeN','__esModule','./helper/getProvideObserve','ProvideRepository','Provide','__createBinding','./decorator/InjectEntity','./definition/Repository','preCreateShardingTables','ScopeEnum','15703461HUJZHA','default','VirtualColumn','__exportStar','InjectEntity','./decorator/ProvideSearch','5702152gWnyGP','SearchScope','defineProperty','prototype','6537704nGorwb','Repository'];a13_0x238d=function(){return _0x35264b;};return a13_0x238d();}Object[a13_0x47cc7(0x92)](exports,a13_0x47cc7(0x66),{'enumerable':!![],'get':function(){var _0x1b90f3=a13_0x47cc7;return getDataSourceEntity_1[_0x1b90f3(0x66)];}});var preCreateShardingTables_1=require(a13_0x47cc7(0x79));Object['defineProperty'](exports,a13_0x47cc7(0x88),{'enumerable':!![],'get':function(){var _0x2f049c=a13_0x47cc7;return preCreateShardingTables_1[_0x2f049c(0x88)];}});var configuration_1=require(a13_0x47cc7(0x64));Object[a13_0x47cc7(0x92)](exports,a13_0x47cc7(0x7a),{'enumerable':!![],'get':function(){var _0x94e68a=a13_0x47cc7;return configuration_1[_0x94e68a(0x68)];}});var core_1=require(a13_0x47cc7(0x7f));Object[a13_0x47cc7(0x92)](exports,'Provide',{'enumerable':!![],'get':function(){var _0x2fcb33=a13_0x47cc7;return core_1[_0x2fcb33(0x84)];}}),Object[a13_0x47cc7(0x92)](exports,a13_0x47cc7(0x71),{'enumerable':!![],'get':function(){var _0x119775=a13_0x47cc7;return core_1[_0x119775(0x71)];}}),Object[a13_0x47cc7(0x92)](exports,a13_0x47cc7(0x6e),{'enumerable':!![],'get':function(){var _0x50728d=a13_0x47cc7;return core_1[_0x50728d(0x6e)];}}),Object['defineProperty'](exports,a13_0x47cc7(0x89),{'enumerable':!![],'get':function(){return core_1['ScopeEnum'];}});
|
package/dist/interface.d.ts
CHANGED
|
@@ -4,15 +4,18 @@ import { RelationMetadataArgs } from "typeorm/metadata-args/RelationMetadataArgs
|
|
|
4
4
|
import { JoinColumnMetadataArgs } from "typeorm/metadata-args/JoinColumnMetadataArgs";
|
|
5
5
|
import { SelectQueryBuilder } from "typeorm";
|
|
6
6
|
import { FindOneOptions, FindOptionsWhereProperty, DeepPartial, ObjectLiteral, QueryRunner } from 'typeorm';
|
|
7
|
+
import './interfaceSharding';
|
|
7
8
|
export declare const ENTIFY_KEY = "decorator:anncic-api:typeorm:entify";
|
|
8
9
|
export declare const ENTIFY_MODULE = "decorator:anncic-api:typeorm:entify:module";
|
|
9
10
|
export declare const ENTIFY_MODULE_SOURCE = "decorator:anncic-api:typeorm:entify:module:source";
|
|
11
|
+
export declare const ENTIFY_SHARDING_KEY = "decorator:anncic-api:typeorm:entify:sharding";
|
|
10
12
|
export declare const REPOSITORY_KEY = "decorator:anncic-api:typeorm:repository";
|
|
11
13
|
export declare const REPOSITORY_OBSERVE_KEY = "decorator:anncic-api:typeorm:repository:observe";
|
|
12
14
|
export declare const MODEL_KEY = "decorator:anncic-api:typeorm:model";
|
|
13
15
|
export declare const MODEL_SEARCH_KEY = "decorator:anncic-api:typeorm:model:search";
|
|
14
16
|
export declare const MODEL_SEARCH_SCOPE_KEY = "decorator:anncic-api:typeorm:model:search:scope";
|
|
15
17
|
export declare const ENTITY_VIRTUAL_COLUMN_KEY = "decorator:anncic-api:typeorm:entity:virtual:column";
|
|
18
|
+
export { ShardingContext, ShardingStrategy, clearTableExistsCache } from './interfaceSharding';
|
|
16
19
|
export type SearchParams<Entity> = {
|
|
17
20
|
[P in keyof Entity]?: {
|
|
18
21
|
operator: '=' | '!=' | '<>' | '>' | '>=' | '<' | '<=' | 'LIKE' | 'NOT LIKE';
|
package/dist/interface.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function a13_0x5775(_0x101dc8,_0x5e6c14){const _0x457daf=a13_0xa775();return a13_0x5775=function(_0x583a1e,_0x2b023f){_0x583a1e=_0x583a1e-0x19f;let _0xa77518=_0x457daf[_0x583a1e];return _0xa77518;},a13_0x5775(_0x101dc8,_0x5e6c14);}const a13_0x4b66cc=a13_0x5775;(function(_0x30b2a4,_0x3438c4){const _0x356010=a13_0x5775,_0x451c70=_0x30b2a4();while(!![]){try{const _0x4d196b=-parseInt(_0x356010(0x1d8))/0x1*(parseInt(_0x356010(0x1fc))/0x2)+-parseInt(_0x356010(0x1dd))/0x3*(parseInt(_0x356010(0x205))/0x4)+parseInt(_0x356010(0x1a2))/0x5*(parseInt(_0x356010(0x1e0))/0x6)+parseInt(_0x356010(0x202))/0x7+-parseInt(_0x356010(0x1b5))/0x8+parseInt(_0x356010(0x222))/0x9+parseInt(_0x356010(0x1ec))/0xa*(-parseInt(_0x356010(0x1b0))/0xb);if(_0x4d196b===_0x3438c4)break;else _0x451c70['push'](_0x451c70['shift']());}catch(_0x1a087b){_0x451c70['push'](_0x451c70['shift']());}}}(a13_0xa775,0x24d7d));const a13_0x2b023f=(function(){let _0xd89f23=!![];return function(_0x443bf0,_0xeec345){const _0x1ae2eb=_0xd89f23?function(){if(_0xeec345){const _0x50f33a=_0xeec345['apply'](_0x443bf0,arguments);return _0xeec345=null,_0x50f33a;}}:function(){};return _0xd89f23=![],_0x1ae2eb;};}()),a13_0x583a1e=a13_0x2b023f(this,function(){const _0x41cf84=a13_0x5775;return a13_0x583a1e['toString']()[_0x41cf84(0x1a9)](_0x41cf84(0x1c0))[_0x41cf84(0x21a)]()['constructor'](a13_0x583a1e)[_0x41cf84(0x1a9)](_0x41cf84(0x1c0));});a13_0x583a1e();'use strict';Object[a13_0x4b66cc(0x1e2)](exports,a13_0x4b66cc(0x1a6),{'value':!![]}),exports[a13_0x4b66cc(0x1a5)]=exports[a13_0x4b66cc(0x1c7)]=exports['MODEL_SEARCH_SCOPE_KEY']=exports[a13_0x4b66cc(0x1b6)]=exports['MODEL_KEY']=exports[a13_0x4b66cc(0x22b)]=exports[a13_0x4b66cc(0x1df)]=exports[a13_0x4b66cc(0x22a)]=exports['ENTIFY_MODULE']=exports[a13_0x4b66cc(0x19f)]=void 0x0;const stream_1=require(a13_0x4b66cc(0x1d6)),core_1=require('@midwayjs/core'),typeorm_1=require(a13_0x4b66cc(0x1db)),DriverUtils_1=require(a13_0x4b66cc(0x20a)),typeorm_2=require('typeorm'),typeorm_3=require(a13_0x4b66cc(0x1db)),sleep_1=require(a13_0x4b66cc(0x1d2));exports['ENTIFY_KEY']=a13_0x4b66cc(0x1b1),exports[a13_0x4b66cc(0x1ea)]='decorator:anncic-api:typeorm:entify:module',exports[a13_0x4b66cc(0x22a)]=a13_0x4b66cc(0x214),exports[a13_0x4b66cc(0x1df)]='decorator:anncic-api:typeorm:repository',exports[a13_0x4b66cc(0x22b)]=a13_0x4b66cc(0x20d),exports[a13_0x4b66cc(0x1f9)]='decorator:anncic-api:typeorm:model',exports[a13_0x4b66cc(0x1b6)]=a13_0x4b66cc(0x224),exports[a13_0x4b66cc(0x1e6)]=a13_0x4b66cc(0x1f2),exports['ENTITY_VIRTUAL_COLUMN_KEY']=a13_0x4b66cc(0x1cf);class SearchPaginate{}function a13_0xa775(){const _0x499f5a=['length','string','type','ENTIFY_MODULE_SOURCE','REPOSITORY_OBSERVE_KEY','mainAlias','getExplainCount','cacheId','referencedColumnName','limit','take','ENTIFY_KEY','many-to-one','skip','45FlfEeu','relation','EXPLAIN\x20','SearchPaginate','__esModule','optimistic','rows','search','findOneOrFail','findOption','withDeleted','expressionMap','getManyAndCount','options','6809CbHhju','decorator:anncic-api:typeorm:entify','andWhere','size','propertyName','51720FrXyrJ','MODEL_SEARCH_KEY','createQueryBuilder','versionColumn','queryEntity','one-to-one','lockMode','metadata','query','all','offset','(((.+)+)+)+$','isMySQLFamily','\x20=\x20:','queryResultCache','getRawAndEntities','driver','function','ENTITY_VIRTUAL_COLUMN_KEY','clone','name','getEntityValue','stringify','setFindOptions','findOneByOrFail','findOne','decorator:anncic-api:typeorm:entity:virtual:column','one-to-many','duration','./helper/sleep','\x20--\x20PARAMETERS:\x20','OptimisticLockCanNotBeUsedError','OptimisticLockVersionMismatchError','stream','getQueryAndParameters','9182jTbELh','updateDateColumn','EntityManager','typeorm','splice','21hpjvMf','getFromCache','REPOSITORY_KEY','104658IkNlmT','joinColumn','defineProperty','storeInCache','cache','obtainQueryRunner','MODEL_SEARCH_SCOPE_KEY','number','getTime','listenerCount','ENTIFY_MODULE','resolve','1370FsasJM','joinColumns','release','findOneBy','getMany','startsWith','decorator:anncic-api:typeorm:model:search:scope','SelectQueryBuilder','delay','cacheDuration','EntityNotFoundError','boolean','push','MODEL_KEY','_appends','getCount','18ZBNmsr','target','relationType','relations','isExpired','lockVersion','841743lenYuL','substring','chunk','100604DMIdnV','getMetadataArgsStorage','object','DriverUtils','end','typeorm/driver/DriverUtils','prototype','map','decorator:anncic-api:typeorm:repository:observe','data','emit','parse','abs','getOne','result','decorator:anncic-api:typeorm:entify:module:source','default','_joinAppendsResolve','getManyExplainCount','then','reject','toString','immediately','queryRunner','countsize','getClassMetadata','records','find','alias','2012724lTigXL','isArray','decorator:anncic-api:typeorm:model:search','connection','destroy'];a13_0xa775=function(){return _0x499f5a;};return a13_0xa775();}exports['SearchPaginate']=SearchPaginate,typeorm_2[a13_0x4b66cc(0x1f3)][a13_0x4b66cc(0x20b)][a13_0x4b66cc(0x204)]=function(_0x42b7b7=0x64,_0x25f649){const _0x3153c6=a13_0x4b66cc;let _0x900d2d=0x1,_0x1b0051=0x64,_0x222268=0x0,_0x53bb1b=0x0,_0x2575df=![],_0x51e21c=!![];if(typeof _0x42b7b7==_0x3153c6(0x1e7)||typeof _0x42b7b7==_0x3153c6(0x228))_0x1b0051=parseInt(''+_0x42b7b7);else _0x42b7b7&&((_0x42b7b7===null||_0x42b7b7===void 0x0?void 0x0:_0x42b7b7[_0x3153c6(0x1b3)])&&(_0x1b0051=parseInt(''+_0x42b7b7[_0x3153c6(0x1b3)])),(_0x42b7b7===null||_0x42b7b7===void 0x0?void 0x0:_0x42b7b7[_0x3153c6(0x21d)])&&(_0x222268=parseInt(''+_0x42b7b7[_0x3153c6(0x21d)])),(_0x42b7b7===null||_0x42b7b7===void 0x0?void 0x0:_0x42b7b7['delay'])&&(_0x2575df=typeof _0x42b7b7[_0x3153c6(0x1f4)]==_0x3153c6(0x1f7)?0x1f4:parseInt(''+_0x42b7b7[_0x3153c6(0x1f4)])),typeof(_0x42b7b7===null||_0x42b7b7===void 0x0?void 0x0:_0x42b7b7[_0x3153c6(0x21b)])==_0x3153c6(0x1f7)&&(_0x51e21c=_0x42b7b7['immediately']));_0x222268>0x0&&_0x222268>_0x1b0051&&(_0x1b0051=_0x222268);const _0x347e21=this,_0x33755c=new stream_1['Readable']({'objectMode':!![],'highWaterMark':_0x1b0051*0x2,async 'read'(){const _0x9c2d4=_0x3153c6;try{if(_0x222268>0x0&&_0x222268<=_0x53bb1b)this[_0x9c2d4(0x1e9)](_0x9c2d4(0x20e))>0x0?this['push'](null):this['emit'](_0x9c2d4(0x209));else{const _0x4936cc=_0x347e21[_0x9c2d4(0x1c8)]()[_0x9c2d4(0x230)](Math[_0x9c2d4(0x211)](_0x1b0051))[_0x9c2d4(0x1bf)]((Math[_0x9c2d4(0x211)](_0x900d2d)-0x1)*Math[_0x9c2d4(0x211)](_0x1b0051)),_0x2fdc49=await _0x4936cc[_0x9c2d4(0x1f0)]();if((_0x2fdc49===null||_0x2fdc49===void 0x0?void 0x0:_0x2fdc49[_0x9c2d4(0x227)])>0x0){_0x222268>0x0&&_0x53bb1b+_0x2fdc49[_0x9c2d4(0x227)]>_0x222268&&_0x2fdc49['splice'](0x0,_0x222268-(_0x53bb1b+_0x2fdc49[_0x9c2d4(0x227)]-_0x222268));if(typeof _0x25f649==_0x9c2d4(0x1c6)){const _0x1b41f9=await _0x25f649(_0x2fdc49,_0x900d2d,_0x4936cc[_0x9c2d4(0x1d7)]());_0x1b41f9&&Array[_0x9c2d4(0x223)](_0x1b41f9)?(_0x1b41f9===null||_0x1b41f9===void 0x0?void 0x0:_0x1b41f9['length'])>0x0&&(_0x53bb1b+=_0x1b41f9[_0x9c2d4(0x227)],_0x222268>0x0&&_0x53bb1b>_0x222268&&_0x1b41f9[_0x9c2d4(0x1dc)](0x0,_0x222268-(_0x53bb1b-_0x222268)),this[_0x9c2d4(0x1f8)](_0x1b41f9),_0x1b41f9[_0x9c2d4(0x227)]=0x0):(_0x53bb1b+=_0x2fdc49[_0x9c2d4(0x227)],_0x222268>0x0&&_0x53bb1b>_0x222268&&_0x2fdc49[_0x9c2d4(0x1dc)](0x0,_0x222268-(_0x53bb1b-_0x222268)),this[_0x9c2d4(0x1f8)](_0x2fdc49));}else _0x53bb1b+=_0x2fdc49['length'],_0x222268>0x0&&_0x53bb1b>_0x222268&&_0x2fdc49['splice'](0x0,_0x222268-(_0x53bb1b-_0x222268)),this[_0x9c2d4(0x1f8)](_0x2fdc49);_0x2fdc49[_0x9c2d4(0x227)]=0x0,_0x900d2d++,_0x2575df&&typeof _0x2575df==_0x9c2d4(0x1e7)&&await(0x0,sleep_1['sleep'])(_0x2575df);}else this[_0x9c2d4(0x1e9)]('data')>0x0?this['push'](null):this[_0x9c2d4(0x20f)](_0x9c2d4(0x209));}}catch(_0xd51e69){this[_0x9c2d4(0x226)](_0xd51e69);}}});return _0x33755c['on'](_0x3153c6(0x209),()=>_0x33755c[_0x3153c6(0x226)]()),_0x33755c['on']('close',()=>_0x33755c[_0x3153c6(0x226)]()),_0x51e21c&&_0x33755c['resume'](),_0x33755c;},typeorm_3[a13_0x4b66cc(0x1da)][a13_0x4b66cc(0x20b)][a13_0x4b66cc(0x1aa)]=async function(_0x197daf,_0x5c06b1){const _0x117e4b=a13_0x4b66cc;return this[_0x117e4b(0x1ce)](_0x197daf,_0x5c06b1)['then'](_0x1302be=>{const _0x443bb4=_0x117e4b;if(_0x1302be===null||_0x1302be===undefined)return Promise[_0x443bb4(0x219)](new typeorm_3[(_0x443bb4(0x1f6))](_0x197daf,_0x5c06b1));return Promise['resolve'](_0x1302be);});},typeorm_3[a13_0x4b66cc(0x1da)][a13_0x4b66cc(0x20b)][a13_0x4b66cc(0x1cd)]=async function(_0x2b2d46,_0x371961){const _0x2d9f69=a13_0x4b66cc;return this[_0x2d9f69(0x1ef)](_0x2b2d46,_0x371961)[_0x2d9f69(0x218)](_0x4a600e=>{const _0x110ae5=_0x2d9f69;if(_0x4a600e===null||_0x4a600e===undefined)return Promise[_0x110ae5(0x219)](new typeorm_3[(_0x110ae5(0x1f6))](_0x2b2d46,_0x371961));return Promise[_0x110ae5(0x1eb)](_0x4a600e);});},typeorm_2[a13_0x4b66cc(0x1f3)][a13_0x4b66cc(0x20b)][a13_0x4b66cc(0x212)]=async function(){const _0x52f9d7=a13_0x4b66cc;var _0x1633c4;const {entities:_0x10b3d9,raw:_0x37c414}=await this[_0x52f9d7(0x1c4)]();if(_0x10b3d9[0x0]&&this[_0x52f9d7(0x1ad)][_0x52f9d7(0x1bb)]===_0x52f9d7(0x1a7)&&this[_0x52f9d7(0x1ad)]['lockVersion']){const _0x4d0f56=this[_0x52f9d7(0x1ad)]['mainAlias'][_0x52f9d7(0x1bc)];if(this[_0x52f9d7(0x1ad)][_0x52f9d7(0x201)]instanceof Date){const _0x415dfe=_0x4d0f56[_0x52f9d7(0x1d9)][_0x52f9d7(0x1ca)](_0x10b3d9[0x0]);if(_0x415dfe[_0x52f9d7(0x1e8)]()!==this[_0x52f9d7(0x1ad)]['lockVersion']['getTime']())throw new typeorm_2[(_0x52f9d7(0x1d5))](_0x4d0f56[_0x52f9d7(0x1c9)],this[_0x52f9d7(0x1ad)]['lockVersion'],_0x415dfe);}else{const _0xc38f83=_0x4d0f56[_0x52f9d7(0x1b8)][_0x52f9d7(0x1ca)](_0x10b3d9[0x0]);if(_0xc38f83!==this[_0x52f9d7(0x1ad)][_0x52f9d7(0x201)])throw new typeorm_2[(_0x52f9d7(0x1d5))](_0x4d0f56[_0x52f9d7(0x1c9)],this[_0x52f9d7(0x1ad)][_0x52f9d7(0x201)],_0xc38f83);}}if(_0x10b3d9[0x0]&&_0x37c414[0x0]){const _0x2337c8=(0x0,core_1[_0x52f9d7(0x21e)])(exports[_0x52f9d7(0x1c7)],_0x10b3d9[0x0]);for(const _0x214b46 in _0x2337c8){_0x37c414[0x0]['hasOwnProperty'](_0x214b46)&&(_0x10b3d9[0x0][_0x214b46]=_0x37c414[0x0][_0x214b46]||((_0x1633c4=_0x2337c8[_0x214b46])===null||_0x1633c4===void 0x0?void 0x0:_0x1633c4[_0x52f9d7(0x215)])||'');}}return _0x10b3d9[0x0]&&typeof this[_0x52f9d7(0x216)]==_0x52f9d7(0x1c6)&&(_0x10b3d9[0x0]=await this[_0x52f9d7(0x216)](_0x10b3d9[0x0])),_0x10b3d9[0x0]||null;},typeorm_2['SelectQueryBuilder'][a13_0x4b66cc(0x20b)][a13_0x4b66cc(0x1f0)]=async function(){const _0x2dc0d5=a13_0x4b66cc;if(this[_0x2dc0d5(0x1ad)]['lockMode']===_0x2dc0d5(0x1a7))throw new typeorm_2[(_0x2dc0d5(0x1d4))]();const {entities:_0xdcfae,raw:_0x44c7f2}=await this['getRawAndEntities']();return await Promise[_0x2dc0d5(0x1be)](_0xdcfae[_0x2dc0d5(0x20c)](async(_0x3dd3ed,_0x484fb8)=>{const _0x16d78f=_0x2dc0d5;var _0x243060;const _0x4db30d=(0x0,core_1[_0x16d78f(0x21e)])(exports[_0x16d78f(0x1c7)],_0x3dd3ed)||{};for(const _0xd1e305 in _0x4db30d){_0x44c7f2[_0x484fb8]&&_0x44c7f2[_0x484fb8]['hasOwnProperty'](_0xd1e305)&&(_0x3dd3ed[_0xd1e305]=_0x44c7f2[_0x484fb8][_0xd1e305]||((_0x243060=_0x4db30d[_0xd1e305])===null||_0x243060===void 0x0?void 0x0:_0x243060[_0x16d78f(0x215)])||'');}return _0x3dd3ed&&typeof this[_0x16d78f(0x216)]=='function'&&(_0x3dd3ed=await this[_0x16d78f(0x216)](_0x3dd3ed)),_0x3dd3ed;}));},typeorm_2[a13_0x4b66cc(0x1f3)]['prototype'][a13_0x4b66cc(0x1ae)]=async function(){const _0x3bfe19=a13_0x4b66cc;return[await this[_0x3bfe19(0x1f0)](),await this[_0x3bfe19(0x1fb)]()];},typeorm_2[a13_0x4b66cc(0x1f3)]['prototype'][a13_0x4b66cc(0x217)]=async function(){const _0x4829b1=a13_0x4b66cc;return[await this[_0x4829b1(0x1f0)](),await this[_0x4829b1(0x22d)]()];},typeorm_2[a13_0x4b66cc(0x1f3)][a13_0x4b66cc(0x20b)][a13_0x4b66cc(0x22d)]=async function(){const _0x1d0535=a13_0x4b66cc;var _0x4ab456,_0x51e46c,_0x5297a6,_0x41d700;if(DriverUtils_1[_0x1d0535(0x208)][_0x1d0535(0x1c1)](this[_0x1d0535(0x225)][_0x1d0535(0x1c5)])){const _0x3de0b4=this[_0x1d0535(0x1e5)]();try{this['expressionMap'][_0x1d0535(0x1b9)]=![];const [_0x1ca8ca,_0x5a57f8]=this[_0x1d0535(0x1c8)]()[_0x1d0535(0x1bf)](undefined)[_0x1d0535(0x230)](undefined)[_0x1d0535(0x1a1)](undefined)[_0x1d0535(0x231)](undefined)[_0x1d0535(0x1d7)](),_0x3a7462=_0x1d0535(0x1a4)+_0x1ca8ca+_0x1d0535(0x1d3)+JSON[_0x1d0535(0x1cb)](_0x5a57f8),_0x4a0589=typeof this['connection'][_0x1d0535(0x1af)][_0x1d0535(0x1e4)]===_0x1d0535(0x207)?this[_0x1d0535(0x225)][_0x1d0535(0x1af)][_0x1d0535(0x1e4)]:{},_0x41c933=_0x4a0589['alwaysEnabled']&&this[_0x1d0535(0x1ad)][_0x1d0535(0x1e4)]||this[_0x1d0535(0x1ad)][_0x1d0535(0x1e4)];let _0x3560c8=undefined,_0x474ad3=![];if(this['connection'][_0x1d0535(0x1c3)]&&_0x41c933)try{_0x3560c8=await this['connection'][_0x1d0535(0x1c3)][_0x1d0535(0x1de)]({'query':_0x3a7462,'identifier':this[_0x1d0535(0x1ad)][_0x1d0535(0x22e)],'duration':this[_0x1d0535(0x1ad)][_0x1d0535(0x1f5)]||_0x4a0589[_0x1d0535(0x1d1)]||0x3e8},_0x3de0b4);if(_0x3560c8&&!this[_0x1d0535(0x225)][_0x1d0535(0x1c3)][_0x1d0535(0x200)](_0x3560c8))return parseInt(((_0x51e46c=(_0x4ab456=JSON[_0x1d0535(0x210)](_0x3560c8[_0x1d0535(0x213)]))===null||_0x4ab456===void 0x0?void 0x0:_0x4ab456[0x0])===null||_0x51e46c===void 0x0?void 0x0:_0x51e46c[_0x1d0535(0x1a8)])||'0');}catch(_0x22c467){if(!_0x4a0589['ignoreErrors'])throw _0x22c467;_0x474ad3=!![];}const _0x42e98d=await _0x3de0b4[_0x1d0535(0x1bd)](_0x1d0535(0x1a4)+_0x1ca8ca,_0x5a57f8,!![]);if(!_0x474ad3&&this[_0x1d0535(0x225)][_0x1d0535(0x1c3)]&&_0x41c933)try{await this[_0x1d0535(0x225)]['queryResultCache'][_0x1d0535(0x1e3)]({'query':_0x3a7462,'time':new Date()[_0x1d0535(0x1e8)](),'identifier':this[_0x1d0535(0x1ad)][_0x1d0535(0x22e)],'duration':this[_0x1d0535(0x1ad)]['cacheDuration']||_0x4a0589[_0x1d0535(0x1d1)]||0x3e8,'result':JSON[_0x1d0535(0x1cb)](_0x42e98d[_0x1d0535(0x21f)])},_0x3560c8,_0x3de0b4);}catch(_0x4d57c4){if(!_0x4a0589['ignoreErrors'])throw _0x4d57c4;}return parseInt(((_0x41d700=(_0x5297a6=_0x42e98d[_0x1d0535(0x21f)])===null||_0x5297a6===void 0x0?void 0x0:_0x5297a6[0x0])===null||_0x41d700===void 0x0?void 0x0:_0x41d700[_0x1d0535(0x1a8)])||'0');}catch(_0x39912a){throw _0x39912a;}finally{_0x3de0b4!==this[_0x1d0535(0x21c)]&&await _0x3de0b4[_0x1d0535(0x1ee)]();}}else return this['getCount']();},typeorm_2['SelectQueryBuilder'][a13_0x4b66cc(0x20b)]['joinAppends']=function(_0x38c988,_0x525288){const _0x47ff66=a13_0x4b66cc;_0x38c988[_0x47ff66(0x1f1)](this['alias']+'.')&&(_0x38c988=_0x38c988[_0x47ff66(0x203)]((this['alias']+'.')[_0x47ff66(0x227)]));const _0x2f2765=typeof _0x525288==_0x47ff66(0x228)?{'alias':_0x525288}:_0x525288,_0x1b6eda=this[_0x47ff66(0x1ad)][_0x47ff66(0x22c)][_0x47ff66(0x1bc)],_0x1842ab=(0x0,typeorm_1[_0x47ff66(0x206)])(),_0x52aa34=_0x1842ab[_0x47ff66(0x1ff)]['find'](_0x5de83b=>_0x5de83b[_0x47ff66(0x1fd)]==_0x1b6eda[_0x47ff66(0x1fd)]&&_0x5de83b['propertyName']==_0x38c988);if((_0x1b6eda===null||_0x1b6eda===void 0x0?void 0x0:_0x1b6eda['target'])&&(_0x52aa34===null||_0x52aa34===void 0x0?void 0x0:_0x52aa34[_0x47ff66(0x1b4)])){!this[_0x47ff66(0x1fa)]&&(this['_appends']=[]);if(_0x52aa34[_0x47ff66(0x1fe)]==_0x47ff66(0x1a0)||_0x52aa34['relationType']==_0x47ff66(0x1ba)){const _0x17c0ac=_0x1842ab[_0x47ff66(0x1ed)][_0x47ff66(0x220)](_0x350650=>_0x350650['target']==_0x1b6eda[_0x47ff66(0x1fd)]&&_0x350650[_0x47ff66(0x1b4)]==_0x38c988);_0x52aa34[_0x47ff66(0x1b4)]==(_0x17c0ac===null||_0x17c0ac===void 0x0?void 0x0:_0x17c0ac['propertyName'])&&(!this[_0x47ff66(0x1fa)]['find'](_0x4d19ed=>_0x4d19ed[_0x47ff66(0x221)]==((_0x2f2765===null||_0x2f2765===void 0x0?void 0x0:_0x2f2765[_0x47ff66(0x221)])||_0x38c988))&&this[_0x47ff66(0x1fa)][_0x47ff66(0x1f8)]({'alias':(_0x2f2765===null||_0x2f2765===void 0x0?void 0x0:_0x2f2765[_0x47ff66(0x221)])||_0x38c988,'relation':_0x52aa34,'joinColumn':_0x17c0ac,'findOption':(_0x2f2765===null||_0x2f2765===void 0x0?void 0x0:_0x2f2765[_0x47ff66(0x1ab)])||undefined}));}else{if(_0x52aa34[_0x47ff66(0x1fe)]==_0x47ff66(0x1d0))try{const _0x54b5e6=_0x1842ab[_0x47ff66(0x1ff)][_0x47ff66(0x220)](_0x4fa558=>_0x4fa558['target']==_0x52aa34[_0x47ff66(0x229)](_0x52aa34[_0x47ff66(0x1b4)])&&_0x4fa558[_0x47ff66(0x229)](_0x4fa558[_0x47ff66(0x1fe)])==_0x1b6eda[_0x47ff66(0x1fd)]),_0x2a79b7=_0x1842ab[_0x47ff66(0x1ed)][_0x47ff66(0x220)](_0x3898c0=>_0x3898c0['target']==_0x54b5e6[_0x47ff66(0x1fd)]&&_0x3898c0[_0x47ff66(0x1b4)]==_0x54b5e6[_0x47ff66(0x1b4)]);_0x54b5e6[_0x47ff66(0x1b4)]==(_0x2a79b7===null||_0x2a79b7===void 0x0?void 0x0:_0x2a79b7['propertyName'])&&(!this[_0x47ff66(0x1fa)][_0x47ff66(0x220)](_0x1b8ea1=>_0x1b8ea1['alias']==((_0x2f2765===null||_0x2f2765===void 0x0?void 0x0:_0x2f2765[_0x47ff66(0x221)])||_0x38c988))&&this['_appends']['push']({'alias':(_0x2f2765===null||_0x2f2765===void 0x0?void 0x0:_0x2f2765[_0x47ff66(0x221)])||_0x38c988,'relation':_0x52aa34,'joinColumn':_0x2a79b7,'findOption':(_0x2f2765===null||_0x2f2765===void 0x0?void 0x0:_0x2f2765[_0x47ff66(0x1ab)])||undefined}));}catch(_0x2aff29){}}}return this;},typeorm_2['SelectQueryBuilder'][a13_0x4b66cc(0x20b)][a13_0x4b66cc(0x216)]=async function(_0x32ee80){const _0x340197=a13_0x4b66cc;var _0xc4d5fe,_0x50ab21,_0x6e2fb5,_0x9e824d;for(const _0x5a1ca7 of this[_0x340197(0x1fa)]||[]){if(!((_0xc4d5fe=_0x5a1ca7===null||_0x5a1ca7===void 0x0?void 0x0:_0x5a1ca7['relation'])===null||_0xc4d5fe===void 0x0?void 0x0:_0xc4d5fe[_0x340197(0x1fe)]))continue;if(!((_0x50ab21=_0x5a1ca7===null||_0x5a1ca7===void 0x0?void 0x0:_0x5a1ca7[_0x340197(0x1e1)])===null||_0x50ab21===void 0x0?void 0x0:_0x50ab21[_0x340197(0x1c9)])||!((_0x6e2fb5=_0x5a1ca7===null||_0x5a1ca7===void 0x0?void 0x0:_0x5a1ca7[_0x340197(0x1e1)])===null||_0x6e2fb5===void 0x0?void 0x0:_0x6e2fb5[_0x340197(0x22f)]))continue;if(!_0x32ee80[_0x5a1ca7[_0x340197(0x1e1)][_0x340197(0x22f)]])continue;if(typeof((_0x9e824d=_0x5a1ca7===null||_0x5a1ca7===void 0x0?void 0x0:_0x5a1ca7[_0x340197(0x1a3)])===null||_0x9e824d===void 0x0?void 0x0:_0x9e824d[_0x340197(0x229)])!=_0x340197(0x1c6))continue;if(_0x5a1ca7[_0x340197(0x1a3)]['relationType']==_0x340197(0x1a0)||_0x5a1ca7['relation'][_0x340197(0x1fe)]==_0x340197(0x1ba)){const _0x559ba7=this[_0x340197(0x225)]['createQueryBuilder'](_0x5a1ca7[_0x340197(0x1a3)][_0x340197(0x229)](_0x5a1ca7[_0x340197(0x1a3)][_0x340197(0x1fe)]),_0x5a1ca7[_0x340197(0x1a3)][_0x340197(0x1b4)])[_0x340197(0x1ac)]();(_0x5a1ca7===null||_0x5a1ca7===void 0x0?void 0x0:_0x5a1ca7[_0x340197(0x1ab)])&&_0x559ba7['setFindOptions']({..._0x5a1ca7[_0x340197(0x1ab)],'skip':0x0,'take':0x1}),_0x32ee80[_0x5a1ca7[_0x340197(0x221)]]=await _0x559ba7[_0x340197(0x1b2)](_0x559ba7[_0x340197(0x221)]+'.'+_0x5a1ca7[_0x340197(0x1e1)][_0x340197(0x22f)]+_0x340197(0x1c2)+_0x5a1ca7[_0x340197(0x1e1)][_0x340197(0x22f)],{[_0x5a1ca7[_0x340197(0x1e1)][_0x340197(0x22f)]]:_0x32ee80[_0x5a1ca7['joinColumn'][_0x340197(0x1c9)]]})[_0x340197(0x212)]();}else{if(_0x5a1ca7[_0x340197(0x1a3)]['relationType']==_0x340197(0x1d0)||_0x5a1ca7[_0x340197(0x1a3)]['relationType']=='many-to-many'){const _0x26d7cd=this[_0x340197(0x225)][_0x340197(0x1b7)](_0x5a1ca7[_0x340197(0x1a3)][_0x340197(0x229)](_0x5a1ca7[_0x340197(0x1a3)][_0x340197(0x1fe)]),_0x5a1ca7[_0x340197(0x1a3)][_0x340197(0x1b4)])[_0x340197(0x1ac)]();(_0x5a1ca7===null||_0x5a1ca7===void 0x0?void 0x0:_0x5a1ca7[_0x340197(0x1ab)])&&_0x26d7cd[_0x340197(0x1cc)]({'skip':0x0,'take':0xa,..._0x5a1ca7[_0x340197(0x1ab)]}),_0x32ee80[_0x5a1ca7[_0x340197(0x221)]]=await _0x26d7cd[_0x340197(0x1b2)](_0x26d7cd[_0x340197(0x221)]+'.'+_0x5a1ca7['joinColumn']['name']+'\x20=\x20:'+_0x5a1ca7[_0x340197(0x1e1)]['name'],{[_0x5a1ca7['joinColumn'][_0x340197(0x1c9)]]:_0x32ee80[_0x5a1ca7[_0x340197(0x1e1)][_0x340197(0x22f)]]})[_0x340197(0x1f0)]();}}}return _0x32ee80;};
|
|
1
|
+
const a14_0x6530c6=a14_0x37f7;(function(_0x47ef88,_0x5faa0f){const _0x237719=a14_0x37f7,_0x11be2f=_0x47ef88();while(!![]){try{const _0x3db43b=-parseInt(_0x237719(0x180))/0x1+-parseInt(_0x237719(0x178))/0x2+-parseInt(_0x237719(0x170))/0x3*(-parseInt(_0x237719(0x183))/0x4)+-parseInt(_0x237719(0x118))/0x5+parseInt(_0x237719(0x147))/0x6*(-parseInt(_0x237719(0x16d))/0x7)+-parseInt(_0x237719(0x119))/0x8+-parseInt(_0x237719(0x11c))/0x9*(-parseInt(_0x237719(0x122))/0xa);if(_0x3db43b===_0x5faa0f)break;else _0x11be2f['push'](_0x11be2f['shift']());}catch(_0x30d2b0){_0x11be2f['push'](_0x11be2f['shift']());}}}(a14_0x1da7,0xbd13d));const a14_0xdad606=(function(){let _0x1ff850=!![];return function(_0x4bd099,_0x5116d4){const _0x19482c=_0x1ff850?function(){if(_0x5116d4){const _0x8b0f66=_0x5116d4['apply'](_0x4bd099,arguments);return _0x5116d4=null,_0x8b0f66;}}:function(){};return _0x1ff850=![],_0x19482c;};}()),a14_0xc5fa90=a14_0xdad606(this,function(){const _0xeb3f68=a14_0x37f7;return a14_0xc5fa90[_0xeb3f68(0x133)]()[_0xeb3f68(0x116)](_0xeb3f68(0x176))[_0xeb3f68(0x133)]()[_0xeb3f68(0x16e)](a14_0xc5fa90)[_0xeb3f68(0x116)](_0xeb3f68(0x176));});a14_0xc5fa90();'use strict';Object[a14_0x6530c6(0x148)](exports,a14_0x6530c6(0xf9),{'value':!![]}),exports['SearchPaginate']=exports['clearTableExistsCache']=exports[a14_0x6530c6(0x13d)]=exports[a14_0x6530c6(0x140)]=exports['MODEL_SEARCH_SCOPE_KEY']=exports[a14_0x6530c6(0x14d)]=exports['MODEL_KEY']=exports['REPOSITORY_OBSERVE_KEY']=exports[a14_0x6530c6(0x101)]=exports[a14_0x6530c6(0x10b)]=exports[a14_0x6530c6(0x107)]=exports[a14_0x6530c6(0x113)]=exports[a14_0x6530c6(0x15b)]=void 0x0;const stream_1=require(a14_0x6530c6(0x17b)),core_1=require(a14_0x6530c6(0x132)),typeorm_1=require('typeorm'),DriverUtils_1=require('typeorm/driver/DriverUtils'),typeorm_2=require(a14_0x6530c6(0x13e)),typeorm_3=require(a14_0x6530c6(0x13e));require(a14_0x6530c6(0x15a));function a14_0x1da7(){const _0x3580e2=['queryRunner','27921483ZMIpgV','findOption','boolean','joinAppends','number','getQueryAndParameters','10NuXaKi','versionColumn','getTime','size','lockMode','length','alias','immediately','resume','lockVersion','./helper/sleep','close','reject','then','clone','decorator:anncic-api:typeorm:entify:module','@midwayjs/core','toString','rows','mainAlias','propertyName','end','getEntityValue','queryResultCache','default','getRawAndEntities','string','ShardingStrategy','typeorm','skip','ENTITY_VIRTUAL_COLUMN_KEY','getClassMetadata','getMetadataArgsStorage','getOne','splice','decorator:anncic-api:typeorm:model:search:scope','query','12vTduyT','defineProperty','SelectQueryBuilder','options','optimistic','OptimisticLockVersionMismatchError','MODEL_SEARCH_KEY','hasOwnProperty','referencedColumnName','function','emit','decorator:anncic-api:typeorm:entify','getCount','Readable','decorator:anncic-api:typeorm:entify:sharding','\x20--\x20PARAMETERS:\x20','decorator:anncic-api:typeorm:model:search','SearchPaginate','destroy','./interfaceSharding','ENTIFY_KEY','isExpired','metadata','decorator:anncic-api:typeorm:repository','limit','prototype','queryEntity','target','delay','many-to-one','joinColumn','sleep','decorator:anncic-api:typeorm:model','withDeleted','relation','records','stringify','relationType','1188229UANaoE','constructor','getMany','2829ihFNTH','REPOSITORY_OBSERVE_KEY','countsize','getFromCache','cacheDuration','type','(((.+)+)+)+$','cacheId','1882846rvIbNK','clearTableExistsCache','ignoreErrors','stream','parse','andWhere','one-to-one','duration','639954FeKkpG','_joinAppendsResolve','chunk','1156Qwisei','find','obtainQueryRunner','_appends','resolve','setFindOptions','map','connection','joinColumns','push','substring','decorator:anncic-api:typeorm:repository:observe','__esModule','all','take','abs','findOneByOrFail','getManyExplainCount','release','expressionMap','REPOSITORY_KEY','name','data','isArray','EXPLAIN\x20','storeInCache','ENTIFY_MODULE_SOURCE','cache','listenerCount','createQueryBuilder','ENTIFY_SHARDING_KEY','MODEL_KEY','DriverUtils','offset','getExplainCount','startsWith','findOne','EntityManager','ENTIFY_MODULE','one-to-many','EntityNotFoundError','search','relations','2558130fYCPHU','1343648MOOQLK','MODEL_SEARCH_SCOPE_KEY'];a14_0x1da7=function(){return _0x3580e2;};return a14_0x1da7();}const sleep_1=require(a14_0x6530c6(0x12c));exports[a14_0x6530c6(0x15b)]=a14_0x6530c6(0x152),exports[a14_0x6530c6(0x113)]=a14_0x6530c6(0x131),exports['ENTIFY_MODULE_SOURCE']='decorator:anncic-api:typeorm:entify:module:source',exports[a14_0x6530c6(0x10b)]=a14_0x6530c6(0x155),exports[a14_0x6530c6(0x101)]=a14_0x6530c6(0x15e),exports[a14_0x6530c6(0x171)]=a14_0x6530c6(0xf8),exports[a14_0x6530c6(0x10c)]=a14_0x6530c6(0x167),exports['MODEL_SEARCH_KEY']=a14_0x6530c6(0x157),exports[a14_0x6530c6(0x11a)]=a14_0x6530c6(0x145),exports['ENTITY_VIRTUAL_COLUMN_KEY']='decorator:anncic-api:typeorm:entity:virtual:column';var interfaceSharding_1=require('./interfaceSharding');Object[a14_0x6530c6(0x148)](exports,'ShardingStrategy',{'enumerable':!![],'get':function(){const _0x4138f6=a14_0x6530c6;return interfaceSharding_1[_0x4138f6(0x13d)];}}),Object[a14_0x6530c6(0x148)](exports,'clearTableExistsCache',{'enumerable':!![],'get':function(){const _0x2b51d2=a14_0x6530c6;return interfaceSharding_1[_0x2b51d2(0x179)];}});function a14_0x37f7(_0x499317,_0x3f0e75){const _0x1f2b33=a14_0x1da7();return a14_0x37f7=function(_0xc5fa90,_0xdad606){_0xc5fa90=_0xc5fa90-0xee;let _0x1da79f=_0x1f2b33[_0xc5fa90];return _0x1da79f;},a14_0x37f7(_0x499317,_0x3f0e75);}class SearchPaginate{}exports[a14_0x6530c6(0x158)]=SearchPaginate,typeorm_2[a14_0x6530c6(0x149)][a14_0x6530c6(0x160)][a14_0x6530c6(0x182)]=function(_0x22fa5d=0x64,_0x5812de){const _0x2dd810=a14_0x6530c6;let _0x55e0f3=0x1,_0x378d5d=0x64,_0x23ad17=0x0,_0x5497cc=0x0,_0x28c0ed=![],_0x234703=!![];if(typeof _0x22fa5d=='number'||typeof _0x22fa5d==_0x2dd810(0x13c))_0x378d5d=parseInt(''+_0x22fa5d);else _0x22fa5d&&((_0x22fa5d===null||_0x22fa5d===void 0x0?void 0x0:_0x22fa5d['size'])&&(_0x378d5d=parseInt(''+_0x22fa5d[_0x2dd810(0x125)])),(_0x22fa5d===null||_0x22fa5d===void 0x0?void 0x0:_0x22fa5d[_0x2dd810(0x172)])&&(_0x23ad17=parseInt(''+_0x22fa5d[_0x2dd810(0x172)])),(_0x22fa5d===null||_0x22fa5d===void 0x0?void 0x0:_0x22fa5d[_0x2dd810(0x163)])&&(_0x28c0ed=typeof _0x22fa5d[_0x2dd810(0x163)]==_0x2dd810(0x11e)?0x1f4:parseInt(''+_0x22fa5d[_0x2dd810(0x163)])),typeof(_0x22fa5d===null||_0x22fa5d===void 0x0?void 0x0:_0x22fa5d['immediately'])=='boolean'&&(_0x234703=_0x22fa5d[_0x2dd810(0x129)]));_0x23ad17>0x0&&_0x23ad17>_0x378d5d&&(_0x378d5d=_0x23ad17);const _0x2fc30b=this,_0x1a9196=new stream_1[(_0x2dd810(0x154))]({'objectMode':!![],'highWaterMark':_0x378d5d*0x2,async 'read'(){const _0x12ec7e=_0x2dd810;try{if(_0x23ad17>0x0&&_0x23ad17<=_0x5497cc)this[_0x12ec7e(0x109)](_0x12ec7e(0x103))>0x0?this['push'](null):this['emit'](_0x12ec7e(0x137));else{const _0x518985=_0x2fc30b[_0x12ec7e(0x130)]()['limit'](Math[_0x12ec7e(0xfc)](_0x378d5d))['offset']((Math['abs'](_0x55e0f3)-0x1)*Math[_0x12ec7e(0xfc)](_0x378d5d)),_0x30fb01=await _0x518985['getMany']();if((_0x30fb01===null||_0x30fb01===void 0x0?void 0x0:_0x30fb01['length'])>0x0){_0x23ad17>0x0&&_0x5497cc+_0x30fb01[_0x12ec7e(0x127)]>_0x23ad17&&_0x30fb01[_0x12ec7e(0x144)](0x0,_0x23ad17-(_0x5497cc+_0x30fb01[_0x12ec7e(0x127)]-_0x23ad17));if(typeof _0x5812de==_0x12ec7e(0x150)){const _0x22d694=await _0x5812de(_0x30fb01,_0x55e0f3,_0x518985[_0x12ec7e(0x121)]());_0x22d694&&Array[_0x12ec7e(0x104)](_0x22d694)?(_0x22d694===null||_0x22d694===void 0x0?void 0x0:_0x22d694[_0x12ec7e(0x127)])>0x0&&(_0x5497cc+=_0x22d694['length'],_0x23ad17>0x0&&_0x5497cc>_0x23ad17&&_0x22d694[_0x12ec7e(0x144)](0x0,_0x23ad17-(_0x5497cc-_0x23ad17)),this[_0x12ec7e(0xf6)](_0x22d694),_0x22d694[_0x12ec7e(0x127)]=0x0):(_0x5497cc+=_0x30fb01[_0x12ec7e(0x127)],_0x23ad17>0x0&&_0x5497cc>_0x23ad17&&_0x30fb01[_0x12ec7e(0x144)](0x0,_0x23ad17-(_0x5497cc-_0x23ad17)),this['push'](_0x30fb01));}else _0x5497cc+=_0x30fb01['length'],_0x23ad17>0x0&&_0x5497cc>_0x23ad17&&_0x30fb01[_0x12ec7e(0x144)](0x0,_0x23ad17-(_0x5497cc-_0x23ad17)),this[_0x12ec7e(0xf6)](_0x30fb01);_0x30fb01['length']=0x0,_0x55e0f3++,_0x28c0ed&&typeof _0x28c0ed==_0x12ec7e(0x120)&&await(0x0,sleep_1[_0x12ec7e(0x166)])(_0x28c0ed);}else this[_0x12ec7e(0x109)](_0x12ec7e(0x103))>0x0?this[_0x12ec7e(0xf6)](null):this[_0x12ec7e(0x151)](_0x12ec7e(0x137));}}catch(_0x2139be){this[_0x12ec7e(0x159)](_0x2139be);}}});return _0x1a9196['on'](_0x2dd810(0x137),()=>_0x1a9196['destroy']()),_0x1a9196['on'](_0x2dd810(0x12d),()=>_0x1a9196[_0x2dd810(0x159)]()),_0x234703&&_0x1a9196[_0x2dd810(0x12a)](),_0x1a9196;},typeorm_3['EntityManager'][a14_0x6530c6(0x160)]['findOneOrFail']=async function(_0x40e218,_0x297ed6){const _0x1c2159=a14_0x6530c6;return this[_0x1c2159(0x111)](_0x40e218,_0x297ed6)[_0x1c2159(0x12f)](_0x18cf12=>{const _0x4becf4=_0x1c2159;if(_0x18cf12===null||_0x18cf12===undefined)return Promise[_0x4becf4(0x12e)](new typeorm_3[(_0x4becf4(0x115))](_0x40e218,_0x297ed6));return Promise[_0x4becf4(0xf1)](_0x18cf12);});},typeorm_3[a14_0x6530c6(0x112)]['prototype'][a14_0x6530c6(0xfd)]=async function(_0x33f65c,_0x51291b){const _0x43f1e4=a14_0x6530c6;return this['findOneBy'](_0x33f65c,_0x51291b)[_0x43f1e4(0x12f)](_0x50888f=>{const _0x5146d9=_0x43f1e4;if(_0x50888f===null||_0x50888f===undefined)return Promise[_0x5146d9(0x12e)](new typeorm_3[(_0x5146d9(0x115))](_0x33f65c,_0x51291b));return Promise['resolve'](_0x50888f);});},typeorm_2[a14_0x6530c6(0x149)][a14_0x6530c6(0x160)][a14_0x6530c6(0x143)]=async function(){const _0x8973c8=a14_0x6530c6;var _0x472756;const {entities:_0x1cd049,raw:_0x57f740}=await this[_0x8973c8(0x13b)]();if(_0x1cd049[0x0]&&this[_0x8973c8(0x100)][_0x8973c8(0x126)]===_0x8973c8(0x14b)&&this[_0x8973c8(0x100)][_0x8973c8(0x12b)]){const _0x10c892=this[_0x8973c8(0x100)][_0x8973c8(0x135)][_0x8973c8(0x15d)];if(this[_0x8973c8(0x100)]['lockVersion']instanceof Date){const _0x497b39=_0x10c892['updateDateColumn'][_0x8973c8(0x138)](_0x1cd049[0x0]);if(_0x497b39[_0x8973c8(0x124)]()!==this['expressionMap'][_0x8973c8(0x12b)][_0x8973c8(0x124)]())throw new typeorm_2['OptimisticLockVersionMismatchError'](_0x10c892[_0x8973c8(0x102)],this[_0x8973c8(0x100)]['lockVersion'],_0x497b39);}else{const _0x18851e=_0x10c892[_0x8973c8(0x123)][_0x8973c8(0x138)](_0x1cd049[0x0]);if(_0x18851e!==this[_0x8973c8(0x100)][_0x8973c8(0x12b)])throw new typeorm_2[(_0x8973c8(0x14c))](_0x10c892[_0x8973c8(0x102)],this[_0x8973c8(0x100)][_0x8973c8(0x12b)],_0x18851e);}}if(_0x1cd049[0x0]&&_0x57f740[0x0]){const _0x1d725d=(0x0,core_1[_0x8973c8(0x141)])(exports[_0x8973c8(0x140)],_0x1cd049[0x0]);for(const _0x5a89f5 in _0x1d725d){_0x57f740[0x0][_0x8973c8(0x14e)](_0x5a89f5)&&(_0x1cd049[0x0][_0x5a89f5]=_0x57f740[0x0][_0x5a89f5]||((_0x472756=_0x1d725d[_0x5a89f5])===null||_0x472756===void 0x0?void 0x0:_0x472756[_0x8973c8(0x13a)])||'');}}return _0x1cd049[0x0]&&typeof this[_0x8973c8(0x181)]=='function'&&(_0x1cd049[0x0]=await this['_joinAppendsResolve'](_0x1cd049[0x0])),_0x1cd049[0x0]||null;},typeorm_2['SelectQueryBuilder'][a14_0x6530c6(0x160)][a14_0x6530c6(0x16f)]=async function(){const _0x3a4342=a14_0x6530c6;if(this[_0x3a4342(0x100)]['lockMode']===_0x3a4342(0x14b))throw new typeorm_2['OptimisticLockCanNotBeUsedError']();const {entities:_0x544c03,raw:_0x18f400}=await this[_0x3a4342(0x13b)]();return await Promise[_0x3a4342(0xfa)](_0x544c03[_0x3a4342(0xf3)](async(_0x4286ad,_0x4886c8)=>{const _0x58cb07=_0x3a4342;var _0x440e52;const _0x1878da=(0x0,core_1[_0x58cb07(0x141)])(exports['ENTITY_VIRTUAL_COLUMN_KEY'],_0x4286ad)||{};for(const _0x1a073b in _0x1878da){_0x18f400[_0x4886c8]&&_0x18f400[_0x4886c8][_0x58cb07(0x14e)](_0x1a073b)&&(_0x4286ad[_0x1a073b]=_0x18f400[_0x4886c8][_0x1a073b]||((_0x440e52=_0x1878da[_0x1a073b])===null||_0x440e52===void 0x0?void 0x0:_0x440e52[_0x58cb07(0x13a)])||'');}return _0x4286ad&&typeof this[_0x58cb07(0x181)]=='function'&&(_0x4286ad=await this['_joinAppendsResolve'](_0x4286ad)),_0x4286ad;}));},typeorm_2[a14_0x6530c6(0x149)]['prototype']['getManyAndCount']=async function(){const _0x51e0c5=a14_0x6530c6;return[await this['getMany'](),await this[_0x51e0c5(0x153)]()];},typeorm_2[a14_0x6530c6(0x149)][a14_0x6530c6(0x160)][a14_0x6530c6(0xfe)]=async function(){const _0x163d56=a14_0x6530c6;return[await this[_0x163d56(0x16f)](),await this['getExplainCount']()];},typeorm_2[a14_0x6530c6(0x149)]['prototype'][a14_0x6530c6(0x10f)]=async function(){const _0x8aa7a8=a14_0x6530c6;var _0x53feea,_0x2e371d,_0x259cc9,_0x256e38;if(DriverUtils_1[_0x8aa7a8(0x10d)]['isMySQLFamily'](this['connection']['driver'])){const _0x4322b5=this[_0x8aa7a8(0xef)]();try{this['expressionMap'][_0x8aa7a8(0x161)]=![];const [_0x57817a,_0x4ec5d1]=this[_0x8aa7a8(0x130)]()[_0x8aa7a8(0x10e)](undefined)[_0x8aa7a8(0x15f)](undefined)[_0x8aa7a8(0x13f)](undefined)[_0x8aa7a8(0xfb)](undefined)[_0x8aa7a8(0x121)](),_0x141651=_0x8aa7a8(0x105)+_0x57817a+_0x8aa7a8(0x156)+JSON[_0x8aa7a8(0x16b)](_0x4ec5d1),_0x1cb3a4=typeof this[_0x8aa7a8(0xf4)][_0x8aa7a8(0x14a)][_0x8aa7a8(0x108)]==='object'?this['connection'][_0x8aa7a8(0x14a)][_0x8aa7a8(0x108)]:{},_0x14f5d2=_0x1cb3a4['alwaysEnabled']&&this[_0x8aa7a8(0x100)]['cache']||this[_0x8aa7a8(0x100)][_0x8aa7a8(0x108)];let _0x142b8f=undefined,_0x2bd966=![];if(this['connection'][_0x8aa7a8(0x139)]&&_0x14f5d2)try{_0x142b8f=await this[_0x8aa7a8(0xf4)][_0x8aa7a8(0x139)][_0x8aa7a8(0x173)]({'query':_0x141651,'identifier':this[_0x8aa7a8(0x100)]['cacheId'],'duration':this[_0x8aa7a8(0x100)][_0x8aa7a8(0x174)]||_0x1cb3a4[_0x8aa7a8(0x17f)]||0x3e8},_0x4322b5);if(_0x142b8f&&!this['connection'][_0x8aa7a8(0x139)][_0x8aa7a8(0x15c)](_0x142b8f))return parseInt(((_0x2e371d=(_0x53feea=JSON[_0x8aa7a8(0x17c)](_0x142b8f['result']))===null||_0x53feea===void 0x0?void 0x0:_0x53feea[0x0])===null||_0x2e371d===void 0x0?void 0x0:_0x2e371d[_0x8aa7a8(0x134)])||'0');}catch(_0x230c2e){if(!_0x1cb3a4[_0x8aa7a8(0x17a)])throw _0x230c2e;_0x2bd966=!![];}const _0x34879a=await _0x4322b5[_0x8aa7a8(0x146)](_0x8aa7a8(0x105)+_0x57817a,_0x4ec5d1,!![]);if(!_0x2bd966&&this[_0x8aa7a8(0xf4)][_0x8aa7a8(0x139)]&&_0x14f5d2)try{await this[_0x8aa7a8(0xf4)][_0x8aa7a8(0x139)][_0x8aa7a8(0x106)]({'query':_0x141651,'time':new Date()['getTime'](),'identifier':this[_0x8aa7a8(0x100)][_0x8aa7a8(0x177)],'duration':this[_0x8aa7a8(0x100)][_0x8aa7a8(0x174)]||_0x1cb3a4['duration']||0x3e8,'result':JSON[_0x8aa7a8(0x16b)](_0x34879a[_0x8aa7a8(0x16a)])},_0x142b8f,_0x4322b5);}catch(_0x427085){if(!_0x1cb3a4[_0x8aa7a8(0x17a)])throw _0x427085;}return parseInt(((_0x256e38=(_0x259cc9=_0x34879a[_0x8aa7a8(0x16a)])===null||_0x259cc9===void 0x0?void 0x0:_0x259cc9[0x0])===null||_0x256e38===void 0x0?void 0x0:_0x256e38[_0x8aa7a8(0x134)])||'0');}catch(_0x3ee2e4){throw _0x3ee2e4;}finally{_0x4322b5!==this[_0x8aa7a8(0x11b)]&&await _0x4322b5[_0x8aa7a8(0xff)]();}}else return this['getCount']();},typeorm_2['SelectQueryBuilder']['prototype'][a14_0x6530c6(0x11f)]=function(_0x3988a1,_0x189ea2){const _0x39a172=a14_0x6530c6;_0x3988a1[_0x39a172(0x110)](this['alias']+'.')&&(_0x3988a1=_0x3988a1[_0x39a172(0xf7)]((this[_0x39a172(0x128)]+'.')[_0x39a172(0x127)]));const _0x52e031=typeof _0x189ea2==_0x39a172(0x13c)?{'alias':_0x189ea2}:_0x189ea2,_0x2a750a=this[_0x39a172(0x100)]['mainAlias']['metadata'],_0xae6e88=(0x0,typeorm_1[_0x39a172(0x142)])(),_0xf04bca=_0xae6e88['relations'][_0x39a172(0xee)](_0x2e7c76=>_0x2e7c76['target']==_0x2a750a[_0x39a172(0x162)]&&_0x2e7c76['propertyName']==_0x3988a1);if((_0x2a750a===null||_0x2a750a===void 0x0?void 0x0:_0x2a750a[_0x39a172(0x162)])&&(_0xf04bca===null||_0xf04bca===void 0x0?void 0x0:_0xf04bca['propertyName'])){!this[_0x39a172(0xf0)]&&(this[_0x39a172(0xf0)]=[]);if(_0xf04bca[_0x39a172(0x16c)]=='many-to-one'||_0xf04bca['relationType']==_0x39a172(0x17e)){const _0x590d4f=_0xae6e88[_0x39a172(0xf5)][_0x39a172(0xee)](_0x308628=>_0x308628['target']==_0x2a750a[_0x39a172(0x162)]&&_0x308628['propertyName']==_0x3988a1);_0xf04bca[_0x39a172(0x136)]==(_0x590d4f===null||_0x590d4f===void 0x0?void 0x0:_0x590d4f[_0x39a172(0x136)])&&(!this[_0x39a172(0xf0)]['find'](_0x1123f9=>_0x1123f9[_0x39a172(0x128)]==((_0x52e031===null||_0x52e031===void 0x0?void 0x0:_0x52e031[_0x39a172(0x128)])||_0x3988a1))&&this[_0x39a172(0xf0)]['push']({'alias':(_0x52e031===null||_0x52e031===void 0x0?void 0x0:_0x52e031[_0x39a172(0x128)])||_0x3988a1,'relation':_0xf04bca,'joinColumn':_0x590d4f,'findOption':(_0x52e031===null||_0x52e031===void 0x0?void 0x0:_0x52e031[_0x39a172(0x11d)])||undefined}));}else{if(_0xf04bca[_0x39a172(0x16c)]==_0x39a172(0x114))try{const _0x281fcc=_0xae6e88[_0x39a172(0x117)][_0x39a172(0xee)](_0x434678=>_0x434678[_0x39a172(0x162)]==_0xf04bca[_0x39a172(0x175)](_0xf04bca[_0x39a172(0x136)])&&_0x434678[_0x39a172(0x175)](_0x434678[_0x39a172(0x16c)])==_0x2a750a[_0x39a172(0x162)]),_0xb6742=_0xae6e88[_0x39a172(0xf5)][_0x39a172(0xee)](_0x199fe7=>_0x199fe7[_0x39a172(0x162)]==_0x281fcc['target']&&_0x199fe7[_0x39a172(0x136)]==_0x281fcc[_0x39a172(0x136)]);_0x281fcc['propertyName']==(_0xb6742===null||_0xb6742===void 0x0?void 0x0:_0xb6742['propertyName'])&&(!this['_appends'][_0x39a172(0xee)](_0x14d41c=>_0x14d41c[_0x39a172(0x128)]==((_0x52e031===null||_0x52e031===void 0x0?void 0x0:_0x52e031[_0x39a172(0x128)])||_0x3988a1))&&this['_appends'][_0x39a172(0xf6)]({'alias':(_0x52e031===null||_0x52e031===void 0x0?void 0x0:_0x52e031[_0x39a172(0x128)])||_0x3988a1,'relation':_0xf04bca,'joinColumn':_0xb6742,'findOption':(_0x52e031===null||_0x52e031===void 0x0?void 0x0:_0x52e031[_0x39a172(0x11d)])||undefined}));}catch(_0x30d17a){}}}return this;},typeorm_2[a14_0x6530c6(0x149)][a14_0x6530c6(0x160)][a14_0x6530c6(0x181)]=async function(_0xe702bf){const _0x22a37e=a14_0x6530c6;var _0x5b9e43,_0x371535,_0x2ca52d,_0x54de20;for(const _0x55875b of this[_0x22a37e(0xf0)]||[]){if(!((_0x5b9e43=_0x55875b===null||_0x55875b===void 0x0?void 0x0:_0x55875b[_0x22a37e(0x169)])===null||_0x5b9e43===void 0x0?void 0x0:_0x5b9e43[_0x22a37e(0x16c)]))continue;if(!((_0x371535=_0x55875b===null||_0x55875b===void 0x0?void 0x0:_0x55875b[_0x22a37e(0x165)])===null||_0x371535===void 0x0?void 0x0:_0x371535[_0x22a37e(0x102)])||!((_0x2ca52d=_0x55875b===null||_0x55875b===void 0x0?void 0x0:_0x55875b['joinColumn'])===null||_0x2ca52d===void 0x0?void 0x0:_0x2ca52d[_0x22a37e(0x14f)]))continue;if(!_0xe702bf[_0x55875b['joinColumn'][_0x22a37e(0x14f)]])continue;if(typeof((_0x54de20=_0x55875b===null||_0x55875b===void 0x0?void 0x0:_0x55875b[_0x22a37e(0x169)])===null||_0x54de20===void 0x0?void 0x0:_0x54de20['type'])!='function')continue;if(_0x55875b[_0x22a37e(0x169)][_0x22a37e(0x16c)]==_0x22a37e(0x164)||_0x55875b[_0x22a37e(0x169)]['relationType']==_0x22a37e(0x17e)){const _0x5e600d=this[_0x22a37e(0xf4)][_0x22a37e(0x10a)](_0x55875b[_0x22a37e(0x169)][_0x22a37e(0x175)](_0x55875b['relation']['relationType']),_0x55875b[_0x22a37e(0x169)][_0x22a37e(0x136)])['withDeleted']();(_0x55875b===null||_0x55875b===void 0x0?void 0x0:_0x55875b[_0x22a37e(0x11d)])&&_0x5e600d['setFindOptions']({..._0x55875b[_0x22a37e(0x11d)],'skip':0x0,'take':0x1}),_0xe702bf[_0x55875b[_0x22a37e(0x128)]]=await _0x5e600d[_0x22a37e(0x17d)](_0x5e600d['alias']+'.'+_0x55875b[_0x22a37e(0x165)][_0x22a37e(0x14f)]+'\x20=\x20:'+_0x55875b['joinColumn'][_0x22a37e(0x14f)],{[_0x55875b[_0x22a37e(0x165)][_0x22a37e(0x14f)]]:_0xe702bf[_0x55875b[_0x22a37e(0x165)][_0x22a37e(0x102)]]})[_0x22a37e(0x143)]();}else{if(_0x55875b['relation'][_0x22a37e(0x16c)]=='one-to-many'||_0x55875b[_0x22a37e(0x169)]['relationType']=='many-to-many'){const _0x3a3bb7=this[_0x22a37e(0xf4)][_0x22a37e(0x10a)](_0x55875b[_0x22a37e(0x169)][_0x22a37e(0x175)](_0x55875b['relation']['relationType']),_0x55875b[_0x22a37e(0x169)]['propertyName'])[_0x22a37e(0x168)]();(_0x55875b===null||_0x55875b===void 0x0?void 0x0:_0x55875b['findOption'])&&_0x3a3bb7[_0x22a37e(0xf2)]({'skip':0x0,'take':0xa,..._0x55875b[_0x22a37e(0x11d)]}),_0xe702bf[_0x55875b['alias']]=await _0x3a3bb7[_0x22a37e(0x17d)](_0x3a3bb7[_0x22a37e(0x128)]+'.'+_0x55875b[_0x22a37e(0x165)][_0x22a37e(0x102)]+'\x20=\x20:'+_0x55875b[_0x22a37e(0x165)][_0x22a37e(0x102)],{[_0x55875b['joinColumn'][_0x22a37e(0x102)]]:_0xe702bf[_0x55875b[_0x22a37e(0x165)][_0x22a37e(0x14f)]]})[_0x22a37e(0x16f)]();}}}return _0xe702bf;};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { DataSource, EntityManager, EntityMetadata } from "typeorm";
|
|
2
|
+
export interface ShardingContext {
|
|
3
|
+
entity: Function;
|
|
4
|
+
baseTableName: string;
|
|
5
|
+
dataSource: DataSource;
|
|
6
|
+
entityMetadata: EntityMetadata;
|
|
7
|
+
manager: EntityManager;
|
|
8
|
+
}
|
|
9
|
+
export declare abstract class ShardingStrategy {
|
|
10
|
+
getTableName?(baseTableName: string, queryParams: any): string;
|
|
11
|
+
getSelectTableName?(baseTableName: string, queryParams: any): string;
|
|
12
|
+
getInsertTableName?(baseTableName: string, queryParams: any): string;
|
|
13
|
+
getUpdateTableName?(baseTableName: string, queryParams: any): string;
|
|
14
|
+
getDeleteTableName?(baseTableName: string, queryParams: any): string;
|
|
15
|
+
getPreCreateTableNames?(baseTableName: string): string[] | Promise<string[]>;
|
|
16
|
+
createTables?(ctx: ShardingContext, tableName: string): boolean | Promise<boolean>;
|
|
17
|
+
checkTableExists(ctx: ShardingContext, tableName: string): Promise<boolean>;
|
|
18
|
+
protected createTableFromMetadata(ctx: ShardingContext, tableName: string): Promise<void>;
|
|
19
|
+
ensureTableExists(ctx: ShardingContext, tableName: string): Promise<void>;
|
|
20
|
+
preCreateTables(ctx: ShardingContext, tableNames?: string[]): Promise<void>;
|
|
21
|
+
}
|
|
22
|
+
export declare function clearTableExistsCache(ds?: DataSource, tableName?: string): void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const a15_0x1a2399=a15_0x16ef;(function(_0x4b860e,_0x5d930a){const _0x3afdc2=a15_0x16ef,_0x10e384=_0x4b860e();while(!![]){try{const _0x4079cc=parseInt(_0x3afdc2(0xb4))/0x1*(parseInt(_0x3afdc2(0xa6))/0x2)+-parseInt(_0x3afdc2(0x7a))/0x3+-parseInt(_0x3afdc2(0x9b))/0x4*(-parseInt(_0x3afdc2(0x80))/0x5)+parseInt(_0x3afdc2(0x7d))/0x6*(parseInt(_0x3afdc2(0x85))/0x7)+-parseInt(_0x3afdc2(0x69))/0x8+parseInt(_0x3afdc2(0xb0))/0x9*(-parseInt(_0x3afdc2(0x82))/0xa)+parseInt(_0x3afdc2(0xa7))/0xb;if(_0x4079cc===_0x5d930a)break;else _0x10e384['push'](_0x10e384['shift']());}catch(_0x28f201){_0x10e384['push'](_0x10e384['shift']());}}}(a15_0x50b0,0xa95c8));const a15_0x5efa00=(function(){let _0x17558a=!![];return function(_0xf58aee,_0x338c6a){const _0x38bb94=_0x17558a?function(){const _0x1b5038=a15_0x16ef;if(_0x338c6a){const _0x4907f3=_0x338c6a[_0x1b5038(0x8d)](_0xf58aee,arguments);return _0x338c6a=null,_0x4907f3;}}:function(){};return _0x17558a=![],_0x38bb94;};}()),a15_0x4b2051=a15_0x5efa00(this,function(){const _0x5eb410=a15_0x16ef;return a15_0x4b2051[_0x5eb410(0x7e)]()['search'](_0x5eb410(0x7f))['toString']()[_0x5eb410(0xaa)](a15_0x4b2051)[_0x5eb410(0x68)](_0x5eb410(0x7f));});a15_0x4b2051();'use strict';function a15_0x16ef(_0x415c1b,_0x8ee270){const _0x2a9306=a15_0x50b0();return a15_0x16ef=function(_0x4b2051,_0x5efa00){_0x4b2051=_0x4b2051-0x67;let _0x50b02a=_0x2a9306[_0x4b2051];return _0x50b02a;},a15_0x16ef(_0x415c1b,_0x8ee270);}Object[a15_0x1a2399(0x94)](exports,a15_0x1a2399(0x86),{'value':!![]}),exports['ShardingStrategy']=void 0x0,exports[a15_0x1a2399(0xa1)]=clearTableExistsCache;const core_1=require(a15_0x1a2399(0xa4)),typeorm_1=require(a15_0x1a2399(0x76)),interface_1=require(a15_0x1a2399(0xb3)),tableExistsCache=new Map(),MAX_CACHE_SIZE=0x3e8;class ShardingStrategy{async[a15_0x1a2399(0x87)](_0x32206a,_0x2953ea){const _0x4b5dfa=a15_0x1a2399;let _0x448c64=tableExistsCache[_0x4b5dfa(0xaf)](_0x32206a[_0x4b5dfa(0xa3)]);if(!_0x448c64)tableExistsCache[_0x4b5dfa(0x8a)](_0x32206a[_0x4b5dfa(0xa3)],_0x448c64=new Map());if(_0x448c64['get'](_0x2953ea))return!![];const _0x3736d9=_0x32206a[_0x4b5dfa(0x99)][_0x4b5dfa(0x6f)][_0x4b5dfa(0x7b)]();try{const _0x4b6c06=await _0x3736d9[_0x4b5dfa(0x95)](_0x2953ea);if(_0x4b6c06){if(_0x448c64['size']>=MAX_CACHE_SIZE)_0x448c64['clear']();_0x448c64[_0x4b5dfa(0x8a)](_0x2953ea,!![]);}return _0x4b6c06;}finally{await _0x3736d9[_0x4b5dfa(0x9e)]();}}async[a15_0x1a2399(0x98)](_0x50c88c,_0x187d62){const _0x441254=a15_0x1a2399;var _0xa21ccd;const _0x43659f=_0x50c88c[_0x441254(0x99)][_0x441254(0x6f)][_0x441254(0x7b)]();try{const _0x4fdd9c=Object[_0x441254(0x84)](Object[_0x441254(0x8f)](Object[_0x441254(0xad)](_0x50c88c['entityMetadata'])),_0x50c88c['entityMetadata']);Object['defineProperty'](_0x4fdd9c,'tableName',{'get':()=>_0x187d62,'enumerable':!![],'configurable':!![]});const _0x6ad8ec=typeorm_1[_0x441254(0x96)]['create'](_0x4fdd9c,_0x50c88c['dataSource'][_0x441254(0x7c)]);_0x6ad8ec['columns'][_0x441254(0x91)](_0x5d88a2=>_0x5d88a2[_0x441254(0x93)]=![]),_0x6ad8ec['indices']=_0x6ad8ec[_0x441254(0x90)][_0x441254(0x8c)](_0x411ca9=>!_0x411ca9[_0x441254(0x93)]),await _0x43659f[_0x441254(0xb2)](_0x6ad8ec,!![],![]),(_0xa21ccd=tableExistsCache[_0x441254(0xaf)](_0x50c88c['dataSource']))===null||_0xa21ccd===void 0x0?void 0x0:_0xa21ccd[_0x441254(0x8a)](_0x187d62,!![]);}finally{await _0x43659f['release']();}}async[a15_0x1a2399(0x81)](_0x396aa1,_0x2526a1){const _0x29e9ea=a15_0x1a2399;if(await this[_0x29e9ea(0x87)](_0x396aa1,_0x2526a1))return;let _0x1509ad=![];if(this[_0x29e9ea(0x77)])try{_0x1509ad=await this['createTables'](_0x396aa1,_0x2526a1);}catch{}!_0x1509ad&&!await this[_0x29e9ea(0x87)](_0x396aa1,_0x2526a1)&&await this[_0x29e9ea(0x98)](_0x396aa1,_0x2526a1);}async[a15_0x1a2399(0x74)](_0x1fbd45,_0x3fde02){const _0x390acd=a15_0x1a2399;var _0xc0e2d4;const _0x2dde3e=_0x3fde02||await((_0xc0e2d4=this[_0x390acd(0x70)])===null||_0xc0e2d4===void 0x0?void 0x0:_0xc0e2d4[_0x390acd(0x83)](this,_0x1fbd45['baseTableName']))||[];for(const _0xa4dc3a of _0x2dde3e){if(_0xa4dc3a&&_0xa4dc3a!==_0x1fbd45['baseTableName'])await this[_0x390acd(0x81)](_0x1fbd45,_0xa4dc3a);}}}exports[a15_0x1a2399(0xac)]=ShardingStrategy;const METHODS=[a15_0x1a2399(0xa2),a15_0x1a2399(0x73),a15_0x1a2399(0x6b),a15_0x1a2399(0x8e)];function getQueryType(_0x110019){const _0x316492=a15_0x1a2399;return _0x110019 instanceof typeorm_1[_0x316492(0x79)]?0x0:_0x110019 instanceof typeorm_1[_0x316492(0x89)]?0x1:_0x110019 instanceof typeorm_1[_0x316492(0xa5)]?0x2:0x3;}function resolveTableName(_0x49a624,_0x355d03,_0x1d6b3c,_0x3586a1){const _0x46c7bb=a15_0x1a2399;var _0x15a01e,_0x36ba6e;const _0x8029db=_0x49a624[METHODS[_0x3586a1]];if(_0x8029db)return _0x8029db['call'](_0x49a624,_0x355d03,_0x1d6b3c);return(_0x36ba6e=(_0x15a01e=_0x49a624[_0x46c7bb(0x9a)])===null||_0x15a01e===void 0x0?void 0x0:_0x15a01e[_0x46c7bb(0x83)](_0x49a624,_0x355d03,_0x1d6b3c))!==null&&_0x36ba6e!==void 0x0?_0x36ba6e:null;}function getShardingMeta(_0x4dc9c6){const _0x2694b9=a15_0x1a2399;var _0x5f3afb;const _0x40c35c=(0x0,core_1[_0x2694b9(0xb1)])(interface_1[_0x2694b9(0x71)],_0x4dc9c6);if(!(_0x40c35c===null||_0x40c35c===void 0x0?void 0x0:_0x40c35c[_0x2694b9(0x78)]))return null;return{'strategy':_0x40c35c['strategy'],'tableName':(_0x5f3afb=(0x0,core_1[_0x2694b9(0xb1)])(interface_1[_0x2694b9(0x88)],_0x4dc9c6))===null||_0x5f3afb===void 0x0?void 0x0:_0x5f3afb['tableName']};}function getShardingTableNameSync(_0xebb5a2,_0x486962){const _0x312a49=a15_0x1a2399;var _0x4a6394,_0xbe47ab,_0x16772f,_0x187d08,_0x1119b6,_0x1abaa4;const _0x895b67=(_0x16772f=(_0xbe47ab=(_0x4a6394=_0xebb5a2['expressionMap'])===null||_0x4a6394===void 0x0?void 0x0:_0x4a6394[_0x312a49(0x6a)])===null||_0xbe47ab===void 0x0?void 0x0:_0xbe47ab[_0x312a49(0x6e)](_0x1df4e4=>{const _0x28738a=_0x312a49;var _0x578607;return _0x1df4e4[_0x28738a(0xa8)]===_0x486962||((_0x578607=_0x1df4e4[_0x28738a(0x92)])===null||_0x578607===void 0x0?void 0x0:_0x578607[_0x28738a(0x97)])===_0x486962;}))===null||_0x16772f===void 0x0?void 0x0:_0x16772f[_0x312a49(0x92)];if(!(_0x895b67===null||_0x895b67===void 0x0?void 0x0:_0x895b67[_0x312a49(0xae)]))return null;const _0x3f1a7e=getShardingMeta(_0x895b67['target']);if(!_0x3f1a7e)return null;try{const _0x27d29f=(_0x187d08=(0x0,core_1['getCurrentApplicationContext'])())===null||_0x187d08===void 0x0?void 0x0:_0x187d08[_0x312a49(0xaf)](_0x3f1a7e[_0x312a49(0x78)]);if(!_0x27d29f)return null;const _0x41185d=_0x3f1a7e[_0x312a49(0x97)]||_0x895b67[_0x312a49(0x97)],_0x2bac40={...(_0x1119b6=_0xebb5a2[_0x312a49(0x6d)])===null||_0x1119b6===void 0x0?void 0x0:_0x1119b6[_0x312a49(0xa9)],...(_0x1abaa4=_0xebb5a2['expressionMap'])===null||_0x1abaa4===void 0x0?void 0x0:_0x1abaa4[_0x312a49(0x9d)]},_0x3b366e=resolveTableName(_0x27d29f,_0x41185d,_0x2bac40,getQueryType(_0xebb5a2));return _0x3b366e&&_0x3b366e!==_0x895b67[_0x312a49(0x97)]?_0x3b366e:null;}catch{}return null;}async function ensureShardingTablesExist(_0x5b8ff){const _0x5159ce=a15_0x1a2399;var _0x12b77f,_0xbd092c,_0x405968;const _0x12c9f3=(0x0,core_1['getCurrentApplicationContext'])();if(!_0x12c9f3)return;const _0x4b3dc3={...(_0x12b77f=_0x5b8ff['expressionMap'])===null||_0x12b77f===void 0x0?void 0x0:_0x12b77f['nativeParameters'],...(_0xbd092c=_0x5b8ff[_0x5159ce(0x6d)])===null||_0xbd092c===void 0x0?void 0x0:_0xbd092c[_0x5159ce(0x9d)]},_0xe54b72=getQueryType(_0x5b8ff);for(const _0x2c32a3 of((_0x405968=_0x5b8ff[_0x5159ce(0x6d)])===null||_0x405968===void 0x0?void 0x0:_0x405968['aliases'])||[]){const _0x3dd4aa=_0x2c32a3[_0x5159ce(0x92)],_0x25c67c=(_0x3dd4aa===null||_0x3dd4aa===void 0x0?void 0x0:_0x3dd4aa['target'])&&getShardingMeta(_0x3dd4aa[_0x5159ce(0xae)]);if(!_0x25c67c)continue;try{const _0x5244b2=await _0x12c9f3[_0x5159ce(0x9c)](_0x25c67c[_0x5159ce(0x78)]);if(!_0x5244b2)continue;const _0x20e804=_0x25c67c[_0x5159ce(0x97)]||_0x3dd4aa[_0x5159ce(0x97)],_0x531602=resolveTableName(_0x5244b2,_0x20e804,_0x4b3dc3,_0xe54b72)||_0x20e804;_0x531602!==_0x20e804&&await _0x5244b2[_0x5159ce(0x81)]({'entity':_0x3dd4aa[_0x5159ce(0xae)],'baseTableName':_0x20e804,'dataSource':_0x5b8ff[_0x5159ce(0x6f)],'entityMetadata':_0x3dd4aa,'manager':_0x5b8ff[_0x5159ce(0x6f)][_0x5159ce(0x99)]},_0x531602);}catch(_0x151978){console[_0x5159ce(0x75)]('[Sharding]\x20Ensure\x20table\x20exists\x20failed:',_0x151978);}}}const _origGetTableName=typeorm_1[a15_0x1a2399(0x6c)][a15_0x1a2399(0x9f)][a15_0x1a2399(0x9a)],_getRawAndEntities=typeorm_1[a15_0x1a2399(0x8b)]['prototype']['getRawAndEntities'],_insert=typeorm_1[a15_0x1a2399(0x79)][a15_0x1a2399(0x9f)][a15_0x1a2399(0xab)],_update=typeorm_1[a15_0x1a2399(0x89)][a15_0x1a2399(0x9f)][a15_0x1a2399(0xab)],_delete=typeorm_1[a15_0x1a2399(0xa5)]['prototype'][a15_0x1a2399(0xab)];function a15_0x50b0(){const _0x489f1e=['(((.+)+)+)+$','911695YfdkWW','ensureTableExists','20VXoFDu','call','assign','28gSOLyV','__esModule','checkTableExists','ENTIFY_MODULE_SOURCE','UpdateQueryBuilder','set','SelectQueryBuilder','filter','apply','getDeleteTableName','create','indices','forEach','metadata','isUnique','defineProperty','hasTable','Table','tableName','createTableFromMetadata','manager','getTableName','16EKRzWo','getAsync','parameters','release','prototype','clear','clearTableExistsCache','getSelectTableName','dataSource','@midwayjs/core','DeleteQueryBuilder','4cFTVyR','1839101Afwryh','tablePath','nativeParameters','constructor','execute','ShardingStrategy','getPrototypeOf','target','get','1266831sHWVPQ','getClassMetadata','createTable','./interface','446401nSWWLe','getRawAndEntities','search','3318104HlmOGE','aliases','getUpdateTableName','QueryBuilder','expressionMap','find','connection','getPreCreateTableNames','ENTIFY_SHARDING_KEY','delete','getInsertTableName','preCreateTables','warn','typeorm','createTables','strategy','InsertQueryBuilder','3990324sUHmsR','createQueryRunner','driver','1396116aFkvJT','toString'];a15_0x50b0=function(){return _0x489f1e;};return a15_0x50b0();}typeorm_1['QueryBuilder'][a15_0x1a2399(0x9f)][a15_0x1a2399(0x9a)]=function(_0x4eb33f){const _0x245583=a15_0x1a2399;return _origGetTableName[_0x245583(0x83)](this,getShardingTableNameSync(this,_0x4eb33f)||_0x4eb33f);},typeorm_1[a15_0x1a2399(0x8b)][a15_0x1a2399(0x9f)][a15_0x1a2399(0x67)]=async function(){const _0x198bf8=a15_0x1a2399;return await ensureShardingTablesExist(this),_getRawAndEntities[_0x198bf8(0x83)](this);},typeorm_1[a15_0x1a2399(0x79)][a15_0x1a2399(0x9f)][a15_0x1a2399(0xab)]=async function(){const _0x5e134d=a15_0x1a2399;return await ensureShardingTablesExist(this),_insert[_0x5e134d(0x83)](this);},typeorm_1[a15_0x1a2399(0x89)][a15_0x1a2399(0x9f)][a15_0x1a2399(0xab)]=async function(){const _0x43f780=a15_0x1a2399;return await ensureShardingTablesExist(this),_update[_0x43f780(0x83)](this);},typeorm_1[a15_0x1a2399(0xa5)][a15_0x1a2399(0x9f)]['execute']=async function(){const _0x53755c=a15_0x1a2399;return await ensureShardingTablesExist(this),_delete[_0x53755c(0x83)](this);};function clearTableExistsCache(_0x5496cb,_0x372ad7){const _0x38faf3=a15_0x1a2399;var _0x1e48b0,_0x2aefa7;if(_0x5496cb&&_0x372ad7)(_0x1e48b0=tableExistsCache['get'](_0x5496cb))===null||_0x1e48b0===void 0x0?void 0x0:_0x1e48b0[_0x38faf3(0x72)](_0x372ad7);else{if(_0x5496cb)(_0x2aefa7=tableExistsCache['get'](_0x5496cb))===null||_0x2aefa7===void 0x0?void 0x0:_0x2aefa7[_0x38faf3(0xa0)]();else tableExistsCache['forEach'](_0x3da0dc=>_0x3da0dc[_0x38faf3(0xa0)]());}}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anncic-api/typeorm",
|
|
3
|
-
"version": "3.7.
|
|
3
|
+
"version": "3.7.6",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"files": [
|
|
@@ -23,5 +23,5 @@
|
|
|
23
23
|
"javascript-obfuscator": "^4.0.2",
|
|
24
24
|
"typescript": "^5.5.4"
|
|
25
25
|
},
|
|
26
|
-
"gitHead": "
|
|
26
|
+
"gitHead": "4a836606af3ebc184ff65b1fe441c09992e1ce3c"
|
|
27
27
|
}
|