@anncic-api/typeorm 1.3.3 → 1.3.5
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 +3 -3
package/dist/configuration.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a0_0x14c02a=a0_0x2898;(function(_0x39e414,_0xe8971){const _0x4f0ea6=a0_0x2898,_0x24485c=_0x39e414();while(!![]){try{const _0x22688a=parseInt(_0x4f0ea6(0xf7))/0x1*(parseInt(_0x4f0ea6(0x115))/0x2)+parseInt(_0x4f0ea6(0x119))/0x3*(-parseInt(_0x4f0ea6(0xf9))/0x4)+-parseInt(_0x4f0ea6(0xf6))/0x5+parseInt(_0x4f0ea6(0xf8))/0x6+parseInt(_0x4f0ea6(0xfa))/0x7+-parseInt(_0x4f0ea6(0x106))/0x8*(-parseInt(_0x4f0ea6(0x11a))/0x9)+-parseInt(_0x4f0ea6(0x111))/0xa;if(_0x22688a===_0xe8971)break;else _0x24485c['push'](_0x24485c['shift']());}catch(_0x4210ba){_0x24485c['push'](_0x24485c['shift']());}}}(a0_0x4039,0x6e025));function a0_0x4039(){const _0xb76dac=['Configuration','getDataSourceNameByModel','399024ibZazj','CustomConfiguration','metadata','find','MidwayDecoratorService','decorate','REPOSITORY_KEY','typeorm','__esModule','TypeORMError','./interface','15541890UkUFNE','name','production','middlewareError','10538sAMxZx','getEnv','function','@midwayjs/core','51pRyUTh','90blXlpq','TypeORMDataSourceManager','design:type','__metadata','target','Repository','@midwayjs/typeorm','./definition/Repository','body','Inject','getOwnPropertyDescriptor','decorator','getRepository','push','object','prototype','handlercache','1377005WtQuxm','164QAKeVh','4361844iyQzUV','146404rJdLeC','5687738pFDuqk','MidwayConfigService','length','ENTIFY_KEY','anncic-api:typeorm','onReady','config','getDataSource','registerPropertyHandler','\x20is\x20not\x20ProvideRepository\x20Entify'];a0_0x4039=function(){return _0xb76dac;};return a0_0x4039();}var __decorate=this&&this['__decorate']||function(_0x3ad096,_0x3c8d21,_0x91ba97,_0x57a233){const _0x10cee6=a0_0x2898;var _0x1a1a31=arguments[_0x10cee6(0xfc)],_0x2f9ac5=_0x1a1a31<0x3?_0x3c8d21:_0x57a233===null?_0x57a233=Object[_0x10cee6(0xef)](_0x3c8d21,_0x91ba97):_0x57a233,_0x11204d;if(typeof Reflect===_0x10cee6(0xf3)&&typeof Reflect[_0x10cee6(0x10b)]===_0x10cee6(0x117))_0x2f9ac5=Reflect['decorate'](_0x3ad096,_0x3c8d21,_0x91ba97,_0x57a233);else{for(var _0x31516f=_0x3ad096['length']-0x1;_0x31516f>=0x0;_0x31516f--)if(_0x11204d=_0x3ad096[_0x31516f])_0x2f9ac5=(_0x1a1a31<0x3?_0x11204d(_0x2f9ac5):_0x1a1a31>0x3?_0x11204d(_0x3c8d21,_0x91ba97,_0x2f9ac5):_0x11204d(_0x3c8d21,_0x91ba97))||_0x2f9ac5;}return _0x1a1a31>0x3&&_0x2f9ac5&&Object['defineProperty'](_0x3c8d21,_0x91ba97,_0x2f9ac5),_0x2f9ac5;},__metadata=this&&this[a0_0x14c02a(0x11d)]||function(_0x5d2460,_0x1611aa){const _0xd04c4b=a0_0x14c02a;if(typeof Reflect===_0xd04c4b(0xf3)&&typeof Reflect[_0xd04c4b(0x108)]==='function')return Reflect['metadata'](_0x5d2460,_0x1611aa);};Object['defineProperty'](exports,a0_0x14c02a(0x10e),{'value':!![]}),exports[a0_0x14c02a(0x107)]=void 0x0;const typeorm_1=require('@midwayjs/typeorm'),core_1=require('@midwayjs/core'),core_2=require(a0_0x14c02a(0x118)),typeorm_2=require(a0_0x14c02a(0x10d)),Repository_1=require(a0_0x14c02a(0xec)),interface_1=require(a0_0x14c02a(0x110)),typeorm=require(a0_0x14c02a(0xeb));function a0_0x2898(_0x280547,_0xfac264){const _0x4039cc=a0_0x4039();return a0_0x2898=function(_0x2898f2,_0x488424){_0x2898f2=_0x2898f2-0xeb;let _0x1a6102=_0x4039cc[_0x2898f2];return _0x1a6102;},a0_0x2898(_0x280547,_0xfac264);}let CustomConfiguration=class CustomConfiguration{constructor(){const _0x338b52=a0_0x14c02a;this[_0x338b52(0xf5)]=[];}async[a0_0x14c02a(0xff)](_0x1d4a29,_0x487d2f){const _0x323725=a0_0x14c02a,_0x368a37=await _0x1d4a29['getAsync'](typeorm_1[_0x323725(0x11b)]);this[_0x323725(0xf0)]['registerPropertyHandler'](interface_1[_0x323725(0xfd)],(_0x72d0c9,{entity:_0x443713,connection:_0x19249b})=>{const _0x113c67=_0x323725;let _0x3a4bb9=this[_0x113c67(0xf5)][_0x113c67(0x109)](_0x25d126=>_0x25d126[_0x113c67(0x11e)]===_0x443713);return!_0x3a4bb9&&(_0x3a4bb9=new Repository_1[(_0x113c67(0x11f))](_0x487d2f,_0x368a37['getDataSource'](_0x19249b||_0x368a37[_0x113c67(0x105)](_0x443713))[_0x113c67(0xf1)](_0x443713)),this[_0x113c67(0xf5)][_0x113c67(0xf2)](_0x3a4bb9)),_0x3a4bb9;}),this[_0x323725(0xf0)][_0x323725(0x102)](interface_1[_0x323725(0x10c)],(_0x709468,{repository:_0x5eca1b,connection:_0x3def64})=>{const _0x1a43fd=_0x323725,{entity:_0xd266e4}=(0x0,core_1['getClassMetadata'])(interface_1['REPOSITORY_KEY'],_0x5eca1b)||{};if(!_0xd266e4)throw new Error('anncic-api-typeorm\x20Error\x20'+((_0x5eca1b===null||_0x5eca1b===void 0x0?void 0x0:_0x5eca1b[_0x1a43fd(0x112)])||_0x5eca1b)+_0x1a43fd(0x103));let _0x485be1=this[_0x1a43fd(0xf5)][_0x1a43fd(0x109)](_0x18e1ac=>_0x18e1ac===_0x5eca1b);return!_0x485be1&&(_0x485be1=new _0x5eca1b(_0x487d2f,_0x368a37[_0x1a43fd(0x101)](_0x3def64||_0x368a37[_0x1a43fd(0x105)](_0xd266e4))[_0x1a43fd(0xf1)](_0xd266e4)),this[_0x1a43fd(0xf5)][_0x1a43fd(0xf2)](_0x485be1)),_0x485be1;}),_0x487d2f['useMiddleware'](this['middlewareError'](_0x487d2f));}[a0_0x14c02a(0x114)](_0x8dfe9){return async(_0x236427,_0x304766)=>{const _0x2219d0=a0_0x2898;try{await _0x304766();}catch(_0x31e1f8){if(_0x31e1f8 instanceof typeorm_2[_0x2219d0(0x10f)])_0x31e1f8 instanceof typeorm_2['EntityNotFoundError']?_0x236427[_0x2219d0(0xed)]={'code':0x194,'msg':'数据不存在'}:(_0x236427['body']={'code':0x1f4,'msg':_0x31e1f8['message']},_0x8dfe9[_0x2219d0(0x116)]()!=_0x2219d0(0x113)&&console['warn'](_0x31e1f8));else throw _0x31e1f8;}};}};__decorate([(0x0,core_1[a0_0x14c02a(0xee)])(),__metadata(a0_0x14c02a(0x11c),core_2[a0_0x14c02a(0xfb)])],CustomConfiguration[a0_0x14c02a(0xf4)],a0_0x14c02a(0x100),void 0x0),__decorate([(0x0,core_1[a0_0x14c02a(0xee)])(),__metadata(a0_0x14c02a(0x11c),core_2[a0_0x14c02a(0x10a)])],CustomConfiguration[a0_0x14c02a(0xf4)],'decorator',void 0x0),CustomConfiguration=__decorate([(0x0,core_1[a0_0x14c02a(0x104)])({'imports':[typeorm],'conflictCheck':![],'namespace':a0_0x14c02a(0xfe)})],CustomConfiguration),exports['CustomConfiguration']=CustomConfiguration;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a1_0x31e990=a1_0x456f;function a1_0x456f(_0x4d1ed4,_0x450724){const _0x365895=a1_0x3658();return a1_0x456f=function(_0x456f88,_0x547d9e){_0x456f88=_0x456f88-0x17a;let _0x458bf8=_0x365895[_0x456f88];return _0x458bf8;},a1_0x456f(_0x4d1ed4,_0x450724);}(function(_0x1a932b,_0x1b3186){const _0x4d3898=a1_0x456f,_0x124f1b=_0x1a932b();while(!![]){try{const _0x4933f0=parseInt(_0x4d3898(0x188))/0x1+parseInt(_0x4d3898(0x18a))/0x2+-parseInt(_0x4d3898(0x183))/0x3*(parseInt(_0x4d3898(0x17d))/0x4)+parseInt(_0x4d3898(0x185))/0x5*(parseInt(_0x4d3898(0x187))/0x6)+parseInt(_0x4d3898(0x186))/0x7+parseInt(_0x4d3898(0x17e))/0x8+parseInt(_0x4d3898(0x189))/0x9*(-parseInt(_0x4d3898(0x181))/0xa);if(_0x4933f0===_0x1b3186)break;else _0x124f1b['push'](_0x124f1b['shift']());}catch(_0x301424){_0x124f1b['push'](_0x124f1b['shift']());}}}(a1_0x3658,0xcaf16));function a1_0x3658(){const _0x3473a0=['__esModule','defineProperty','../interface','default','368IVtXdM','1691456wyAjzc','InjectEntity','@midwayjs/core','12763950dCFpAV','ENTIFY_KEY','41226vCtvSl','createCustomPropertyDecorator','305qXJAIb','1099161rVCNtr','149658jzPzPi','1622315USBnYE','18lVDKCg','2272030pusSon'];a1_0x3658=function(){return _0x3473a0;};return a1_0x3658();}Object[a1_0x31e990(0x17a)](exports,a1_0x31e990(0x18b),{'value':!![]}),exports['InjectEntity']=void 0x0;const core_1=require(a1_0x31e990(0x180)),interface_1=require(a1_0x31e990(0x17b));function InjectEntity(_0x43553a,_0x5d29ea=a1_0x31e990(0x17c)){const _0x3a6324=a1_0x31e990;return(0x0,core_1[_0x3a6324(0x184)])(interface_1[_0x3a6324(0x182)],{'entity':_0x43553a,'connection':_0x5d29ea});}exports[a1_0x31e990(0x17f)]=InjectEntity;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';function
|
|
1
|
+
'use strict';function a2_0x1f71(){const _0x4e51da=['3136032tNVEAh','InjectRepository','4145zoaevi','41HWxIVt','8682YTcfYC','34852GBoRKA','../interface','10665171EjFXgD','10607680PoxkTC','2237172oZYeVZ','__esModule','7RCpDxr','13913830cZcwSP','REPOSITORY_KEY','createCustomPropertyDecorator'];a2_0x1f71=function(){return _0x4e51da;};return a2_0x1f71();}const a2_0x5ae4be=a2_0x3c4d;(function(_0x5b575a,_0x1d61a3){const _0x3cd3c2=a2_0x3c4d,_0x28c17c=_0x5b575a();while(!![]){try{const _0x303dbc=parseInt(_0x3cd3c2(0x14c))/0x1*(-parseInt(_0x3cd3c2(0x14e))/0x2)+parseInt(_0x3cd3c2(0x152))/0x3+parseInt(_0x3cd3c2(0x149))/0x4+parseInt(_0x3cd3c2(0x14b))/0x5*(-parseInt(_0x3cd3c2(0x14d))/0x6)+-parseInt(_0x3cd3c2(0x145))/0x7*(parseInt(_0x3cd3c2(0x151))/0x8)+parseInt(_0x3cd3c2(0x150))/0x9+parseInt(_0x3cd3c2(0x146))/0xa;if(_0x303dbc===_0x1d61a3)break;else _0x28c17c['push'](_0x28c17c['shift']());}catch(_0x469947){_0x28c17c['push'](_0x28c17c['shift']());}}}(a2_0x1f71,0xd3761));Object['defineProperty'](exports,a2_0x5ae4be(0x153),{'value':!![]}),exports[a2_0x5ae4be(0x14a)]=void 0x0;const core_1=require('@midwayjs/core'),interface_1=require(a2_0x5ae4be(0x14f));function InjectRepository(_0x3a3531,_0x20fcf9='default'){const _0x44815b=a2_0x5ae4be;return(0x0,core_1[_0x44815b(0x148)])(interface_1[_0x44815b(0x147)],{'repository':_0x3a3531,'connection':_0x20fcf9});}function a2_0x3c4d(_0x34b783,_0x1ed682){const _0x1f71d8=a2_0x1f71();return a2_0x3c4d=function(_0x3c4d19,_0x3305ae){_0x3c4d19=_0x3c4d19-0x145;let _0x31d5c5=_0x1f71d8[_0x3c4d19];return _0x31d5c5;},a2_0x3c4d(_0x34b783,_0x1ed682);}exports['InjectRepository']=InjectRepository;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a3_0x356011=a3_0x28ab;(function(_0x4e5322,_0x36e615){const _0x23af36=a3_0x28ab,_0x3a2bf6=_0x4e5322();while(!![]){try{const _0x2171a8=parseInt(_0x23af36(0x18b))/0x1*(parseInt(_0x23af36(0x18f))/0x2)+parseInt(_0x23af36(0x17f))/0x3*(parseInt(_0x23af36(0x18a))/0x4)+parseInt(_0x23af36(0x180))/0x5*(parseInt(_0x23af36(0x18c))/0x6)+parseInt(_0x23af36(0x186))/0x7+parseInt(_0x23af36(0x17a))/0x8+parseInt(_0x23af36(0x184))/0x9+-parseInt(_0x23af36(0x181))/0xa;if(_0x2171a8===_0x36e615)break;else _0x3a2bf6['push'](_0x3a2bf6['shift']());}catch(_0x31bd64){_0x3a2bf6['push'](_0x3a2bf6['shift']());}}}(a3_0x3e4f,0x1b4ec));function a3_0x28ab(_0x193cee,_0x4cbcc2){const _0x3e4f2c=a3_0x3e4f();return a3_0x28ab=function(_0x28ab74,_0x3ba4f6){_0x28ab74=_0x28ab74-0x179;let _0x59e13b=_0x3e4f2c[_0x28ab74];return _0x59e13b;},a3_0x28ab(_0x193cee,_0x4cbcc2);}Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[a3_0x356011(0x187)]=void 0x0;const typeorm_1=require(a3_0x356011(0x182)),core_1=require(a3_0x356011(0x185)),interface_1=require(a3_0x356011(0x17c));function ProvideEntity(_0x970d6a,_0xebd361={}){return _0x445977=>{const _0x5910a0=a3_0x28ab;_0xebd361[_0x5910a0(0x18e)]=_0x970d6a[_0x5910a0(0x17b)];const _0x2850d8=[];if(!(_0x970d6a===null||_0x970d6a===void 0x0?void 0x0:_0x970d6a['dataSource']))_0x2850d8[_0x5910a0(0x179)](_0x5910a0(0x18d));else{if(typeof(_0x970d6a===null||_0x970d6a===void 0x0?void 0x0:_0x970d6a[_0x5910a0(0x188)])==_0x5910a0(0x17e))_0x2850d8[_0x5910a0(0x179)](_0x970d6a===null||_0x970d6a===void 0x0?void 0x0:_0x970d6a[_0x5910a0(0x188)]);else{if(Array['isArray'](_0x970d6a===null||_0x970d6a===void 0x0?void 0x0:_0x970d6a[_0x5910a0(0x188)]))for(let _0x404662 of _0x970d6a[_0x5910a0(0x188)]||[_0x5910a0(0x18d)]){_0x2850d8[_0x5910a0(0x179)](_0x404662);}}}(0x0,core_1['saveModule'])(interface_1[_0x5910a0(0x183)],_0x445977),(0x0,core_1[_0x5910a0(0x17d)])(interface_1[_0x5910a0(0x189)],{'tableName':_0x970d6a['tableName'],'dataSource':_0x2850d8},_0x445977),(0x0,typeorm_1['Entity'])(_0x970d6a[_0x5910a0(0x17b)],_0xebd361)(_0x445977);};}exports[a3_0x356011(0x187)]=ProvideEntity;function a3_0x3e4f(){const _0x15f2ad=['typeorm','ENTIFY_MODULE','986751bvezVa','@midwayjs/core','357021aJBEqa','ProvideEntity','dataSource','ENTIFY_MODULE_SOURCE','145524PxxwTx','29ilttyY','12CoiDNS','default','name','878hneRdJ','push','914224jQFBBl','tableName','../interface','saveClassMetadata','string','3kyYdgD','263380iROprP','3175320TmPOWu'];a3_0x3e4f=function(){return _0x15f2ad;};return a3_0x3e4f();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a4_0x34bb50=a4_0x2915;(function(_0x2f7d80,_0x145e6b){const _0x1d83a6=a4_0x2915,_0x4cf3b0=_0x2f7d80();while(!![]){try{const _0x192331=-parseInt(_0x1d83a6(0x16f))/0x1*(parseInt(_0x1d83a6(0x169))/0x2)+parseInt(_0x1d83a6(0x175))/0x3*(parseInt(_0x1d83a6(0x176))/0x4)+-parseInt(_0x1d83a6(0x16d))/0x5+parseInt(_0x1d83a6(0x166))/0x6*(-parseInt(_0x1d83a6(0x16a))/0x7)+-parseInt(_0x1d83a6(0x171))/0x8*(-parseInt(_0x1d83a6(0x172))/0x9)+-parseInt(_0x1d83a6(0x16b))/0xa+-parseInt(_0x1d83a6(0x174))/0xb*(-parseInt(_0x1d83a6(0x167))/0xc);if(_0x192331===_0x145e6b)break;else _0x4cf3b0['push'](_0x4cf3b0['shift']());}catch(_0x4f49b6){_0x4cf3b0['push'](_0x4cf3b0['shift']());}}}(a4_0x1e22,0x5ea5c));function a4_0x1e22(){const _0x176b60=['4zQGWVD','../interface','ScopeEnum','defineProperty','6ZbjXwr','5796ykjGzE','ProvideRepository','2rmtiaM','1866669idjpRI','670860LscScI','Provide','3873220MEzSxy','@midwayjs/core','45242HUFgMg','saveClassMetadata','120GswQtJ','426366aOOwZc','__esModule','2486pxJTty','2164641urzJMo'];a4_0x1e22=function(){return _0x176b60;};return a4_0x1e22();}Object[a4_0x34bb50(0x179)](exports,a4_0x34bb50(0x173),{'value':!![]}),exports[a4_0x34bb50(0x168)]=void 0x0;const core_1=require(a4_0x34bb50(0x16e)),interface_1=require(a4_0x34bb50(0x177));function ProvideRepository(_0x41d3a6){return _0x20b0e4=>{const _0x5cf6e1=a4_0x2915;(0x0,core_1['Scope'])(core_1[_0x5cf6e1(0x178)]['Request'],{'allowDowngrade':!![]})(_0x20b0e4),((0x0,core_1[_0x5cf6e1(0x16c)])()(_0x20b0e4),(0x0,core_1[_0x5cf6e1(0x170)])(interface_1['REPOSITORY_KEY'],{'entity':_0x41d3a6},_0x20b0e4));};}function a4_0x2915(_0x1e6404,_0x30c3f1){const _0x1e2248=a4_0x1e22();return a4_0x2915=function(_0x291556,_0x584abc){_0x291556=_0x291556-0x166;let _0x4b264c=_0x1e2248[_0x291556];return _0x4b264c;},a4_0x2915(_0x1e6404,_0x30c3f1);}exports[a4_0x34bb50(0x168)]=ProvideRepository;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a5_0x3b8406=a5_0x5bfc;(function(_0x245037,_0x5c74a7){const _0x2c98cd=a5_0x5bfc,_0x44c872=_0x245037();while(!![]){try{const _0x59155=-parseInt(_0x2c98cd(0xcf))/0x1*(parseInt(_0x2c98cd(0xd2))/0x2)+-parseInt(_0x2c98cd(0xe4))/0x3*(-parseInt(_0x2c98cd(0xd8))/0x4)+parseInt(_0x2c98cd(0xd0))/0x5+parseInt(_0x2c98cd(0xd7))/0x6*(-parseInt(_0x2c98cd(0xce))/0x7)+-parseInt(_0x2c98cd(0xda))/0x8*(-parseInt(_0x2c98cd(0xe5))/0x9)+-parseInt(_0x2c98cd(0xd4))/0xa*(-parseInt(_0x2c98cd(0xe1))/0xb)+-parseInt(_0x2c98cd(0xdd))/0xc;if(_0x59155===_0x5c74a7)break;else _0x44c872['push'](_0x44c872['shift']());}catch(_0x3c239){_0x44c872['push'](_0x44c872['shift']());}}}(a5_0x2d0e,0x42e7e));function a5_0x2d0e(){const _0x5f0eb2=['../interface','saveModule','3657324nnoJjx','MODEL_SEARCH_KEY','Search','defineProperty','20383SxOfLr','MODEL_KEY','ProvideSearch','24IgZrWk','111015pawIFz','3015089uFmOqz','253kUBdqi','595805USbFuG','ScopeEnum','1354orwNjf','attachClassMetadata','1930FWIfIb','Singleton','Scope','6HShQos','259508YxQOoX','@midwayjs/core','120bRKPgA'];a5_0x2d0e=function(){return _0x5f0eb2;};return a5_0x2d0e();}function a5_0x5bfc(_0x3a349c,_0x3bccdb){const _0x2d0ee3=a5_0x2d0e();return a5_0x5bfc=function(_0x5bfcfb,_0x318dab){_0x5bfcfb=_0x5bfcfb-0xce;let _0x3a9762=_0x2d0ee3[_0x5bfcfb];return _0x3a9762;},a5_0x5bfc(_0x3a349c,_0x3bccdb);}Object[a5_0x3b8406(0xe0)](exports,'__esModule',{'value':!![]}),exports[a5_0x3b8406(0xdf)]=exports[a5_0x3b8406(0xe3)]=void 0x0;const core_1=require(a5_0x3b8406(0xd9)),interface_1=require(a5_0x3b8406(0xdb));function ProvideSearch(_0x16a11e){return _0x2b26e2=>{const _0x1005cc=a5_0x5bfc;(0x0,core_1[_0x1005cc(0xdc)])(interface_1['MODEL_KEY'],_0x2b26e2),(0x0,core_1[_0x1005cc(0xd6)])(core_1[_0x1005cc(0xd1)][_0x1005cc(0xd5)])(_0x2b26e2),(0x0,core_1[_0x1005cc(0xd3)])(interface_1[_0x1005cc(0xe2)],_0x16a11e,_0x2b26e2);};}exports[a5_0x3b8406(0xe3)]=ProvideSearch;function Search(_0x2a6405,_0x2f7846){return(_0x47a4df,_0x2869c4,_0x4782fd)=>{const _0x4c14c0=a5_0x5bfc;(0x0,core_1[_0x4c14c0(0xd3)])(interface_1[_0x4c14c0(0xde)],{'field':_0x2a6405,'comment':_0x2f7846,'target':_0x47a4df,'methodName':_0x2869c4,'descriptor':_0x4782fd},_0x47a4df);};}exports[a5_0x3b8406(0xdf)]=Search;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';function a6_0x29fd(_0x5a4991,_0x2412b4){const _0x2b1714=a6_0x2b17();return a6_0x29fd=function(_0x29fde2,_0x55289e){_0x29fde2=_0x29fde2-0x138;let _0x33fe63=_0x2b1714[_0x29fde2];return _0x33fe63;},a6_0x29fd(_0x5a4991,_0x2412b4);}function a6_0x2b17(){const _0x5d5855=['getClassMetadata','saveClassMetadata','1236HxMLpB','1653pnaMFs','VirtualColumn','3004hHdPlX','6414kQUhTU','60247WaTwOT','615xkUQPv','12CSWltd','../interface','10KUTgpr','__esModule','ENTITY_VIRTUAL_COLUMN_KEY','1681839vpsrLi','4573422MkQRzu','68424HoAysW','4091880AYRaZL'];a6_0x2b17=function(){return _0x5d5855;};return a6_0x2b17();}const a6_0x202862=a6_0x29fd;(function(_0x2f59cb,_0x133ded){const _0x498fa4=a6_0x29fd,_0x8b046a=_0x2f59cb();while(!![]){try{const _0x70235e=-parseInt(_0x498fa4(0x13d))/0x1*(-parseInt(_0x498fa4(0x148))/0x2)+-parseInt(_0x498fa4(0x142))/0x3*(-parseInt(_0x498fa4(0x144))/0x4)+parseInt(_0x498fa4(0x147))/0x5*(parseInt(_0x498fa4(0x145))/0x6)+parseInt(_0x498fa4(0x13c))/0x7+-parseInt(_0x498fa4(0x13e))/0x8+-parseInt(_0x498fa4(0x13b))/0x9*(parseInt(_0x498fa4(0x138))/0xa)+parseInt(_0x498fa4(0x146))/0xb*(-parseInt(_0x498fa4(0x141))/0xc);if(_0x70235e===_0x133ded)break;else _0x8b046a['push'](_0x8b046a['shift']());}catch(_0x59b308){_0x8b046a['push'](_0x8b046a['shift']());}}}(a6_0x2b17,0x54a43));Object['defineProperty'](exports,a6_0x202862(0x139),{'value':!![]}),exports[a6_0x202862(0x143)]=void 0x0;const core_1=require('@midwayjs/core'),interface_1=require(a6_0x202862(0x149));function VirtualColumn(_0x4031b0,_0x5c8573){return(_0x357fd3,_0x4974eb)=>{const _0xc6032d=a6_0x29fd,_0x22e96e=(0x0,core_1[_0xc6032d(0x13f)])(interface_1[_0xc6032d(0x13a)],_0x357fd3)||{};_0x22e96e[_0x4974eb]={'comment':_0x4031b0,..._0x5c8573},(0x0,core_1[_0xc6032d(0x140)])(interface_1[_0xc6032d(0x13a)],_0x22e96e,_0x357fd3);};}exports[a6_0x202862(0x143)]=VirtualColumn;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';function a7_0x1ab5(_0x4e6228,_0x2c4914){const _0x1d7895=a7_0x1d78();return a7_0x1ab5=function(_0x1ab526,_0x16511d){_0x1ab526=_0x1ab526-0xfd;let _0x47b29a=_0x1d7895[_0x1ab526];return _0x47b29a;},a7_0x1ab5(_0x4e6228,_0x2c4914);}const a7_0x746606=a7_0x1ab5;(function(_0x7c03e8,_0x3c69df){const _0x3a634b=a7_0x1ab5,_0x2d477a=_0x7c03e8();while(!![]){try{const _0x2ba07d=-parseInt(_0x3a634b(0x121))/0x1*(parseInt(_0x3a634b(0x108))/0x2)+-parseInt(_0x3a634b(0x111))/0x3+-parseInt(_0x3a634b(0x119))/0x4*(parseInt(_0x3a634b(0x113))/0x5)+-parseInt(_0x3a634b(0x117))/0x6*(parseInt(_0x3a634b(0x109))/0x7)+-parseInt(_0x3a634b(0x132))/0x8*(-parseInt(_0x3a634b(0x114))/0x9)+parseInt(_0x3a634b(0x104))/0xa+parseInt(_0x3a634b(0x10b))/0xb*(parseInt(_0x3a634b(0x112))/0xc);if(_0x2ba07d===_0x3c69df)break;else _0x2d477a['push'](_0x2d477a['shift']());}catch(_0x2fcc11){_0x2d477a['push'](_0x2d477a['shift']());}}}(a7_0x1d78,0x7eb4a));function a7_0x1d78(){const _0xea5172=['24lGAPpM','excess','_order','manager','defineProperty','\x20=\x20:_auto_','_auto_','ceil','_isreverse','createQueryBuilder','type','NOT\x20BETWEEN','NOT\x20LIKE','../interface','findColumnWithPropertyName','LIKE','_size','metadata','createSave','isArray','name','\x20AND\x20:','FIND\x20IN\x20SET','searchs','function','getAsync','field','abs','split','1589290eFzSVG','undefined','andWhere','length','4042JLtXed','476seyIhd','NOT\x20FIND\x20IN\x20SET','1441nxVBzb','ASC','push','string','indexOf','bind','2570856cQJwFB','147192vVCbpw','277345yYGdWu','2184543XTzKKL','typeorm','methodName','606UEQkhJ','DESC','52dvKYyD','target','\x20like\x20:_auto_','app','String','orderBy','skip','mergeSave','193fOhQgT','operator','alias','@midwayjs/core','transaction','random','getClassMetadata','search','create','merge','save','toUpperCase','_page','modelSearchs','model','__esModule','hasOwnProperty'];a7_0x1d78=function(){return _0xea5172;};return a7_0x1d78();}Object[a7_0x746606(0x136)](exports,a7_0x746606(0x130),{'value':!![]}),exports['Repository']=void 0x0;const core_1=require(a7_0x746606(0x124)),typeorm_1=require(a7_0x746606(0x115)),interface_1=require(a7_0x746606(0x13f));class Repository extends typeorm_1['Repository']{constructor(_0x4d5658,_0x496cf3){const _0x582898=a7_0x746606;super(_0x496cf3[_0x582898(0x11a)],_0x496cf3[_0x582898(0x135)],_0x496cf3['queryRunner']),this[_0x582898(0x12e)]=[];for(const _0x107a91 of(0x0,core_1[_0x582898(0x127)])(interface_1['MODEL_KEY'],this['target'])||[]){const _0x56fb42={'model':_0x107a91,'searchs':[]};for(const _0x148ff4 of(0x0,core_1[_0x582898(0x127)])(interface_1['MODEL_SEARCH_KEY'],_0x107a91)||[]){_0x56fb42[_0x582898(0xfe)][_0x582898(0x10d)](_0x148ff4);}this[_0x582898(0x12e)][_0x582898(0x10d)](_0x56fb42);}this[_0x582898(0x11c)]=_0x4d5658;}async[a7_0x746606(0x128)](_0x56de71,_0x189069,_0x5f4d42={}){const _0x2709ce=a7_0x746606;var _0x50f53e,_0x199ec3,_0x5e3ec5,_0x48ee54,_0x8d75eb,_0x25b65f;const _0x278d7b=this[_0x2709ce(0x13b)](undefined,_0x5f4d42===null||_0x5f4d42===void 0x0?void 0x0:_0x5f4d42['queryRunner']),_0x3c507b=[];for(const _0x393b0f of this[_0x2709ce(0x12e)]){if((_0x393b0f===null||_0x393b0f===void 0x0?void 0x0:_0x393b0f[_0x2709ce(0x12f)])&&((_0x50f53e=_0x393b0f===null||_0x393b0f===void 0x0?void 0x0:_0x393b0f['searchs'])===null||_0x50f53e===void 0x0?void 0x0:_0x50f53e['length'])>0x0){const _0x504c96=await this[_0x2709ce(0x11c)]['getApplicationContext']()[_0x2709ce(0x100)](_0x393b0f[_0x2709ce(0x12f)]);for(const _0x4406fd of _0x393b0f[_0x2709ce(0xfe)]){(_0x4406fd===null||_0x4406fd===void 0x0?void 0x0:_0x4406fd[_0x2709ce(0x101)])&&(_0x4406fd===null||_0x4406fd===void 0x0?void 0x0:_0x4406fd['methodName'])&&typeof _0x504c96[_0x4406fd['methodName']]==_0x2709ce(0xff)&&(typeof(_0x56de71===null||_0x56de71===void 0x0?void 0x0:_0x56de71[_0x4406fd[_0x2709ce(0x101)]])!=_0x2709ce(0x105)&&!((_0x199ec3=_0x56de71===null||_0x56de71===void 0x0?void 0x0:_0x56de71[_0x4406fd[_0x2709ce(0x101)]])===null||_0x199ec3===void 0x0?void 0x0:_0x199ec3[_0x2709ce(0x131)](_0x2709ce(0x122)))&&(_0x3c507b[_0x2709ce(0x10f)](_0x4406fd[_0x2709ce(0x101)])==-0x1&&_0x3c507b[_0x2709ce(0x10d)](_0x4406fd[_0x2709ce(0x101)]),await _0x504c96[_0x4406fd[_0x2709ce(0x116)]][_0x2709ce(0x110)](_0x504c96)(_0x278d7b,_0x56de71[_0x4406fd[_0x2709ce(0x101)]],_0x56de71,_0x189069,_0x5f4d42===null||_0x5f4d42===void 0x0?void 0x0:_0x5f4d42['queryRunner'])));}}}for(const _0x585efb in _0x56de71){if(typeof _0x56de71[_0x585efb]!=_0x2709ce(0x105)&&_0x3c507b[_0x2709ce(0x10f)](_0x585efb)==-0x1){const _0x433cb8=this[_0x2709ce(0x143)][_0x2709ce(0x140)](_0x585efb);if(_0x433cb8){if((_0x5e3ec5=_0x56de71===null||_0x56de71===void 0x0?void 0x0:_0x56de71[_0x585efb])===null||_0x5e3ec5===void 0x0?void 0x0:_0x5e3ec5[_0x2709ce(0x131)](_0x2709ce(0x122))){const _0x2970bd=(_0x48ee54=_0x56de71[_0x585efb])===null||_0x48ee54===void 0x0?void 0x0:_0x48ee54['condition'],_0x2f9f4e=(_0x8d75eb=_0x56de71[_0x585efb])===null||_0x8d75eb===void 0x0?void 0x0:_0x8d75eb[_0x2709ce(0x122)]['trim']()[_0x2709ce(0x12c)](),_0x5cb12d='_auto_'+_0x585efb+'_'+Math[_0x2709ce(0x139)](Math[_0x2709ce(0x126)]()*0xa)+Math[_0x2709ce(0x139)](Math[_0x2709ce(0x126)]()*0xa)+Math[_0x2709ce(0x139)](Math[_0x2709ce(0x126)]()*0xa)+Math[_0x2709ce(0x139)](Math['random']()*0xa);if(['=','!=','<>','>','>=','<','<=',_0x2709ce(0x141),_0x2709ce(0x13e)][_0x2709ce(0x10f)](_0x2f9f4e)!=-0x1)typeof _0x2970bd!=_0x2709ce(0x105)&&_0x278d7b[_0x2709ce(0x106)](_0x278d7b['alias']+'.'+_0x585efb+'\x20'+_0x2f9f4e+'\x20:'+_0x5cb12d,{[_0x5cb12d]:_0x2970bd});else{if(['IN','NOT\x20IN']['indexOf'](_0x2f9f4e)!=-0x1){if(typeof _0x2970bd!=_0x2709ce(0x105)){const _0x3ee39e=Array[_0x2709ce(0x145)](_0x2970bd)?_0x2970bd:typeof _0x2970bd==_0x2709ce(0x10e)?_0x2970bd[_0x2709ce(0x103)](','):[_0x2970bd];_0x278d7b[_0x2709ce(0x106)](_0x278d7b['alias']+'.'+_0x585efb+'\x20'+_0x2f9f4e+'(:'+_0x5cb12d+')',{[_0x5cb12d]:_0x3ee39e});}}else{if([_0x2709ce(0xfd),_0x2709ce(0x10a)][_0x2709ce(0x10f)](_0x2f9f4e)!=-0x1)typeof _0x2970bd!=_0x2709ce(0x105)&&_0x278d7b['andWhere'](_0x2f9f4e+'(:'+_0x5cb12d+','+_0x278d7b[_0x2709ce(0x123)]+'.'+_0x585efb+')',{[_0x5cb12d]:_0x2970bd});else{if(['BETWEEN',_0x2709ce(0x13d)][_0x2709ce(0x10f)](_0x2f9f4e)!=-0x1){if(typeof _0x2970bd!=_0x2709ce(0x105)){const _0x293fc1=Array['isArray'](_0x2970bd)?_0x2970bd:typeof _0x2970bd==_0x2709ce(0x10e)?_0x2970bd[_0x2709ce(0x103)](','):[_0x2970bd];_0x293fc1[_0x2709ce(0x107)]>0x1&&_0x278d7b[_0x2709ce(0x106)](_0x278d7b[_0x2709ce(0x123)]+'.'+_0x585efb+'\x20'+_0x2f9f4e+'\x20:'+_0x5cb12d+_0x2709ce(0x147)+_0x5cb12d+'_2',{[''+_0x5cb12d]:_0x293fc1[0x0],[_0x5cb12d+'_2']:_0x293fc1[0x1]});}}else['ISNULL','NOT\x20ISNULL'][_0x2709ce(0x10f)](_0x2f9f4e)!=-0x1&&_0x278d7b[_0x2709ce(0x106)](_0x2f9f4e+'('+_0x278d7b['alias']+'.'+_0x585efb+')');}}}}else{if(_0x3c507b[_0x2709ce(0x10f)](_0x585efb)==-0x1){const _0x5315d6=typeof _0x433cb8[_0x2709ce(0x13c)]=='function'?(_0x25b65f=_0x433cb8===null||_0x433cb8===void 0x0?void 0x0:_0x433cb8[_0x2709ce(0x13c)])===null||_0x25b65f===void 0x0?void 0x0:_0x25b65f[_0x2709ce(0x146)]:_0x433cb8[_0x2709ce(0x13c)]['toString']();_0x5315d6==_0x2709ce(0x11d)?_0x278d7b['andWhere'](_0x278d7b[_0x2709ce(0x123)]+'.'+_0x585efb+_0x2709ce(0x11b)+_0x585efb,{[_0x2709ce(0x138)+_0x585efb]:'%'+_0x56de71[_0x585efb]+'%'}):_0x278d7b[_0x2709ce(0x106)](_0x278d7b[_0x2709ce(0x123)]+'.'+_0x585efb+_0x2709ce(0x137)+_0x585efb,{[_0x2709ce(0x138)+_0x585efb]:_0x56de71[_0x585efb]});}}}}}(_0x189069===null||_0x189069===void 0x0?void 0x0:_0x189069[_0x2709ce(0x142)])&&_0x278d7b['take'](Math[_0x2709ce(0x102)](_0x189069[_0x2709ce(0x142)]));(_0x189069===null||_0x189069===void 0x0?void 0x0:_0x189069['_page'])&&(_0x189069===null||_0x189069===void 0x0?void 0x0:_0x189069[_0x2709ce(0x142)])&&_0x278d7b[_0x2709ce(0x11f)]((Math[_0x2709ce(0x102)](_0x189069[_0x2709ce(0x12d)])-0x1)*Math[_0x2709ce(0x102)](_0x189069[_0x2709ce(0x142)]));if(_0x189069===null||_0x189069===void 0x0?void 0x0:_0x189069[_0x2709ce(0x134)]){if(_0x189069['_order'][_0x2709ce(0x10f)]('.')!==-0x1)_0x278d7b[_0x2709ce(0x11e)](''+_0x189069[_0x2709ce(0x134)],(_0x189069===null||_0x189069===void 0x0?void 0x0:_0x189069['_isreverse'])?_0x2709ce(0x10c):_0x2709ce(0x118));else _0x3c507b[_0x2709ce(0x10f)](_0x189069['_order'])==-0x1&&(this['metadata']['findColumnWithPropertyName'](_0x189069[_0x2709ce(0x134)])?_0x278d7b['orderBy'](_0x278d7b['alias']+'.'+_0x189069[_0x2709ce(0x134)],(_0x189069===null||_0x189069===void 0x0?void 0x0:_0x189069[_0x2709ce(0x13a)])?_0x2709ce(0x10c):'DESC'):_0x278d7b[_0x2709ce(0x11e)](''+_0x189069[_0x2709ce(0x134)],(_0x189069===null||_0x189069===void 0x0?void 0x0:_0x189069[_0x2709ce(0x13a)])?_0x2709ce(0x10c):_0x2709ce(0x118)));}return typeof(_0x5f4d42===null||_0x5f4d42===void 0x0?void 0x0:_0x5f4d42['excess'])==_0x2709ce(0xff)&&await(_0x5f4d42===null||_0x5f4d42===void 0x0?void 0x0:_0x5f4d42[_0x2709ce(0x133)](_0x278d7b)),_0x278d7b;}async[a7_0x746606(0x120)](_0x55c68b,..._0x96d01b){const _0x20ab3a=a7_0x746606,_0x453821=this[_0x20ab3a(0x12a)](_0x55c68b,..._0x96d01b);return await this[_0x20ab3a(0x12b)](_0x453821);}async[a7_0x746606(0x144)](_0x2aea9e,..._0x20b550){const _0x1f8792=a7_0x746606,_0x57489f=this[_0x1f8792(0x12a)](this[_0x1f8792(0x129)](_0x2aea9e),..._0x20b550);return await this['save'](_0x57489f);}async[a7_0x746606(0x125)](_0x292434,_0x247f80){const _0x2853b3=a7_0x746606;return this[_0x2853b3(0x135)][_0x2853b3(0x125)](_0x292434,_0x247f80);}}exports['Repository']=Repository;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a8_0x4f7357=a8_0x10d1;(function(_0xd078e0,_0x2f6b04){const _0x12f2ba=a8_0x10d1,_0x51f8db=_0xd078e0();while(!![]){try{const _0x34b6be=-parseInt(_0x12f2ba(0x1c3))/0x1+parseInt(_0x12f2ba(0x1ca))/0x2+parseInt(_0x12f2ba(0x1bc))/0x3+-parseInt(_0x12f2ba(0x1cc))/0x4*(parseInt(_0x12f2ba(0x1c1))/0x5)+parseInt(_0x12f2ba(0x1cd))/0x6+-parseInt(_0x12f2ba(0x1c0))/0x7*(-parseInt(_0x12f2ba(0x1c4))/0x8)+-parseInt(_0x12f2ba(0x1bf))/0x9*(parseInt(_0x12f2ba(0x1c6))/0xa);if(_0x34b6be===_0x2f6b04)break;else _0x51f8db['push'](_0x51f8db['shift']());}catch(_0x2ce00d){_0x51f8db['push'](_0x51f8db['shift']());}}}(a8_0x1b67,0x9b31f));function a8_0x1b67(){const _0x460f99=['../interface','810376QCEzkn','ENTIFY_MODULE','20gyRzDX','5629104HxxnIr','@midwayjs/core','push','getClassMetadata','2061660LgMVdT','dataSource','__esModule','18QIDswX','2935289jLeFLl','996180fPRQmS','getDataSourceEntity','476348pFvwgU','24FlKfKk','defineProperty','5901830fGbYuG','listModule','find'];a8_0x1b67=function(){return _0x460f99;};return a8_0x1b67();}Object[a8_0x4f7357(0x1c5)](exports,a8_0x4f7357(0x1be),{'value':!![]}),exports[a8_0x4f7357(0x1c2)]=void 0x0;const core_1=require(a8_0x4f7357(0x1ce)),interface_1=require(a8_0x4f7357(0x1c9));function getDataSourceEntity(_0x2e2183='default'){const _0x3b0940=a8_0x4f7357;var _0x44128a;const _0x31249d=[];for(const _0x183359 of(0x0,core_1[_0x3b0940(0x1c7)])(interface_1[_0x3b0940(0x1cb)])){const _0x360801=(0x0,core_1[_0x3b0940(0x1bb)])(interface_1['ENTIFY_MODULE_SOURCE'],_0x183359);((_0x44128a=_0x360801===null||_0x360801===void 0x0?void 0x0:_0x360801[_0x3b0940(0x1bd)])===null||_0x44128a===void 0x0?void 0x0:_0x44128a[_0x3b0940(0x1c8)](_0x70c1b=>_0x70c1b==_0x2e2183))&&_0x31249d[_0x3b0940(0x1cf)](_0x183359);}return _0x31249d;}function a8_0x10d1(_0x114ff9,_0x162eae){const _0x1b6799=a8_0x1b67();return a8_0x10d1=function(_0x10d1ea,_0xa5b32){_0x10d1ea=_0x10d1ea-0x1bb;let _0x124b44=_0x1b6799[_0x10d1ea];return _0x124b44;},a8_0x10d1(_0x114ff9,_0x162eae);}exports[a8_0x4f7357(0x1c2)]=getDataSourceEntity;
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';var a9_0x2e07b3=a9_0x39ef;(function(_0x1f499c,_0x2ade5a){var _0x4efb41=a9_0x39ef,_0x3eb74d=_0x1f499c();while(!![]){try{var _0x4d7502=parseInt(_0x4efb41(0x15f))/0x1*(parseInt(_0x4efb41(0x15b))/0x2)+parseInt(_0x4efb41(0x16f))/0x3*(parseInt(_0x4efb41(0x172))/0x4)+parseInt(_0x4efb41(0x159))/0x5*(-parseInt(_0x4efb41(0x16a))/0x6)+-parseInt(_0x4efb41(0x166))/0x7+parseInt(_0x4efb41(0x156))/0x8*(-parseInt(_0x4efb41(0x155))/0x9)+parseInt(_0x4efb41(0x157))/0xa+parseInt(_0x4efb41(0x154))/0xb;if(_0x4d7502===_0x2ade5a)break;else _0x3eb74d['push'](_0x3eb74d['shift']());}catch(_0x5a8f3b){_0x3eb74d['push'](_0x3eb74d['shift']());}}}(a9_0x25d5,0xb8ca2));var __createBinding=this&&this['__createBinding']||(Object['create']?function(_0x137005,_0x355b7a,_0x41d638,_0x34073c){var _0x346558=a9_0x39ef;if(_0x34073c===undefined)_0x34073c=_0x41d638;var _0x373fc5=Object['getOwnPropertyDescriptor'](_0x355b7a,_0x41d638);(!_0x373fc5||(_0x346558(0x152)in _0x373fc5?!_0x355b7a['__esModule']:_0x373fc5[_0x346558(0x161)]||_0x373fc5[_0x346558(0x16b)]))&&(_0x373fc5={'enumerable':!![],'get':function(){return _0x355b7a[_0x41d638];}}),Object[_0x346558(0x173)](_0x137005,_0x34073c,_0x373fc5);}:function(_0x18b3ba,_0x5479b8,_0x57c588,_0x254d47){if(_0x254d47===undefined)_0x254d47=_0x57c588;_0x18b3ba[_0x254d47]=_0x5479b8[_0x57c588];}),__exportStar=this&&this['__exportStar']||function(_0x36a9fb,_0x1d9e91){var _0xa58566=a9_0x39ef;for(var _0x28d094 in _0x36a9fb)if(_0x28d094!==_0xa58566(0x15c)&&!Object[_0xa58566(0x170)][_0xa58566(0x175)][_0xa58566(0x151)](_0x1d9e91,_0x28d094))__createBinding(_0x1d9e91,_0x36a9fb,_0x28d094);};Object[a9_0x2e07b3(0x173)](exports,a9_0x2e07b3(0x153),{'value':!![]}),exports[a9_0x2e07b3(0x169)]=exports[a9_0x2e07b3(0x165)]=exports['Inject']=exports[a9_0x2e07b3(0x15e)]=exports[a9_0x2e07b3(0x16d)]=exports[a9_0x2e07b3(0x14f)]=exports[a9_0x2e07b3(0x15a)]=exports[a9_0x2e07b3(0x158)]=exports['ProvideRepository']=exports[a9_0x2e07b3(0x15d)]=exports['InjectRepository']=exports['InjectEntity']=exports['VirtualColumn']=exports['Repository']=void 0x0,__exportStar(require('typeorm'),exports),__exportStar(require('./interface'),exports);var Repository_1=require(a9_0x2e07b3(0x163));Object[a9_0x2e07b3(0x173)](exports,'Repository',{'enumerable':!![],'get':function(){return Repository_1['Repository'];}});var VirtualColumn_1=require(a9_0x2e07b3(0x168));Object[a9_0x2e07b3(0x173)](exports,a9_0x2e07b3(0x160),{'enumerable':!![],'get':function(){var _0x371f8d=a9_0x2e07b3;return VirtualColumn_1[_0x371f8d(0x160)];}});var InjectEntity_1=require('./decorator/InjectEntity');Object['defineProperty'](exports,a9_0x2e07b3(0x167),{'enumerable':!![],'get':function(){var _0x2011f6=a9_0x2e07b3;return InjectEntity_1[_0x2011f6(0x167)];}});var InjectRepository_1=require('./decorator/InjectRepository');Object[a9_0x2e07b3(0x173)](exports,a9_0x2e07b3(0x171),{'enumerable':!![],'get':function(){var _0x5d0e4e=a9_0x2e07b3;return InjectRepository_1[_0x5d0e4e(0x171)];}});var ProvideEntity_1=require('./decorator/ProvideEntity');Object[a9_0x2e07b3(0x173)](exports,a9_0x2e07b3(0x15d),{'enumerable':!![],'get':function(){var _0x3a8001=a9_0x2e07b3;return ProvideEntity_1[_0x3a8001(0x15d)];}});var ProvideRepository_1=require(a9_0x2e07b3(0x162));function a9_0x25d5(){var _0x55293f=['ScopeEnum','91710ryiCfa','configurable','./decorator/ProvideSearch','Configuration','./helper/getDataSourceEntity','2241kMuphL','prototype','InjectRepository','4804ruaSTm','defineProperty','./configuration','hasOwnProperty','getDataSourceEntity','Inject','call','get','__esModule','9492978Siwkhk','3029724zOfJXr','32fepoKz','10059940IRRwvq','ProvideSearch','175UdSGYi','Search','356ROFCKq','default','ProvideEntity','Provide','2197DpgDhe','VirtualColumn','writable','./decorator/ProvideRepository','./definition/Repository','CustomConfiguration','Scope','3631516fqeXNg','InjectEntity','./decorator/VirtualColumn'];a9_0x25d5=function(){return _0x55293f;};return a9_0x25d5();}Object[a9_0x2e07b3(0x173)](exports,'ProvideRepository',{'enumerable':!![],'get':function(){return ProvideRepository_1['ProvideRepository'];}});var ProvideSearch_1=require(a9_0x2e07b3(0x16c));Object['defineProperty'](exports,a9_0x2e07b3(0x158),{'enumerable':!![],'get':function(){return ProvideSearch_1['ProvideSearch'];}}),Object[a9_0x2e07b3(0x173)](exports,a9_0x2e07b3(0x15a),{'enumerable':!![],'get':function(){var _0x2495f5=a9_0x2e07b3;return ProvideSearch_1[_0x2495f5(0x15a)];}});function a9_0x39ef(_0x2acca0,_0x19f052){var _0x25d5bc=a9_0x25d5();return a9_0x39ef=function(_0x39ef58,_0x303a29){_0x39ef58=_0x39ef58-0x14f;var _0x3409ac=_0x25d5bc[_0x39ef58];return _0x3409ac;},a9_0x39ef(_0x2acca0,_0x19f052);}var getDataSourceEntity_1=require(a9_0x2e07b3(0x16e));Object['defineProperty'](exports,'getDataSourceEntity',{'enumerable':!![],'get':function(){return getDataSourceEntity_1['getDataSourceEntity'];}});var configuration_1=require(a9_0x2e07b3(0x174));Object[a9_0x2e07b3(0x173)](exports,a9_0x2e07b3(0x16d),{'enumerable':!![],'get':function(){var _0x45766e=a9_0x2e07b3;return configuration_1[_0x45766e(0x164)];}});var core_1=require('@midwayjs/core');Object[a9_0x2e07b3(0x173)](exports,'Provide',{'enumerable':!![],'get':function(){var _0x29c3c7=a9_0x2e07b3;return core_1[_0x29c3c7(0x15e)];}}),Object[a9_0x2e07b3(0x173)](exports,a9_0x2e07b3(0x150),{'enumerable':!![],'get':function(){var _0x2df417=a9_0x2e07b3;return core_1[_0x2df417(0x150)];}}),Object['defineProperty'](exports,'Scope',{'enumerable':!![],'get':function(){var _0x386d3a=a9_0x2e07b3;return core_1[_0x386d3a(0x165)];}}),Object[a9_0x2e07b3(0x173)](exports,'ScopeEnum',{'enumerable':!![],'get':function(){return core_1['ScopeEnum'];}});
|
package/dist/interface.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a10_0x5e81bf=a10_0x47e7;(function(_0x368cc1,_0x414997){const _0x697709=a10_0x47e7,_0x26a5d2=_0x368cc1();while(!![]){try{const _0x31ec1a=parseInt(_0x697709(0x1ac))/0x1*(parseInt(_0x697709(0x1ab))/0x2)+-parseInt(_0x697709(0x1b2))/0x3+parseInt(_0x697709(0x1a1))/0x4+parseInt(_0x697709(0x19e))/0x5*(parseInt(_0x697709(0x1af))/0x6)+-parseInt(_0x697709(0x197))/0x7*(-parseInt(_0x697709(0x1b0))/0x8)+parseInt(_0x697709(0x1c1))/0x9+-parseInt(_0x697709(0x1a6))/0xa*(parseInt(_0x697709(0x1c0))/0xb);if(_0x31ec1a===_0x414997)break;else _0x26a5d2['push'](_0x26a5d2['shift']());}catch(_0x4c6982){_0x26a5d2['push'](_0x26a5d2['shift']());}}}(a10_0x5a07,0xf3dd3));Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[a10_0x5e81bf(0x1b3)]=exports[a10_0x5e81bf(0x1b1)]=exports[a10_0x5e81bf(0x1a9)]=exports[a10_0x5e81bf(0x1b7)]=exports[a10_0x5e81bf(0x1be)]=exports[a10_0x5e81bf(0x1aa)]=exports[a10_0x5e81bf(0x198)]=exports[a10_0x5e81bf(0x1bc)]=void 0x0;function a10_0x5a07(){const _0x5769da=['407070NXPBnN','default','hasOwnProperty','OptimisticLockCanNotBeUsedError','updateDateColumn','prototype','decorator:anncic-api:typeorm:entify:module:source','getManyAndCount','1311961PrzCCa','ENTIFY_MODULE','decorator:anncic-api:typeorm:entify','getEntityValue','OptimisticLockVersionMismatchError','lockVersion','lockMode','90hsqYCY','decorator:anncic-api:typeorm:entity:virtual:column','resolve','1326508GRIySO','decorator:anncic-api:typeorm:entify:module','optimistic','getMany','metadata','93410qjaWBB','EntityManager','typeorm','MODEL_SEARCH_KEY','ENTIFY_MODULE_SOURCE','24ulJxxK','1075CFeRbK','then','decorator:anncic-api:typeorm:repository','517512vjjFfY','8CqdwMy','ENTITY_VIRTUAL_COLUMN_KEY','1851282ucTZOq','SearchPaginate','getRawAndEntities','EntityNotFoundError','getClassMetadata','MODEL_KEY','SelectQueryBuilder','mainAlias','getCount','expressionMap','ENTIFY_KEY','decorator:anncic-api:typeorm:model:search','REPOSITORY_KEY','map','605SHqvvb'];a10_0x5a07=function(){return _0x5769da;};return a10_0x5a07();}const core_1=require('@midwayjs/core'),typeorm_1=require(a10_0x5e81bf(0x1a8)),typeorm_2=require(a10_0x5e81bf(0x1a8));exports['ENTIFY_KEY']=a10_0x5e81bf(0x199),exports['ENTIFY_MODULE']=a10_0x5e81bf(0x1a2),exports[a10_0x5e81bf(0x1aa)]=a10_0x5e81bf(0x1c7),exports[a10_0x5e81bf(0x1be)]=a10_0x5e81bf(0x1ae),exports[a10_0x5e81bf(0x1b7)]='decorator:anncic-api:typeorm:model',exports[a10_0x5e81bf(0x1a9)]=a10_0x5e81bf(0x1bd),exports['ENTITY_VIRTUAL_COLUMN_KEY']=a10_0x5e81bf(0x19f);class SearchPaginate{}function a10_0x47e7(_0x406e5d,_0x13ae4a){const _0x5a07fd=a10_0x5a07();return a10_0x47e7=function(_0x47e77a,_0x4088ab){_0x47e77a=_0x47e77a-0x197;let _0x4d53ee=_0x5a07fd[_0x47e77a];return _0x4d53ee;},a10_0x47e7(_0x406e5d,_0x13ae4a);}exports[a10_0x5e81bf(0x1b3)]=SearchPaginate,typeorm_2[a10_0x5e81bf(0x1a7)][a10_0x5e81bf(0x1c6)]['findOneOrFail']=async function(_0x3b95aa,_0x56604a){const _0x46d226=a10_0x5e81bf;return this['findOne'](_0x3b95aa,_0x56604a)[_0x46d226(0x1ad)](_0x3e7b77=>{if(_0x3e7b77===null||_0x3e7b77===undefined)return Promise['reject'](new typeorm_2['EntityNotFoundError'](_0x3b95aa,_0x56604a));return Promise['resolve'](_0x3e7b77);});},typeorm_2['EntityManager'][a10_0x5e81bf(0x1c6)]['findOneByOrFail']=async function(_0x3803d3,_0x29f4d5){const _0x552197=a10_0x5e81bf;return this['findOneBy'](_0x3803d3,_0x29f4d5)[_0x552197(0x1ad)](_0x29df27=>{const _0x953ed7=_0x552197;if(_0x29df27===null||_0x29df27===undefined)return Promise['reject'](new typeorm_2[(_0x953ed7(0x1b5))](_0x3803d3,_0x29f4d5));return Promise[_0x953ed7(0x1a0)](_0x29df27);});},typeorm_1[a10_0x5e81bf(0x1b8)][a10_0x5e81bf(0x1c6)][a10_0x5e81bf(0x1a4)]=async function(){const _0x39d6b6=a10_0x5e81bf;if(this[_0x39d6b6(0x1bb)][_0x39d6b6(0x19d)]===_0x39d6b6(0x1a3))throw new typeorm_1[(_0x39d6b6(0x1c4))]();const {entities:_0x157514,raw:_0xbf05ad}=await this['getRawAndEntities']();return _0x157514[_0x39d6b6(0x1bf)]((_0x12eb11,_0x1dc0eb)=>{const _0x34ac11=_0x39d6b6;var _0x4064c6;const _0x1b1d19=(0x0,core_1['getClassMetadata'])(exports[_0x34ac11(0x1b1)],_0x12eb11)||{};for(const _0x4751b0 in _0x1b1d19){_0xbf05ad[_0x1dc0eb]&&_0xbf05ad[_0x1dc0eb][_0x34ac11(0x1c3)](_0x4751b0)&&(_0x12eb11[_0x4751b0]=_0xbf05ad[_0x1dc0eb][_0x4751b0]||((_0x4064c6=_0x1b1d19[_0x4751b0])===null||_0x4064c6===void 0x0?void 0x0:_0x4064c6[_0x34ac11(0x1c2)])||'');}return _0x12eb11;});},typeorm_1['SelectQueryBuilder'][a10_0x5e81bf(0x1c6)][a10_0x5e81bf(0x1c8)]=async function(){const _0x4f8585=a10_0x5e81bf;return[await this[_0x4f8585(0x1a4)](),await this[_0x4f8585(0x1ba)]()];},typeorm_1[a10_0x5e81bf(0x1b8)]['prototype']['getOne']=async function(){const _0x50ab26=a10_0x5e81bf;var _0x3a5ea3;const {entities:_0x489b88,raw:_0x35aaf9}=await this[_0x50ab26(0x1b4)]();if(_0x489b88[0x0]&&this['expressionMap'][_0x50ab26(0x19d)]==='optimistic'&&this[_0x50ab26(0x1bb)]['lockVersion']){const _0x47e274=this[_0x50ab26(0x1bb)][_0x50ab26(0x1b9)][_0x50ab26(0x1a5)];if(this['expressionMap']['lockVersion']instanceof Date){const _0x575fba=_0x47e274[_0x50ab26(0x1c5)][_0x50ab26(0x19a)](_0x489b88[0x0]);if(_0x575fba['getTime']()!==this['expressionMap'][_0x50ab26(0x19c)]['getTime']())throw new typeorm_1[(_0x50ab26(0x19b))](_0x47e274['name'],this[_0x50ab26(0x1bb)][_0x50ab26(0x19c)],_0x575fba);}else{const _0xb631f9=_0x47e274['versionColumn']['getEntityValue'](_0x489b88[0x0]);if(_0xb631f9!==this[_0x50ab26(0x1bb)]['lockVersion'])throw new typeorm_1[(_0x50ab26(0x19b))](_0x47e274['name'],this[_0x50ab26(0x1bb)][_0x50ab26(0x19c)],_0xb631f9);}}if(_0x489b88[0x0]&&_0x35aaf9[0x0]){const _0x4b77f0=(0x0,core_1[_0x50ab26(0x1b6)])(exports[_0x50ab26(0x1b1)],_0x489b88[0x0]);for(const _0x4d9a21 in _0x4b77f0){_0x35aaf9[0x0]['hasOwnProperty'](_0x4d9a21)&&(_0x489b88[0x0][_0x4d9a21]=_0x35aaf9[0x0][_0x4d9a21]||((_0x3a5ea3=_0x4b77f0[_0x4d9a21])===null||_0x3a5ea3===void 0x0?void 0x0:_0x3a5ea3[_0x50ab26(0x1c2)])||'');}}return _0x489b88[0x0]||null;};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anncic-api/typeorm",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.5",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"files": [
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"build": "tsc && javascript-obfuscator ./dist --output ./dist --config obfuscator.json"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@midwayjs/typeorm": "^3.7.
|
|
17
|
+
"@midwayjs/typeorm": "^3.7.3",
|
|
18
18
|
"typeorm": "^0.3.10"
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
@@ -22,5 +22,5 @@
|
|
|
22
22
|
"javascript-obfuscator": "2.19.0",
|
|
23
23
|
"typescript": "^4.7.4"
|
|
24
24
|
},
|
|
25
|
-
"gitHead": "
|
|
25
|
+
"gitHead": "d8c71ca8c30793c3fa8b6e0f74fc5b6e123f1066"
|
|
26
26
|
}
|