@anncic-api/typeorm 1.2.4 → 1.2.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.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/index.js +1 -1
- package/dist/interface.js +1 -1
- package/package.json +2 -2
package/dist/configuration.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';function a0_0xe87a(_0x2a7d33,_0x24119a){const _0x4b0450=a0_0x4b04();return a0_0xe87a=function(_0xe87a62,_0x363457){_0xe87a62=_0xe87a62-0x1ea;let _0x4cef72=_0x4b0450[_0xe87a62];return _0x4cef72;},a0_0xe87a(_0x2a7d33,_0x24119a);}const a0_0x4cd5bc=a0_0xe87a;(function(_0x3ebca9,_0x2c41f6){const _0x375e1b=a0_0xe87a,_0x185e4c=_0x3ebca9();while(!![]){try{const _0x5a828b=-parseInt(_0x375e1b(0x1ec))/0x1*(parseInt(_0x375e1b(0x207))/0x2)+parseInt(_0x375e1b(0x212))/0x3+parseInt(_0x375e1b(0x209))/0x4*(parseInt(_0x375e1b(0x202))/0x5)+-parseInt(_0x375e1b(0x1f6))/0x6+-parseInt(_0x375e1b(0x1f9))/0x7*(parseInt(_0x375e1b(0x218))/0x8)+parseInt(_0x375e1b(0x211))/0x9+parseInt(_0x375e1b(0x1f1))/0xa;if(_0x5a828b===_0x2c41f6)break;else _0x185e4c['push'](_0x185e4c['shift']());}catch(_0xef290c){_0x185e4c['push'](_0x185e4c['shift']());}}}(a0_0x4b04,0x1ad09));function a0_0x4b04(){const _0x37f5d6=['数据不存在','9015tUYADn','getOwnPropertyDescriptor','getClassMetadata','decorator','defineProperty','437950wQITKg','EntityNotFoundError','276RDptbV','target','onReady','typeorm','message','registerPropertyHandler','useMiddleware','__metadata','719307zotfxm','626361xLbWev','production','Repository','__esModule','find','ENTIFY_KEY','25720KTDJGH','getRepository','./definition/Repository','MidwayDecoratorService','metadata','object','TypeORMError','prototype','\x20is\x20not\x20ProvideRepository\x20Entify','getDataSource','anncic-api:typeorm','1SXwIte','decorate','Inject','TypeORMDataSourceManager','getDataSourceNameByModel','1597010swEpuX','@midwayjs/core','push','getEnv','middlewareError','345240DCBhyj','anncic-api-typeorm\x20Error\x20','handlercache','406rsPnCo','@midwayjs/typeorm','REPOSITORY_KEY','MidwayConfigService','function','design:type','CustomConfiguration','name'];a0_0x4b04=function(){return _0x37f5d6;};return a0_0x4b04();}var __decorate=this&&this['__decorate']||function(_0x11ff65,_0xe29599,_0x24b4df,_0x833ea7){const _0x31696a=a0_0xe87a;var _0x2e637d=arguments['length'],_0x3d8539=_0x2e637d<0x3?_0xe29599:_0x833ea7===null?_0x833ea7=Object[_0x31696a(0x203)](_0xe29599,_0x24b4df):_0x833ea7,_0x17e6ee;if(typeof Reflect==='object'&&typeof Reflect[_0x31696a(0x1ed)]==='function')_0x3d8539=Reflect['decorate'](_0x11ff65,_0xe29599,_0x24b4df,_0x833ea7);else{for(var _0x48cd8e=_0x11ff65['length']-0x1;_0x48cd8e>=0x0;_0x48cd8e--)if(_0x17e6ee=_0x11ff65[_0x48cd8e])_0x3d8539=(_0x2e637d<0x3?_0x17e6ee(_0x3d8539):_0x2e637d>0x3?_0x17e6ee(_0xe29599,_0x24b4df,_0x3d8539):_0x17e6ee(_0xe29599,_0x24b4df))||_0x3d8539;}return _0x2e637d>0x3&&_0x3d8539&&Object[_0x31696a(0x206)](_0xe29599,_0x24b4df,_0x3d8539),_0x3d8539;},__metadata=this&&this[a0_0x4cd5bc(0x210)]||function(_0x1accae,_0x317b65){const _0x499fd7=a0_0x4cd5bc;if(typeof Reflect===_0x499fd7(0x21d)&&typeof Reflect['metadata']===_0x499fd7(0x1fd))return Reflect[_0x499fd7(0x21c)](_0x1accae,_0x317b65);};Object[a0_0x4cd5bc(0x206)](exports,a0_0x4cd5bc(0x215),{'value':!![]}),exports[a0_0x4cd5bc(0x1ff)]=void 0x0;const typeorm_1=require('@midwayjs/typeorm'),core_1=require(a0_0x4cd5bc(0x1f2)),core_2=require('@midwayjs/core'),typeorm_2=require(a0_0x4cd5bc(0x20c)),Repository_1=require(a0_0x4cd5bc(0x21a)),interface_1=require('./interface'),typeorm=require(a0_0x4cd5bc(0x1fa));let CustomConfiguration=class CustomConfiguration{constructor(){this['handlercache']=[];}async[a0_0x4cd5bc(0x20b)](_0x3fa22d,_0x195032){const _0x472874=a0_0x4cd5bc,_0x413e2=await _0x3fa22d['getAsync'](typeorm_1[_0x472874(0x1ef)]);this[_0x472874(0x205)][_0x472874(0x20e)](interface_1[_0x472874(0x217)],(_0x188455,{entity:_0x3727e0,connection:_0x403661})=>{const _0x188331=_0x472874;let _0x5ce762=this[_0x188331(0x1f8)][_0x188331(0x216)](_0x58a6fd=>_0x58a6fd[_0x188331(0x20a)]===_0x3727e0);return!_0x5ce762&&(_0x5ce762=new Repository_1[(_0x188331(0x214))](_0x195032,_0x413e2[_0x188331(0x1ea)](_0x403661||_0x413e2[_0x188331(0x1f0)](_0x3727e0))['getRepository'](_0x3727e0)),this['handlercache'][_0x188331(0x1f3)](_0x5ce762)),_0x5ce762;}),this[_0x472874(0x205)][_0x472874(0x20e)](interface_1[_0x472874(0x1fb)],(_0x44ab97,{repository:_0x1bb82f,connection:_0x320514})=>{const _0x4ad7c0=_0x472874,{entity:_0x2d71ed}=(0x0,core_1[_0x4ad7c0(0x204)])(interface_1[_0x4ad7c0(0x1fb)],_0x1bb82f)||{};if(!_0x2d71ed)throw new Error(_0x4ad7c0(0x1f7)+((_0x1bb82f===null||_0x1bb82f===void 0x0?void 0x0:_0x1bb82f[_0x4ad7c0(0x200)])||_0x1bb82f)+_0x4ad7c0(0x220));let _0x159b5a=this[_0x4ad7c0(0x1f8)]['find'](_0x2590e0=>_0x2590e0===_0x1bb82f);return!_0x159b5a&&(_0x159b5a=new _0x1bb82f(_0x195032,_0x413e2[_0x4ad7c0(0x1ea)](_0x320514||_0x413e2['getDataSourceNameByModel'](_0x2d71ed))[_0x4ad7c0(0x219)](_0x2d71ed)),this[_0x4ad7c0(0x1f8)][_0x4ad7c0(0x1f3)](_0x159b5a)),_0x159b5a;}),_0x195032[_0x472874(0x20f)](this[_0x472874(0x1f5)](_0x195032));}[a0_0x4cd5bc(0x1f5)](_0x581747){return async(_0x30cc8f,_0x54ef18)=>{const _0x4262b=a0_0xe87a;try{await _0x54ef18();}catch(_0x1e3732){if(_0x1e3732 instanceof typeorm_2[_0x4262b(0x21e)])_0x1e3732 instanceof typeorm_2[_0x4262b(0x208)]?_0x30cc8f['body']={'code':0x194,'msg':_0x4262b(0x201)}:(_0x30cc8f['body']={'code':0x1f4,'msg':_0x1e3732[_0x4262b(0x20d)]},_0x581747[_0x4262b(0x1f4)]()!=_0x4262b(0x213)&&console['warn'](_0x1e3732));else throw _0x1e3732;}};}};__decorate([(0x0,core_1[a0_0x4cd5bc(0x1ee)])(),__metadata(a0_0x4cd5bc(0x1fe),core_2[a0_0x4cd5bc(0x1fc)])],CustomConfiguration[a0_0x4cd5bc(0x21f)],'config',void 0x0),__decorate([(0x0,core_1[a0_0x4cd5bc(0x1ee)])(),__metadata(a0_0x4cd5bc(0x1fe),core_2[a0_0x4cd5bc(0x21b)])],CustomConfiguration[a0_0x4cd5bc(0x21f)],a0_0x4cd5bc(0x205),void 0x0),CustomConfiguration=__decorate([(0x0,core_1['Configuration'])({'imports':[typeorm],'conflictCheck':![],'namespace':a0_0x4cd5bc(0x1eb)})],CustomConfiguration),exports[a0_0x4cd5bc(0x1ff)]=CustomConfiguration;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a1_0x326104=a1_0x2503;(function(_0xe3e293,_0xedd9f5){const _0x20c749=a1_0x2503,_0x1ab286=_0xe3e293();while(!![]){try{const _0x103072=-parseInt(_0x20c749(0x196))/0x1*(-parseInt(_0x20c749(0x195))/0x2)+-parseInt(_0x20c749(0x19c))/0x3*(-parseInt(_0x20c749(0x198))/0x4)+-parseInt(_0x20c749(0x1a1))/0x5+parseInt(_0x20c749(0x19b))/0x6+-parseInt(_0x20c749(0x1a0))/0x7*(-parseInt(_0x20c749(0x19a))/0x8)+-parseInt(_0x20c749(0x19f))/0x9+-parseInt(_0x20c749(0x19d))/0xa;if(_0x103072===_0xedd9f5)break;else _0x1ab286['push'](_0x1ab286['shift']());}catch(_0x5696ce){_0x1ab286['push'](_0x1ab286['shift']());}}}(a1_0x9ea1,0xcb034));function a1_0x2503(_0xab165b,_0x54645c){const _0x9ea160=a1_0x9ea1();return a1_0x2503=function(_0x250321,_0x56f80d){_0x250321=_0x250321-0x193;let _0x231ee2=_0x9ea160[_0x250321];return _0x231ee2;},a1_0x2503(_0xab165b,_0x54645c);}Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[a1_0x326104(0x193)]=void 0x0;const core_1=require(a1_0x326104(0x199)),interface_1=require(a1_0x326104(0x194));function a1_0x9ea1(){const _0x51139a=['2430708ICtEjD','6551245MAyyAt','InjectEntity','../interface','75644WWUxdt','38wFRQYS','default','4iOKjIY','@midwayjs/core','8AHLJuL','6133950XezvAd','2812065CbWlac','15603280eZqEge','ENTIFY_KEY','378387xiDTnb'];a1_0x9ea1=function(){return _0x51139a;};return a1_0x9ea1();}function InjectEntity(_0x30c861,_0x3a0de0=a1_0x326104(0x197)){const _0x374cd8=a1_0x326104;return(0x0,core_1['createCustomPropertyDecorator'])(interface_1[_0x374cd8(0x19e)],{'entity':_0x30c861,'connection':_0x3a0de0});}exports[a1_0x326104(0x193)]=InjectEntity;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';function
|
|
1
|
+
'use strict';const a2_0x413273=a2_0x2960;function a2_0x120b(){const _0x5400b1=['default','10234632dxAcpU','480530lWZUbf','3dhiWPy','__esModule','5267090vsZkoF','2655196mdKuwJ','InjectRepository','4236449pGgqWG','9VkKyMt','11nYzJmv','@midwayjs/core','545872JBslVz','createCustomPropertyDecorator','30fclLwQ','592584FDvMST','../interface'];a2_0x120b=function(){return _0x5400b1;};return a2_0x120b();}(function(_0x5260b2,_0x7542db){const _0x2ecf02=a2_0x2960,_0x45d2d8=_0x5260b2();while(!![]){try{const _0x15698a=-parseInt(_0x2ecf02(0x96))/0x1+parseInt(_0x2ecf02(0x8c))/0x2*(-parseInt(_0x2ecf02(0x8d))/0x3)+parseInt(_0x2ecf02(0x90))/0x4+-parseInt(_0x2ecf02(0x98))/0x5*(parseInt(_0x2ecf02(0x99))/0x6)+parseInt(_0x2ecf02(0x92))/0x7+parseInt(_0x2ecf02(0x8b))/0x8*(parseInt(_0x2ecf02(0x93))/0x9)+-parseInt(_0x2ecf02(0x8f))/0xa*(parseInt(_0x2ecf02(0x94))/0xb);if(_0x15698a===_0x7542db)break;else _0x45d2d8['push'](_0x45d2d8['shift']());}catch(_0x32c2a3){_0x45d2d8['push'](_0x45d2d8['shift']());}}}(a2_0x120b,0x9cf59));function a2_0x2960(_0x22e30c,_0xef6770){const _0x120beb=a2_0x120b();return a2_0x2960=function(_0x296048,_0xcb509d){_0x296048=_0x296048-0x89;let _0x23aa3e=_0x120beb[_0x296048];return _0x23aa3e;},a2_0x2960(_0x22e30c,_0xef6770);}Object['defineProperty'](exports,a2_0x413273(0x8e),{'value':!![]}),exports[a2_0x413273(0x91)]=void 0x0;const core_1=require(a2_0x413273(0x95)),interface_1=require(a2_0x413273(0x89));function InjectRepository(_0x15ca5f,_0x1f7331=a2_0x413273(0x8a)){const _0x7e5a56=a2_0x413273;return(0x0,core_1[_0x7e5a56(0x97)])(interface_1['REPOSITORY_KEY'],{'repository':_0x15ca5f,'connection':_0x1f7331});}exports[a2_0x413273(0x91)]=InjectRepository;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a3_0x1ccb0e=a3_0x2944;function a3_0x56c0(){const _0x2fba3e=['@midwayjs/core','12rsXtmK','207684FyuuiT','155080rPehtw','126SYjdgy','268040KoGUIx','name','Entity','77iowIth','dataSource','tableName','ENTIFY_MODULE','ProvideEntity','198qSZlsW','238830GdcdWL','284517wlXeax','15wpcpVB','push','saveClassMetadata','isArray','defineProperty','31fsREZM','ENTIFY_MODULE_SOURCE','saveModule','56dPVmFe','../interface','typeorm','10744iSJMOQ','__esModule','default','547768UDyHsO'];a3_0x56c0=function(){return _0x2fba3e;};return a3_0x56c0();}(function(_0x514695,_0x1a8d22){const _0x23305d=a3_0x2944,_0x1c8e28=_0x514695();while(!![]){try{const _0x126b28=-parseInt(_0x23305d(0x1af))/0x1*(-parseInt(_0x23305d(0x1b5))/0x2)+-parseInt(_0x23305d(0x1a9))/0x3*(-parseInt(_0x23305d(0x1ba))/0x4)+parseInt(_0x23305d(0x1aa))/0x5*(parseInt(_0x23305d(0x1a8))/0x6)+parseInt(_0x23305d(0x1a2))/0x7*(-parseInt(_0x23305d(0x19d))/0x8)+parseInt(_0x23305d(0x19e))/0x9*(parseInt(_0x23305d(0x19f))/0xa)+parseInt(_0x23305d(0x1a7))/0xb*(-parseInt(_0x23305d(0x1bb))/0xc)+-parseInt(_0x23305d(0x1b8))/0xd*(parseInt(_0x23305d(0x1b2))/0xe);if(_0x126b28===_0x1a8d22)break;else _0x1c8e28['push'](_0x1c8e28['shift']());}catch(_0x5fc2bf){_0x1c8e28['push'](_0x1c8e28['shift']());}}}(a3_0x56c0,0x3d9ff));function a3_0x2944(_0x6ed932,_0x5ce263){const _0x56c093=a3_0x56c0();return a3_0x2944=function(_0x29448c,_0x1c169e){_0x29448c=_0x29448c-0x19d;let _0x5994bb=_0x56c093[_0x29448c];return _0x5994bb;},a3_0x2944(_0x6ed932,_0x5ce263);}Object[a3_0x1ccb0e(0x1ae)](exports,a3_0x1ccb0e(0x1b6),{'value':!![]}),exports[a3_0x1ccb0e(0x1a6)]=void 0x0;const typeorm_1=require(a3_0x1ccb0e(0x1b4)),core_1=require(a3_0x1ccb0e(0x1b9)),interface_1=require(a3_0x1ccb0e(0x1b3));function ProvideEntity(_0x2f4aa4,_0x5d0078={}){return _0x14d2a8=>{const _0x320dc3=a3_0x2944;_0x5d0078[_0x320dc3(0x1a0)]=_0x2f4aa4[_0x320dc3(0x1a4)];const _0x3c60c4=[];if(!(_0x2f4aa4===null||_0x2f4aa4===void 0x0?void 0x0:_0x2f4aa4['dataSource']))_0x3c60c4[_0x320dc3(0x1ab)](_0x320dc3(0x1b7));else{if(typeof(_0x2f4aa4===null||_0x2f4aa4===void 0x0?void 0x0:_0x2f4aa4['dataSource'])=='string')_0x3c60c4['push'](_0x2f4aa4===null||_0x2f4aa4===void 0x0?void 0x0:_0x2f4aa4[_0x320dc3(0x1a3)]);else{if(Array[_0x320dc3(0x1ad)](_0x2f4aa4===null||_0x2f4aa4===void 0x0?void 0x0:_0x2f4aa4['dataSource']))for(let _0x38089b of _0x2f4aa4[_0x320dc3(0x1a3)]||[_0x320dc3(0x1b7)]){_0x3c60c4[_0x320dc3(0x1ab)](_0x38089b);}}}(0x0,core_1[_0x320dc3(0x1b1)])(interface_1[_0x320dc3(0x1a5)],_0x14d2a8),(0x0,core_1[_0x320dc3(0x1ac)])(interface_1[_0x320dc3(0x1b0)],{'tableName':_0x2f4aa4[_0x320dc3(0x1a4)],'dataSource':_0x3c60c4},_0x14d2a8),(0x0,typeorm_1[_0x320dc3(0x1a1)])(_0x2f4aa4[_0x320dc3(0x1a4)],_0x5d0078)(_0x14d2a8);};}exports[a3_0x1ccb0e(0x1a6)]=ProvideEntity;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a4_0x9b1e79=a4_0x2b39;(function(_0x25c104,_0x58f2ab){const _0x17f729=a4_0x2b39,_0x20e5d9=_0x25c104();while(!![]){try{const _0x2917b9=parseInt(_0x17f729(0x1b8))/0x1*(-parseInt(_0x17f729(0x1c5))/0x2)+parseInt(_0x17f729(0x1bf))/0x3+-parseInt(_0x17f729(0x1b4))/0x4*(-parseInt(_0x17f729(0x1be))/0x5)+parseInt(_0x17f729(0x1c4))/0x6+parseInt(_0x17f729(0x1bc))/0x7*(parseInt(_0x17f729(0x1c6))/0x8)+-parseInt(_0x17f729(0x1ba))/0x9+-parseInt(_0x17f729(0x1b9))/0xa*(parseInt(_0x17f729(0x1b3))/0xb);if(_0x2917b9===_0x58f2ab)break;else _0x20e5d9['push'](_0x20e5d9['shift']());}catch(_0x47171f){_0x20e5d9['push'](_0x20e5d9['shift']());}}}(a4_0x2a43,0xa49fb));function a4_0x2b39(_0x2ed3bb,_0x504550){const _0x2a4303=a4_0x2a43();return a4_0x2b39=function(_0x2b3907,_0x19667c){_0x2b3907=_0x2b3907-0x1b3;let _0x4e542d=_0x2a4303[_0x2b3907];return _0x4e542d;},a4_0x2b39(_0x2ed3bb,_0x504550);}Object['defineProperty'](exports,a4_0x9b1e79(0x1bd),{'value':!![]}),exports[a4_0x9b1e79(0x1c2)]=void 0x0;const core_1=require(a4_0x9b1e79(0x1b5)),interface_1=require('../interface');function a4_0x2a43(){const _0x397871=['3764652SqEDzt','Provide','REPOSITORY_KEY','ProvideRepository','ScopeEnum','7023330JhSZHG','204078LGMXZQ','416MzzdsW','66krYWiv','737116MSGrLZ','@midwayjs/core','Request','Scope','1YoazrL','3256230IUeXlv','10919106BebnsF','saveClassMetadata','179522SGWHrJ','__esModule','5pQdoOA'];a4_0x2a43=function(){return _0x397871;};return a4_0x2a43();}function ProvideRepository(_0x31d628){return _0x542e9d=>{const _0x530747=a4_0x2b39;(0x0,core_1[_0x530747(0x1b7)])(core_1[_0x530747(0x1c3)][_0x530747(0x1b6)],{'allowDowngrade':!![]})(_0x542e9d),((0x0,core_1[_0x530747(0x1c0)])()(_0x542e9d),(0x0,core_1[_0x530747(0x1bb)])(interface_1[_0x530747(0x1c1)],{'entity':_0x31d628},_0x542e9d));};}exports[a4_0x9b1e79(0x1c2)]=ProvideRepository;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';
|
|
1
|
+
'use strict';const a5_0x12903f=a5_0x30a9;(function(_0x500e12,_0x1e449d){const _0x9d5050=a5_0x30a9,_0x1a2156=_0x500e12();while(!![]){try{const _0x3df785=parseInt(_0x9d5050(0x148))/0x1+-parseInt(_0x9d5050(0x140))/0x2+parseInt(_0x9d5050(0x144))/0x3+parseInt(_0x9d5050(0x149))/0x4*(-parseInt(_0x9d5050(0x14a))/0x5)+-parseInt(_0x9d5050(0x147))/0x6*(parseInt(_0x9d5050(0x152))/0x7)+-parseInt(_0x9d5050(0x142))/0x8*(-parseInt(_0x9d5050(0x14f))/0x9)+-parseInt(_0x9d5050(0x146))/0xa*(-parseInt(_0x9d5050(0x14d))/0xb);if(_0x3df785===_0x1e449d)break;else _0x1a2156['push'](_0x1a2156['shift']());}catch(_0x4e441a){_0x1a2156['push'](_0x1a2156['shift']());}}}(a5_0x3518,0x29ece));function a5_0x30a9(_0x5a551b,_0x3f89b5){const _0x351875=a5_0x3518();return a5_0x30a9=function(_0x30a937,_0x18ce6a){_0x30a937=_0x30a937-0x140;let _0x462fad=_0x351875[_0x30a937];return _0x462fad;},a5_0x30a9(_0x5a551b,_0x3f89b5);}function a5_0x3518(){const _0x373fd1=['3830aLrJfA','ScopeEnum','MODEL_KEY','58322hudQIS','Singleton','242343eavlcv','ProvideSearch','Scope','28476bHbZgr','../interface','__esModule','519728ewGHzp','MODEL_SEARCH_KEY','56ouXHVV','attachClassMetadata','766623VYBlNg','@midwayjs/core','110iEGeMt','492jYPiLN','298050gjNykn','184VVhKuY'];a5_0x3518=function(){return _0x373fd1;};return a5_0x3518();}Object['defineProperty'](exports,a5_0x12903f(0x154),{'value':!![]}),exports['Search']=exports[a5_0x12903f(0x150)]=void 0x0;const core_1=require(a5_0x12903f(0x145)),interface_1=require(a5_0x12903f(0x153));function ProvideSearch(_0x1e47f1){return _0x2323b4=>{const _0x4b33ed=a5_0x30a9;(0x0,core_1['saveModule'])(interface_1[_0x4b33ed(0x14c)],_0x2323b4),(0x0,core_1[_0x4b33ed(0x151)])(core_1[_0x4b33ed(0x14b)][_0x4b33ed(0x14e)])(_0x2323b4),(0x0,core_1[_0x4b33ed(0x143)])(interface_1[_0x4b33ed(0x14c)],_0x1e47f1,_0x2323b4);};}exports[a5_0x12903f(0x150)]=ProvideSearch;function Search(_0x22231a,_0x8bf415){return(_0x40aaba,_0xb6a384,_0x3502ca)=>{const _0x45b959=a5_0x30a9;(0x0,core_1[_0x45b959(0x143)])(interface_1[_0x45b959(0x141)],{'field':_0x22231a,'comment':_0x8bf415,'target':_0x40aaba,'methodName':_0xb6a384,'descriptor':_0x3502ca},_0x40aaba);};}exports['Search']=Search;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a6_0x29c2ae=a6_0xca4b;(function(_0x41926c,_0x55dd3e){const _0x45eecf=a6_0xca4b,_0x521aae=_0x41926c();while(!![]){try{const _0x1da0ce=-parseInt(_0x45eecf(0x8b))/0x1+parseInt(_0x45eecf(0x96))/0x2+-parseInt(_0x45eecf(0x98))/0x3+parseInt(_0x45eecf(0x9a))/0x4+-parseInt(_0x45eecf(0x8a))/0x5*(parseInt(_0x45eecf(0x97))/0x6)+-parseInt(_0x45eecf(0x95))/0x7*(-parseInt(_0x45eecf(0x8c))/0x8)+parseInt(_0x45eecf(0x8e))/0x9*(parseInt(_0x45eecf(0x94))/0xa);if(_0x1da0ce===_0x55dd3e)break;else _0x521aae['push'](_0x521aae['shift']());}catch(_0x5c6a39){_0x521aae['push'](_0x521aae['shift']());}}}(a6_0x5062,0x84112));Object[a6_0x29c2ae(0x91)](exports,a6_0x29c2ae(0x99),{'value':!![]}),exports[a6_0x29c2ae(0x93)]=void 0x0;function a6_0x5062(){const _0x1dc1e6=['791feyTaR','2063398ecsXVO','30rdxtyE','1131213IGZNNw','__esModule','1256040OkIYwi','getClassMetadata','660730AAWfoA','569432FwCLak','49736SwGYpE','@midwayjs/core','7083wJgIlD','../interface','ENTITY_VIRTUAL_COLUMN_KEY','defineProperty','saveClassMetadata','VirtualColumn','1270dmSJOL'];a6_0x5062=function(){return _0x1dc1e6;};return a6_0x5062();}const core_1=require(a6_0x29c2ae(0x8d)),interface_1=require(a6_0x29c2ae(0x8f));function VirtualColumn(_0x2afeda,_0x4bab96){return(_0x1000f3,_0x66304d)=>{const _0x29bbe8=a6_0xca4b,_0x25f15c=(0x0,core_1[_0x29bbe8(0x9b)])(interface_1[_0x29bbe8(0x90)],_0x1000f3)||{};_0x25f15c[_0x66304d]={'comment':_0x2afeda,..._0x4bab96},(0x0,core_1[_0x29bbe8(0x92)])(interface_1['ENTITY_VIRTUAL_COLUMN_KEY'],_0x25f15c,_0x1000f3);};}function a6_0xca4b(_0x32e210,_0x17be64){const _0x5062b5=a6_0x5062();return a6_0xca4b=function(_0xca4bbc,_0x4d5d03){_0xca4bbc=_0xca4bbc-0x8a;let _0x16cb29=_0x5062b5[_0xca4bbc];return _0x16cb29;},a6_0xca4b(_0x32e210,_0x17be64);}exports[a6_0x29c2ae(0x93)]=VirtualColumn;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a7_0x3c6f0d=a7_0x1df5;(function(_0x5b16f1,_0xbae6b7){const _0x3ebf9f=a7_0x1df5,_0xa37e7a=_0x5b16f1();while(!![]){try{const _0x238200=-parseInt(_0x3ebf9f(0x19d))/0x1+parseInt(_0x3ebf9f(0x1b0))/0x2*(parseInt(_0x3ebf9f(0x199))/0x3)+-parseInt(_0x3ebf9f(0x16c))/0x4+-parseInt(_0x3ebf9f(0x17d))/0x5+parseInt(_0x3ebf9f(0x1b4))/0x6*(parseInt(_0x3ebf9f(0x17c))/0x7)+-parseInt(_0x3ebf9f(0x176))/0x8*(parseInt(_0x3ebf9f(0x191))/0x9)+parseInt(_0x3ebf9f(0x1a2))/0xa;if(_0x238200===_0xbae6b7)break;else _0xa37e7a['push'](_0xa37e7a['shift']());}catch(_0x314494){_0xa37e7a['push'](_0xa37e7a['shift']());}}}(a7_0x97dd,0x21817));function a7_0x1df5(_0x21f181,_0x9d0171){const _0x97dd94=a7_0x97dd();return a7_0x1df5=function(_0x1df589,_0x5e4b2c){_0x1df589=_0x1df589-0x16a;let _0x30c431=_0x97dd94[_0x1df589];return _0x30c431;},a7_0x1df5(_0x21f181,_0x9d0171);}Object[a7_0x3c6f0d(0x183)](exports,'__esModule',{'value':!![]}),exports['Repository']=void 0x0;function a7_0x97dd(){const _0x328bef=['bind','orderBy','metadata','NOT\x20BETWEEN','String','@midwayjs/core','save','push','MODEL_KEY','_isreverse','function','_size','90dOxxwE','ASC','_order','skip','queryRunner','FIND\x20IN\x20SET','split','alias','1257HKpypQ','ISNULL','getAsync','MODEL_SEARCH_KEY','115303pTSqls','searchs','target','BETWEEN','\x20AND\x20:','3040730mWdybE','Repository','getClassMetadata','random','name','length','excess','create','model','getApplicationContext','operator','toUpperCase','toString','merge','790jJyjbX','../interface','NOT\x20IN','isArray','84XmwXeJ','createQueryBuilder','_page','manager','andWhere','_auto_','538744BCkDrc','ceil','trim','LIKE','indexOf','mergeSave','take','DESC','methodName','transaction','153304nHeYNW','NOT\x20ISNULL','field','condition','hasOwnProperty','app','73857IeFgOK','192170EASvRK','modelSearchs','abs','undefined','\x20like\x20:_auto_','type','defineProperty','findColumnWithPropertyName'];a7_0x97dd=function(){return _0x328bef;};return a7_0x97dd();}const core_1=require(a7_0x3c6f0d(0x18a)),typeorm_1=require('typeorm'),interface_1=require(a7_0x3c6f0d(0x1b1));class Repository extends typeorm_1[a7_0x3c6f0d(0x1a3)]{constructor(_0x466720,_0x16d7a1){const _0x5da2b2=a7_0x3c6f0d;super(_0x16d7a1[_0x5da2b2(0x19f)],_0x16d7a1['manager'],_0x16d7a1[_0x5da2b2(0x195)]),this[_0x5da2b2(0x17e)]=[];for(const _0x5255e0 of(0x0,core_1[_0x5da2b2(0x1a4)])(interface_1[_0x5da2b2(0x18d)],this['target'])||[]){const _0x55f4b4={'model':_0x5255e0,'searchs':[]};for(const _0x353031 of(0x0,core_1[_0x5da2b2(0x1a4)])(interface_1[_0x5da2b2(0x19c)],_0x5255e0)||[]){_0x55f4b4[_0x5da2b2(0x19e)][_0x5da2b2(0x18c)](_0x353031);}this[_0x5da2b2(0x17e)]['push'](_0x55f4b4);}this['app']=_0x466720;}async['search'](_0x3d8c71,_0x40e88c,_0x37562a={}){const _0x252be6=a7_0x3c6f0d;var _0x1f071b,_0x5af8ca,_0x4958e4,_0x5b478d,_0x69bea2,_0x8f8241;const _0x41f750=this[_0x252be6(0x1b5)](undefined,_0x37562a===null||_0x37562a===void 0x0?void 0x0:_0x37562a[_0x252be6(0x195)]),_0x231e63=[];for(const _0x3c7541 of this[_0x252be6(0x17e)]){if((_0x3c7541===null||_0x3c7541===void 0x0?void 0x0:_0x3c7541[_0x252be6(0x1aa)])&&((_0x1f071b=_0x3c7541===null||_0x3c7541===void 0x0?void 0x0:_0x3c7541[_0x252be6(0x19e)])===null||_0x1f071b===void 0x0?void 0x0:_0x1f071b['length'])>0x0){const _0x5e1f0c=await this[_0x252be6(0x17b)][_0x252be6(0x1ab)]()[_0x252be6(0x19b)](_0x3c7541[_0x252be6(0x1aa)]);for(const _0x22096b of _0x3c7541[_0x252be6(0x19e)]){(_0x22096b===null||_0x22096b===void 0x0?void 0x0:_0x22096b[_0x252be6(0x178)])&&(_0x22096b===null||_0x22096b===void 0x0?void 0x0:_0x22096b['methodName'])&&typeof _0x5e1f0c[_0x22096b[_0x252be6(0x174)]]==_0x252be6(0x18f)&&(typeof(_0x3d8c71===null||_0x3d8c71===void 0x0?void 0x0:_0x3d8c71[_0x22096b[_0x252be6(0x178)]])!=_0x252be6(0x180)&&!((_0x5af8ca=_0x3d8c71===null||_0x3d8c71===void 0x0?void 0x0:_0x3d8c71[_0x22096b[_0x252be6(0x178)]])===null||_0x5af8ca===void 0x0?void 0x0:_0x5af8ca['hasOwnProperty'](_0x252be6(0x1ac)))&&(_0x231e63[_0x252be6(0x170)](_0x22096b['field'])==-0x1&&_0x231e63[_0x252be6(0x18c)](_0x22096b[_0x252be6(0x178)]),await _0x5e1f0c[_0x22096b['methodName']][_0x252be6(0x185)](_0x5e1f0c)(_0x41f750,_0x3d8c71[_0x22096b[_0x252be6(0x178)]],_0x3d8c71,_0x40e88c,_0x37562a===null||_0x37562a===void 0x0?void 0x0:_0x37562a[_0x252be6(0x195)])));}}}for(const _0xc1101b in _0x3d8c71){if(typeof _0x3d8c71[_0xc1101b]!='undefined'&&_0x231e63[_0x252be6(0x170)](_0xc1101b)==-0x1){const _0xcc9cc8=this[_0x252be6(0x187)]['findColumnWithPropertyName'](_0xc1101b);if(_0xcc9cc8){if((_0x4958e4=_0x3d8c71===null||_0x3d8c71===void 0x0?void 0x0:_0x3d8c71[_0xc1101b])===null||_0x4958e4===void 0x0?void 0x0:_0x4958e4[_0x252be6(0x17a)](_0x252be6(0x1ac))){const _0x28145b=(_0x5b478d=_0x3d8c71[_0xc1101b])===null||_0x5b478d===void 0x0?void 0x0:_0x5b478d[_0x252be6(0x179)],_0x290dd8=(_0x69bea2=_0x3d8c71[_0xc1101b])===null||_0x69bea2===void 0x0?void 0x0:_0x69bea2[_0x252be6(0x1ac)][_0x252be6(0x16e)]()[_0x252be6(0x1ad)](),_0x19216e=_0x252be6(0x16b)+_0xc1101b+'_'+Math[_0x252be6(0x16d)](Math[_0x252be6(0x1a5)]()*0xa)+Math['ceil'](Math[_0x252be6(0x1a5)]()*0xa)+Math[_0x252be6(0x16d)](Math[_0x252be6(0x1a5)]()*0xa)+Math[_0x252be6(0x16d)](Math[_0x252be6(0x1a5)]()*0xa);if(['=','!=','<>','>','>=','<','<=',_0x252be6(0x16f),'NOT\x20LIKE'][_0x252be6(0x170)](_0x290dd8)!=-0x1)typeof _0x28145b!=_0x252be6(0x180)&&_0x41f750['andWhere'](_0x41f750[_0x252be6(0x198)]+'.'+_0xc1101b+'\x20'+_0x290dd8+'\x20:'+_0x19216e,{[_0x19216e]:_0x28145b});else{if(['IN',_0x252be6(0x1b2)][_0x252be6(0x170)](_0x290dd8)!=-0x1){if(typeof _0x28145b!=_0x252be6(0x180)){const _0x3e5e91=Array[_0x252be6(0x1b3)](_0x28145b)?_0x28145b:typeof _0x28145b=='string'?_0x28145b['split'](','):[_0x28145b];_0x41f750[_0x252be6(0x16a)](_0x41f750['alias']+'.'+_0xc1101b+'\x20'+_0x290dd8+'(:'+_0x19216e+')',{[_0x19216e]:_0x3e5e91});}}else{if([_0x252be6(0x196),'NOT\x20FIND\x20IN\x20SET']['indexOf'](_0x290dd8)!=-0x1)typeof _0x28145b!=_0x252be6(0x180)&&_0x41f750[_0x252be6(0x16a)](_0x290dd8+'(:'+_0x19216e+','+_0x41f750[_0x252be6(0x198)]+'.'+_0xc1101b+')',{[_0x19216e]:_0x28145b});else{if([_0x252be6(0x1a0),_0x252be6(0x188)][_0x252be6(0x170)](_0x290dd8)!=-0x1){if(typeof _0x28145b!=_0x252be6(0x180)){const _0x202512=Array[_0x252be6(0x1b3)](_0x28145b)?_0x28145b:typeof _0x28145b=='string'?_0x28145b[_0x252be6(0x197)](','):[_0x28145b];_0x202512[_0x252be6(0x1a7)]>0x1&&_0x41f750['andWhere'](_0x41f750[_0x252be6(0x198)]+'.'+_0xc1101b+'\x20'+_0x290dd8+'\x20:'+_0x19216e+_0x252be6(0x1a1)+_0x19216e+'_2',{[''+_0x19216e]:_0x202512[0x0],[_0x19216e+'_2']:_0x202512[0x1]});}}else[_0x252be6(0x19a),_0x252be6(0x177)][_0x252be6(0x170)](_0x290dd8)!=-0x1&&_0x41f750[_0x252be6(0x16a)](_0x290dd8+'('+_0x41f750[_0x252be6(0x198)]+'.'+_0xc1101b+')');}}}}else{if(_0x231e63[_0x252be6(0x170)](_0xc1101b)==-0x1){const _0x5da168=typeof _0xcc9cc8[_0x252be6(0x182)]==_0x252be6(0x18f)?(_0x8f8241=_0xcc9cc8===null||_0xcc9cc8===void 0x0?void 0x0:_0xcc9cc8['type'])===null||_0x8f8241===void 0x0?void 0x0:_0x8f8241[_0x252be6(0x1a6)]:_0xcc9cc8[_0x252be6(0x182)][_0x252be6(0x1ae)]();_0x5da168==_0x252be6(0x189)?_0x41f750[_0x252be6(0x16a)](_0x41f750[_0x252be6(0x198)]+'.'+_0xc1101b+_0x252be6(0x181)+_0xc1101b,{[_0x252be6(0x16b)+_0xc1101b]:'%'+_0x3d8c71[_0xc1101b]+'%'}):_0x41f750[_0x252be6(0x16a)](_0x41f750[_0x252be6(0x198)]+'.'+_0xc1101b+'\x20=\x20:_auto_'+_0xc1101b,{[_0x252be6(0x16b)+_0xc1101b]:_0x3d8c71[_0xc1101b]});}}}}}(_0x40e88c===null||_0x40e88c===void 0x0?void 0x0:_0x40e88c['_size'])&&_0x41f750[_0x252be6(0x172)](Math['abs'](_0x40e88c[_0x252be6(0x190)]));(_0x40e88c===null||_0x40e88c===void 0x0?void 0x0:_0x40e88c[_0x252be6(0x1b6)])&&(_0x40e88c===null||_0x40e88c===void 0x0?void 0x0:_0x40e88c[_0x252be6(0x190)])&&_0x41f750[_0x252be6(0x194)]((Math['abs'](_0x40e88c[_0x252be6(0x1b6)])-0x1)*Math[_0x252be6(0x17f)](_0x40e88c[_0x252be6(0x190)]));if(_0x40e88c===null||_0x40e88c===void 0x0?void 0x0:_0x40e88c[_0x252be6(0x193)]){if(_0x40e88c[_0x252be6(0x193)]['indexOf']('.')!==-0x1)_0x41f750[_0x252be6(0x186)](''+_0x40e88c[_0x252be6(0x193)],(_0x40e88c===null||_0x40e88c===void 0x0?void 0x0:_0x40e88c[_0x252be6(0x18e)])?_0x252be6(0x192):_0x252be6(0x173));else _0x231e63[_0x252be6(0x170)](_0x40e88c[_0x252be6(0x193)])==-0x1&&(this[_0x252be6(0x187)][_0x252be6(0x184)](_0x40e88c[_0x252be6(0x193)])?_0x41f750['orderBy'](_0x41f750[_0x252be6(0x198)]+'.'+_0x40e88c[_0x252be6(0x193)],(_0x40e88c===null||_0x40e88c===void 0x0?void 0x0:_0x40e88c[_0x252be6(0x18e)])?_0x252be6(0x192):_0x252be6(0x173)):_0x41f750[_0x252be6(0x186)](''+_0x40e88c[_0x252be6(0x193)],(_0x40e88c===null||_0x40e88c===void 0x0?void 0x0:_0x40e88c[_0x252be6(0x18e)])?_0x252be6(0x192):_0x252be6(0x173)));}return typeof(_0x37562a===null||_0x37562a===void 0x0?void 0x0:_0x37562a[_0x252be6(0x1a8)])==_0x252be6(0x18f)&&await(_0x37562a===null||_0x37562a===void 0x0?void 0x0:_0x37562a[_0x252be6(0x1a8)](_0x41f750)),_0x41f750;}async[a7_0x3c6f0d(0x171)](_0x3acbde,..._0x181ab1){const _0x2cefa8=a7_0x3c6f0d,_0x2cb83b=this[_0x2cefa8(0x1af)](_0x3acbde,..._0x181ab1);return await this[_0x2cefa8(0x18b)](_0x2cb83b);}async['createSave'](_0x1cafcb,..._0x362af1){const _0x405723=a7_0x3c6f0d,_0x581874=this[_0x405723(0x1af)](this[_0x405723(0x1a9)](_0x1cafcb),..._0x362af1);return await this['save'](_0x581874);}async[a7_0x3c6f0d(0x175)](_0x512a65,_0x21d5b5){const _0x4c56fa=a7_0x3c6f0d;return this[_0x4c56fa(0x1b7)][_0x4c56fa(0x175)](_0x512a65,_0x21d5b5);}}exports['Repository']=Repository;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a8_0x598d35=a8_0x38e1;(function(_0x56b19f,_0x418d5d){const _0x1c65a4=a8_0x38e1,_0x474aa3=_0x56b19f();while(!![]){try{const _0x19f794=-parseInt(_0x1c65a4(0x9a))/0x1+parseInt(_0x1c65a4(0x98))/0x2*(-parseInt(_0x1c65a4(0xa8))/0x3)+-parseInt(_0x1c65a4(0xa7))/0x4*(parseInt(_0x1c65a4(0xa6))/0x5)+-parseInt(_0x1c65a4(0xa5))/0x6+parseInt(_0x1c65a4(0x9b))/0x7+-parseInt(_0x1c65a4(0xa0))/0x8*(parseInt(_0x1c65a4(0xa1))/0x9)+-parseInt(_0x1c65a4(0xa4))/0xa*(-parseInt(_0x1c65a4(0x9f))/0xb);if(_0x19f794===_0x418d5d)break;else _0x474aa3['push'](_0x474aa3['shift']());}catch(_0x190e0f){_0x474aa3['push'](_0x474aa3['shift']());}}}(a8_0x46f2,0xe38ca));function a8_0x46f2(){const _0x17c68c=['1231752jLTYvP','8834994MgJuLJ','listModule','dataSource','@midwayjs/core','319oAGLMj','152RfMMbt','647811IQWgxH','ENTIFY_MODULE_SOURCE','push','1292750FyQGnY','3382602NJXCMm','3721945PdOJbZ','4sLamGw','4722PGqDKM','getDataSourceEntity','find','218dcWoTW','defineProperty'];a8_0x46f2=function(){return _0x17c68c;};return a8_0x46f2();}Object[a8_0x598d35(0x99)](exports,'__esModule',{'value':!![]}),exports[a8_0x598d35(0xa9)]=void 0x0;const core_1=require(a8_0x598d35(0x9e)),interface_1=require('../interface');function getDataSourceEntity(_0x4085f2='default'){const _0xdb0f3d=a8_0x598d35;var _0x50b4ea;const _0x10f9d5=[];for(const _0x5f5625 of(0x0,core_1[_0xdb0f3d(0x9c)])(interface_1['ENTIFY_MODULE'])){const _0x27f483=(0x0,core_1['getClassMetadata'])(interface_1[_0xdb0f3d(0xa2)],_0x5f5625);((_0x50b4ea=_0x27f483===null||_0x27f483===void 0x0?void 0x0:_0x27f483[_0xdb0f3d(0x9d)])===null||_0x50b4ea===void 0x0?void 0x0:_0x50b4ea[_0xdb0f3d(0x97)](_0x3a4a0e=>_0x3a4a0e==_0x4085f2))&&_0x10f9d5[_0xdb0f3d(0xa3)](_0x5f5625);}return _0x10f9d5;}function a8_0x38e1(_0x5a8204,_0x21962f){const _0x46f2b9=a8_0x46f2();return a8_0x38e1=function(_0x38e1dd,_0x4065f2){_0x38e1dd=_0x38e1dd-0x97;let _0x386811=_0x46f2b9[_0x38e1dd];return _0x386811;},a8_0x38e1(_0x5a8204,_0x21962f);}exports[a8_0x598d35(0xa9)]=getDataSourceEntity;
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';
|
|
1
|
+
'use strict';var a9_0xba92de=a9_0x8e98;(function(_0x4524d7,_0x1e521b){var _0x49ed1c=a9_0x8e98,_0x16460b=_0x4524d7();while(!![]){try{var _0x1c1322=parseInt(_0x49ed1c(0x182))/0x1*(parseInt(_0x49ed1c(0x179))/0x2)+-parseInt(_0x49ed1c(0x168))/0x3*(parseInt(_0x49ed1c(0x15e))/0x4)+parseInt(_0x49ed1c(0x186))/0x5+parseInt(_0x49ed1c(0x178))/0x6+parseInt(_0x49ed1c(0x17b))/0x7+parseInt(_0x49ed1c(0x175))/0x8+-parseInt(_0x49ed1c(0x16f))/0x9;if(_0x1c1322===_0x1e521b)break;else _0x16460b['push'](_0x16460b['shift']());}catch(_0x3a195f){_0x16460b['push'](_0x16460b['shift']());}}}(a9_0x1b80,0xa73cf));function a9_0x1b80(){var _0xf39aa6=['CustomConfiguration','VirtualColumn','configurable','__exportStar','336511TGAqFR','InjectRepository','writable','default','1442295hYeWYH','ScopeEnum','Configuration','3537444OpBkkR','./helper/getDataSourceEntity','Search','defineProperty','getOwnPropertyDescriptor','./decorator/ProvideEntity','prototype','getDataSourceEntity','Inject','Provide','3UEZTrB','./configuration','Repository','Scope','InjectEntity','get','./decorator/ProvideSearch','17969508Fbpjlq','./interface','./decorator/VirtualColumn','./definition/Repository','./decorator/InjectRepository','__createBinding','6562864WKVhCj','ProvideEntity','ProvideSearch','7104294psEomD','2yHBnth','ProvideRepository','6556221CynPlM','typeorm','@midwayjs/core'];a9_0x1b80=function(){return _0xf39aa6;};return a9_0x1b80();}var __createBinding=this&&this[a9_0xba92de(0x174)]||(Object['create']?function(_0x351c01,_0x49354d,_0x1e3865,_0x12fac0){var _0x172520=a9_0xba92de;if(_0x12fac0===undefined)_0x12fac0=_0x1e3865;var _0x3e4085=Object[_0x172520(0x162)](_0x49354d,_0x1e3865);(!_0x3e4085||(_0x172520(0x16d)in _0x3e4085?!_0x49354d['__esModule']:_0x3e4085[_0x172520(0x184)]||_0x3e4085[_0x172520(0x180)]))&&(_0x3e4085={'enumerable':!![],'get':function(){return _0x49354d[_0x1e3865];}}),Object[_0x172520(0x161)](_0x351c01,_0x12fac0,_0x3e4085);}:function(_0x13053d,_0x199968,_0x241e3b,_0x45c7bc){if(_0x45c7bc===undefined)_0x45c7bc=_0x241e3b;_0x13053d[_0x45c7bc]=_0x199968[_0x241e3b];}),__exportStar=this&&this[a9_0xba92de(0x181)]||function(_0xff08d2,_0x4ee84b){var _0x2b8cef=a9_0xba92de;for(var _0x3583b5 in _0xff08d2)if(_0x3583b5!==_0x2b8cef(0x185)&&!Object[_0x2b8cef(0x164)]['hasOwnProperty']['call'](_0x4ee84b,_0x3583b5))__createBinding(_0x4ee84b,_0xff08d2,_0x3583b5);};Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports['ScopeEnum']=exports['Scope']=exports[a9_0xba92de(0x166)]=exports[a9_0xba92de(0x167)]=exports['Configuration']=exports['getDataSourceEntity']=exports[a9_0xba92de(0x160)]=exports[a9_0xba92de(0x177)]=exports[a9_0xba92de(0x17a)]=exports['ProvideEntity']=exports[a9_0xba92de(0x183)]=exports['InjectEntity']=exports['VirtualColumn']=exports[a9_0xba92de(0x16a)]=void 0x0,__exportStar(require(a9_0xba92de(0x17c)),exports),__exportStar(require(a9_0xba92de(0x170)),exports);function a9_0x8e98(_0x293b24,_0x511e98){var _0x1b8079=a9_0x1b80();return a9_0x8e98=function(_0x8e9887,_0x3907b9){_0x8e9887=_0x8e9887-0x15e;var _0x8c0bd2=_0x1b8079[_0x8e9887];return _0x8c0bd2;},a9_0x8e98(_0x293b24,_0x511e98);}var Repository_1=require(a9_0xba92de(0x172));Object[a9_0xba92de(0x161)](exports,'Repository',{'enumerable':!![],'get':function(){return Repository_1['Repository'];}});var VirtualColumn_1=require(a9_0xba92de(0x171));Object[a9_0xba92de(0x161)](exports,'VirtualColumn',{'enumerable':!![],'get':function(){var _0x57a3f1=a9_0xba92de;return VirtualColumn_1[_0x57a3f1(0x17f)];}});var InjectEntity_1=require('./decorator/InjectEntity');Object[a9_0xba92de(0x161)](exports,a9_0xba92de(0x16c),{'enumerable':!![],'get':function(){var _0x56ca56=a9_0xba92de;return InjectEntity_1[_0x56ca56(0x16c)];}});var InjectRepository_1=require(a9_0xba92de(0x173));Object[a9_0xba92de(0x161)](exports,a9_0xba92de(0x183),{'enumerable':!![],'get':function(){var _0x378b7e=a9_0xba92de;return InjectRepository_1[_0x378b7e(0x183)];}});var ProvideEntity_1=require(a9_0xba92de(0x163));Object[a9_0xba92de(0x161)](exports,a9_0xba92de(0x176),{'enumerable':!![],'get':function(){var _0x25df5e=a9_0xba92de;return ProvideEntity_1[_0x25df5e(0x176)];}});var ProvideRepository_1=require('./decorator/ProvideRepository');Object[a9_0xba92de(0x161)](exports,a9_0xba92de(0x17a),{'enumerable':!![],'get':function(){var _0x3967fd=a9_0xba92de;return ProvideRepository_1[_0x3967fd(0x17a)];}});var ProvideSearch_1=require(a9_0xba92de(0x16e));Object[a9_0xba92de(0x161)](exports,'ProvideSearch',{'enumerable':!![],'get':function(){var _0x27b718=a9_0xba92de;return ProvideSearch_1[_0x27b718(0x177)];}}),Object[a9_0xba92de(0x161)](exports,a9_0xba92de(0x160),{'enumerable':!![],'get':function(){var _0xa80f09=a9_0xba92de;return ProvideSearch_1[_0xa80f09(0x160)];}});var getDataSourceEntity_1=require(a9_0xba92de(0x15f));Object[a9_0xba92de(0x161)](exports,a9_0xba92de(0x165),{'enumerable':!![],'get':function(){var _0x99e31f=a9_0xba92de;return getDataSourceEntity_1[_0x99e31f(0x165)];}});var configuration_1=require(a9_0xba92de(0x169));Object[a9_0xba92de(0x161)](exports,a9_0xba92de(0x188),{'enumerable':!![],'get':function(){var _0x2107c1=a9_0xba92de;return configuration_1[_0x2107c1(0x17e)];}});var core_1=require(a9_0xba92de(0x17d));Object[a9_0xba92de(0x161)](exports,'Provide',{'enumerable':!![],'get':function(){var _0x3ef292=a9_0xba92de;return core_1[_0x3ef292(0x167)];}}),Object[a9_0xba92de(0x161)](exports,'Inject',{'enumerable':!![],'get':function(){return core_1['Inject'];}}),Object['defineProperty'](exports,a9_0xba92de(0x16b),{'enumerable':!![],'get':function(){return core_1['Scope'];}}),Object[a9_0xba92de(0x161)](exports,a9_0xba92de(0x187),{'enumerable':!![],'get':function(){var _0x1a92a7=a9_0xba92de;return core_1[_0x1a92a7(0x187)];}});
|
package/dist/interface.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a10_0x3bc580=a10_0x293e;function a10_0x3da6(){const _0x4d27ec=['decorator:anncic-api:typeorm:model','ENTIFY_MODULE','EntityManager','hasOwnProperty','EntityNotFoundError','getTime','MODEL_KEY','lockMode','5059775TiRRGv','decorator:anncic-api:typeorm:entify:module:source','3112500DGcwUl','versionColumn','metadata','4THRrYn','resolve','getManyAndCount','ENTITY_VIRTUAL_COLUMN_KEY','decorator:anncic-api:typeorm:entity:virtual:column','SelectQueryBuilder','optimistic','1080428odcxCB','getCount','1034464wkDyid','decorator:anncic-api:typeorm:repository','decorator:anncic-api:typeorm:entify','findOneByOrFail','reject','OptimisticLockCanNotBeUsedError','then','findOneOrFail','REPOSITORY_KEY','default','getMany','getRawAndEntities','10347417ReKpTN','OptimisticLockVersionMismatchError','prototype','ENTIFY_MODULE_SOURCE','393222XpPljV','SearchPaginate','typeorm','2014798WywAig','getEntityValue','MODEL_SEARCH_KEY','expressionMap','49hRYEhi','findOne','lockVersion','getClassMetadata','getOne','ENTIFY_KEY','decorator:anncic-api:typeorm:entify:module','@midwayjs/core','__esModule'];a10_0x3da6=function(){return _0x4d27ec;};return a10_0x3da6();}function a10_0x293e(_0x30bcc8,_0x810020){const _0x3da601=a10_0x3da6();return a10_0x293e=function(_0x293e7e,_0x442d4f){_0x293e7e=_0x293e7e-0x166;let _0x2ad63c=_0x3da601[_0x293e7e];return _0x2ad63c;},a10_0x293e(_0x30bcc8,_0x810020);}(function(_0x54d314,_0x382c3e){const _0x48d68e=a10_0x293e,_0x17a1c2=_0x54d314();while(!![]){try{const _0x86002e=parseInt(_0x48d68e(0x16d))/0x1+parseInt(_0x48d68e(0x182))/0x2+-parseInt(_0x48d68e(0x199))/0x3+-parseInt(_0x48d68e(0x166))/0x4*(parseInt(_0x48d68e(0x197))/0x5)+parseInt(_0x48d68e(0x17f))/0x6*(-parseInt(_0x48d68e(0x186))/0x7)+-parseInt(_0x48d68e(0x16f))/0x8+parseInt(_0x48d68e(0x17b))/0x9;if(_0x86002e===_0x382c3e)break;else _0x17a1c2['push'](_0x17a1c2['shift']());}catch(_0x520317){_0x17a1c2['push'](_0x17a1c2['shift']());}}}(a10_0x3da6,0x927d2));Object['defineProperty'](exports,a10_0x3bc580(0x18e),{'value':!![]}),exports[a10_0x3bc580(0x180)]=exports['ENTITY_VIRTUAL_COLUMN_KEY']=exports[a10_0x3bc580(0x184)]=exports['MODEL_KEY']=exports[a10_0x3bc580(0x177)]=exports['ENTIFY_MODULE_SOURCE']=exports[a10_0x3bc580(0x190)]=exports[a10_0x3bc580(0x18b)]=void 0x0;const core_1=require(a10_0x3bc580(0x18d)),typeorm_1=require(a10_0x3bc580(0x181)),typeorm_2=require(a10_0x3bc580(0x181));exports[a10_0x3bc580(0x18b)]=a10_0x3bc580(0x171),exports[a10_0x3bc580(0x190)]=a10_0x3bc580(0x18c),exports[a10_0x3bc580(0x17e)]=a10_0x3bc580(0x198),exports[a10_0x3bc580(0x177)]=a10_0x3bc580(0x170),exports[a10_0x3bc580(0x195)]=a10_0x3bc580(0x18f),exports[a10_0x3bc580(0x184)]='decorator:anncic-api:typeorm:model:search',exports[a10_0x3bc580(0x169)]=a10_0x3bc580(0x16a);class SearchPaginate{}exports[a10_0x3bc580(0x180)]=SearchPaginate,typeorm_2['EntityManager'][a10_0x3bc580(0x17d)][a10_0x3bc580(0x176)]=async function(_0x162007,_0x2498e4){const _0x29356b=a10_0x3bc580;return this[_0x29356b(0x187)](_0x162007,_0x2498e4)[_0x29356b(0x175)](_0x313ff5=>{const _0x34a7ef=_0x29356b;if(_0x313ff5===null||_0x313ff5===undefined)return Promise[_0x34a7ef(0x173)](new typeorm_2[(_0x34a7ef(0x193))](_0x162007,_0x2498e4));return Promise[_0x34a7ef(0x167)](_0x313ff5);});},typeorm_2[a10_0x3bc580(0x191)][a10_0x3bc580(0x17d)][a10_0x3bc580(0x172)]=async function(_0x5b24c2,_0xb5502e){const _0x54f739=a10_0x3bc580;return this['findOneBy'](_0x5b24c2,_0xb5502e)[_0x54f739(0x175)](_0x524d7c=>{const _0x579502=_0x54f739;if(_0x524d7c===null||_0x524d7c===undefined)return Promise[_0x579502(0x173)](new typeorm_2[(_0x579502(0x193))](_0x5b24c2,_0xb5502e));return Promise['resolve'](_0x524d7c);});},typeorm_1[a10_0x3bc580(0x16b)][a10_0x3bc580(0x17d)][a10_0x3bc580(0x179)]=async function(){const _0x550bd3=a10_0x3bc580;if(this[_0x550bd3(0x185)]['lockMode']==='optimistic')throw new typeorm_1[(_0x550bd3(0x174))]();const {entities:_0x2336b5,raw:_0x2bc337}=await this[_0x550bd3(0x17a)]();return _0x2336b5['map']((_0x1ded43,_0x8bc810)=>{const _0x3ec81d=_0x550bd3;var _0x3c9be3;const _0x58a86d=(0x0,core_1['getClassMetadata'])(exports['ENTITY_VIRTUAL_COLUMN_KEY'],_0x1ded43)||{};for(const _0x3d9bd1 in _0x58a86d){_0x2bc337[_0x8bc810]&&_0x2bc337[_0x8bc810]['hasOwnProperty'](_0x3d9bd1)&&(_0x1ded43[_0x3d9bd1]=_0x2bc337[_0x8bc810][_0x3d9bd1]||((_0x3c9be3=_0x58a86d[_0x3d9bd1])===null||_0x3c9be3===void 0x0?void 0x0:_0x3c9be3[_0x3ec81d(0x178)])||'');}return _0x1ded43;});},typeorm_1['SelectQueryBuilder'][a10_0x3bc580(0x17d)][a10_0x3bc580(0x168)]=async function(){const _0x4bc02=a10_0x3bc580;return[await this[_0x4bc02(0x179)](),await this[_0x4bc02(0x16e)]()];},typeorm_1[a10_0x3bc580(0x16b)][a10_0x3bc580(0x17d)][a10_0x3bc580(0x18a)]=async function(){const _0x2dd852=a10_0x3bc580;var _0x42681c;const {entities:_0x210e4a,raw:_0x4013cb}=await this[_0x2dd852(0x17a)]();if(_0x210e4a[0x0]&&this[_0x2dd852(0x185)][_0x2dd852(0x196)]===_0x2dd852(0x16c)&&this[_0x2dd852(0x185)]['lockVersion']){const _0x1484c1=this[_0x2dd852(0x185)]['mainAlias'][_0x2dd852(0x19b)];if(this[_0x2dd852(0x185)][_0x2dd852(0x188)]instanceof Date){const _0xd558f6=_0x1484c1['updateDateColumn'][_0x2dd852(0x183)](_0x210e4a[0x0]);if(_0xd558f6['getTime']()!==this[_0x2dd852(0x185)][_0x2dd852(0x188)][_0x2dd852(0x194)]())throw new typeorm_1[(_0x2dd852(0x17c))](_0x1484c1['name'],this[_0x2dd852(0x185)]['lockVersion'],_0xd558f6);}else{const _0x2b1f21=_0x1484c1[_0x2dd852(0x19a)]['getEntityValue'](_0x210e4a[0x0]);if(_0x2b1f21!==this[_0x2dd852(0x185)]['lockVersion'])throw new typeorm_1[(_0x2dd852(0x17c))](_0x1484c1['name'],this['expressionMap']['lockVersion'],_0x2b1f21);}}if(_0x210e4a[0x0]&&_0x4013cb[0x0]){const _0x4ee1e1=(0x0,core_1[_0x2dd852(0x189)])(exports['ENTITY_VIRTUAL_COLUMN_KEY'],_0x210e4a[0x0]);for(const _0x1fc61b in _0x4ee1e1){_0x4013cb[0x0][_0x2dd852(0x192)](_0x1fc61b)&&(_0x210e4a[0x0][_0x1fc61b]=_0x4013cb[0x0][_0x1fc61b]||((_0x42681c=_0x4ee1e1[_0x1fc61b])===null||_0x42681c===void 0x0?void 0x0:_0x42681c[_0x2dd852(0x178)])||'');}}return _0x210e4a[0x0]||null;};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anncic-api/typeorm",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.6",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"files": [
|
|
@@ -22,5 +22,5 @@
|
|
|
22
22
|
"javascript-obfuscator": "2.19.0",
|
|
23
23
|
"typescript": "^4.7.4"
|
|
24
24
|
},
|
|
25
|
-
"gitHead": "
|
|
25
|
+
"gitHead": "72f135b6b4e51ed0ab07c69d973c31361a68a47e"
|
|
26
26
|
}
|