Built motion from commit 10af8726.|2.6.34
[motion2.git] / server / api / whatsappQueueReport / whatsappQueueReport.controller.js
index 1f751b3..7c39b20 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xbaf0=['../../config/license/hardware','../../config/logger','api','../../config/utils','../../config/environment','sendStatus','end','status','json','offset','undefined','limit','count','Content-Range','apply','reject','save','update','error','stack','name','send','index','map','WhatsappQueueReport','rawAttributes','fieldName','type','key','query','keys','filters','intersection','model','attributes','fields','length','nolimit','order','sort','where','pick','filter','VIRTUAL','merge','options','then','includeAll','include','findAll','rows','show','params','find','catch','create','body','describe','rimraf','zip-dir','fast-json-patch','request-promise','moment','bluebird','util','path','sox','to-csv','ejs','fs-extra','lodash','squel','crypto','desk.js','querystring','papaparse','ioredis','../../components/auth/service','../../components/parsers/qs','../../components/parsers/advancedSearch'];(function(_0x3f0781,_0x327714){var _0x220035=function(_0x2981c3){while(--_0x2981c3){_0x3f0781['push'](_0x3f0781['shift']());}};_0x220035(++_0x327714);}(_0xbaf0,0x12a));var _0x0baf=function(_0x1facfa,_0x1acf7d){_0x1facfa=_0x1facfa-0x0;var _0x9ec701=_0xbaf0[_0x1facfa];return _0x9ec701;};'use strict';var emlformat=require('eml-format');var rimraf=require(_0x0baf('0x0'));var zipdir=require(_0x0baf('0x1'));var jsonpatch=require(_0x0baf('0x2'));var rp=require(_0x0baf('0x3'));var moment=require(_0x0baf('0x4'));var BPromise=require(_0x0baf('0x5'));var Mustache=require('mustache');var util=require(_0x0baf('0x6'));var path=require(_0x0baf('0x7'));var sox=require(_0x0baf('0x8'));var csv=require(_0x0baf('0x9'));var ejs=require(_0x0baf('0xa'));var fs=require('fs');var fs_extra=require(_0x0baf('0xb'));var _=require(_0x0baf('0xc'));var squel=require(_0x0baf('0xd'));var crypto=require(_0x0baf('0xe'));var jsforce=require('jsforce');var deskjs=require(_0x0baf('0xf'));var toCsv=require('to-csv');var querystring=require(_0x0baf('0x10'));var Papa=require(_0x0baf('0x11'));var Redis=require(_0x0baf('0x12'));var authService=require(_0x0baf('0x13'));var qs=require(_0x0baf('0x14'));var as=require(_0x0baf('0x15'));var hardwareService=require(_0x0baf('0x16'));var logger=require(_0x0baf('0x17'))(_0x0baf('0x18'));var utils=require(_0x0baf('0x19'));var config=require(_0x0baf('0x1a'));var licenseUtil=require('../../config/license/util');var db=require('../../mysqldb')['db'];function respondWithStatusCode(_0x465dd7,_0xe4378c){_0xe4378c=_0xe4378c||0xcc;return function(_0x5db689){if(_0x5db689){return _0x465dd7[_0x0baf('0x1b')](_0xe4378c);}return _0x465dd7['status'](_0xe4378c)[_0x0baf('0x1c')]();};}function respondWithResult(_0x49e44b,_0x1c76a8){_0x1c76a8=_0x1c76a8||0xc8;return function(_0x1f50c3){if(_0x1f50c3){return _0x49e44b[_0x0baf('0x1d')](_0x1c76a8)[_0x0baf('0x1e')](_0x1f50c3);}};}function respondWithFilteredResult(_0xb8339e,_0x469599){return function(_0x4f80a8){if(_0x4f80a8){var _0x4cd79d=typeof _0x469599[_0x0baf('0x1f')]===_0x0baf('0x20')&&typeof _0x469599[_0x0baf('0x21')]===_0x0baf('0x20');var _0x2cf7da=_0x4f80a8[_0x0baf('0x22')];var _0x53c338=_0x4cd79d?0x0:_0x469599[_0x0baf('0x1f')];var _0xfbecec=_0x4cd79d?_0x4f80a8[_0x0baf('0x22')]:_0x469599[_0x0baf('0x1f')]+_0x469599[_0x0baf('0x21')];var _0x42b7f2;if(_0xfbecec>=_0x2cf7da){_0xfbecec=_0x2cf7da;_0x42b7f2=0xc8;}else{_0x42b7f2=0xce;}_0xb8339e['status'](_0x42b7f2);return _0xb8339e['set'](_0x0baf('0x23'),_0x53c338+'-'+_0xfbecec+'/'+_0x2cf7da)[_0x0baf('0x1e')](_0x4f80a8);}return null;};}function patchUpdates(_0x32e839){return function(_0x1848e8){try{jsonpatch[_0x0baf('0x24')](_0x1848e8,_0x32e839,!![]);}catch(_0x3e3e20){return BPromise[_0x0baf('0x25')](_0x3e3e20);}return _0x1848e8[_0x0baf('0x26')]();};}function saveUpdates(_0x2c42e2,_0x15a2c3){return function(_0x54f2fa){if(_0x54f2fa){return _0x54f2fa[_0x0baf('0x27')](_0x2c42e2)['then'](function(_0xf6c158){return _0xf6c158;});}return null;};}function removeEntity(_0x5dbf00,_0x4de74c){return function(_0x2ef0aa){if(_0x2ef0aa){return _0x2ef0aa['destroy']()['then'](function(){_0x5dbf00[_0x0baf('0x1d')](0xcc)[_0x0baf('0x1c')]();});}};}function handleEntityNotFound(_0x34e264,_0x19d9fd){return function(_0x3a1ba1){if(!_0x3a1ba1){_0x34e264['sendStatus'](0x194);}return _0x3a1ba1;};}function handleError(_0x448617,_0x4681c5){_0x4681c5=_0x4681c5||0x1f4;return function(_0x1ca35a){logger[_0x0baf('0x28')](_0x1ca35a[_0x0baf('0x29')]);if(_0x1ca35a[_0x0baf('0x2a')]){delete _0x1ca35a[_0x0baf('0x2a')];}_0x448617['status'](_0x4681c5)[_0x0baf('0x2b')](_0x1ca35a);};}exports[_0x0baf('0x2c')]=function(_0xcaf13d,_0x265915){var _0x55c715={},_0x29dbdf={},_0x34a58a={'count':0x0,'rows':[]};var _0x5d9d7f=_[_0x0baf('0x2d')](db[_0x0baf('0x2e')][_0x0baf('0x2f')],function(_0xb4dbb1){return{'name':_0xb4dbb1[_0x0baf('0x30')],'type':_0xb4dbb1[_0x0baf('0x31')][_0x0baf('0x32')]};});_0x29dbdf['model']=_[_0x0baf('0x2d')](_0x5d9d7f,_0x0baf('0x2a'));_0x29dbdf[_0x0baf('0x33')]=_[_0x0baf('0x34')](_0xcaf13d[_0x0baf('0x33')]);_0x29dbdf[_0x0baf('0x35')]=_[_0x0baf('0x36')](_0x29dbdf[_0x0baf('0x37')],_0x29dbdf[_0x0baf('0x33')]);_0x55c715[_0x0baf('0x38')]=_[_0x0baf('0x36')](_0x29dbdf[_0x0baf('0x37')],qs[_0x0baf('0x39')](_0xcaf13d[_0x0baf('0x33')]['fields']));_0x55c715[_0x0baf('0x38')]=_0x55c715['attributes'][_0x0baf('0x3a')]?_0x55c715[_0x0baf('0x38')]:_0x29dbdf[_0x0baf('0x37')];if(!_0xcaf13d[_0x0baf('0x33')]['hasOwnProperty'](_0x0baf('0x3b'))){_0x55c715[_0x0baf('0x21')]=qs['limit'](_0xcaf13d[_0x0baf('0x33')][_0x0baf('0x21')]);_0x55c715[_0x0baf('0x1f')]=qs[_0x0baf('0x1f')](_0xcaf13d[_0x0baf('0x33')][_0x0baf('0x1f')]);}_0x55c715[_0x0baf('0x3c')]=qs[_0x0baf('0x3d')](_0xcaf13d['query'][_0x0baf('0x3d')]);_0x55c715[_0x0baf('0x3e')]=qs['filters'](_[_0x0baf('0x3f')](_0xcaf13d['query'],_0x29dbdf['filters']),_0x5d9d7f);if(_0xcaf13d[_0x0baf('0x33')][_0x0baf('0x40')]){_0x55c715['where']=_['merge'](_0x55c715[_0x0baf('0x3e')],{'$or':_[_0x0baf('0x2d')](_0x5d9d7f,function(_0x3412bc){if(_0x3412bc[_0x0baf('0x31')]!==_0x0baf('0x41')){var _0x2028ad={};_0x2028ad[_0x3412bc[_0x0baf('0x2a')]]={'$like':'%'+_0xcaf13d[_0x0baf('0x33')][_0x0baf('0x40')]+'%'};return _0x2028ad;}})});}_0x55c715=_[_0x0baf('0x42')]({},_0x55c715,_0xcaf13d[_0x0baf('0x43')]);var _0x148540={'where':_0x55c715[_0x0baf('0x3e')]};return db[_0x0baf('0x2e')]['count'](_0x148540)[_0x0baf('0x44')](function(_0x1435d5){_0x34a58a['count']=_0x1435d5;if(_0xcaf13d[_0x0baf('0x33')][_0x0baf('0x45')]){_0x55c715[_0x0baf('0x46')]=[{'all':!![]}];}return db[_0x0baf('0x2e')][_0x0baf('0x47')](_0x55c715);})[_0x0baf('0x44')](function(_0x57b581){_0x34a58a[_0x0baf('0x48')]=_0x57b581;return _0x34a58a;})[_0x0baf('0x44')](respondWithFilteredResult(_0x265915,_0x55c715))['catch'](handleError(_0x265915,null));};exports[_0x0baf('0x49')]=function(_0x412e6f,_0x45c6aa){var _0x57903e={'raw':!![],'where':{'id':_0x412e6f[_0x0baf('0x4a')]['id']}},_0x504031={};_0x504031[_0x0baf('0x37')]=_[_0x0baf('0x34')](db[_0x0baf('0x2e')][_0x0baf('0x2f')]);_0x504031[_0x0baf('0x33')]=_[_0x0baf('0x34')](_0x412e6f[_0x0baf('0x33')]);_0x504031[_0x0baf('0x35')]=_[_0x0baf('0x36')](_0x504031['model'],_0x504031[_0x0baf('0x33')]);_0x57903e[_0x0baf('0x38')]=_[_0x0baf('0x36')](_0x504031[_0x0baf('0x37')],qs[_0x0baf('0x39')](_0x412e6f['query'][_0x0baf('0x39')]));_0x57903e[_0x0baf('0x38')]=_0x57903e[_0x0baf('0x38')][_0x0baf('0x3a')]?_0x57903e[_0x0baf('0x38')]:_0x504031['model'];if(_0x412e6f[_0x0baf('0x33')][_0x0baf('0x45')]){_0x57903e[_0x0baf('0x46')]=[{'all':!![]}];}_0x57903e=_[_0x0baf('0x42')]({},_0x57903e,_0x412e6f[_0x0baf('0x43')]);return db[_0x0baf('0x2e')][_0x0baf('0x4b')](_0x57903e)['then'](handleEntityNotFound(_0x45c6aa,null))[_0x0baf('0x44')](respondWithResult(_0x45c6aa,null))[_0x0baf('0x4c')](handleError(_0x45c6aa,null));};exports[_0x0baf('0x4d')]=function(_0x57008f,_0x3c9de3){return db[_0x0baf('0x2e')][_0x0baf('0x4d')](_0x57008f[_0x0baf('0x4e')],{})[_0x0baf('0x44')](respondWithResult(_0x3c9de3,0xc9))[_0x0baf('0x4c')](handleError(_0x3c9de3,null));};exports[_0x0baf('0x27')]=function(_0x5a54bb,_0x22c451){if(_0x5a54bb[_0x0baf('0x4e')]['id']){delete _0x5a54bb[_0x0baf('0x4e')]['id'];}return db[_0x0baf('0x2e')][_0x0baf('0x4b')]({'where':{'id':_0x5a54bb[_0x0baf('0x4a')]['id']}})[_0x0baf('0x44')](handleEntityNotFound(_0x22c451,null))[_0x0baf('0x44')](saveUpdates(_0x5a54bb[_0x0baf('0x4e')],null))[_0x0baf('0x44')](respondWithResult(_0x22c451,null))[_0x0baf('0x4c')](handleError(_0x22c451,null));};exports['destroy']=function(_0x528ff6,_0x354329){return db[_0x0baf('0x2e')][_0x0baf('0x4b')]({'where':{'id':_0x528ff6[_0x0baf('0x4a')]['id']}})[_0x0baf('0x44')](handleEntityNotFound(_0x354329,null))[_0x0baf('0x44')](removeEntity(_0x354329,null))[_0x0baf('0x4c')](handleError(_0x354329,null));};exports['describe']=function(_0x3fe534,_0x2ef4c1){return db[_0x0baf('0x2e')][_0x0baf('0x4f')]()[_0x0baf('0x44')](respondWithResult(_0x2ef4c1,null))[_0x0baf('0x4c')](handleError(_0x2ef4c1,null));};
\ No newline at end of file
+var _0x6b20=['../../config/utils','../../config/environment','../../config/license/util','../../mysqldb','sendStatus','status','end','json','offset','limit','undefined','count','set','Content-Range','apply','reject','save','then','destroy','error','stack','name','index','WhatsappQueueReport','rawAttributes','fieldName','type','key','model','map','query','keys','filters','intersection','fields','attributes','length','nolimit','order','sort','where','pick','filter','merge','includeAll','findAll','rows','catch','show','params','include','options','find','create','update','body','describe','eml-format','rimraf','fast-json-patch','moment','bluebird','mustache','path','sox','to-csv','ejs','fs-extra','lodash','squel','jsforce','desk.js','papaparse','../../components/auth/service','../../config/license/hardware','../../config/logger'];(function(_0x137f64,_0xed0963){var _0x2b5e9b=function(_0x23314f){while(--_0x23314f){_0x137f64['push'](_0x137f64['shift']());}};_0x2b5e9b(++_0xed0963);}(_0x6b20,0xd1));var _0x06b2=function(_0x87115,_0x4f0e23){_0x87115=_0x87115-0x0;var _0xda622f=_0x6b20[_0x87115];return _0xda622f;};'use strict';var emlformat=require(_0x06b2('0x0'));var rimraf=require(_0x06b2('0x1'));var zipdir=require('zip-dir');var jsonpatch=require(_0x06b2('0x2'));var rp=require('request-promise');var moment=require(_0x06b2('0x3'));var BPromise=require(_0x06b2('0x4'));var Mustache=require(_0x06b2('0x5'));var util=require('util');var path=require(_0x06b2('0x6'));var sox=require(_0x06b2('0x7'));var csv=require(_0x06b2('0x8'));var ejs=require(_0x06b2('0x9'));var fs=require('fs');var fs_extra=require(_0x06b2('0xa'));var _=require(_0x06b2('0xb'));var squel=require(_0x06b2('0xc'));var crypto=require('crypto');var jsforce=require(_0x06b2('0xd'));var deskjs=require(_0x06b2('0xe'));var toCsv=require(_0x06b2('0x8'));var querystring=require('querystring');var Papa=require(_0x06b2('0xf'));var Redis=require('ioredis');var authService=require(_0x06b2('0x10'));var qs=require('../../components/parsers/qs');var as=require('../../components/parsers/advancedSearch');var hardwareService=require(_0x06b2('0x11'));var logger=require(_0x06b2('0x12'))('api');var utils=require(_0x06b2('0x13'));var config=require(_0x06b2('0x14'));var licenseUtil=require(_0x06b2('0x15'));var db=require(_0x06b2('0x16'))['db'];function respondWithStatusCode(_0x44a9b4,_0x810a12){_0x810a12=_0x810a12||0xcc;return function(_0x3039c9){if(_0x3039c9){return _0x44a9b4[_0x06b2('0x17')](_0x810a12);}return _0x44a9b4[_0x06b2('0x18')](_0x810a12)[_0x06b2('0x19')]();};}function respondWithResult(_0xa81f11,_0x2822e9){_0x2822e9=_0x2822e9||0xc8;return function(_0x26faee){if(_0x26faee){return _0xa81f11['status'](_0x2822e9)[_0x06b2('0x1a')](_0x26faee);}};}function respondWithFilteredResult(_0xaee98c,_0x47496c){return function(_0x3830e9){if(_0x3830e9){var _0xef0466=typeof _0x47496c[_0x06b2('0x1b')]==='undefined'&&typeof _0x47496c[_0x06b2('0x1c')]===_0x06b2('0x1d');var _0x525945=_0x3830e9[_0x06b2('0x1e')];var _0x594b48=_0xef0466?0x0:_0x47496c['offset'];var _0x192270=_0xef0466?_0x3830e9[_0x06b2('0x1e')]:_0x47496c[_0x06b2('0x1b')]+_0x47496c[_0x06b2('0x1c')];var _0x4c4e21;if(_0x192270>=_0x525945){_0x192270=_0x525945;_0x4c4e21=0xc8;}else{_0x4c4e21=0xce;}_0xaee98c[_0x06b2('0x18')](_0x4c4e21);return _0xaee98c[_0x06b2('0x1f')](_0x06b2('0x20'),_0x594b48+'-'+_0x192270+'/'+_0x525945)[_0x06b2('0x1a')](_0x3830e9);}return null;};}function patchUpdates(_0xe28985){return function(_0x368ad8){try{jsonpatch[_0x06b2('0x21')](_0x368ad8,_0xe28985,!![]);}catch(_0x5ca622){return BPromise[_0x06b2('0x22')](_0x5ca622);}return _0x368ad8[_0x06b2('0x23')]();};}function saveUpdates(_0xb05f65,_0x208384){return function(_0x4e2a4c){if(_0x4e2a4c){return _0x4e2a4c['update'](_0xb05f65)[_0x06b2('0x24')](function(_0xb5231e){return _0xb5231e;});}return null;};}function removeEntity(_0x4fc95f,_0x39659f){return function(_0x5e40f2){if(_0x5e40f2){return _0x5e40f2[_0x06b2('0x25')]()[_0x06b2('0x24')](function(){_0x4fc95f[_0x06b2('0x18')](0xcc)['end']();});}};}function handleEntityNotFound(_0x4382ce,_0x306ce){return function(_0xc65820){if(!_0xc65820){_0x4382ce[_0x06b2('0x17')](0x194);}return _0xc65820;};}function handleError(_0x1173fc,_0x4f5e90){_0x4f5e90=_0x4f5e90||0x1f4;return function(_0xbb00ea){logger[_0x06b2('0x26')](_0xbb00ea[_0x06b2('0x27')]);if(_0xbb00ea[_0x06b2('0x28')]){delete _0xbb00ea[_0x06b2('0x28')];}_0x1173fc[_0x06b2('0x18')](_0x4f5e90)['send'](_0xbb00ea);};}exports[_0x06b2('0x29')]=function(_0x2a3228,_0x2720fa){var _0x13c0eb={},_0x1f02d8={},_0x1bfaa9={'count':0x0,'rows':[]};var _0x3668bb=_['map'](db[_0x06b2('0x2a')][_0x06b2('0x2b')],function(_0x1637c2){return{'name':_0x1637c2[_0x06b2('0x2c')],'type':_0x1637c2[_0x06b2('0x2d')][_0x06b2('0x2e')]};});_0x1f02d8[_0x06b2('0x2f')]=_[_0x06b2('0x30')](_0x3668bb,'name');_0x1f02d8[_0x06b2('0x31')]=_[_0x06b2('0x32')](_0x2a3228[_0x06b2('0x31')]);_0x1f02d8[_0x06b2('0x33')]=_[_0x06b2('0x34')](_0x1f02d8[_0x06b2('0x2f')],_0x1f02d8[_0x06b2('0x31')]);_0x13c0eb['attributes']=_['intersection'](_0x1f02d8[_0x06b2('0x2f')],qs[_0x06b2('0x35')](_0x2a3228[_0x06b2('0x31')]['fields']));_0x13c0eb[_0x06b2('0x36')]=_0x13c0eb[_0x06b2('0x36')][_0x06b2('0x37')]?_0x13c0eb[_0x06b2('0x36')]:_0x1f02d8[_0x06b2('0x2f')];if(!_0x2a3228[_0x06b2('0x31')]['hasOwnProperty'](_0x06b2('0x38'))){_0x13c0eb[_0x06b2('0x1c')]=qs[_0x06b2('0x1c')](_0x2a3228['query'][_0x06b2('0x1c')]);_0x13c0eb[_0x06b2('0x1b')]=qs['offset'](_0x2a3228[_0x06b2('0x31')][_0x06b2('0x1b')]);}_0x13c0eb[_0x06b2('0x39')]=qs[_0x06b2('0x3a')](_0x2a3228[_0x06b2('0x31')][_0x06b2('0x3a')]);_0x13c0eb[_0x06b2('0x3b')]=qs[_0x06b2('0x33')](_[_0x06b2('0x3c')](_0x2a3228[_0x06b2('0x31')],_0x1f02d8[_0x06b2('0x33')]),_0x3668bb);if(_0x2a3228[_0x06b2('0x31')]['filter']){_0x13c0eb[_0x06b2('0x3b')]=_['merge'](_0x13c0eb['where'],{'$or':_[_0x06b2('0x30')](_0x3668bb,function(_0x4e92e0){if(_0x4e92e0[_0x06b2('0x2d')]!=='VIRTUAL'){var _0x35e29c={};_0x35e29c[_0x4e92e0[_0x06b2('0x28')]]={'$like':'%'+_0x2a3228[_0x06b2('0x31')][_0x06b2('0x3d')]+'%'};return _0x35e29c;}})});}_0x13c0eb=_[_0x06b2('0x3e')]({},_0x13c0eb,_0x2a3228['options']);var _0x404eab={'where':_0x13c0eb[_0x06b2('0x3b')]};return db[_0x06b2('0x2a')][_0x06b2('0x1e')](_0x404eab)[_0x06b2('0x24')](function(_0x39fd60){_0x1bfaa9['count']=_0x39fd60;if(_0x2a3228[_0x06b2('0x31')][_0x06b2('0x3f')]){_0x13c0eb['include']=[{'all':!![]}];}return db['WhatsappQueueReport'][_0x06b2('0x40')](_0x13c0eb);})[_0x06b2('0x24')](function(_0x286c9b){_0x1bfaa9[_0x06b2('0x41')]=_0x286c9b;return _0x1bfaa9;})[_0x06b2('0x24')](respondWithFilteredResult(_0x2720fa,_0x13c0eb))[_0x06b2('0x42')](handleError(_0x2720fa,null));};exports[_0x06b2('0x43')]=function(_0x2ff968,_0x2e2a80){var _0x117bf4={'raw':!![],'where':{'id':_0x2ff968[_0x06b2('0x44')]['id']}},_0x1d7750={};_0x1d7750[_0x06b2('0x2f')]=_[_0x06b2('0x32')](db[_0x06b2('0x2a')][_0x06b2('0x2b')]);_0x1d7750[_0x06b2('0x31')]=_[_0x06b2('0x32')](_0x2ff968[_0x06b2('0x31')]);_0x1d7750['filters']=_[_0x06b2('0x34')](_0x1d7750[_0x06b2('0x2f')],_0x1d7750[_0x06b2('0x31')]);_0x117bf4[_0x06b2('0x36')]=_['intersection'](_0x1d7750[_0x06b2('0x2f')],qs[_0x06b2('0x35')](_0x2ff968['query'][_0x06b2('0x35')]));_0x117bf4[_0x06b2('0x36')]=_0x117bf4['attributes'][_0x06b2('0x37')]?_0x117bf4[_0x06b2('0x36')]:_0x1d7750['model'];if(_0x2ff968['query']['includeAll']){_0x117bf4[_0x06b2('0x45')]=[{'all':!![]}];}_0x117bf4=_[_0x06b2('0x3e')]({},_0x117bf4,_0x2ff968[_0x06b2('0x46')]);return db[_0x06b2('0x2a')][_0x06b2('0x47')](_0x117bf4)['then'](handleEntityNotFound(_0x2e2a80,null))['then'](respondWithResult(_0x2e2a80,null))[_0x06b2('0x42')](handleError(_0x2e2a80,null));};exports[_0x06b2('0x48')]=function(_0x979759,_0x1f4d89){return db[_0x06b2('0x2a')][_0x06b2('0x48')](_0x979759['body'],{})[_0x06b2('0x24')](respondWithResult(_0x1f4d89,0xc9))[_0x06b2('0x42')](handleError(_0x1f4d89,null));};exports[_0x06b2('0x49')]=function(_0x33f72e,_0x146c5c){if(_0x33f72e[_0x06b2('0x4a')]['id']){delete _0x33f72e['body']['id'];}return db[_0x06b2('0x2a')][_0x06b2('0x47')]({'where':{'id':_0x33f72e[_0x06b2('0x44')]['id']}})[_0x06b2('0x24')](handleEntityNotFound(_0x146c5c,null))['then'](saveUpdates(_0x33f72e[_0x06b2('0x4a')],null))[_0x06b2('0x24')](respondWithResult(_0x146c5c,null))[_0x06b2('0x42')](handleError(_0x146c5c,null));};exports[_0x06b2('0x25')]=function(_0x546c9e,_0x346f04){return db[_0x06b2('0x2a')][_0x06b2('0x47')]({'where':{'id':_0x546c9e[_0x06b2('0x44')]['id']}})[_0x06b2('0x24')](handleEntityNotFound(_0x346f04,null))[_0x06b2('0x24')](removeEntity(_0x346f04,null))[_0x06b2('0x42')](handleError(_0x346f04,null));};exports[_0x06b2('0x4b')]=function(_0x568091,_0x33bc8e){return db[_0x06b2('0x2a')][_0x06b2('0x4b')]()[_0x06b2('0x24')](respondWithResult(_0x33bc8e,null))[_0x06b2('0x42')](handleError(_0x33bc8e,null));};
\ No newline at end of file