@anncic-api/typeorm 1.4.20 → 1.4.22
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';
|
|
1
|
+
'use strict';function a0_0x35dc(){const _0x5f39e3=['1946644OhFvJL','production','16WxFaKz','registerPropertyHandler','getDataSource','name','getRepository','TypeORMError','typeorm\x20Error\x20','@midwayjs/core','getClassMetadata','28JjTHLw','typeorm\x20Error\x20propertyName\x20is\x20not\x20InjectRepository\x20repository','REPOSITORY_KEY','3318955cKElLy','Configuration','__metadata','./interface','@midwayjs/typeorm','push','getOwnPropertyDescriptor','prototype','403737GNuXmS','decorate','object','__decorate','CustomConfiguration','defineProperty','2007deAoVX','1884qErasE','182670UZWlYH','handlercache','MidwayConfigService','design:type','function','anncic-api:typeorm','1960091MgdpSf','length','onReady','getAsync','find','40490vFbepB','decorator','__esModule','useMiddleware','middlewareError','warn','getDataSourceNameByModel','body','EntityNotFoundError','MidwayDecoratorService','数据不存在','Inject','\x20is\x20not\x20ProvideRepository\x20Entify','metadata','1DxCmDo','11693dehCbk','message','./definition/Repository','typeorm','TypeORMDataSourceManager'];a0_0x35dc=function(){return _0x5f39e3;};return a0_0x35dc();}const a0_0x1a2d03=a0_0x5aaf;(function(_0x2a7e48,_0x1857ae){const _0xf26af2=a0_0x5aaf,_0x16495e=_0x2a7e48();while(!![]){try{const _0x37b245=parseInt(_0xf26af2(0x99))/0x1*(parseInt(_0xf26af2(0x9f))/0x2)+parseInt(_0xf26af2(0x78))/0x3*(-parseInt(_0xf26af2(0x6d))/0x4)+parseInt(_0xf26af2(0x70))/0x5+-parseInt(_0xf26af2(0x80))/0x6+parseInt(_0xf26af2(0x86))/0x7*(parseInt(_0xf26af2(0xa1))/0x8)+-parseInt(_0xf26af2(0x7e))/0x9*(parseInt(_0xf26af2(0x8b))/0xa)+parseInt(_0xf26af2(0x9a))/0xb*(parseInt(_0xf26af2(0x7f))/0xc);if(_0x37b245===_0x1857ae)break;else _0x16495e['push'](_0x16495e['shift']());}catch(_0x406253){_0x16495e['push'](_0x16495e['shift']());}}}(a0_0x35dc,0x7749d));var __decorate=this&&this[a0_0x1a2d03(0x7b)]||function(_0x58081e,_0x8612e0,_0x4608f0,_0x16834e){const _0x35fb33=a0_0x1a2d03;var _0x6e2acb=arguments[_0x35fb33(0x87)],_0x67d9ba=_0x6e2acb<0x3?_0x8612e0:_0x16834e===null?_0x16834e=Object[_0x35fb33(0x76)](_0x8612e0,_0x4608f0):_0x16834e,_0x2b2082;if(typeof Reflect===_0x35fb33(0x7a)&&typeof Reflect['decorate']===_0x35fb33(0x84))_0x67d9ba=Reflect[_0x35fb33(0x79)](_0x58081e,_0x8612e0,_0x4608f0,_0x16834e);else{for(var _0x3fcf45=_0x58081e[_0x35fb33(0x87)]-0x1;_0x3fcf45>=0x0;_0x3fcf45--)if(_0x2b2082=_0x58081e[_0x3fcf45])_0x67d9ba=(_0x6e2acb<0x3?_0x2b2082(_0x67d9ba):_0x6e2acb>0x3?_0x2b2082(_0x8612e0,_0x4608f0,_0x67d9ba):_0x2b2082(_0x8612e0,_0x4608f0))||_0x67d9ba;}return _0x6e2acb>0x3&&_0x67d9ba&&Object['defineProperty'](_0x8612e0,_0x4608f0,_0x67d9ba),_0x67d9ba;},__metadata=this&&this[a0_0x1a2d03(0x72)]||function(_0x227700,_0x400411){const _0xe129be=a0_0x1a2d03;if(typeof Reflect===_0xe129be(0x7a)&&typeof Reflect[_0xe129be(0x98)]===_0xe129be(0x84))return Reflect[_0xe129be(0x98)](_0x227700,_0x400411);};Object[a0_0x1a2d03(0x7d)](exports,a0_0x1a2d03(0x8d),{'value':!![]}),exports[a0_0x1a2d03(0x7c)]=void 0x0;function a0_0x5aaf(_0x4fe9b7,_0x5ab46d){const _0x35dc43=a0_0x35dc();return a0_0x5aaf=function(_0x5aaf21,_0x43a881){_0x5aaf21=_0x5aaf21-0x6b;let _0xdeb853=_0x35dc43[_0x5aaf21];return _0xdeb853;},a0_0x5aaf(_0x4fe9b7,_0x5ab46d);}const typeorm_1=require('@midwayjs/typeorm'),core_1=require('@midwayjs/core'),core_2=require(a0_0x1a2d03(0x6b)),typeorm_2=require(a0_0x1a2d03(0x9d)),Repository_1=require(a0_0x1a2d03(0x9c)),interface_1=require(a0_0x1a2d03(0x73)),typeorm=require(a0_0x1a2d03(0x74));let CustomConfiguration=class CustomConfiguration{constructor(){const _0x34d8ad=a0_0x1a2d03;this[_0x34d8ad(0x81)]=[];}async[a0_0x1a2d03(0x88)](_0x4d5178,_0x79b405){const _0x468baa=a0_0x1a2d03,_0x14a720=await _0x4d5178[_0x468baa(0x89)](typeorm_1[_0x468baa(0x9e)]);this[_0x468baa(0x8c)][_0x468baa(0xa2)](interface_1['ENTIFY_KEY'],(_0x274b63,{entity:_0x39c23b,connection:_0x3c51ed})=>{const _0x50d2ce=_0x468baa;let _0x3720f3=this[_0x50d2ce(0x81)][_0x50d2ce(0x8a)](_0x89f956=>_0x89f956['target']===_0x39c23b);return!_0x3720f3&&(_0x3720f3=new Repository_1['Repository'](_0x79b405,_0x4d5178,_0x14a720[_0x50d2ce(0xa3)](_0x3c51ed||_0x14a720[_0x50d2ce(0x91)](_0x39c23b))[_0x50d2ce(0xa5)](_0x39c23b)),this[_0x50d2ce(0x81)][_0x50d2ce(0x75)](_0x3720f3)),_0x3720f3;}),this[_0x468baa(0x8c)][_0x468baa(0xa2)](interface_1['REPOSITORY_KEY'],(_0x793a48,{repository:_0x4cb2e0,connection:_0x3b2b5b})=>{const _0x3afddd=_0x468baa;if(!_0x4cb2e0)throw new Error(_0x3afddd(0x6e));const {entity:_0x1ea129}=(0x0,core_1[_0x3afddd(0x6c)])(interface_1[_0x3afddd(0x6f)],_0x4cb2e0)||{};if(!_0x1ea129)throw new Error(_0x3afddd(0xa7)+((_0x4cb2e0===null||_0x4cb2e0===void 0x0?void 0x0:_0x4cb2e0[_0x3afddd(0xa4)])||_0x4cb2e0)+_0x3afddd(0x97));let _0x1b214a=this['handlercache']['find'](_0x4602ec=>_0x4602ec===_0x4cb2e0);return!_0x1b214a&&(_0x1b214a=new _0x4cb2e0(_0x79b405,_0x4d5178,_0x14a720['getDataSource'](_0x3b2b5b||_0x14a720['getDataSourceNameByModel'](_0x1ea129))[_0x3afddd(0xa5)](_0x1ea129)),this[_0x3afddd(0x81)][_0x3afddd(0x75)](_0x1b214a)),_0x1b214a;}),_0x79b405[_0x468baa(0x8e)](this['middlewareError'](_0x79b405));}[a0_0x1a2d03(0x8f)](_0x343251){return async(_0x3b464a,_0x371651)=>{const _0x4eb6c4=a0_0x5aaf;try{await _0x371651();}catch(_0x21dbea){if(_0x21dbea instanceof typeorm_2[_0x4eb6c4(0xa6)])_0x21dbea instanceof typeorm_2[_0x4eb6c4(0x93)]?_0x3b464a['body']={'code':0x194,'msg':_0x4eb6c4(0x95)}:(_0x3b464a[_0x4eb6c4(0x92)]={'code':0x1f4,'msg':_0x21dbea[_0x4eb6c4(0x9b)]},_0x343251['getEnv']()!=_0x4eb6c4(0xa0)&&console[_0x4eb6c4(0x90)](_0x21dbea));else throw _0x21dbea;}};}};__decorate([(0x0,core_1[a0_0x1a2d03(0x96)])(),__metadata(a0_0x1a2d03(0x83),core_2[a0_0x1a2d03(0x82)])],CustomConfiguration['prototype'],'config',void 0x0),__decorate([(0x0,core_1[a0_0x1a2d03(0x96)])(),__metadata(a0_0x1a2d03(0x83),core_2[a0_0x1a2d03(0x94)])],CustomConfiguration[a0_0x1a2d03(0x77)],a0_0x1a2d03(0x8c),void 0x0),CustomConfiguration=__decorate([(0x0,core_1[a0_0x1a2d03(0x71)])({'imports':[typeorm],'conflictCheck':![],'namespace':a0_0x1a2d03(0x85)})],CustomConfiguration),exports[a0_0x1a2d03(0x7c)]=CustomConfiguration;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a1_0xbbb996=a1_0x65e5;function a1_0x3452(){const _0x3c856f=['2ToiomL','2415440iylHji','InjectEntity','6OkfKtZ','7072TYacje','defineProperty','4187106jVZnFO','47460MyZOzF','4213idvhVC','5800104WDSZrX','95414paRNzN','../interface','45Ptdqlu','__esModule','ENTIFY_KEY','@midwayjs/core','3549815faDCpL'];a1_0x3452=function(){return _0x3c856f;};return a1_0x3452();}(function(_0x233320,_0x2c3512){const _0x2a5e2d=a1_0x65e5,_0x271a18=_0x233320();while(!![]){try{const _0x21fcb5=parseInt(_0x2a5e2d(0x134))/0x1*(-parseInt(_0x2a5e2d(0x12d))/0x2)+parseInt(_0x2a5e2d(0x12f))/0x3*(parseInt(_0x2a5e2d(0x127))/0x4)+parseInt(_0x2a5e2d(0x133))/0x5*(parseInt(_0x2a5e2d(0x126))/0x6)+parseInt(_0x2a5e2d(0x129))/0x7+parseInt(_0x2a5e2d(0x135))/0x8+parseInt(_0x2a5e2d(0x12c))/0x9+-parseInt(_0x2a5e2d(0x12a))/0xa*(parseInt(_0x2a5e2d(0x12b))/0xb);if(_0x21fcb5===_0x2c3512)break;else _0x271a18['push'](_0x271a18['shift']());}catch(_0x4b78bd){_0x271a18['push'](_0x271a18['shift']());}}}(a1_0x3452,0x59d17));Object[a1_0xbbb996(0x128)](exports,a1_0xbbb996(0x130),{'value':!![]}),exports[a1_0xbbb996(0x136)]=void 0x0;function a1_0x65e5(_0x31f151,_0x3b2ebe){const _0x345279=a1_0x3452();return a1_0x65e5=function(_0x65e5af,_0x2a7670){_0x65e5af=_0x65e5af-0x126;let _0x1d0079=_0x345279[_0x65e5af];return _0x1d0079;},a1_0x65e5(_0x31f151,_0x3b2ebe);}const core_1=require(a1_0xbbb996(0x132)),interface_1=require(a1_0xbbb996(0x12e));function InjectEntity(_0x110d74,_0x1a77ac='default'){const _0x33b01=a1_0xbbb996;return(0x0,core_1['createCustomPropertyDecorator'])(interface_1[_0x33b01(0x131)],{'entity':_0x110d74,'connection':_0x1a77ac});}exports[a1_0xbbb996(0x136)]=InjectEntity;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a2_0x1b5b30=a2_0x2656;(function(_0x5f59f6,_0x1e2fbc){const _0xd1c80d=a2_0x2656,_0x1f377a=_0x5f59f6();while(!![]){try{const _0x134e77=parseInt(_0xd1c80d(0x14b))/0x1*(-parseInt(_0xd1c80d(0x14d))/0x2)+parseInt(_0xd1c80d(0x13d))/0x3*(parseInt(_0xd1c80d(0x140))/0x4)+-parseInt(_0xd1c80d(0x144))/0x5*(-parseInt(_0xd1c80d(0x13e))/0x6)+-parseInt(_0xd1c80d(0x146))/0x7*(-parseInt(_0xd1c80d(0x13f))/0x8)+parseInt(_0xd1c80d(0x148))/0x9*(parseInt(_0xd1c80d(0x14a))/0xa)+-parseInt(_0xd1c80d(0x143))/0xb*(-parseInt(_0xd1c80d(0x13c))/0xc)+parseInt(_0xd1c80d(0x14c))/0xd*(-parseInt(_0xd1c80d(0x141))/0xe);if(_0x134e77===_0x1e2fbc)break;else _0x1f377a['push'](_0x1f377a['shift']());}catch(_0x4a5f77){_0x1f377a['push'](_0x1f377a['shift']());}}}(a2_0x3b91,0x31c93));Object[a2_0x1b5b30(0x147)](exports,a2_0x1b5b30(0x142),{'value':!![]}),exports['InjectRepository']=void 0x0;const core_1=require('@midwayjs/core'),interface_1=require(a2_0x1b5b30(0x149));function InjectRepository(_0x3dc54b,_0x5be5c9='default'){const _0x426318=a2_0x1b5b30;return(0x0,core_1['createCustomPropertyDecorator'])(interface_1[_0x426318(0x145)],{'repository':_0x3dc54b,'connection':_0x5be5c9});}function a2_0x2656(_0x2de327,_0x367cad){const _0x3b91cd=a2_0x3b91();return a2_0x2656=function(_0x2656d1,_0x252d8a){_0x2656d1=_0x2656d1-0x13c;let _0x52339f=_0x3b91cd[_0x2656d1];return _0x52339f;},a2_0x2656(_0x2de327,_0x367cad);}function a2_0x3b91(){const _0x7cd7de=['12vkMpSU','13363042JeAsLC','__esModule','121rNbpAG','15HbaZxk','REPOSITORY_KEY','25963orvtUe','defineProperty','3060513YagWYm','../interface','10THgRCO','10408WVueWQ','13kKuIeS','46EBwEBC','215484cdSCID','179649PCqJxm','604518bdaiXA','816aNfjKB'];a2_0x3b91=function(){return _0x7cd7de;};return a2_0x3b91();}exports['InjectRepository']=InjectRepository;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';function a3_0x418d(){const _0x349c22=['ProvideEntity','typeorm','saveModule','string','21SprBkW','__esModule','../interface','defineProperty','3610664ubdihq','name','dataSource','tableName','saveClassMetadata','ENTIFY_MODULE','124cCphyB','push','72xLuvIi','Entity','13802uXLMYQ','4731057IdQEZQ','8227860NQlbJa','478902gICoEm','13844xXpUaz','60535pAmlSF','ENTIFY_MODULE_SOURCE'];a3_0x418d=function(){return _0x349c22;};return a3_0x418d();}const a3_0x160996=a3_0x3d8f;(function(_0x2d7b3b,_0x4689b1){const _0x4bc81b=a3_0x3d8f,_0x269b64=_0x2d7b3b();while(!![]){try{const _0x46f7fe=-parseInt(_0x4bc81b(0x19c))/0x1+-parseInt(_0x4bc81b(0x1b1))/0x2*(-parseInt(_0x4bc81b(0x1af))/0x3)+parseInt(_0x4bc81b(0x1ad))/0x4*(-parseInt(_0x4bc81b(0x19d))/0x5)+parseInt(_0x4bc81b(0x1b4))/0x6*(-parseInt(_0x4bc81b(0x1a3))/0x7)+parseInt(_0x4bc81b(0x1a7))/0x8+-parseInt(_0x4bc81b(0x1b2))/0x9+parseInt(_0x4bc81b(0x1b3))/0xa;if(_0x46f7fe===_0x4689b1)break;else _0x269b64['push'](_0x269b64['shift']());}catch(_0x793332){_0x269b64['push'](_0x269b64['shift']());}}}(a3_0x418d,0x45b12));Object[a3_0x160996(0x1a6)](exports,a3_0x160996(0x1a4),{'value':!![]}),exports[a3_0x160996(0x19f)]=void 0x0;const typeorm_1=require(a3_0x160996(0x1a0)),core_1=require('@midwayjs/core'),interface_1=require(a3_0x160996(0x1a5));function a3_0x3d8f(_0x5cc37b,_0x392f45){const _0x418de2=a3_0x418d();return a3_0x3d8f=function(_0x3d8fed,_0x4063d1){_0x3d8fed=_0x3d8fed-0x19c;let _0x52e91c=_0x418de2[_0x3d8fed];return _0x52e91c;},a3_0x3d8f(_0x5cc37b,_0x392f45);}function ProvideEntity(_0x4e5782,_0x3b2aaf={}){return _0x32699f=>{const _0x1beffe=a3_0x3d8f;_0x3b2aaf[_0x1beffe(0x1a8)]=_0x4e5782['tableName'];const _0x5a39aa=[];if(!(_0x4e5782===null||_0x4e5782===void 0x0?void 0x0:_0x4e5782[_0x1beffe(0x1a9)]))_0x5a39aa[_0x1beffe(0x1ae)]('default');else{if(typeof(_0x4e5782===null||_0x4e5782===void 0x0?void 0x0:_0x4e5782[_0x1beffe(0x1a9)])==_0x1beffe(0x1a2))_0x5a39aa[_0x1beffe(0x1ae)](_0x4e5782===null||_0x4e5782===void 0x0?void 0x0:_0x4e5782['dataSource']);else{if(Array['isArray'](_0x4e5782===null||_0x4e5782===void 0x0?void 0x0:_0x4e5782['dataSource']))for(let _0x29a438 of _0x4e5782[_0x1beffe(0x1a9)]||['default']){_0x5a39aa['push'](_0x29a438);}}}(0x0,core_1[_0x1beffe(0x1a1)])(interface_1[_0x1beffe(0x1ac)],_0x32699f),(0x0,core_1[_0x1beffe(0x1ab)])(interface_1[_0x1beffe(0x19e)],{'tableName':_0x4e5782[_0x1beffe(0x1aa)],'dataSource':_0x5a39aa},_0x32699f),(0x0,typeorm_1[_0x1beffe(0x1b0)])(_0x4e5782[_0x1beffe(0x1aa)],_0x3b2aaf)(_0x32699f);};}exports[a3_0x160996(0x19f)]=ProvideEntity;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';
|
|
1
|
+
'use strict';function a4_0x2674(){const _0x14e825=['4902pcXwdx','8286751BADTHa','2834444KfOMOQ','130859AKPkoP','2491745cHJYaR','Scope','3RVNgSU','defineProperty','8MJksKn','@midwayjs/core','22SjWxBS','ProvideRepository','5190309qZZkBI','ScopeEnum','10675NMGzgM','saveClassMetadata','Provide','12435530vvowkM','24Enwlly'];a4_0x2674=function(){return _0x14e825;};return a4_0x2674();}const a4_0x359d47=a4_0xde09;(function(_0x492c7c,_0x51b15f){const _0x3e58be=a4_0xde09,_0x1143dd=_0x492c7c();while(!![]){try{const _0x561256=-parseInt(_0x3e58be(0x1e4))/0x1*(-parseInt(_0x3e58be(0x1eb))/0x2)+-parseInt(_0x3e58be(0x1e7))/0x3*(-parseInt(_0x3e58be(0x1e3))/0x4)+-parseInt(_0x3e58be(0x1e5))/0x5+parseInt(_0x3e58be(0x1f4))/0x6*(parseInt(_0x3e58be(0x1ef))/0x7)+parseInt(_0x3e58be(0x1e9))/0x8*(parseInt(_0x3e58be(0x1ed))/0x9)+-parseInt(_0x3e58be(0x1f2))/0xa+parseInt(_0x3e58be(0x1e2))/0xb*(-parseInt(_0x3e58be(0x1f3))/0xc);if(_0x561256===_0x51b15f)break;else _0x1143dd['push'](_0x1143dd['shift']());}catch(_0x4862e0){_0x1143dd['push'](_0x1143dd['shift']());}}}(a4_0x2674,0xb04b6));Object[a4_0x359d47(0x1e8)](exports,'__esModule',{'value':!![]}),exports[a4_0x359d47(0x1ec)]=void 0x0;const core_1=require(a4_0x359d47(0x1ea)),interface_1=require('../interface');function a4_0xde09(_0x10abf4,_0x46f342){const _0x2674cc=a4_0x2674();return a4_0xde09=function(_0xde09ce,_0x2675eb){_0xde09ce=_0xde09ce-0x1e2;let _0x396704=_0x2674cc[_0xde09ce];return _0x396704;},a4_0xde09(_0x10abf4,_0x46f342);}function ProvideRepository(_0x3f6315){return _0x2e86ee=>{const _0x51c61b=a4_0xde09;(0x0,core_1[_0x51c61b(0x1e6)])(core_1[_0x51c61b(0x1ee)]['Request'],{'allowDowngrade':!![]})(_0x2e86ee),((0x0,core_1[_0x51c61b(0x1f1)])()(_0x2e86ee),(0x0,core_1[_0x51c61b(0x1f0)])(interface_1['REPOSITORY_KEY'],{'entity':_0x3f6315},_0x2e86ee));};}exports[a4_0x359d47(0x1ec)]=ProvideRepository;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a5_0x1ebc9b=a5_0x491f;function a5_0x491f(_0x535640,_0x74115a){const _0x383ffd=a5_0x383f();return a5_0x491f=function(_0x491f8c,_0x2e06ff){_0x491f8c=_0x491f8c-0x9e;let _0x5df3bd=_0x383ffd[_0x491f8c];return _0x5df3bd;},a5_0x491f(_0x535640,_0x74115a);}(function(_0x151057,_0x4e0783){const _0x4e53c1=a5_0x491f,_0x29c7ae=_0x151057();while(!![]){try{const _0xde45b=-parseInt(_0x4e53c1(0xb5))/0x1*(-parseInt(_0x4e53c1(0xa5))/0x2)+-parseInt(_0x4e53c1(0xb4))/0x3+parseInt(_0x4e53c1(0xa7))/0x4+-parseInt(_0x4e53c1(0xaa))/0x5*(-parseInt(_0x4e53c1(0xa4))/0x6)+parseInt(_0x4e53c1(0xa2))/0x7*(parseInt(_0x4e53c1(0xb3))/0x8)+parseInt(_0x4e53c1(0x9e))/0x9+parseInt(_0x4e53c1(0xab))/0xa*(-parseInt(_0x4e53c1(0xac))/0xb);if(_0xde45b===_0x4e0783)break;else _0x29c7ae['push'](_0x29c7ae['shift']());}catch(_0x2b9cea){_0x29c7ae['push'](_0x29c7ae['shift']());}}}(a5_0x383f,0xe313d));Object[a5_0x1ebc9b(0xa1)](exports,a5_0x1ebc9b(0x9f),{'value':!![]}),exports[a5_0x1ebc9b(0xb0)]=exports[a5_0x1ebc9b(0xa6)]=exports[a5_0x1ebc9b(0xb2)]=void 0x0;const core_1=require('@midwayjs/core'),interface_1=require(a5_0x1ebc9b(0xad));function ProvideSearch(_0x4a62aa){return _0x1138b8=>{const _0x348c82=a5_0x491f;(0x0,core_1[_0x348c82(0xae)])(interface_1[_0x348c82(0xb1)],_0x1138b8),(0x0,core_1['Scope'])(core_1[_0x348c82(0xa8)][_0x348c82(0xa9)])(_0x1138b8),(0x0,core_1[_0x348c82(0xaf)])(interface_1[_0x348c82(0xb1)],_0x4a62aa,_0x1138b8);};}exports['ProvideSearch']=ProvideSearch;function Search(_0x25e56d,_0x3bdbee){return(_0x39c8a5,_0x16f722,_0x2d7100)=>{const _0x1d1c77=a5_0x491f;(0x0,core_1['attachClassMetadata'])(interface_1[_0x1d1c77(0xa0)],{'field':_0x25e56d,'comment':_0x3bdbee,'target':_0x39c8a5,'methodName':_0x16f722,'descriptor':_0x2d7100},_0x39c8a5);};}exports[a5_0x1ebc9b(0xa6)]=Search;function a5_0x383f(){const _0x2a981a=['273290shtUie','1298sUTHai','../interface','saveModule','attachClassMetadata','SearchScope','MODEL_KEY','ProvideSearch','24ooqMtu','5440851uVWzPp','1PtONib','15019929bfOwIL','__esModule','MODEL_SEARCH_KEY','defineProperty','1507345pVkNJJ','MODEL_SEARCH_SCOPE_KEY','78lFaDOq','1593346duuAUQ','Search','7007644IGxgsI','ScopeEnum','Singleton','425030qCqUnx'];a5_0x383f=function(){return _0x2a981a;};return a5_0x383f();}function SearchScope(_0x2dece8,_0x102eda){return(_0x22b814,_0x53c48f,_0x34eae6)=>{const _0x60efba=a5_0x491f;(0x0,core_1['attachClassMetadata'])(interface_1[_0x60efba(0xa3)],{'scope':_0x2dece8,'comment':_0x102eda,'target':_0x22b814,'methodName':_0x53c48f,'descriptor':_0x34eae6},_0x22b814);};}exports[a5_0x1ebc9b(0xb0)]=SearchScope;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';function a6_0x430b(){const _0x3b884b=['getClassMetadata','2855192fCTjyr','VirtualColumn','3398360XuxGnz','../interface','2829nUftqj','defineProperty','515spIpDq','194088DMCCOu','4482snQcZP','saveClassMetadata','3468564iSrmnH','7183575rmiAXf','ENTITY_VIRTUAL_COLUMN_KEY','1426QSOLxV','@midwayjs/core'];a6_0x430b=function(){return _0x3b884b;};return a6_0x430b();}const a6_0x684489=a6_0x2ec4;(function(_0xaf0bbe,_0x5e8629){const _0x3100de=a6_0x2ec4,_0x57cec7=_0xaf0bbe();while(!![]){try{const _0x1c8830=-parseInt(_0x3100de(0xd5))/0x1+parseInt(_0x3100de(0xdb))/0x2*(parseInt(_0x3100de(0xe2))/0x3)+parseInt(_0x3100de(0xd8))/0x4+parseInt(_0x3100de(0xd4))/0x5*(-parseInt(_0x3100de(0xd6))/0x6)+parseInt(_0x3100de(0xe0))/0x7+-parseInt(_0x3100de(0xde))/0x8+-parseInt(_0x3100de(0xd9))/0x9;if(_0x1c8830===_0x5e8629)break;else _0x57cec7['push'](_0x57cec7['shift']());}catch(_0x1c9435){_0x57cec7['push'](_0x57cec7['shift']());}}}(a6_0x430b,0x9235d));Object[a6_0x684489(0xe3)](exports,'__esModule',{'value':!![]}),exports[a6_0x684489(0xdf)]=void 0x0;const core_1=require(a6_0x684489(0xdc)),interface_1=require(a6_0x684489(0xe1));function VirtualColumn(_0x4603b6,_0x528932){return(_0x4e2d75,_0x2e25bc)=>{const _0x15d45c=a6_0x2ec4,_0x2de180=(0x0,core_1[_0x15d45c(0xdd)])(interface_1[_0x15d45c(0xda)],_0x4e2d75)||{};_0x2de180[_0x2e25bc]={'comment':_0x4603b6,..._0x528932},(0x0,core_1[_0x15d45c(0xd7)])(interface_1[_0x15d45c(0xda)],_0x2de180,_0x4e2d75);};}function a6_0x2ec4(_0x376691,_0x50d63a){const _0x430bb3=a6_0x430b();return a6_0x2ec4=function(_0x2ec438,_0x2fa368){_0x2ec438=_0x2ec438-0xd4;let _0x108d73=_0x430bb3[_0x2ec438];return _0x108d73;},a6_0x2ec4(_0x376691,_0x50d63a);}exports[a6_0x684489(0xdf)]=VirtualColumn;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const a7_0x7ae074=a7_0x4692;(function(_0x2a40e6,_0xa42af9){const _0x71d0e6=a7_0x4692,_0x1bcb8c=_0x2a40e6();while(!![]){try{const _0x345c1f=-parseInt(_0x71d0e6(0x136))/0x1*(parseInt(_0x71d0e6(0x139))/0x2)+parseInt(_0x71d0e6(0x14b))/0x3*(parseInt(_0x71d0e6(0x152))/0x4)+-parseInt(_0x71d0e6(0x17b))/0x5*(parseInt(_0x71d0e6(0x17a))/0x6)+parseInt(_0x71d0e6(0x14c))/0x7+parseInt(_0x71d0e6(0x12d))/0x8+-parseInt(_0x71d0e6(0x158))/0x9+parseInt(_0x71d0e6(0x155))/0xa*(-parseInt(_0x71d0e6(0x165))/0xb);if(_0x345c1f===_0xa42af9)break;else _0x1bcb8c['push'](_0x1bcb8c['shift']());}catch(_0x599e32){_0x1bcb8c['push'](_0x1bcb8c['shift']());}}}(a7_0x5c97,0x7f1ac));function a7_0x5c97(){const _0x57512f=['1529289cvJZtZ','NOT\x20FIND\x20IN\x20SET','__esModule','\x20=\x20:_auto_','NOT\x20IN','andWhere','getApplicationContext','_isreverse','random','getDirty','search','name','defineProperty','467764ORvXaW','length','searchScopes','indexOf','(:...','createQueryBuilder','toUpperCase','getClassMetadata','function','alias','save','abs','merge','trim','excess','orderBy','skip','\x20IN(:..._auto_','scope','ASC','isDirty','1594338nkJtZt','5MOESvg','typeorm','type','container','modelSearchs','metadata','mergeSave','toLowerCase','isArray','5625440GRDsVQ','transaction','getAsync','MODEL_KEY','undefined','Repository','split','push','../interface','1IIWGhe','_order','manager','1187794xPMVGe','field','ISNULL','app','target','bind','operator','NOT\x20BETWEEN','findColumnWithPropertyName','FIND\x20IN\x20SET','hasOwnProperty','_auto_','__initialize','MODEL_SEARCH_SCOPE_KEY','methodName','_page','toString','_size','21tJnNUI','3056368PMmRML','DESC','string','1\x20=\x202','createSave','MODEL_SEARCH_KEY','307388jZcwYq','ceil','queryRunner','30nXahnC','searchs','NOT\x20ISNULL'];a7_0x5c97=function(){return _0x57512f;};return a7_0x5c97();}function a7_0x4692(_0x8054e0,_0x5bc0f9){const _0x5c97a2=a7_0x5c97();return a7_0x4692=function(_0x4692c0,_0x2ef089){_0x4692c0=_0x4692c0-0x127;let _0x58f89c=_0x5c97a2[_0x4692c0];return _0x58f89c;},a7_0x4692(_0x8054e0,_0x5bc0f9);}Object[a7_0x7ae074(0x164)](exports,a7_0x7ae074(0x15a),{'value':!![]}),exports[a7_0x7ae074(0x132)]=void 0x0;const core_1=require('@midwayjs/core'),typeorm_1=require(a7_0x7ae074(0x17c)),interface_1=require(a7_0x7ae074(0x135));class Repository extends typeorm_1[a7_0x7ae074(0x132)]{constructor(_0x29cba6,_0xe9cb0e,_0x1e8c55){const _0x475763=a7_0x7ae074;super(_0x1e8c55[_0x475763(0x13d)],_0x1e8c55['manager'],_0x1e8c55['queryRunner']),this[_0x475763(0x128)]=[];for(const _0x2ec0b9 of(0x0,core_1[_0x475763(0x16c)])(interface_1[_0x475763(0x130)],this[_0x475763(0x13d)])||[]){const _0x340ce7={'model':_0x2ec0b9,'searchs':[],'searchScopes':[]};for(const _0x5ebe65 of(0x0,core_1['getClassMetadata'])(interface_1[_0x475763(0x151)],_0x2ec0b9)||[]){_0x340ce7[_0x475763(0x156)][_0x475763(0x134)](_0x5ebe65);}for(const _0x29e512 of(0x0,core_1[_0x475763(0x16c)])(interface_1[_0x475763(0x146)],_0x2ec0b9)||[]){_0x340ce7[_0x475763(0x167)][_0x475763(0x134)](_0x29e512);}this[_0x475763(0x128)][_0x475763(0x134)](_0x340ce7);}this['app']=_0x29cba6,this[_0x475763(0x127)]=_0xe9cb0e;}async[a7_0x7ae074(0x162)](_0x49efec,_0x3ddf84,_0x1c46b0={}){const _0x42b3dd=a7_0x7ae074;var _0x5bb336,_0x3aa0b8,_0x571a90,_0x263100,_0x4ab9ac,_0x108cd6;const _0x8c9ba9=this[_0x42b3dd(0x16a)](undefined,_0x1c46b0===null||_0x1c46b0===void 0x0?void 0x0:_0x1c46b0['queryRunner']),_0xd870e0=[];for(const _0x3a3cb8 of this[_0x42b3dd(0x128)]){if(_0x3a3cb8===null||_0x3a3cb8===void 0x0?void 0x0:_0x3a3cb8['model']){const _0x1aabe4=await this[_0x42b3dd(0x13c)][_0x42b3dd(0x15e)]()[_0x42b3dd(0x12f)](_0x3a3cb8['model']);if(_0x1aabe4){typeof _0x1aabe4[_0x42b3dd(0x145)]=='function'&&await _0x1aabe4['__initialize'][_0x42b3dd(0x13e)](_0x1aabe4)(_0x8c9ba9,_0x49efec,{'app':this['app'],'container':this[_0x42b3dd(0x127)],'paginate':_0x3ddf84,'queryRunner':_0x1c46b0===null||_0x1c46b0===void 0x0?void 0x0:_0x1c46b0[_0x42b3dd(0x154)]});if(_0x1c46b0===null||_0x1c46b0===void 0x0?void 0x0:_0x1c46b0['scope']){const _0x11f66e=Array['isArray'](_0x1c46b0[_0x42b3dd(0x177)])?_0x1c46b0[_0x42b3dd(0x177)]:[_0x1c46b0[_0x42b3dd(0x177)]];for(const _0x281215 of(_0x3a3cb8===null||_0x3a3cb8===void 0x0?void 0x0:_0x3a3cb8[_0x42b3dd(0x167)])||[]){(_0x281215===null||_0x281215===void 0x0?void 0x0:_0x281215[_0x42b3dd(0x177)])&&_0x11f66e[_0x42b3dd(0x168)](_0x281215[_0x42b3dd(0x177)])!=-0x1&&(_0x281215===null||_0x281215===void 0x0?void 0x0:_0x281215[_0x42b3dd(0x147)])&&typeof _0x1aabe4[_0x281215[_0x42b3dd(0x147)]]=='function'&&await _0x1aabe4[_0x281215['methodName']][_0x42b3dd(0x13e)](_0x1aabe4)(_0x8c9ba9,_0x49efec,{'app':this['app'],'container':this[_0x42b3dd(0x127)],'paginate':_0x3ddf84,'queryRunner':_0x1c46b0===null||_0x1c46b0===void 0x0?void 0x0:_0x1c46b0['queryRunner']});}}if(_0x49efec)for(const _0x1e033a of(_0x3a3cb8===null||_0x3a3cb8===void 0x0?void 0x0:_0x3a3cb8[_0x42b3dd(0x156)])||[]){(_0x1e033a===null||_0x1e033a===void 0x0?void 0x0:_0x1e033a[_0x42b3dd(0x13a)])&&(_0x1e033a===null||_0x1e033a===void 0x0?void 0x0:_0x1e033a[_0x42b3dd(0x147)])&&typeof _0x1aabe4[_0x1e033a[_0x42b3dd(0x147)]]=='function'&&(typeof(_0x49efec===null||_0x49efec===void 0x0?void 0x0:_0x49efec[_0x1e033a[_0x42b3dd(0x13a)]])!=_0x42b3dd(0x131)&&!((_0x5bb336=_0x49efec===null||_0x49efec===void 0x0?void 0x0:_0x49efec[_0x1e033a[_0x42b3dd(0x13a)]])===null||_0x5bb336===void 0x0?void 0x0:_0x5bb336[_0x42b3dd(0x143)](_0x42b3dd(0x13f)))&&(_0xd870e0[_0x42b3dd(0x168)](_0x1e033a[_0x42b3dd(0x13a)])==-0x1&&_0xd870e0[_0x42b3dd(0x134)](_0x1e033a[_0x42b3dd(0x13a)]),await _0x1aabe4[_0x1e033a['methodName']][_0x42b3dd(0x13e)](_0x1aabe4)(_0x8c9ba9,_0x49efec[_0x1e033a[_0x42b3dd(0x13a)]],_0x49efec,{'app':this['app'],'container':this[_0x42b3dd(0x127)],'paginate':_0x3ddf84,'queryRunner':_0x1c46b0===null||_0x1c46b0===void 0x0?void 0x0:_0x1c46b0[_0x42b3dd(0x154)]})));}}}}for(const _0x524f8a in _0x49efec){if(typeof _0x49efec[_0x524f8a]=='undefined')continue;if(_0xd870e0[_0x42b3dd(0x168)](_0x524f8a)!=-0x1)continue;const _0x526b16=this[_0x42b3dd(0x129)][_0x42b3dd(0x141)](_0x524f8a);if(!_0x526b16)continue;if((_0x3aa0b8=_0x49efec===null||_0x49efec===void 0x0?void 0x0:_0x49efec[_0x524f8a])===null||_0x3aa0b8===void 0x0?void 0x0:_0x3aa0b8[_0x42b3dd(0x143)](_0x42b3dd(0x13f))){const _0x366b02=(_0x571a90=_0x49efec[_0x524f8a])===null||_0x571a90===void 0x0?void 0x0:_0x571a90['condition'],_0xe9ece1=(_0x263100=_0x49efec[_0x524f8a])===null||_0x263100===void 0x0?void 0x0:_0x263100[_0x42b3dd(0x13f)][_0x42b3dd(0x172)]()[_0x42b3dd(0x16b)](),_0x84b387=_0x42b3dd(0x144)+_0x524f8a+'_'+Math['ceil'](Math[_0x42b3dd(0x160)]()*0xa)+Math[_0x42b3dd(0x153)](Math[_0x42b3dd(0x160)]()*0xa)+Math['ceil'](Math['random']()*0xa)+Math[_0x42b3dd(0x153)](Math[_0x42b3dd(0x160)]()*0xa);if(['=','!=','<>','>','>=','<','<=','LIKE','NOT\x20LIKE'][_0x42b3dd(0x168)](_0xe9ece1)!=-0x1)typeof _0x366b02!=_0x42b3dd(0x131)&&_0x8c9ba9[_0x42b3dd(0x15d)](_0x8c9ba9[_0x42b3dd(0x16e)]+'.'+_0x524f8a+'\x20'+_0xe9ece1+'\x20:'+_0x84b387,{[_0x84b387]:_0x366b02});else{if(['IN',_0x42b3dd(0x15c)][_0x42b3dd(0x168)](_0xe9ece1)!=-0x1){if(typeof _0x366b02!=_0x42b3dd(0x131)){const _0x5abfb7=Array[_0x42b3dd(0x12c)](_0x366b02)?_0x366b02:typeof _0x366b02==_0x42b3dd(0x14e)?_0x366b02[_0x42b3dd(0x133)](','):[_0x366b02];_0x5abfb7[_0x42b3dd(0x166)]==0x0?_0x8c9ba9['andWhere'](_0x42b3dd(0x14f)):_0x8c9ba9['andWhere'](_0x8c9ba9[_0x42b3dd(0x16e)]+'.'+_0x524f8a+'\x20'+_0xe9ece1+_0x42b3dd(0x169)+_0x84b387+')',{[_0x84b387]:_0x5abfb7});}}else{if([_0x42b3dd(0x142),_0x42b3dd(0x159)][_0x42b3dd(0x168)](_0xe9ece1)!=-0x1)typeof _0x366b02!=_0x42b3dd(0x131)&&_0x8c9ba9['andWhere'](_0xe9ece1+'(:'+_0x84b387+','+_0x8c9ba9[_0x42b3dd(0x16e)]+'.'+_0x524f8a+')',{[_0x84b387]:_0x366b02});else{if(['BETWEEN',_0x42b3dd(0x140)][_0x42b3dd(0x168)](_0xe9ece1)!=-0x1){if(typeof _0x366b02!=_0x42b3dd(0x131)){const _0x2586cf=Array[_0x42b3dd(0x12c)](_0x366b02)?_0x366b02:typeof _0x366b02==_0x42b3dd(0x14e)?_0x366b02['split'](','):[_0x366b02];_0x2586cf[_0x42b3dd(0x166)]>0x1&&_0x8c9ba9[_0x42b3dd(0x15d)](_0x8c9ba9[_0x42b3dd(0x16e)]+'.'+_0x524f8a+'\x20'+_0xe9ece1+'\x20:'+_0x84b387+'\x20AND\x20:'+_0x84b387+'_2',{[''+_0x84b387]:_0x2586cf[0x0],[_0x84b387+'_2']:_0x2586cf[0x1]});}}else[_0x42b3dd(0x13b),_0x42b3dd(0x157)][_0x42b3dd(0x168)](_0xe9ece1)!=-0x1&&_0x8c9ba9['andWhere'](_0xe9ece1+'('+_0x8c9ba9['alias']+'.'+_0x524f8a+')');}}}}else{const _0x2b7248=((_0x108cd6=typeof _0x526b16[_0x42b3dd(0x17d)]==_0x42b3dd(0x16d)?(_0x4ab9ac=_0x526b16===null||_0x526b16===void 0x0?void 0x0:_0x526b16[_0x42b3dd(0x17d)])===null||_0x4ab9ac===void 0x0?void 0x0:_0x4ab9ac[_0x42b3dd(0x163)]:_0x526b16['type'][_0x42b3dd(0x149)]())===null||_0x108cd6===void 0x0?void 0x0:_0x108cd6[_0x42b3dd(0x12b)]())||undefined;if(_0x2b7248){if(Array[_0x42b3dd(0x12c)](_0x49efec[_0x524f8a]))_0x49efec[_0x524f8a][_0x42b3dd(0x166)]==0x0?_0x8c9ba9[_0x42b3dd(0x15d)](_0x42b3dd(0x14f)):_0x8c9ba9[_0x42b3dd(0x15d)](_0x8c9ba9[_0x42b3dd(0x16e)]+'.'+_0x524f8a+_0x42b3dd(0x176)+_0x524f8a+')',{['_auto_'+_0x524f8a]:_0x49efec[_0x524f8a]});else _0x2b7248=='string'?_0x8c9ba9[_0x42b3dd(0x15d)](_0x8c9ba9[_0x42b3dd(0x16e)]+'.'+_0x524f8a+'\x20like\x20:_auto_'+_0x524f8a,{[_0x42b3dd(0x144)+_0x524f8a]:'%'+_0x49efec[_0x524f8a]+'%'}):_0x8c9ba9['andWhere'](_0x8c9ba9[_0x42b3dd(0x16e)]+'.'+_0x524f8a+_0x42b3dd(0x15b)+_0x524f8a,{['_auto_'+_0x524f8a]:_0x49efec[_0x524f8a]});}}}(_0x3ddf84===null||_0x3ddf84===void 0x0?void 0x0:_0x3ddf84['_size'])&&_0x8c9ba9['take'](Math['abs'](_0x3ddf84[_0x42b3dd(0x14a)]));(_0x3ddf84===null||_0x3ddf84===void 0x0?void 0x0:_0x3ddf84[_0x42b3dd(0x148)])&&(_0x3ddf84===null||_0x3ddf84===void 0x0?void 0x0:_0x3ddf84[_0x42b3dd(0x14a)])&&_0x8c9ba9[_0x42b3dd(0x175)]((Math[_0x42b3dd(0x170)](_0x3ddf84[_0x42b3dd(0x148)])-0x1)*Math[_0x42b3dd(0x170)](_0x3ddf84['_size']));if(_0x3ddf84===null||_0x3ddf84===void 0x0?void 0x0:_0x3ddf84[_0x42b3dd(0x137)]){if(_0x3ddf84[_0x42b3dd(0x137)]['indexOf']('.')!==-0x1)_0x8c9ba9[_0x42b3dd(0x174)](''+_0x3ddf84[_0x42b3dd(0x137)],(_0x3ddf84===null||_0x3ddf84===void 0x0?void 0x0:_0x3ddf84[_0x42b3dd(0x15f)])?'ASC':'DESC');else _0xd870e0[_0x42b3dd(0x168)](_0x3ddf84[_0x42b3dd(0x137)])==-0x1&&(this[_0x42b3dd(0x129)]['findColumnWithPropertyName'](_0x3ddf84[_0x42b3dd(0x137)])?_0x8c9ba9[_0x42b3dd(0x174)](_0x8c9ba9[_0x42b3dd(0x16e)]+'.'+_0x3ddf84[_0x42b3dd(0x137)],(_0x3ddf84===null||_0x3ddf84===void 0x0?void 0x0:_0x3ddf84[_0x42b3dd(0x15f)])?_0x42b3dd(0x178):_0x42b3dd(0x14d)):_0x8c9ba9[_0x42b3dd(0x174)](''+_0x3ddf84[_0x42b3dd(0x137)],(_0x3ddf84===null||_0x3ddf84===void 0x0?void 0x0:_0x3ddf84[_0x42b3dd(0x15f)])?_0x42b3dd(0x178):_0x42b3dd(0x14d)));}return typeof(_0x1c46b0===null||_0x1c46b0===void 0x0?void 0x0:_0x1c46b0[_0x42b3dd(0x173)])=='function'&&await(_0x1c46b0===null||_0x1c46b0===void 0x0?void 0x0:_0x1c46b0[_0x42b3dd(0x173)](_0x8c9ba9)),_0x8c9ba9;}async[a7_0x7ae074(0x12a)](_0x18a89c,..._0x5d7f23){const _0x23cdce=a7_0x7ae074,_0x3586f8=this[_0x23cdce(0x171)](_0x18a89c,..._0x5d7f23);return await this['save'](_0x3586f8);}async[a7_0x7ae074(0x150)](_0x492669,..._0x10f5c5){const _0x2df242=a7_0x7ae074,_0x49e678=this[_0x2df242(0x171)](this['create'](_0x492669),..._0x10f5c5);return await this[_0x2df242(0x16f)](_0x49e678);}async[a7_0x7ae074(0x12e)](_0x4b0ac9,_0x412f29){const _0xd0348=a7_0x7ae074;return this[_0xd0348(0x138)][_0xd0348(0x12e)](_0x4b0ac9,_0x412f29);}[a7_0x7ae074(0x179)](_0x3be8a1,_0x433456,..._0x1cfe05){const _0x313efa=a7_0x7ae074;for(const _0x17243b of _0x1cfe05){if(typeof(_0x3be8a1===null||_0x3be8a1===void 0x0?void 0x0:_0x3be8a1[_0x17243b])=='undefined')continue;if(typeof(_0x433456===null||_0x433456===void 0x0?void 0x0:_0x433456[_0x17243b])==_0x313efa(0x131))continue;if(_0x3be8a1[_0x17243b]!=_0x433456[_0x17243b])return!![];}return![];}[a7_0x7ae074(0x161)](_0xfde877,..._0x4e5b77){const _0x1d76fd=a7_0x7ae074,_0x1afa2d={};for(const _0x4f72a5 of _0x4e5b77){for(const _0x3f05bc in _0x4f72a5){typeof(_0x4f72a5===null||_0x4f72a5===void 0x0?void 0x0:_0x4f72a5[_0x3f05bc])!=_0x1d76fd(0x131)&&(_0x4f72a5===null||_0x4f72a5===void 0x0?void 0x0:_0x4f72a5[_0x3f05bc])!=(_0xfde877===null||_0xfde877===void 0x0?void 0x0:_0xfde877[_0x3f05bc])&&(_0x1afa2d[_0x3f05bc]=_0x4f72a5[_0x3f05bc]);}}return _0x1afa2d;}}exports[a7_0x7ae074(0x132)]=Repository;
|
|
1
|
+
'use strict';function a7_0x3cfb(_0x3141fd,_0x594737){const _0x159ac5=a7_0x159a();return a7_0x3cfb=function(_0x3cfbf2,_0x4871c2){_0x3cfbf2=_0x3cfbf2-0x129;let _0x2d241e=_0x159ac5[_0x3cfbf2];return _0x2d241e;},a7_0x3cfb(_0x3141fd,_0x594737);}const a7_0x5ac0bc=a7_0x3cfb;(function(_0x393a08,_0x1b658b){const _0x1ea96a=a7_0x3cfb,_0x4541d3=_0x393a08();while(!![]){try{const _0x1c5d90=-parseInt(_0x1ea96a(0x13a))/0x1*(parseInt(_0x1ea96a(0x166))/0x2)+-parseInt(_0x1ea96a(0x15d))/0x3+-parseInt(_0x1ea96a(0x14f))/0x4*(parseInt(_0x1ea96a(0x12f))/0x5)+-parseInt(_0x1ea96a(0x14e))/0x6+-parseInt(_0x1ea96a(0x16c))/0x7+parseInt(_0x1ea96a(0x159))/0x8*(-parseInt(_0x1ea96a(0x175))/0x9)+parseInt(_0x1ea96a(0x165))/0xa;if(_0x1c5d90===_0x1b658b)break;else _0x4541d3['push'](_0x4541d3['shift']());}catch(_0x521d41){_0x4541d3['push'](_0x4541d3['shift']());}}}(a7_0x159a,0x4b102));Object['defineProperty'](exports,a7_0x5ac0bc(0x174),{'value':!![]}),exports['Repository']=void 0x0;const core_1=require(a7_0x5ac0bc(0x151)),typeorm_1=require(a7_0x5ac0bc(0x134)),interface_1=require(a7_0x5ac0bc(0x157));class Repository extends typeorm_1[a7_0x5ac0bc(0x156)]{constructor(_0x21a951,_0x1e7f0b,_0xe49520){const _0x4811e5=a7_0x5ac0bc;super(_0xe49520['target'],_0xe49520['manager'],_0xe49520[_0x4811e5(0x12b)]),this[_0x4811e5(0x172)]=[];for(const _0x231c52 of(0x0,core_1[_0x4811e5(0x130)])(interface_1[_0x4811e5(0x149)],this[_0x4811e5(0x152)])||[]){const _0xce6d84={'model':_0x231c52,'searchs':[],'searchScopes':[]};for(const _0x113717 of(0x0,core_1[_0x4811e5(0x130)])(interface_1[_0x4811e5(0x139)],_0x231c52)||[]){_0xce6d84[_0x4811e5(0x168)][_0x4811e5(0x15f)](_0x113717);}for(const _0x5ad3dd of(0x0,core_1[_0x4811e5(0x130)])(interface_1['MODEL_SEARCH_SCOPE_KEY'],_0x231c52)||[]){_0xce6d84['searchScopes'][_0x4811e5(0x15f)](_0x5ad3dd);}this[_0x4811e5(0x172)][_0x4811e5(0x15f)](_0xce6d84);}this['app']=_0x21a951,this[_0x4811e5(0x145)]=_0x1e7f0b;}async[a7_0x5ac0bc(0x158)](_0x157634,_0x1bf28a,_0x4eb988={}){const _0x4b31d6=a7_0x5ac0bc;var _0x2a2711,_0x3b18e3,_0x3b10f4,_0xe1d182,_0x3b2e61,_0x5da692;const _0x4879bc=this['createQueryBuilder'](undefined,_0x4eb988===null||_0x4eb988===void 0x0?void 0x0:_0x4eb988['queryRunner']),_0x161847=[];for(const _0x3e96fa of this['modelSearchs']){if(_0x3e96fa===null||_0x3e96fa===void 0x0?void 0x0:_0x3e96fa['model']){const _0x46696b=await this['app'][_0x4b31d6(0x12d)]()['getAsync'](_0x3e96fa[_0x4b31d6(0x147)]);if(_0x46696b){typeof _0x46696b[_0x4b31d6(0x142)]=='function'&&await _0x46696b[_0x4b31d6(0x142)][_0x4b31d6(0x14d)](_0x46696b)(_0x4879bc,_0x157634,{'app':this[_0x4b31d6(0x162)],'container':this['container'],'paginate':_0x1bf28a,'queryRunner':_0x4eb988===null||_0x4eb988===void 0x0?void 0x0:_0x4eb988[_0x4b31d6(0x12b)]});if(_0x4eb988===null||_0x4eb988===void 0x0?void 0x0:_0x4eb988['scope']){const _0x1cb3ce=Array[_0x4b31d6(0x12c)](_0x4eb988[_0x4b31d6(0x16b)])?_0x4eb988[_0x4b31d6(0x16b)]:[_0x4eb988[_0x4b31d6(0x16b)]];for(const _0x2d53ca of(_0x3e96fa===null||_0x3e96fa===void 0x0?void 0x0:_0x3e96fa[_0x4b31d6(0x177)])||[]){(_0x2d53ca===null||_0x2d53ca===void 0x0?void 0x0:_0x2d53ca[_0x4b31d6(0x16b)])&&_0x1cb3ce[_0x4b31d6(0x170)](_0x2d53ca[_0x4b31d6(0x16b)])!=-0x1&&(_0x2d53ca===null||_0x2d53ca===void 0x0?void 0x0:_0x2d53ca['methodName'])&&typeof _0x46696b[_0x2d53ca[_0x4b31d6(0x136)]]=='function'&&await _0x46696b[_0x2d53ca[_0x4b31d6(0x136)]][_0x4b31d6(0x14d)](_0x46696b)(_0x4879bc,_0x157634,{'app':this[_0x4b31d6(0x162)],'container':this[_0x4b31d6(0x145)],'paginate':_0x1bf28a,'queryRunner':_0x4eb988===null||_0x4eb988===void 0x0?void 0x0:_0x4eb988['queryRunner']});}}if(_0x157634)for(const _0x20d9d1 of(_0x3e96fa===null||_0x3e96fa===void 0x0?void 0x0:_0x3e96fa[_0x4b31d6(0x168)])||[]){(_0x20d9d1===null||_0x20d9d1===void 0x0?void 0x0:_0x20d9d1[_0x4b31d6(0x167)])&&(_0x20d9d1===null||_0x20d9d1===void 0x0?void 0x0:_0x20d9d1['methodName'])&&typeof _0x46696b[_0x20d9d1['methodName']]==_0x4b31d6(0x15c)&&(typeof(_0x157634===null||_0x157634===void 0x0?void 0x0:_0x157634[_0x20d9d1[_0x4b31d6(0x167)]])!=_0x4b31d6(0x144)&&!((_0x2a2711=_0x157634===null||_0x157634===void 0x0?void 0x0:_0x157634[_0x20d9d1[_0x4b31d6(0x167)]])===null||_0x2a2711===void 0x0?void 0x0:_0x2a2711['hasOwnProperty']('operator'))&&(_0x161847[_0x4b31d6(0x170)](_0x20d9d1['field'])==-0x1&&_0x161847['push'](_0x20d9d1[_0x4b31d6(0x167)]),await _0x46696b[_0x20d9d1[_0x4b31d6(0x136)]]['bind'](_0x46696b)(_0x4879bc,_0x157634[_0x20d9d1[_0x4b31d6(0x167)]],_0x157634,{'app':this[_0x4b31d6(0x162)],'container':this[_0x4b31d6(0x145)],'paginate':_0x1bf28a,'queryRunner':_0x4eb988===null||_0x4eb988===void 0x0?void 0x0:_0x4eb988[_0x4b31d6(0x12b)]})));}}}}for(const _0x48b57b in _0x157634){if(typeof _0x157634[_0x48b57b]=='undefined')continue;if(_0x161847[_0x4b31d6(0x170)](_0x48b57b)!=-0x1)continue;const _0x5a0914=this['metadata']['findColumnWithPropertyName'](_0x48b57b);if(!_0x5a0914)continue;if((_0x3b18e3=_0x157634===null||_0x157634===void 0x0?void 0x0:_0x157634[_0x48b57b])===null||_0x3b18e3===void 0x0?void 0x0:_0x3b18e3[_0x4b31d6(0x16d)](_0x4b31d6(0x15b))){const _0x1f4d7c=(_0x3b10f4=_0x157634[_0x48b57b])===null||_0x3b10f4===void 0x0?void 0x0:_0x3b10f4[_0x4b31d6(0x155)],_0x45d72b=(_0xe1d182=_0x157634[_0x48b57b])===null||_0xe1d182===void 0x0?void 0x0:_0xe1d182[_0x4b31d6(0x15b)][_0x4b31d6(0x164)]()[_0x4b31d6(0x14c)](),_0x2ec999=_0x4b31d6(0x133)+_0x48b57b+'_'+Math[_0x4b31d6(0x15a)](Math[_0x4b31d6(0x160)]()*0xa)+Math[_0x4b31d6(0x15a)](Math[_0x4b31d6(0x160)]()*0xa)+Math[_0x4b31d6(0x15a)](Math[_0x4b31d6(0x160)]()*0xa)+Math[_0x4b31d6(0x15a)](Math[_0x4b31d6(0x160)]()*0xa);if(['=','!=','<>','>','>=','<','<=',_0x4b31d6(0x140),_0x4b31d6(0x138)][_0x4b31d6(0x170)](_0x45d72b)!=-0x1)typeof _0x1f4d7c!=_0x4b31d6(0x144)&&_0x4879bc[_0x4b31d6(0x16e)](_0x4879bc[_0x4b31d6(0x135)]+'.'+_0x48b57b+'\x20'+_0x45d72b+'\x20:'+_0x2ec999,{[_0x2ec999]:_0x1f4d7c});else{if(['IN','NOT\x20IN'][_0x4b31d6(0x170)](_0x45d72b)!=-0x1){if(typeof _0x1f4d7c!=_0x4b31d6(0x144)){const _0x48fa56=Array[_0x4b31d6(0x12c)](_0x1f4d7c)?_0x1f4d7c:typeof _0x1f4d7c=='string'?_0x1f4d7c[_0x4b31d6(0x15e)](','):[_0x1f4d7c];_0x48fa56[_0x4b31d6(0x16f)]==0x0?_0x4879bc[_0x4b31d6(0x16e)](_0x4b31d6(0x171)):_0x4879bc['andWhere'](_0x4879bc['alias']+'.'+_0x48b57b+'\x20'+_0x45d72b+_0x4b31d6(0x141)+_0x2ec999+')',{[_0x2ec999]:_0x48fa56});}}else{if(['FIND\x20IN\x20SET',_0x4b31d6(0x132)]['indexOf'](_0x45d72b)!=-0x1)typeof _0x1f4d7c!=_0x4b31d6(0x144)&&_0x4879bc[_0x4b31d6(0x16e)](_0x45d72b+'(:'+_0x2ec999+','+_0x4879bc[_0x4b31d6(0x135)]+'.'+_0x48b57b+')',{[_0x2ec999]:_0x1f4d7c});else{if([_0x4b31d6(0x129),_0x4b31d6(0x12e)][_0x4b31d6(0x170)](_0x45d72b)!=-0x1){if(typeof _0x1f4d7c!='undefined'){const _0x32748b=Array[_0x4b31d6(0x12c)](_0x1f4d7c)?_0x1f4d7c:typeof _0x1f4d7c==_0x4b31d6(0x14b)?_0x1f4d7c['split'](','):[_0x1f4d7c];_0x32748b[_0x4b31d6(0x16f)]>0x1&&_0x4879bc[_0x4b31d6(0x16e)](_0x4879bc[_0x4b31d6(0x135)]+'.'+_0x48b57b+'\x20'+_0x45d72b+'\x20:'+_0x2ec999+_0x4b31d6(0x163)+_0x2ec999+'_2',{[''+_0x2ec999]:_0x32748b[0x0],[_0x2ec999+'_2']:_0x32748b[0x1]});}}else[_0x4b31d6(0x150),'NOT\x20ISNULL'][_0x4b31d6(0x170)](_0x45d72b)!=-0x1&&_0x4879bc[_0x4b31d6(0x16e)](_0x45d72b+'('+_0x4879bc[_0x4b31d6(0x135)]+'.'+_0x48b57b+')');}}}}else{const _0x423243=((_0x5da692=typeof _0x5a0914[_0x4b31d6(0x13d)]==_0x4b31d6(0x15c)?(_0x3b2e61=_0x5a0914===null||_0x5a0914===void 0x0?void 0x0:_0x5a0914[_0x4b31d6(0x13d)])===null||_0x3b2e61===void 0x0?void 0x0:_0x3b2e61['name']:_0x5a0914[_0x4b31d6(0x13d)][_0x4b31d6(0x13e)]())===null||_0x5da692===void 0x0?void 0x0:_0x5da692['toLowerCase']())||undefined;if(_0x423243){if(Array[_0x4b31d6(0x12c)](_0x157634[_0x48b57b]))_0x157634[_0x48b57b][_0x4b31d6(0x16f)]==0x0?_0x4879bc[_0x4b31d6(0x16e)](_0x4b31d6(0x171)):_0x4879bc[_0x4b31d6(0x16e)](_0x4879bc[_0x4b31d6(0x135)]+'.'+_0x48b57b+'\x20IN(:..._auto_'+_0x48b57b+')',{[_0x4b31d6(0x133)+_0x48b57b]:_0x157634[_0x48b57b]});else _0x423243=='string'?_0x4879bc[_0x4b31d6(0x16e)](_0x4879bc[_0x4b31d6(0x135)]+'.'+_0x48b57b+'\x20like\x20:_auto_'+_0x48b57b,{[_0x4b31d6(0x133)+_0x48b57b]:'%'+_0x157634[_0x48b57b]+'%'}):_0x4879bc[_0x4b31d6(0x16e)](_0x4879bc[_0x4b31d6(0x135)]+'.'+_0x48b57b+_0x4b31d6(0x13f)+_0x48b57b,{[_0x4b31d6(0x133)+_0x48b57b]:_0x157634[_0x48b57b]});}}}(_0x1bf28a===null||_0x1bf28a===void 0x0?void 0x0:_0x1bf28a[_0x4b31d6(0x161)])&&_0x4879bc[_0x4b31d6(0x148)](Math[_0x4b31d6(0x153)](_0x1bf28a[_0x4b31d6(0x161)]));(_0x1bf28a===null||_0x1bf28a===void 0x0?void 0x0:_0x1bf28a[_0x4b31d6(0x173)])&&(_0x1bf28a===null||_0x1bf28a===void 0x0?void 0x0:_0x1bf28a['_size'])&&_0x4879bc['skip']((Math[_0x4b31d6(0x153)](_0x1bf28a[_0x4b31d6(0x173)])-0x1)*Math[_0x4b31d6(0x153)](_0x1bf28a[_0x4b31d6(0x161)]));if(_0x1bf28a===null||_0x1bf28a===void 0x0?void 0x0:_0x1bf28a[_0x4b31d6(0x12a)]){if(_0x1bf28a[_0x4b31d6(0x12a)][_0x4b31d6(0x170)]('.')!==-0x1)_0x4879bc[_0x4b31d6(0x13c)](''+_0x1bf28a['_order'],(_0x1bf28a===null||_0x1bf28a===void 0x0?void 0x0:_0x1bf28a[_0x4b31d6(0x143)])?'ASC':_0x4b31d6(0x146));else _0x161847['indexOf'](_0x1bf28a[_0x4b31d6(0x12a)])==-0x1&&(this['metadata']['findColumnWithPropertyName'](_0x1bf28a[_0x4b31d6(0x12a)])?_0x4879bc[_0x4b31d6(0x13c)](_0x4879bc[_0x4b31d6(0x135)]+'.'+_0x1bf28a[_0x4b31d6(0x12a)],(_0x1bf28a===null||_0x1bf28a===void 0x0?void 0x0:_0x1bf28a[_0x4b31d6(0x143)])?_0x4b31d6(0x13b):_0x4b31d6(0x146)):_0x4879bc[_0x4b31d6(0x13c)](''+_0x1bf28a[_0x4b31d6(0x12a)],(_0x1bf28a===null||_0x1bf28a===void 0x0?void 0x0:_0x1bf28a[_0x4b31d6(0x143)])?_0x4b31d6(0x13b):'DESC'));}return typeof(_0x4eb988===null||_0x4eb988===void 0x0?void 0x0:_0x4eb988[_0x4b31d6(0x14a)])=='function'&&await(_0x4eb988===null||_0x4eb988===void 0x0?void 0x0:_0x4eb988['excess'](_0x4879bc)),_0x4879bc;}async['mergeSave'](_0x20d1e9,..._0x10fc15){const _0x468b35=a7_0x5ac0bc,_0x46bf48=this[_0x468b35(0x137)](_0x20d1e9,..._0x10fc15);return await this[_0x468b35(0x169)](_0x46bf48);}async[a7_0x5ac0bc(0x154)](_0x312b5f,..._0x547e90){const _0x44544f=a7_0x5ac0bc,_0x5187f4=this[_0x44544f(0x137)](this[_0x44544f(0x176)](_0x312b5f),..._0x547e90);return await this[_0x44544f(0x169)](_0x5187f4);}async['transaction'](_0x2f8dc4,_0x299b9d){const _0x3d88db=a7_0x5ac0bc;return this[_0x3d88db(0x16a)]['transaction'](_0x2f8dc4,_0x299b9d);}['isDirty'](_0x419cc8,_0x5221a7,..._0x5ca529){const _0x1c75f8=a7_0x5ac0bc;for(const _0x4d508f of _0x5ca529){if(typeof(_0x419cc8===null||_0x419cc8===void 0x0?void 0x0:_0x419cc8[_0x4d508f])==_0x1c75f8(0x144))continue;if(typeof(_0x5221a7===null||_0x5221a7===void 0x0?void 0x0:_0x5221a7[_0x4d508f])=='undefined')continue;if(_0x419cc8[_0x4d508f]!=_0x5221a7[_0x4d508f])return!![];}return![];}[a7_0x5ac0bc(0x131)](_0xd5ff17,..._0x2063c5){const _0x2d3e7e=a7_0x5ac0bc,_0x4960f8={};for(const _0x2d84ed of _0x2063c5){for(const _0x125a0e in _0x2d84ed){typeof(_0x2d84ed===null||_0x2d84ed===void 0x0?void 0x0:_0x2d84ed[_0x125a0e])!=_0x2d3e7e(0x144)&&(_0x2d84ed===null||_0x2d84ed===void 0x0?void 0x0:_0x2d84ed[_0x125a0e])!=(_0xd5ff17===null||_0xd5ff17===void 0x0?void 0x0:_0xd5ff17[_0x125a0e])&&(_0x4960f8[_0x125a0e]=_0x2d84ed[_0x125a0e]);}}return _0x4960f8;}}function a7_0x159a(){const _0x2ad235=['NOT\x20FIND\x20IN\x20SET','_auto_','typeorm','alias','methodName','merge','NOT\x20LIKE','MODEL_SEARCH_KEY','1bsIYxi','ASC','orderBy','type','toString','\x20=\x20:_auto_','LIKE','(:...','__initialize','_isreverse','undefined','container','DESC','model','take','MODEL_KEY','excess','string','toUpperCase','bind','3279630bFGFeE','316944kAZWcy','ISNULL','@midwayjs/core','target','abs','createSave','condition','Repository','../interface','search','57176dlxjdK','ceil','operator','function','319566YvXjUb','split','push','random','_size','app','\x20AND\x20:','trim','22835950cNTKLx','1197542hmMZlm','field','searchs','save','manager','scope','1700398PxtftY','hasOwnProperty','andWhere','length','indexOf','1\x20=\x202','modelSearchs','_page','__esModule','207bmffat','create','searchScopes','BETWEEN','_order','queryRunner','isArray','getApplicationContext','NOT\x20BETWEEN','20MEQGjw','getClassMetadata','getDirty'];a7_0x159a=function(){return _0x2ad235;};return a7_0x159a();}exports['Repository']=Repository;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';
|
|
1
|
+
'use strict';const a8_0x2fb860=a8_0x3e6d;(function(_0x486fde,_0x307e0c){const _0x148564=a8_0x3e6d,_0x1af6e0=_0x486fde();while(!![]){try{const _0x318ad4=parseInt(_0x148564(0x90))/0x1+-parseInt(_0x148564(0x98))/0x2+parseInt(_0x148564(0x8e))/0x3*(-parseInt(_0x148564(0x91))/0x4)+parseInt(_0x148564(0x97))/0x5*(-parseInt(_0x148564(0x94))/0x6)+parseInt(_0x148564(0xa1))/0x7+parseInt(_0x148564(0x9b))/0x8*(-parseInt(_0x148564(0x9f))/0x9)+-parseInt(_0x148564(0x9d))/0xa*(-parseInt(_0x148564(0x93))/0xb);if(_0x318ad4===_0x307e0c)break;else _0x1af6e0['push'](_0x1af6e0['shift']());}catch(_0x29840c){_0x1af6e0['push'](_0x1af6e0['shift']());}}}(a8_0x5735,0x84f31));Object[a8_0x2fb860(0x92)](exports,a8_0x2fb860(0x96),{'value':!![]}),exports[a8_0x2fb860(0x9e)]=void 0x0;function a8_0x5735(){const _0x593a49=['getDataSourceEntity','30249qdipIz','listModule','1903118ggmjjW','9jWiMQp','ENTIFY_MODULE_SOURCE','297641Noktht','298900oCwrKV','defineProperty','22145233jBFAFR','1892358xycZae','default','__esModule','5KwNnRK','899914znBeFZ','../interface','getClassMetadata','2496SAqupu','find','10eGnMpx'];a8_0x5735=function(){return _0x593a49;};return a8_0x5735();}const core_1=require('@midwayjs/core'),interface_1=require(a8_0x2fb860(0x99));function getDataSourceEntity(_0x39a4b1=a8_0x2fb860(0x95)){const _0x30e2e6=a8_0x2fb860;var _0xe795c5;const _0x49531e=[];for(const _0x327129 of(0x0,core_1[_0x30e2e6(0xa0)])(interface_1['ENTIFY_MODULE'])){const _0x20126d=(0x0,core_1[_0x30e2e6(0x9a)])(interface_1[_0x30e2e6(0x8f)],_0x327129);((_0xe795c5=_0x20126d===null||_0x20126d===void 0x0?void 0x0:_0x20126d['dataSource'])===null||_0xe795c5===void 0x0?void 0x0:_0xe795c5[_0x30e2e6(0x9c)](_0x238cf5=>_0x238cf5==_0x39a4b1))&&_0x49531e['push'](_0x327129);}return _0x49531e;}function a8_0x3e6d(_0x32812c,_0x2b071b){const _0x5735df=a8_0x5735();return a8_0x3e6d=function(_0x3e6d6d,_0x31585c){_0x3e6d6d=_0x3e6d6d-0x8e;let _0x4ad82a=_0x5735df[_0x3e6d6d];return _0x4ad82a;},a8_0x3e6d(_0x32812c,_0x2b071b);}exports[a8_0x2fb860(0x9e)]=getDataSourceEntity;
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';var a9_0x26d36c=a9_0x5281;(function(_0x331066,_0x1f0111){var _0x343f81=a9_0x5281,_0x3bc228=_0x331066();while(!![]){try{var _0xd91c40=-parseInt(_0x343f81(0x1f3))/0x1*(parseInt(_0x343f81(0x1d4))/0x2)+parseInt(_0x343f81(0x1dd))/0x3+-parseInt(_0x343f81(0x1d3))/0x4+-parseInt(_0x343f81(0x1ea))/0x5*(parseInt(_0x343f81(0x1ed))/0x6)+-parseInt(_0x343f81(0x1d6))/0x7*(-parseInt(_0x343f81(0x1e4))/0x8)+parseInt(_0x343f81(0x1fc))/0x9+parseInt(_0x343f81(0x1e1))/0xa;if(_0xd91c40===_0x1f0111)break;else _0x3bc228['push'](_0x3bc228['shift']());}catch(_0x4e197d){_0x3bc228['push'](_0x3bc228['shift']());}}}(a9_0x39c9,0xe335c));var __createBinding=this&&this[a9_0x26d36c(0x1d7)]||(Object['create']?function(_0x18dc61,_0x941205,_0x230e01,_0x1e8a1d){var _0x40416e=a9_0x26d36c;if(_0x1e8a1d===undefined)_0x1e8a1d=_0x230e01;var _0x3cba64=Object[_0x40416e(0x1f9)](_0x941205,_0x230e01);(!_0x3cba64||(_0x40416e(0x1e6)in _0x3cba64?!_0x941205[_0x40416e(0x1d8)]:_0x3cba64[_0x40416e(0x1f7)]||_0x3cba64['configurable']))&&(_0x3cba64={'enumerable':!![],'get':function(){return _0x941205[_0x230e01];}}),Object[_0x40416e(0x1de)](_0x18dc61,_0x1e8a1d,_0x3cba64);}:function(_0x170663,_0x155474,_0x4c1059,_0x32dfe9){if(_0x32dfe9===undefined)_0x32dfe9=_0x4c1059;_0x170663[_0x32dfe9]=_0x155474[_0x4c1059];}),__exportStar=this&&this[a9_0x26d36c(0x1f8)]||function(_0x30d31c,_0x44c331){var _0xfa6d83=a9_0x26d36c;for(var _0x5d6e9b in _0x30d31c)if(_0x5d6e9b!==_0xfa6d83(0x1ee)&&!Object['prototype']['hasOwnProperty'][_0xfa6d83(0x1f0)](_0x44c331,_0x5d6e9b))__createBinding(_0x44c331,_0x30d31c,_0x5d6e9b);};Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports['ScopeEnum']=exports[a9_0x26d36c(0x1f6)]=exports[a9_0x26d36c(0x1fe)]=exports[a9_0x26d36c(0x1e2)]=exports[a9_0x26d36c(0x1e8)]=exports[a9_0x26d36c(0x1e7)]=exports[a9_0x26d36c(0x1dc)]=exports[a9_0x26d36c(0x1f1)]=exports[a9_0x26d36c(0x1e3)]=exports['ProvideRepository']=exports[a9_0x26d36c(0x1fa)]=exports[a9_0x26d36c(0x1ef)]=exports[a9_0x26d36c(0x1da)]=exports[a9_0x26d36c(0x1fb)]=exports['Repository']=void 0x0,__exportStar(require(a9_0x26d36c(0x1f5)),exports),__exportStar(require(a9_0x26d36c(0x1f2)),exports);var Repository_1=require(a9_0x26d36c(0x1e9));function a9_0x5281(_0x12e6d6,_0x3eba00){var _0x39c9b4=a9_0x39c9();return a9_0x5281=function(_0x52810f,_0x45f338){_0x52810f=_0x52810f-0x1d3;var _0x40b21f=_0x39c9b4[_0x52810f];return _0x40b21f;},a9_0x5281(_0x12e6d6,_0x3eba00);}Object['defineProperty'](exports,a9_0x26d36c(0x1db),{'enumerable':!![],'get':function(){var _0x2d0d12=a9_0x26d36c;return Repository_1[_0x2d0d12(0x1db)];}});var VirtualColumn_1=require(a9_0x26d36c(0x1fd));Object[a9_0x26d36c(0x1de)](exports,a9_0x26d36c(0x1fb),{'enumerable':!![],'get':function(){var _0x412561=a9_0x26d36c;return VirtualColumn_1[_0x412561(0x1fb)];}});function a9_0x39c9(){var _0x108135=['ScopeEnum','get','getDataSourceEntity','Configuration','./definition/Repository','10805eeZAQw','./decorator/ProvideEntity','./decorator/InjectEntity','2082JjItZs','default','InjectRepository','call','Search','./interface','1VfNjXE','./decorator/ProvideRepository','typeorm','Scope','writable','__exportStar','getOwnPropertyDescriptor','ProvideEntity','VirtualColumn','3749526IIfUNi','./decorator/VirtualColumn','Inject','./helper/getDataSourceEntity','1475676PhEGhu','3246168BcuUwt','CustomConfiguration','4904515mpsvre','__createBinding','__esModule','ProvideRepository','InjectEntity','Repository','SearchScope','4182582unwOxR','defineProperty','./configuration','./decorator/InjectRepository','11610690TLnMNs','Provide','ProvideSearch','8XZTjkN'];a9_0x39c9=function(){return _0x108135;};return a9_0x39c9();}var InjectEntity_1=require(a9_0x26d36c(0x1ec));Object[a9_0x26d36c(0x1de)](exports,a9_0x26d36c(0x1da),{'enumerable':!![],'get':function(){var _0x5604d6=a9_0x26d36c;return InjectEntity_1[_0x5604d6(0x1da)];}});var InjectRepository_1=require(a9_0x26d36c(0x1e0));Object[a9_0x26d36c(0x1de)](exports,a9_0x26d36c(0x1ef),{'enumerable':!![],'get':function(){var _0x3fa683=a9_0x26d36c;return InjectRepository_1[_0x3fa683(0x1ef)];}});var ProvideEntity_1=require(a9_0x26d36c(0x1eb));Object[a9_0x26d36c(0x1de)](exports,a9_0x26d36c(0x1fa),{'enumerable':!![],'get':function(){var _0x50dd95=a9_0x26d36c;return ProvideEntity_1[_0x50dd95(0x1fa)];}});var ProvideRepository_1=require(a9_0x26d36c(0x1f4));Object[a9_0x26d36c(0x1de)](exports,a9_0x26d36c(0x1d9),{'enumerable':!![],'get':function(){return ProvideRepository_1['ProvideRepository'];}});var ProvideSearch_1=require('./decorator/ProvideSearch');Object[a9_0x26d36c(0x1de)](exports,a9_0x26d36c(0x1e3),{'enumerable':!![],'get':function(){var _0x6b1513=a9_0x26d36c;return ProvideSearch_1[_0x6b1513(0x1e3)];}}),Object['defineProperty'](exports,'Search',{'enumerable':!![],'get':function(){var _0x4b48f1=a9_0x26d36c;return ProvideSearch_1[_0x4b48f1(0x1f1)];}}),Object[a9_0x26d36c(0x1de)](exports,'SearchScope',{'enumerable':!![],'get':function(){var _0x335105=a9_0x26d36c;return ProvideSearch_1[_0x335105(0x1dc)];}});var getDataSourceEntity_1=require(a9_0x26d36c(0x1ff));Object[a9_0x26d36c(0x1de)](exports,'getDataSourceEntity',{'enumerable':!![],'get':function(){var _0x1173e5=a9_0x26d36c;return getDataSourceEntity_1[_0x1173e5(0x1e7)];}});var configuration_1=require(a9_0x26d36c(0x1df));Object['defineProperty'](exports,'Configuration',{'enumerable':!![],'get':function(){var _0xbdb2b5=a9_0x26d36c;return configuration_1[_0xbdb2b5(0x1d5)];}});var core_1=require('@midwayjs/core');Object[a9_0x26d36c(0x1de)](exports,'Provide',{'enumerable':!![],'get':function(){var _0x49f449=a9_0x26d36c;return core_1[_0x49f449(0x1e2)];}}),Object['defineProperty'](exports,a9_0x26d36c(0x1fe),{'enumerable':!![],'get':function(){return core_1['Inject'];}}),Object[a9_0x26d36c(0x1de)](exports,a9_0x26d36c(0x1f6),{'enumerable':!![],'get':function(){return core_1['Scope'];}}),Object[a9_0x26d36c(0x1de)](exports,a9_0x26d36c(0x1e5),{'enumerable':!![],'get':function(){var _0x124cfa=a9_0x26d36c;return core_1[_0x124cfa(0x1e5)];}});
|
package/dist/interface.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';
|
|
1
|
+
'use strict';const a10_0x3323df=a10_0xfe15;(function(_0x13bd71,_0x1f457c){const _0x195764=a10_0xfe15,_0x1078ee=_0x13bd71();while(!![]){try{const _0x113b09=-parseInt(_0x195764(0x174))/0x1+parseInt(_0x195764(0x182))/0x2+parseInt(_0x195764(0x16f))/0x3*(parseInt(_0x195764(0x179))/0x4)+-parseInt(_0x195764(0x16e))/0x5+parseInt(_0x195764(0x15c))/0x6*(parseInt(_0x195764(0x185))/0x7)+parseInt(_0x195764(0x16c))/0x8*(-parseInt(_0x195764(0x18a))/0x9)+parseInt(_0x195764(0x16b))/0xa*(parseInt(_0x195764(0x165))/0xb);if(_0x113b09===_0x1f457c)break;else _0x1078ee['push'](_0x1078ee['shift']());}catch(_0x223e09){_0x1078ee['push'](_0x1078ee['shift']());}}}(a10_0x1c1e,0xef549));function a10_0x1c1e(){const _0x260654=['275tgxMlk','decorator:anncic-api:typeorm:entity:virtual:column','getOne','EntityNotFoundError','getRawAndEntities','decorator:anncic-api:typeorm:entify:module:source','123540rnirIt','80zOYGff','ENTIFY_KEY','1342145KOICJJ','1014417IANveh','getManyAndCount','lockMode','SearchPaginate','OptimisticLockVersionMismatchError','1485392QjcNfo','lockVersion','findOne','default','versionColumn','16vojqMf','metadata','updateDateColumn','decorator:anncic-api:typeorm:model:search','ENTIFY_MODULE_SOURCE','defineProperty','prototype','mainAlias','getTime','2628356HLqfNH','typeorm','name','10512068vtIgAf','getEntityValue','@midwayjs/core','MODEL_SEARCH_KEY','getClassMetadata','1568871NMQqZE','hasOwnProperty','getMany','decorator:anncic-api:typeorm:model:search:scope','REPOSITORY_KEY','findOneBy','EntityManager','MODEL_SEARCH_SCOPE_KEY','ENTIFY_MODULE','reject','SelectQueryBuilder','decorator:anncic-api:typeorm:entify','6JQNmCx','ENTITY_VIRTUAL_COLUMN_KEY','map','resolve','MODEL_KEY','expressionMap','decorator:anncic-api:typeorm:model','then','findOneByOrFail'];a10_0x1c1e=function(){return _0x260654;};return a10_0x1c1e();}function a10_0xfe15(_0x38f7dd,_0x538279){const _0x1c1eac=a10_0x1c1e();return a10_0xfe15=function(_0xfe158,_0x129a53){_0xfe158=_0xfe158-0x153;let _0x2f8b63=_0x1c1eac[_0xfe158];return _0x2f8b63;},a10_0xfe15(_0x38f7dd,_0x538279);}Object[a10_0x3323df(0x17e)](exports,'__esModule',{'value':!![]}),exports[a10_0x3323df(0x172)]=exports[a10_0x3323df(0x15d)]=exports[a10_0x3323df(0x157)]=exports[a10_0x3323df(0x188)]=exports[a10_0x3323df(0x160)]=exports[a10_0x3323df(0x154)]=exports[a10_0x3323df(0x17d)]=exports['ENTIFY_MODULE']=exports[a10_0x3323df(0x16d)]=void 0x0;const core_1=require(a10_0x3323df(0x187)),typeorm_1=require('typeorm'),typeorm_2=require(a10_0x3323df(0x183));exports['ENTIFY_KEY']=a10_0x3323df(0x15b),exports[a10_0x3323df(0x158)]='decorator:anncic-api:typeorm:entify:module',exports[a10_0x3323df(0x17d)]=a10_0x3323df(0x16a),exports[a10_0x3323df(0x154)]='decorator:anncic-api:typeorm:repository',exports[a10_0x3323df(0x160)]=a10_0x3323df(0x162),exports[a10_0x3323df(0x188)]=a10_0x3323df(0x17c),exports[a10_0x3323df(0x157)]=a10_0x3323df(0x153),exports[a10_0x3323df(0x15d)]=a10_0x3323df(0x166);class SearchPaginate{}exports[a10_0x3323df(0x172)]=SearchPaginate,typeorm_2[a10_0x3323df(0x156)][a10_0x3323df(0x17f)]['findOneOrFail']=async function(_0x89518b,_0x24385c){const _0x17e687=a10_0x3323df;return this[_0x17e687(0x176)](_0x89518b,_0x24385c)['then'](_0x2dfdb1=>{const _0x20bbb7=_0x17e687;if(_0x2dfdb1===null||_0x2dfdb1===undefined)return Promise[_0x20bbb7(0x159)](new typeorm_2[(_0x20bbb7(0x168))](_0x89518b,_0x24385c));return Promise[_0x20bbb7(0x15f)](_0x2dfdb1);});},typeorm_2[a10_0x3323df(0x156)]['prototype'][a10_0x3323df(0x164)]=async function(_0x1d9ca4,_0x304384){const _0x3e932c=a10_0x3323df;return this[_0x3e932c(0x155)](_0x1d9ca4,_0x304384)[_0x3e932c(0x163)](_0x48106a=>{const _0x172bf8=_0x3e932c;if(_0x48106a===null||_0x48106a===undefined)return Promise['reject'](new typeorm_2[(_0x172bf8(0x168))](_0x1d9ca4,_0x304384));return Promise[_0x172bf8(0x15f)](_0x48106a);});},typeorm_1[a10_0x3323df(0x15a)]['prototype'][a10_0x3323df(0x18c)]=async function(){const _0x45f8bc=a10_0x3323df;if(this['expressionMap'][_0x45f8bc(0x171)]==='optimistic')throw new typeorm_1['OptimisticLockCanNotBeUsedError']();const {entities:_0x2d79f6,raw:_0x184c50}=await this[_0x45f8bc(0x169)]();return _0x2d79f6[_0x45f8bc(0x15e)]((_0x290f55,_0x72ff82)=>{const _0x3fccf8=_0x45f8bc;var _0x3d8dc3;const _0x155601=(0x0,core_1[_0x3fccf8(0x189)])(exports[_0x3fccf8(0x15d)],_0x290f55)||{};for(const _0x2664b7 in _0x155601){_0x184c50[_0x72ff82]&&_0x184c50[_0x72ff82][_0x3fccf8(0x18b)](_0x2664b7)&&(_0x290f55[_0x2664b7]=_0x184c50[_0x72ff82][_0x2664b7]||((_0x3d8dc3=_0x155601[_0x2664b7])===null||_0x3d8dc3===void 0x0?void 0x0:_0x3d8dc3[_0x3fccf8(0x177)])||'');}return _0x290f55;});},typeorm_1[a10_0x3323df(0x15a)][a10_0x3323df(0x17f)][a10_0x3323df(0x170)]=async function(){return[await this['getMany'](),await this['getCount']()];},typeorm_1[a10_0x3323df(0x15a)][a10_0x3323df(0x17f)][a10_0x3323df(0x167)]=async function(){const _0x30dd29=a10_0x3323df;var _0xa96db1;const {entities:_0x31be5b,raw:_0x4dc9f5}=await this[_0x30dd29(0x169)]();if(_0x31be5b[0x0]&&this[_0x30dd29(0x161)][_0x30dd29(0x171)]==='optimistic'&&this[_0x30dd29(0x161)]['lockVersion']){const _0x384651=this['expressionMap'][_0x30dd29(0x180)][_0x30dd29(0x17a)];if(this['expressionMap'][_0x30dd29(0x175)]instanceof Date){const _0x1a0834=_0x384651[_0x30dd29(0x17b)][_0x30dd29(0x186)](_0x31be5b[0x0]);if(_0x1a0834[_0x30dd29(0x181)]()!==this['expressionMap'][_0x30dd29(0x175)][_0x30dd29(0x181)]())throw new typeorm_1['OptimisticLockVersionMismatchError'](_0x384651[_0x30dd29(0x184)],this[_0x30dd29(0x161)]['lockVersion'],_0x1a0834);}else{const _0x4b5fb8=_0x384651[_0x30dd29(0x178)][_0x30dd29(0x186)](_0x31be5b[0x0]);if(_0x4b5fb8!==this[_0x30dd29(0x161)]['lockVersion'])throw new typeorm_1[(_0x30dd29(0x173))](_0x384651['name'],this[_0x30dd29(0x161)][_0x30dd29(0x175)],_0x4b5fb8);}}if(_0x31be5b[0x0]&&_0x4dc9f5[0x0]){const _0x2071a8=(0x0,core_1[_0x30dd29(0x189)])(exports[_0x30dd29(0x15d)],_0x31be5b[0x0]);for(const _0x53de49 in _0x2071a8){_0x4dc9f5[0x0]['hasOwnProperty'](_0x53de49)&&(_0x31be5b[0x0][_0x53de49]=_0x4dc9f5[0x0][_0x53de49]||((_0xa96db1=_0x2071a8[_0x53de49])===null||_0xa96db1===void 0x0?void 0x0:_0xa96db1[_0x30dd29(0x177)])||'');}}return _0x31be5b[0x0]||null;};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anncic-api/typeorm",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.22",
|
|
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": "60b66cdaaf850e963345cfd226f2aec091e1bd50"
|
|
26
26
|
}
|