Built motion from commit 994c64e1.|2.6.1
[motion2.git] / server / api / intVtigerField / intVtigerField.controller.js
index 3c3df03..cef30ae 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xf9f3=['findAll','rows','catch','show','params','create','body','find','eml-format','rimraf','request-promise','bluebird','mustache','util','path','sox','ejs','fs-extra','lodash','squel','crypto','jsforce','to-csv','papaparse','ioredis','../../components/auth/service','../../components/parsers/qs','../../components/parsers/advancedSearch','../../config/license/hardware','../../config/logger','../../config/environment','../../config/license/util','../../mysqldb','status','end','json','undefined','count','offset','set','Content-Range','apply','reject','update','then','destroy','sendStatus','error','stack','name','send','map','VtigerField','rawAttributes','fieldName','type','key','model','query','keys','filters','intersection','attributes','fields','length','hasOwnProperty','nolimit','limit','order','sort','where','pick','merge','VIRTUAL','options','includeAll','include'];(function(_0x12aaee,_0x5bf50c){var _0x37c350=function(_0x182775){while(--_0x182775){_0x12aaee['push'](_0x12aaee['shift']());}};_0x37c350(++_0x5bf50c);}(_0xf9f3,0x189));var _0x3f9f=function(_0x3bf83f,_0x181cac){_0x3bf83f=_0x3bf83f-0x0;var _0x22c4a9=_0xf9f3[_0x3bf83f];return _0x22c4a9;};'use strict';var emlformat=require(_0x3f9f('0x0'));var rimraf=require(_0x3f9f('0x1'));var zipdir=require('zip-dir');var jsonpatch=require('fast-json-patch');var rp=require(_0x3f9f('0x2'));var moment=require('moment');var BPromise=require(_0x3f9f('0x3'));var Mustache=require(_0x3f9f('0x4'));var util=require(_0x3f9f('0x5'));var path=require(_0x3f9f('0x6'));var sox=require(_0x3f9f('0x7'));var csv=require('to-csv');var ejs=require(_0x3f9f('0x8'));var fs=require('fs');var fs_extra=require(_0x3f9f('0x9'));var _=require(_0x3f9f('0xa'));var squel=require(_0x3f9f('0xb'));var crypto=require(_0x3f9f('0xc'));var jsforce=require(_0x3f9f('0xd'));var deskjs=require('desk.js');var toCsv=require(_0x3f9f('0xe'));var querystring=require('querystring');var Papa=require(_0x3f9f('0xf'));var Redis=require(_0x3f9f('0x10'));var authService=require(_0x3f9f('0x11'));var qs=require(_0x3f9f('0x12'));var as=require(_0x3f9f('0x13'));var hardwareService=require(_0x3f9f('0x14'));var logger=require(_0x3f9f('0x15'))('api');var utils=require('../../config/utils');var config=require(_0x3f9f('0x16'));var licenseUtil=require(_0x3f9f('0x17'));var db=require(_0x3f9f('0x18'))['db'];function respondWithStatusCode(_0x487dc4,_0x150c7e){_0x150c7e=_0x150c7e||0xcc;return function(_0x1daf91){if(_0x1daf91){return _0x487dc4['sendStatus'](_0x150c7e);}return _0x487dc4[_0x3f9f('0x19')](_0x150c7e)[_0x3f9f('0x1a')]();};}function respondWithResult(_0x188a10,_0x41bfdc){_0x41bfdc=_0x41bfdc||0xc8;return function(_0x31a381){if(_0x31a381){return _0x188a10[_0x3f9f('0x19')](_0x41bfdc)[_0x3f9f('0x1b')](_0x31a381);}};}function respondWithFilteredResult(_0x475769,_0x2245cb){return function(_0x57fad2){if(_0x57fad2){var _0x52fe9a=typeof _0x2245cb['offset']===_0x3f9f('0x1c')&&typeof _0x2245cb['limit']===_0x3f9f('0x1c');var _0x1fbd58=_0x57fad2[_0x3f9f('0x1d')];var _0x4b9264=_0x52fe9a?0x0:_0x2245cb['offset'];var _0x50f39b=_0x52fe9a?_0x57fad2[_0x3f9f('0x1d')]:_0x2245cb[_0x3f9f('0x1e')]+_0x2245cb['limit'];var _0x3ceef4;if(_0x50f39b>=_0x1fbd58){_0x50f39b=_0x1fbd58;_0x3ceef4=0xc8;}else{_0x3ceef4=0xce;}_0x475769[_0x3f9f('0x19')](_0x3ceef4);return _0x475769[_0x3f9f('0x1f')](_0x3f9f('0x20'),_0x4b9264+'-'+_0x50f39b+'/'+_0x1fbd58)['json'](_0x57fad2);}return null;};}function patchUpdates(_0x2a9888){return function(_0x5b6cb2){try{jsonpatch[_0x3f9f('0x21')](_0x5b6cb2,_0x2a9888,!![]);}catch(_0x3a24bf){return BPromise[_0x3f9f('0x22')](_0x3a24bf);}return _0x5b6cb2['save']();};}function saveUpdates(_0x118c0d,_0x3868d4){return function(_0x3d6fbe){if(_0x3d6fbe){return _0x3d6fbe[_0x3f9f('0x23')](_0x118c0d)[_0x3f9f('0x24')](function(_0x3064c9){return _0x3064c9;});}return null;};}function removeEntity(_0x1c5168,_0x521bb5){return function(_0x2ba9d3){if(_0x2ba9d3){return _0x2ba9d3[_0x3f9f('0x25')]()['then'](function(){_0x1c5168['status'](0xcc)[_0x3f9f('0x1a')]();});}};}function handleEntityNotFound(_0x4908f1,_0xf32900){return function(_0x76f44b){if(!_0x76f44b){_0x4908f1[_0x3f9f('0x26')](0x194);}return _0x76f44b;};}function handleError(_0x37235d,_0x839b94){_0x839b94=_0x839b94||0x1f4;return function(_0x591ae9){logger[_0x3f9f('0x27')](_0x591ae9[_0x3f9f('0x28')]);if(_0x591ae9[_0x3f9f('0x29')]){delete _0x591ae9[_0x3f9f('0x29')];}_0x37235d['status'](_0x839b94)[_0x3f9f('0x2a')](_0x591ae9);};}exports['index']=function(_0x242955,_0x506f26){var _0x47e544={},_0x499477={},_0x23c50a={'count':0x0,'rows':[]};var _0x560645=_[_0x3f9f('0x2b')](db[_0x3f9f('0x2c')][_0x3f9f('0x2d')],function(_0xc254fd){return{'name':_0xc254fd[_0x3f9f('0x2e')],'type':_0xc254fd[_0x3f9f('0x2f')][_0x3f9f('0x30')]};});_0x499477[_0x3f9f('0x31')]=_[_0x3f9f('0x2b')](_0x560645,_0x3f9f('0x29'));_0x499477[_0x3f9f('0x32')]=_[_0x3f9f('0x33')](_0x242955[_0x3f9f('0x32')]);_0x499477[_0x3f9f('0x34')]=_[_0x3f9f('0x35')](_0x499477[_0x3f9f('0x31')],_0x499477[_0x3f9f('0x32')]);_0x47e544[_0x3f9f('0x36')]=_['intersection'](_0x499477['model'],qs[_0x3f9f('0x37')](_0x242955['query'][_0x3f9f('0x37')]));_0x47e544[_0x3f9f('0x36')]=_0x47e544[_0x3f9f('0x36')][_0x3f9f('0x38')]?_0x47e544[_0x3f9f('0x36')]:_0x499477[_0x3f9f('0x31')];if(!_0x242955[_0x3f9f('0x32')][_0x3f9f('0x39')](_0x3f9f('0x3a'))){_0x47e544['limit']=qs[_0x3f9f('0x3b')](_0x242955['query'][_0x3f9f('0x3b')]);_0x47e544['offset']=qs[_0x3f9f('0x1e')](_0x242955[_0x3f9f('0x32')][_0x3f9f('0x1e')]);}_0x47e544[_0x3f9f('0x3c')]=qs[_0x3f9f('0x3d')](_0x242955['query'][_0x3f9f('0x3d')]);_0x47e544[_0x3f9f('0x3e')]=qs[_0x3f9f('0x34')](_[_0x3f9f('0x3f')](_0x242955['query'],_0x499477[_0x3f9f('0x34')]),_0x560645);if(_0x242955[_0x3f9f('0x32')]['filter']){_0x47e544[_0x3f9f('0x3e')]=_[_0x3f9f('0x40')](_0x47e544['where'],{'$or':_[_0x3f9f('0x2b')](_0x560645,function(_0x181e85){if(_0x181e85['type']!==_0x3f9f('0x41')){var _0x3305dc={};_0x3305dc[_0x181e85[_0x3f9f('0x29')]]={'$like':'%'+_0x242955[_0x3f9f('0x32')]['filter']+'%'};return _0x3305dc;}})});}_0x47e544=_[_0x3f9f('0x40')]({},_0x47e544,_0x242955[_0x3f9f('0x42')]);var _0x13bfc4={'where':_0x47e544[_0x3f9f('0x3e')]};return db[_0x3f9f('0x2c')][_0x3f9f('0x1d')](_0x13bfc4)[_0x3f9f('0x24')](function(_0x272f04){_0x23c50a[_0x3f9f('0x1d')]=_0x272f04;if(_0x242955[_0x3f9f('0x32')][_0x3f9f('0x43')]){_0x47e544[_0x3f9f('0x44')]=[{'all':!![]}];}return db[_0x3f9f('0x2c')][_0x3f9f('0x45')](_0x47e544);})[_0x3f9f('0x24')](function(_0x331693){_0x23c50a[_0x3f9f('0x46')]=_0x331693;return _0x23c50a;})[_0x3f9f('0x24')](respondWithFilteredResult(_0x506f26,_0x47e544))[_0x3f9f('0x47')](handleError(_0x506f26,null));};exports[_0x3f9f('0x48')]=function(_0x5d337c,_0x350f3d){var _0x37e1af={'raw':!![],'where':{'id':_0x5d337c[_0x3f9f('0x49')]['id']}},_0x3fa91d={};_0x3fa91d['model']=_[_0x3f9f('0x33')](db[_0x3f9f('0x2c')]['rawAttributes']);_0x3fa91d['query']=_[_0x3f9f('0x33')](_0x5d337c[_0x3f9f('0x32')]);_0x3fa91d[_0x3f9f('0x34')]=_[_0x3f9f('0x35')](_0x3fa91d['model'],_0x3fa91d[_0x3f9f('0x32')]);_0x37e1af[_0x3f9f('0x36')]=_[_0x3f9f('0x35')](_0x3fa91d[_0x3f9f('0x31')],qs[_0x3f9f('0x37')](_0x5d337c[_0x3f9f('0x32')]['fields']));_0x37e1af[_0x3f9f('0x36')]=_0x37e1af[_0x3f9f('0x36')][_0x3f9f('0x38')]?_0x37e1af[_0x3f9f('0x36')]:_0x3fa91d['model'];if(_0x5d337c['query'][_0x3f9f('0x43')]){_0x37e1af[_0x3f9f('0x44')]=[{'all':!![]}];}_0x37e1af=_[_0x3f9f('0x40')]({},_0x37e1af,_0x5d337c['options']);return db['VtigerField']['find'](_0x37e1af)[_0x3f9f('0x24')](handleEntityNotFound(_0x350f3d,null))[_0x3f9f('0x24')](respondWithResult(_0x350f3d,null))[_0x3f9f('0x47')](handleError(_0x350f3d,null));};exports['create']=function(_0x2335a5,_0x566035){return db[_0x3f9f('0x2c')][_0x3f9f('0x4a')](_0x2335a5[_0x3f9f('0x4b')],{})['then'](respondWithResult(_0x566035,0xc9))[_0x3f9f('0x47')](handleError(_0x566035,null));};exports[_0x3f9f('0x23')]=function(_0x45f37a,_0x3cafb5){if(_0x45f37a[_0x3f9f('0x4b')]['id']){delete _0x45f37a[_0x3f9f('0x4b')]['id'];}return db[_0x3f9f('0x2c')][_0x3f9f('0x4c')]({'where':{'id':_0x45f37a[_0x3f9f('0x49')]['id']}})[_0x3f9f('0x24')](handleEntityNotFound(_0x3cafb5,null))[_0x3f9f('0x24')](saveUpdates(_0x45f37a['body'],null))[_0x3f9f('0x24')](respondWithResult(_0x3cafb5,null))['catch'](handleError(_0x3cafb5,null));};exports[_0x3f9f('0x25')]=function(_0x4becf2,_0x174679){return db[_0x3f9f('0x2c')][_0x3f9f('0x4c')]({'where':{'id':_0x4becf2[_0x3f9f('0x49')]['id']}})[_0x3f9f('0x24')](handleEntityNotFound(_0x174679,null))[_0x3f9f('0x24')](removeEntity(_0x174679,null))['catch'](handleError(_0x174679,null));};
\ No newline at end of file
+var _0xf853=['findAll','rows','catch','show','intersection','include','merge','find','create','body','params','eml-format','rimraf','fast-json-patch','request-promise','moment','bluebird','util','sox','to-csv','ejs','fs-extra','lodash','squel','crypto','jsforce','desk.js','querystring','ioredis','../../components/auth/service','../../components/parsers/qs','../../components/parsers/advancedSearch','../../config/logger','api','../../mysqldb','sendStatus','status','json','offset','undefined','limit','count','set','reject','save','update','then','destroy','end','error','stack','send','map','rawAttributes','fieldName','type','key','model','name','query','keys','filters','attributes','fields','length','hasOwnProperty','order','sort','pick','filter','where','VIRTUAL','options','includeAll','VtigerField'];(function(_0x330723,_0x8de382){var _0x60c546=function(_0xd6d3fe){while(--_0xd6d3fe){_0x330723['push'](_0x330723['shift']());}};_0x60c546(++_0x8de382);}(_0xf853,0x1cd));var _0x3f85=function(_0xe896bf,_0x4f8e5e){_0xe896bf=_0xe896bf-0x0;var _0x4c7a8a=_0xf853[_0xe896bf];return _0x4c7a8a;};'use strict';var emlformat=require(_0x3f85('0x0'));var rimraf=require(_0x3f85('0x1'));var zipdir=require('zip-dir');var jsonpatch=require(_0x3f85('0x2'));var rp=require(_0x3f85('0x3'));var moment=require(_0x3f85('0x4'));var BPromise=require(_0x3f85('0x5'));var Mustache=require('mustache');var util=require(_0x3f85('0x6'));var path=require('path');var sox=require(_0x3f85('0x7'));var csv=require(_0x3f85('0x8'));var ejs=require(_0x3f85('0x9'));var fs=require('fs');var fs_extra=require(_0x3f85('0xa'));var _=require(_0x3f85('0xb'));var squel=require(_0x3f85('0xc'));var crypto=require(_0x3f85('0xd'));var jsforce=require(_0x3f85('0xe'));var deskjs=require(_0x3f85('0xf'));var toCsv=require(_0x3f85('0x8'));var querystring=require(_0x3f85('0x10'));var Papa=require('papaparse');var Redis=require(_0x3f85('0x11'));var authService=require(_0x3f85('0x12'));var qs=require(_0x3f85('0x13'));var as=require(_0x3f85('0x14'));var hardwareService=require('../../config/license/hardware');var logger=require(_0x3f85('0x15'))(_0x3f85('0x16'));var utils=require('../../config/utils');var config=require('../../config/environment');var licenseUtil=require('../../config/license/util');var db=require(_0x3f85('0x17'))['db'];function respondWithStatusCode(_0x3c1cb7,_0x1885ae){_0x1885ae=_0x1885ae||0xcc;return function(_0x1a5474){if(_0x1a5474){return _0x3c1cb7[_0x3f85('0x18')](_0x1885ae);}return _0x3c1cb7[_0x3f85('0x19')](_0x1885ae)['end']();};}function respondWithResult(_0x4b8bc9,_0x478df6){_0x478df6=_0x478df6||0xc8;return function(_0x196a5f){if(_0x196a5f){return _0x4b8bc9[_0x3f85('0x19')](_0x478df6)[_0x3f85('0x1a')](_0x196a5f);}};}function respondWithFilteredResult(_0x274a04,_0x35ed10){return function(_0x53d27d){if(_0x53d27d){var _0x2d8927=typeof _0x35ed10[_0x3f85('0x1b')]===_0x3f85('0x1c')&&typeof _0x35ed10[_0x3f85('0x1d')]===_0x3f85('0x1c');var _0x3f3315=_0x53d27d[_0x3f85('0x1e')];var _0x3bc49a=_0x2d8927?0x0:_0x35ed10[_0x3f85('0x1b')];var _0xcdd71f=_0x2d8927?_0x53d27d[_0x3f85('0x1e')]:_0x35ed10['offset']+_0x35ed10[_0x3f85('0x1d')];var _0x4c664d;if(_0xcdd71f>=_0x3f3315){_0xcdd71f=_0x3f3315;_0x4c664d=0xc8;}else{_0x4c664d=0xce;}_0x274a04[_0x3f85('0x19')](_0x4c664d);return _0x274a04[_0x3f85('0x1f')]('Content-Range',_0x3bc49a+'-'+_0xcdd71f+'/'+_0x3f3315)['json'](_0x53d27d);}return null;};}function patchUpdates(_0x16caed){return function(_0x2bfe6e){try{jsonpatch['apply'](_0x2bfe6e,_0x16caed,!![]);}catch(_0x55fd2b){return BPromise[_0x3f85('0x20')](_0x55fd2b);}return _0x2bfe6e[_0x3f85('0x21')]();};}function saveUpdates(_0x4581dd,_0x50c473){return function(_0x4739f5){if(_0x4739f5){return _0x4739f5[_0x3f85('0x22')](_0x4581dd)[_0x3f85('0x23')](function(_0x121495){return _0x121495;});}return null;};}function removeEntity(_0x3faf6c,_0x298d06){return function(_0x4ca964){if(_0x4ca964){return _0x4ca964[_0x3f85('0x24')]()[_0x3f85('0x23')](function(){_0x3faf6c[_0x3f85('0x19')](0xcc)[_0x3f85('0x25')]();});}};}function handleEntityNotFound(_0x579158,_0xd8e991){return function(_0x21d552){if(!_0x21d552){_0x579158[_0x3f85('0x18')](0x194);}return _0x21d552;};}function handleError(_0x4f3453,_0x1b0f53){_0x1b0f53=_0x1b0f53||0x1f4;return function(_0x5e4b03){logger[_0x3f85('0x26')](_0x5e4b03[_0x3f85('0x27')]);if(_0x5e4b03['name']){delete _0x5e4b03['name'];}_0x4f3453['status'](_0x1b0f53)[_0x3f85('0x28')](_0x5e4b03);};}exports['index']=function(_0xd10ad2,_0x5657f6){var _0x47f05c={},_0x370943={},_0x24eaed={'count':0x0,'rows':[]};var _0x17e6d3=_[_0x3f85('0x29')](db['VtigerField'][_0x3f85('0x2a')],function(_0x21b893){return{'name':_0x21b893[_0x3f85('0x2b')],'type':_0x21b893[_0x3f85('0x2c')][_0x3f85('0x2d')]};});_0x370943[_0x3f85('0x2e')]=_['map'](_0x17e6d3,_0x3f85('0x2f'));_0x370943[_0x3f85('0x30')]=_[_0x3f85('0x31')](_0xd10ad2[_0x3f85('0x30')]);_0x370943[_0x3f85('0x32')]=_['intersection'](_0x370943[_0x3f85('0x2e')],_0x370943[_0x3f85('0x30')]);_0x47f05c[_0x3f85('0x33')]=_['intersection'](_0x370943[_0x3f85('0x2e')],qs[_0x3f85('0x34')](_0xd10ad2[_0x3f85('0x30')][_0x3f85('0x34')]));_0x47f05c[_0x3f85('0x33')]=_0x47f05c[_0x3f85('0x33')][_0x3f85('0x35')]?_0x47f05c[_0x3f85('0x33')]:_0x370943['model'];if(!_0xd10ad2[_0x3f85('0x30')][_0x3f85('0x36')]('nolimit')){_0x47f05c[_0x3f85('0x1d')]=qs[_0x3f85('0x1d')](_0xd10ad2['query'][_0x3f85('0x1d')]);_0x47f05c['offset']=qs[_0x3f85('0x1b')](_0xd10ad2[_0x3f85('0x30')][_0x3f85('0x1b')]);}_0x47f05c[_0x3f85('0x37')]=qs[_0x3f85('0x38')](_0xd10ad2[_0x3f85('0x30')][_0x3f85('0x38')]);_0x47f05c['where']=qs['filters'](_[_0x3f85('0x39')](_0xd10ad2[_0x3f85('0x30')],_0x370943['filters']),_0x17e6d3);if(_0xd10ad2['query'][_0x3f85('0x3a')]){_0x47f05c[_0x3f85('0x3b')]=_['merge'](_0x47f05c[_0x3f85('0x3b')],{'$or':_[_0x3f85('0x29')](_0x17e6d3,function(_0x1d9952){if(_0x1d9952['type']!==_0x3f85('0x3c')){var _0x260110={};_0x260110[_0x1d9952[_0x3f85('0x2f')]]={'$like':'%'+_0xd10ad2[_0x3f85('0x30')][_0x3f85('0x3a')]+'%'};return _0x260110;}})});}_0x47f05c=_['merge']({},_0x47f05c,_0xd10ad2[_0x3f85('0x3d')]);var _0x651768={'where':_0x47f05c[_0x3f85('0x3b')]};return db['VtigerField'][_0x3f85('0x1e')](_0x651768)[_0x3f85('0x23')](function(_0x5dda4b){_0x24eaed['count']=_0x5dda4b;if(_0xd10ad2['query'][_0x3f85('0x3e')]){_0x47f05c['include']=[{'all':!![]}];}return db[_0x3f85('0x3f')][_0x3f85('0x40')](_0x47f05c);})[_0x3f85('0x23')](function(_0x3bf47e){_0x24eaed[_0x3f85('0x41')]=_0x3bf47e;return _0x24eaed;})['then'](respondWithFilteredResult(_0x5657f6,_0x47f05c))[_0x3f85('0x42')](handleError(_0x5657f6,null));};exports[_0x3f85('0x43')]=function(_0x180399,_0xdae88c){var _0x428d21={'raw':!![],'where':{'id':_0x180399['params']['id']}},_0x226bc6={};_0x226bc6[_0x3f85('0x2e')]=_[_0x3f85('0x31')](db['VtigerField'][_0x3f85('0x2a')]);_0x226bc6[_0x3f85('0x30')]=_[_0x3f85('0x31')](_0x180399[_0x3f85('0x30')]);_0x226bc6[_0x3f85('0x32')]=_['intersection'](_0x226bc6['model'],_0x226bc6[_0x3f85('0x30')]);_0x428d21[_0x3f85('0x33')]=_[_0x3f85('0x44')](_0x226bc6[_0x3f85('0x2e')],qs[_0x3f85('0x34')](_0x180399[_0x3f85('0x30')][_0x3f85('0x34')]));_0x428d21[_0x3f85('0x33')]=_0x428d21[_0x3f85('0x33')][_0x3f85('0x35')]?_0x428d21['attributes']:_0x226bc6[_0x3f85('0x2e')];if(_0x180399[_0x3f85('0x30')][_0x3f85('0x3e')]){_0x428d21[_0x3f85('0x45')]=[{'all':!![]}];}_0x428d21=_[_0x3f85('0x46')]({},_0x428d21,_0x180399[_0x3f85('0x3d')]);return db[_0x3f85('0x3f')][_0x3f85('0x47')](_0x428d21)['then'](handleEntityNotFound(_0xdae88c,null))['then'](respondWithResult(_0xdae88c,null))['catch'](handleError(_0xdae88c,null));};exports[_0x3f85('0x48')]=function(_0x55124e,_0x40f374){return db[_0x3f85('0x3f')][_0x3f85('0x48')](_0x55124e[_0x3f85('0x49')],{})[_0x3f85('0x23')](respondWithResult(_0x40f374,0xc9))[_0x3f85('0x42')](handleError(_0x40f374,null));};exports[_0x3f85('0x22')]=function(_0x201cbc,_0x751d9f){if(_0x201cbc[_0x3f85('0x49')]['id']){delete _0x201cbc[_0x3f85('0x49')]['id'];}return db[_0x3f85('0x3f')][_0x3f85('0x47')]({'where':{'id':_0x201cbc[_0x3f85('0x4a')]['id']}})[_0x3f85('0x23')](handleEntityNotFound(_0x751d9f,null))[_0x3f85('0x23')](saveUpdates(_0x201cbc[_0x3f85('0x49')],null))['then'](respondWithResult(_0x751d9f,null))[_0x3f85('0x42')](handleError(_0x751d9f,null));};exports['destroy']=function(_0xcd64a2,_0x3a2e98){return db[_0x3f85('0x3f')][_0x3f85('0x47')]({'where':{'id':_0xcd64a2[_0x3f85('0x4a')]['id']}})[_0x3f85('0x23')](handleEntityNotFound(_0x3a2e98,null))['then'](removeEntity(_0x3a2e98,null))[_0x3f85('0x42')](handleError(_0x3a2e98,null));};
\ No newline at end of file