Built motion from commit 639a1a7f.|2.6.19
[motion2.git] / server / api / smsTransferReport / smsTransferReport.controller.js
index 790a3e8..c1cc0fc 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xbf30=['rawAttributes','fieldName','type','key','model','query','keys','filters','intersection','attributes','fields','length','hasOwnProperty','nolimit','order','sort','pick','filter','where','merge','map','VIRTUAL','options','includeAll','include','findAll','rows','catch','show','params','find','create','body','describe','eml-format','rimraf','request-promise','moment','bluebird','mustache','util','ejs','squel','crypto','desk.js','querystring','papaparse','ioredis','../../components/parsers/advancedSearch','../../config/license/hardware','../../config/logger','api','../../config/utils','../../config/environment','../../config/license/util','end','json','offset','undefined','count','limit','status','set','Content-Range','apply','save','update','then','destroy','sendStatus','error','name','index','SmsTransferReport'];(function(_0x2e1c21,_0x3873fc){var _0x35cfc7=function(_0x43722e){while(--_0x43722e){_0x2e1c21['push'](_0x2e1c21['shift']());}};_0x35cfc7(++_0x3873fc);}(_0xbf30,0x1de));var _0x0bf3=function(_0x25210a,_0xfdda84){_0x25210a=_0x25210a-0x0;var _0x4c1bd9=_0xbf30[_0x25210a];return _0x4c1bd9;};'use strict';var emlformat=require(_0x0bf3('0x0'));var rimraf=require(_0x0bf3('0x1'));var zipdir=require('zip-dir');var jsonpatch=require('fast-json-patch');var rp=require(_0x0bf3('0x2'));var moment=require(_0x0bf3('0x3'));var BPromise=require(_0x0bf3('0x4'));var Mustache=require(_0x0bf3('0x5'));var util=require(_0x0bf3('0x6'));var path=require('path');var sox=require('sox');var csv=require('to-csv');var ejs=require(_0x0bf3('0x7'));var fs=require('fs');var fs_extra=require('fs-extra');var _=require('lodash');var squel=require(_0x0bf3('0x8'));var crypto=require(_0x0bf3('0x9'));var jsforce=require('jsforce');var deskjs=require(_0x0bf3('0xa'));var toCsv=require('to-csv');var querystring=require(_0x0bf3('0xb'));var Papa=require(_0x0bf3('0xc'));var Redis=require(_0x0bf3('0xd'));var authService=require('../../components/auth/service');var qs=require('../../components/parsers/qs');var as=require(_0x0bf3('0xe'));var hardwareService=require(_0x0bf3('0xf'));var logger=require(_0x0bf3('0x10'))(_0x0bf3('0x11'));var utils=require(_0x0bf3('0x12'));var config=require(_0x0bf3('0x13'));var licenseUtil=require(_0x0bf3('0x14'));var db=require('../../mysqldb')['db'];function respondWithStatusCode(_0x1e7db3,_0x1af62a){_0x1af62a=_0x1af62a||0xcc;return function(_0x172e72){if(_0x172e72){return _0x1e7db3['sendStatus'](_0x1af62a);}return _0x1e7db3['status'](_0x1af62a)[_0x0bf3('0x15')]();};}function respondWithResult(_0x22ce05,_0x5d0cf3){_0x5d0cf3=_0x5d0cf3||0xc8;return function(_0xe723b4){if(_0xe723b4){return _0x22ce05['status'](_0x5d0cf3)[_0x0bf3('0x16')](_0xe723b4);}};}function respondWithFilteredResult(_0x1ca19c,_0x2e7a9b){return function(_0xce254d){if(_0xce254d){var _0x11e380=typeof _0x2e7a9b[_0x0bf3('0x17')]===_0x0bf3('0x18')&&typeof _0x2e7a9b['limit']===_0x0bf3('0x18');var _0xd5f018=_0xce254d[_0x0bf3('0x19')];var _0x25a1fb=_0x11e380?0x0:_0x2e7a9b['offset'];var _0x1e761d=_0x11e380?_0xce254d['count']:_0x2e7a9b[_0x0bf3('0x17')]+_0x2e7a9b[_0x0bf3('0x1a')];var _0x37e9b4;if(_0x1e761d>=_0xd5f018){_0x1e761d=_0xd5f018;_0x37e9b4=0xc8;}else{_0x37e9b4=0xce;}_0x1ca19c[_0x0bf3('0x1b')](_0x37e9b4);return _0x1ca19c[_0x0bf3('0x1c')](_0x0bf3('0x1d'),_0x25a1fb+'-'+_0x1e761d+'/'+_0xd5f018)[_0x0bf3('0x16')](_0xce254d);}return null;};}function patchUpdates(_0x4eaa04){return function(_0x4c4ff8){try{jsonpatch[_0x0bf3('0x1e')](_0x4c4ff8,_0x4eaa04,!![]);}catch(_0x3bc916){return BPromise['reject'](_0x3bc916);}return _0x4c4ff8[_0x0bf3('0x1f')]();};}function saveUpdates(_0x4d706d,_0x21cacf){return function(_0x28bfc6){if(_0x28bfc6){return _0x28bfc6[_0x0bf3('0x20')](_0x4d706d)[_0x0bf3('0x21')](function(_0x23a967){return _0x23a967;});}return null;};}function removeEntity(_0x2f89f7,_0x44fb1d){return function(_0x14c950){if(_0x14c950){return _0x14c950[_0x0bf3('0x22')]()[_0x0bf3('0x21')](function(){_0x2f89f7[_0x0bf3('0x1b')](0xcc)[_0x0bf3('0x15')]();});}};}function handleEntityNotFound(_0x5369a8,_0x4fe233){return function(_0x544920){if(!_0x544920){_0x5369a8[_0x0bf3('0x23')](0x194);}return _0x544920;};}function handleError(_0x161c5b,_0x3baa04){_0x3baa04=_0x3baa04||0x1f4;return function(_0x4d631f){logger[_0x0bf3('0x24')](_0x4d631f['stack']);if(_0x4d631f[_0x0bf3('0x25')]){delete _0x4d631f[_0x0bf3('0x25')];}_0x161c5b['status'](_0x3baa04)['send'](_0x4d631f);};}exports[_0x0bf3('0x26')]=function(_0x4f5793,_0x40706e){var _0x14b0ce={},_0x2a235c={},_0x1c7a7e={'count':0x0,'rows':[]};var _0x3881b9=_['map'](db[_0x0bf3('0x27')][_0x0bf3('0x28')],function(_0x2e04ff){return{'name':_0x2e04ff[_0x0bf3('0x29')],'type':_0x2e04ff[_0x0bf3('0x2a')][_0x0bf3('0x2b')]};});_0x2a235c[_0x0bf3('0x2c')]=_['map'](_0x3881b9,'name');_0x2a235c[_0x0bf3('0x2d')]=_[_0x0bf3('0x2e')](_0x4f5793[_0x0bf3('0x2d')]);_0x2a235c[_0x0bf3('0x2f')]=_[_0x0bf3('0x30')](_0x2a235c[_0x0bf3('0x2c')],_0x2a235c[_0x0bf3('0x2d')]);_0x14b0ce[_0x0bf3('0x31')]=_[_0x0bf3('0x30')](_0x2a235c[_0x0bf3('0x2c')],qs[_0x0bf3('0x32')](_0x4f5793[_0x0bf3('0x2d')][_0x0bf3('0x32')]));_0x14b0ce[_0x0bf3('0x31')]=_0x14b0ce['attributes'][_0x0bf3('0x33')]?_0x14b0ce['attributes']:_0x2a235c[_0x0bf3('0x2c')];if(!_0x4f5793[_0x0bf3('0x2d')][_0x0bf3('0x34')](_0x0bf3('0x35'))){_0x14b0ce[_0x0bf3('0x1a')]=qs[_0x0bf3('0x1a')](_0x4f5793[_0x0bf3('0x2d')]['limit']);_0x14b0ce['offset']=qs[_0x0bf3('0x17')](_0x4f5793[_0x0bf3('0x2d')][_0x0bf3('0x17')]);}_0x14b0ce[_0x0bf3('0x36')]=qs[_0x0bf3('0x37')](_0x4f5793[_0x0bf3('0x2d')][_0x0bf3('0x37')]);_0x14b0ce['where']=qs[_0x0bf3('0x2f')](_[_0x0bf3('0x38')](_0x4f5793[_0x0bf3('0x2d')],_0x2a235c[_0x0bf3('0x2f')]),_0x3881b9);if(_0x4f5793['query'][_0x0bf3('0x39')]){_0x14b0ce[_0x0bf3('0x3a')]=_[_0x0bf3('0x3b')](_0x14b0ce[_0x0bf3('0x3a')],{'$or':_[_0x0bf3('0x3c')](_0x3881b9,function(_0x2bf6d1){if(_0x2bf6d1[_0x0bf3('0x2a')]!==_0x0bf3('0x3d')){var _0x4a69ea={};_0x4a69ea[_0x2bf6d1[_0x0bf3('0x25')]]={'$like':'%'+_0x4f5793[_0x0bf3('0x2d')][_0x0bf3('0x39')]+'%'};return _0x4a69ea;}})});}_0x14b0ce=_[_0x0bf3('0x3b')]({},_0x14b0ce,_0x4f5793[_0x0bf3('0x3e')]);var _0x1c2f9b={'where':_0x14b0ce[_0x0bf3('0x3a')]};return db[_0x0bf3('0x27')][_0x0bf3('0x19')](_0x1c2f9b)[_0x0bf3('0x21')](function(_0x311082){_0x1c7a7e[_0x0bf3('0x19')]=_0x311082;if(_0x4f5793[_0x0bf3('0x2d')][_0x0bf3('0x3f')]){_0x14b0ce[_0x0bf3('0x40')]=[{'all':!![]}];}return db[_0x0bf3('0x27')][_0x0bf3('0x41')](_0x14b0ce);})['then'](function(_0x28c879){_0x1c7a7e[_0x0bf3('0x42')]=_0x28c879;return _0x1c7a7e;})[_0x0bf3('0x21')](respondWithFilteredResult(_0x40706e,_0x14b0ce))[_0x0bf3('0x43')](handleError(_0x40706e,null));};exports[_0x0bf3('0x44')]=function(_0x309798,_0x271aad){var _0x48d8bf={'raw':!![],'where':{'id':_0x309798[_0x0bf3('0x45')]['id']}},_0x424813={};_0x424813[_0x0bf3('0x2c')]=_['keys'](db[_0x0bf3('0x27')][_0x0bf3('0x28')]);_0x424813[_0x0bf3('0x2d')]=_['keys'](_0x309798[_0x0bf3('0x2d')]);_0x424813[_0x0bf3('0x2f')]=_['intersection'](_0x424813[_0x0bf3('0x2c')],_0x424813[_0x0bf3('0x2d')]);_0x48d8bf[_0x0bf3('0x31')]=_['intersection'](_0x424813[_0x0bf3('0x2c')],qs[_0x0bf3('0x32')](_0x309798[_0x0bf3('0x2d')]['fields']));_0x48d8bf[_0x0bf3('0x31')]=_0x48d8bf[_0x0bf3('0x31')][_0x0bf3('0x33')]?_0x48d8bf['attributes']:_0x424813[_0x0bf3('0x2c')];if(_0x309798['query'][_0x0bf3('0x3f')]){_0x48d8bf[_0x0bf3('0x40')]=[{'all':!![]}];}_0x48d8bf=_['merge']({},_0x48d8bf,_0x309798[_0x0bf3('0x3e')]);return db[_0x0bf3('0x27')][_0x0bf3('0x46')](_0x48d8bf)[_0x0bf3('0x21')](handleEntityNotFound(_0x271aad,null))[_0x0bf3('0x21')](respondWithResult(_0x271aad,null))[_0x0bf3('0x43')](handleError(_0x271aad,null));};exports[_0x0bf3('0x47')]=function(_0x5cb8c7,_0xdfd79c){return db[_0x0bf3('0x27')][_0x0bf3('0x47')](_0x5cb8c7[_0x0bf3('0x48')],{})[_0x0bf3('0x21')](respondWithResult(_0xdfd79c,0xc9))[_0x0bf3('0x43')](handleError(_0xdfd79c,null));};exports[_0x0bf3('0x20')]=function(_0x27d32e,_0x7fabaf){if(_0x27d32e['body']['id']){delete _0x27d32e[_0x0bf3('0x48')]['id'];}return db['SmsTransferReport'][_0x0bf3('0x46')]({'where':{'id':_0x27d32e[_0x0bf3('0x45')]['id']}})[_0x0bf3('0x21')](handleEntityNotFound(_0x7fabaf,null))[_0x0bf3('0x21')](saveUpdates(_0x27d32e[_0x0bf3('0x48')],null))[_0x0bf3('0x21')](respondWithResult(_0x7fabaf,null))[_0x0bf3('0x43')](handleError(_0x7fabaf,null));};exports[_0x0bf3('0x22')]=function(_0x15f34b,_0x241172){return db[_0x0bf3('0x27')]['find']({'where':{'id':_0x15f34b[_0x0bf3('0x45')]['id']}})[_0x0bf3('0x21')](handleEntityNotFound(_0x241172,null))[_0x0bf3('0x21')](removeEntity(_0x241172,null))[_0x0bf3('0x43')](handleError(_0x241172,null));};exports[_0x0bf3('0x49')]=function(_0x3dbb57,_0x12c840){return db[_0x0bf3('0x27')][_0x0bf3('0x49')]()[_0x0bf3('0x21')](respondWithResult(_0x12c840,null))[_0x0bf3('0x43')](handleError(_0x12c840,null));};
\ No newline at end of file
+var _0x61a7=['intersection','attributes','fields','length','hasOwnProperty','nolimit','order','sort','where','pick','filter','merge','options','includeAll','include','rows','catch','show','keys','create','body','find','params','describe','eml-format','rimraf','zip-dir','fast-json-patch','request-promise','bluebird','mustache','path','sox','fs-extra','lodash','crypto','jsforce','desk.js','to-csv','querystring','papaparse','ioredis','../../components/auth/service','../../components/parsers/qs','../../config/logger','../../config/utils','../../config/environment','../../mysqldb','sendStatus','status','end','json','offset','undefined','limit','count','set','Content-Range','apply','reject','save','update','then','destroy','error','stack','name','index','map','SmsTransferReport','rawAttributes','fieldName','type','key','model','query','filters'];(function(_0x5b66ca,_0x132e14){var _0x1dcc64=function(_0x4fd0a3){while(--_0x4fd0a3){_0x5b66ca['push'](_0x5b66ca['shift']());}};_0x1dcc64(++_0x132e14);}(_0x61a7,0xb2));var _0x761a=function(_0x17304b,_0x3cf1fe){_0x17304b=_0x17304b-0x0;var _0x2e4071=_0x61a7[_0x17304b];return _0x2e4071;};'use strict';var emlformat=require(_0x761a('0x0'));var rimraf=require(_0x761a('0x1'));var zipdir=require(_0x761a('0x2'));var jsonpatch=require(_0x761a('0x3'));var rp=require(_0x761a('0x4'));var moment=require('moment');var BPromise=require(_0x761a('0x5'));var Mustache=require(_0x761a('0x6'));var util=require('util');var path=require(_0x761a('0x7'));var sox=require(_0x761a('0x8'));var csv=require('to-csv');var ejs=require('ejs');var fs=require('fs');var fs_extra=require(_0x761a('0x9'));var _=require(_0x761a('0xa'));var squel=require('squel');var crypto=require(_0x761a('0xb'));var jsforce=require(_0x761a('0xc'));var deskjs=require(_0x761a('0xd'));var toCsv=require(_0x761a('0xe'));var querystring=require(_0x761a('0xf'));var Papa=require(_0x761a('0x10'));var Redis=require(_0x761a('0x11'));var authService=require(_0x761a('0x12'));var qs=require(_0x761a('0x13'));var as=require('../../components/parsers/advancedSearch');var hardwareService=require('../../config/license/hardware');var logger=require(_0x761a('0x14'))('api');var utils=require(_0x761a('0x15'));var config=require(_0x761a('0x16'));var licenseUtil=require('../../config/license/util');var db=require(_0x761a('0x17'))['db'];function respondWithStatusCode(_0x1b63ac,_0x5d9a74){_0x5d9a74=_0x5d9a74||0xcc;return function(_0x552c12){if(_0x552c12){return _0x1b63ac[_0x761a('0x18')](_0x5d9a74);}return _0x1b63ac[_0x761a('0x19')](_0x5d9a74)[_0x761a('0x1a')]();};}function respondWithResult(_0x28ad22,_0x4663e2){_0x4663e2=_0x4663e2||0xc8;return function(_0x2026b9){if(_0x2026b9){return _0x28ad22['status'](_0x4663e2)[_0x761a('0x1b')](_0x2026b9);}};}function respondWithFilteredResult(_0x564619,_0x4c9e54){return function(_0x287f7e){if(_0x287f7e){var _0x43c378=typeof _0x4c9e54[_0x761a('0x1c')]===_0x761a('0x1d')&&typeof _0x4c9e54[_0x761a('0x1e')]==='undefined';var _0x2167df=_0x287f7e[_0x761a('0x1f')];var _0x75ad11=_0x43c378?0x0:_0x4c9e54[_0x761a('0x1c')];var _0x5f35b4=_0x43c378?_0x287f7e[_0x761a('0x1f')]:_0x4c9e54[_0x761a('0x1c')]+_0x4c9e54[_0x761a('0x1e')];var _0x53af2c;if(_0x5f35b4>=_0x2167df){_0x5f35b4=_0x2167df;_0x53af2c=0xc8;}else{_0x53af2c=0xce;}_0x564619[_0x761a('0x19')](_0x53af2c);return _0x564619[_0x761a('0x20')](_0x761a('0x21'),_0x75ad11+'-'+_0x5f35b4+'/'+_0x2167df)[_0x761a('0x1b')](_0x287f7e);}return null;};}function patchUpdates(_0x38ed2c){return function(_0xb85353){try{jsonpatch[_0x761a('0x22')](_0xb85353,_0x38ed2c,!![]);}catch(_0x51341c){return BPromise[_0x761a('0x23')](_0x51341c);}return _0xb85353[_0x761a('0x24')]();};}function saveUpdates(_0x1eb452,_0x27bf78){return function(_0x39e474){if(_0x39e474){return _0x39e474[_0x761a('0x25')](_0x1eb452)[_0x761a('0x26')](function(_0x35de8a){return _0x35de8a;});}return null;};}function removeEntity(_0x549cf2,_0x2852e0){return function(_0x538046){if(_0x538046){return _0x538046[_0x761a('0x27')]()[_0x761a('0x26')](function(){_0x549cf2[_0x761a('0x19')](0xcc)[_0x761a('0x1a')]();});}};}function handleEntityNotFound(_0x5566c0,_0x446967){return function(_0x51302a){if(!_0x51302a){_0x5566c0[_0x761a('0x18')](0x194);}return _0x51302a;};}function handleError(_0x2f9d4f,_0x274d37){_0x274d37=_0x274d37||0x1f4;return function(_0x3f234c){logger[_0x761a('0x28')](_0x3f234c[_0x761a('0x29')]);if(_0x3f234c[_0x761a('0x2a')]){delete _0x3f234c[_0x761a('0x2a')];}_0x2f9d4f['status'](_0x274d37)['send'](_0x3f234c);};}exports[_0x761a('0x2b')]=function(_0x1effff,_0x887b1d){var _0x16b2fa={},_0x5376a2={},_0x38826c={'count':0x0,'rows':[]};var _0x422341=_[_0x761a('0x2c')](db[_0x761a('0x2d')][_0x761a('0x2e')],function(_0x215715){return{'name':_0x215715[_0x761a('0x2f')],'type':_0x215715[_0x761a('0x30')][_0x761a('0x31')]};});_0x5376a2[_0x761a('0x32')]=_['map'](_0x422341,'name');_0x5376a2[_0x761a('0x33')]=_['keys'](_0x1effff['query']);_0x5376a2[_0x761a('0x34')]=_[_0x761a('0x35')](_0x5376a2[_0x761a('0x32')],_0x5376a2[_0x761a('0x33')]);_0x16b2fa[_0x761a('0x36')]=_[_0x761a('0x35')](_0x5376a2[_0x761a('0x32')],qs[_0x761a('0x37')](_0x1effff[_0x761a('0x33')][_0x761a('0x37')]));_0x16b2fa[_0x761a('0x36')]=_0x16b2fa[_0x761a('0x36')][_0x761a('0x38')]?_0x16b2fa[_0x761a('0x36')]:_0x5376a2['model'];if(!_0x1effff[_0x761a('0x33')][_0x761a('0x39')](_0x761a('0x3a'))){_0x16b2fa['limit']=qs[_0x761a('0x1e')](_0x1effff['query'][_0x761a('0x1e')]);_0x16b2fa['offset']=qs[_0x761a('0x1c')](_0x1effff[_0x761a('0x33')][_0x761a('0x1c')]);}_0x16b2fa[_0x761a('0x3b')]=qs[_0x761a('0x3c')](_0x1effff[_0x761a('0x33')][_0x761a('0x3c')]);_0x16b2fa[_0x761a('0x3d')]=qs['filters'](_[_0x761a('0x3e')](_0x1effff[_0x761a('0x33')],_0x5376a2[_0x761a('0x34')]),_0x422341);if(_0x1effff['query'][_0x761a('0x3f')]){_0x16b2fa[_0x761a('0x3d')]=_[_0x761a('0x40')](_0x16b2fa[_0x761a('0x3d')],{'$or':_[_0x761a('0x2c')](_0x422341,function(_0x206c79){if(_0x206c79['type']!=='VIRTUAL'){var _0xb4815b={};_0xb4815b[_0x206c79[_0x761a('0x2a')]]={'$like':'%'+_0x1effff['query'][_0x761a('0x3f')]+'%'};return _0xb4815b;}})});}_0x16b2fa=_[_0x761a('0x40')]({},_0x16b2fa,_0x1effff[_0x761a('0x41')]);var _0x2e0005={'where':_0x16b2fa[_0x761a('0x3d')]};return db[_0x761a('0x2d')][_0x761a('0x1f')](_0x2e0005)[_0x761a('0x26')](function(_0x2d0228){_0x38826c[_0x761a('0x1f')]=_0x2d0228;if(_0x1effff['query'][_0x761a('0x42')]){_0x16b2fa[_0x761a('0x43')]=[{'all':!![]}];}return db['SmsTransferReport']['findAll'](_0x16b2fa);})['then'](function(_0x3ac8d2){_0x38826c[_0x761a('0x44')]=_0x3ac8d2;return _0x38826c;})['then'](respondWithFilteredResult(_0x887b1d,_0x16b2fa))[_0x761a('0x45')](handleError(_0x887b1d,null));};exports[_0x761a('0x46')]=function(_0x5c960d,_0x5d84f4){var _0x3dc68c={'raw':!![],'where':{'id':_0x5c960d['params']['id']}},_0x132b55={};_0x132b55['model']=_[_0x761a('0x47')](db[_0x761a('0x2d')][_0x761a('0x2e')]);_0x132b55[_0x761a('0x33')]=_[_0x761a('0x47')](_0x5c960d[_0x761a('0x33')]);_0x132b55['filters']=_['intersection'](_0x132b55[_0x761a('0x32')],_0x132b55[_0x761a('0x33')]);_0x3dc68c['attributes']=_[_0x761a('0x35')](_0x132b55[_0x761a('0x32')],qs[_0x761a('0x37')](_0x5c960d[_0x761a('0x33')]['fields']));_0x3dc68c['attributes']=_0x3dc68c[_0x761a('0x36')][_0x761a('0x38')]?_0x3dc68c['attributes']:_0x132b55['model'];if(_0x5c960d[_0x761a('0x33')][_0x761a('0x42')]){_0x3dc68c['include']=[{'all':!![]}];}_0x3dc68c=_[_0x761a('0x40')]({},_0x3dc68c,_0x5c960d['options']);return db[_0x761a('0x2d')]['find'](_0x3dc68c)[_0x761a('0x26')](handleEntityNotFound(_0x5d84f4,null))[_0x761a('0x26')](respondWithResult(_0x5d84f4,null))['catch'](handleError(_0x5d84f4,null));};exports[_0x761a('0x48')]=function(_0x54ba43,_0x3a118a){return db[_0x761a('0x2d')][_0x761a('0x48')](_0x54ba43[_0x761a('0x49')],{})['then'](respondWithResult(_0x3a118a,0xc9))['catch'](handleError(_0x3a118a,null));};exports['update']=function(_0x33fa6c,_0x53c1ce){if(_0x33fa6c[_0x761a('0x49')]['id']){delete _0x33fa6c[_0x761a('0x49')]['id'];}return db[_0x761a('0x2d')][_0x761a('0x4a')]({'where':{'id':_0x33fa6c[_0x761a('0x4b')]['id']}})['then'](handleEntityNotFound(_0x53c1ce,null))[_0x761a('0x26')](saveUpdates(_0x33fa6c[_0x761a('0x49')],null))[_0x761a('0x26')](respondWithResult(_0x53c1ce,null))[_0x761a('0x45')](handleError(_0x53c1ce,null));};exports[_0x761a('0x27')]=function(_0x224007,_0x1c05e5){return db[_0x761a('0x2d')][_0x761a('0x4a')]({'where':{'id':_0x224007[_0x761a('0x4b')]['id']}})[_0x761a('0x26')](handleEntityNotFound(_0x1c05e5,null))['then'](removeEntity(_0x1c05e5,null))['catch'](handleError(_0x1c05e5,null));};exports[_0x761a('0x4c')]=function(_0x219043,_0x3411ea){return db[_0x761a('0x2d')][_0x761a('0x4c')]()[_0x761a('0x26')](respondWithResult(_0x3411ea,null))[_0x761a('0x45')](handleError(_0x3411ea,null));};
\ No newline at end of file