Built motion from commit ab870f9e.|2.5.44
[motion2.git] / server / api / intFreshsalesField / intFreshsalesField.controller.js
index 48566ae..73c0aa7 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xc285=['html-pdf','eml-format','zip-dir','request-promise','bluebird','mustache','path','sox','to-csv','ejs','lodash','squel','crypto','desk.js','querystring','papaparse','ioredis','../../components/parsers/qs','../../components/parsers/advancedSearch','../../config/license/hardware','../../config/logger','api','../../config/utils','../../config/license/util','status','end','offset','limit','set','Content-Range','json','apply','reject','save','update','then','error','name','send','index','map','rawAttributes','fieldName','type','key','model','keys','query','filters','attributes','intersection','fields','length','hasOwnProperty','nolimit','sort','where','filter','merge','options','FreshsalesField','count','include','findAll','rows','catch','show','params','find','create','body','destroy'];(function(_0x26491f,_0x33badb){var _0x8f4b6a=function(_0xe290b2){while(--_0xe290b2){_0x26491f['push'](_0x26491f['shift']());}};_0x8f4b6a(++_0x33badb);}(_0xc285,0xd8));var _0x5c28=function(_0x342baa,_0x4a110f){_0x342baa=_0x342baa-0x0;var _0x1208f3=_0xc285[_0x342baa];return _0x1208f3;};'use strict';var pdf=require(_0x5c28('0x0'));var emlformat=require(_0x5c28('0x1'));var rimraf=require('rimraf');var zipdir=require(_0x5c28('0x2'));var jsonpatch=require('fast-json-patch');var rp=require(_0x5c28('0x3'));var moment=require('moment');var BPromise=require(_0x5c28('0x4'));var Mustache=require(_0x5c28('0x5'));var util=require('util');var path=require(_0x5c28('0x6'));var sox=require(_0x5c28('0x7'));var csv=require(_0x5c28('0x8'));var ejs=require(_0x5c28('0x9'));var fs=require('fs');var _=require(_0x5c28('0xa'));var squel=require(_0x5c28('0xb'));var crypto=require(_0x5c28('0xc'));var jsforce=require('jsforce');var deskjs=require(_0x5c28('0xd'));var toCsv=require(_0x5c28('0x8'));var querystring=require(_0x5c28('0xe'));var Papa=require(_0x5c28('0xf'));var Redis=require(_0x5c28('0x10'));var authService=require('../../components/auth/service');var qs=require(_0x5c28('0x11'));var as=require(_0x5c28('0x12'));var hardwareService=require(_0x5c28('0x13'));var logger=require(_0x5c28('0x14'))(_0x5c28('0x15'));var utils=require(_0x5c28('0x16'));var config=require('../../config/environment');var licenseUtil=require(_0x5c28('0x17'));var db=require('../../mysqldb')['db'];function respondWithStatusCode(_0x5a2b5a,_0x3860e5){_0x3860e5=_0x3860e5||0xcc;return function(_0x336f8b){if(_0x336f8b){return _0x5a2b5a['sendStatus'](_0x3860e5);}return _0x5a2b5a[_0x5c28('0x18')](_0x3860e5)[_0x5c28('0x19')]();};}function respondWithResult(_0x13d894,_0x1c63fe){_0x1c63fe=_0x1c63fe||0xc8;return function(_0x1fee6b){if(_0x1fee6b){return _0x13d894[_0x5c28('0x18')](_0x1c63fe)['json'](_0x1fee6b);}};}function respondWithFilteredResult(_0x1c3e45,_0x3e0d9f){return function(_0x11e4cd){if(_0x11e4cd){var _0x267995=_0x11e4cd['count'],_0x1cdf93=_0x3e0d9f[_0x5c28('0x1a')],_0x256bf2=_0x3e0d9f['offset']+_0x3e0d9f[_0x5c28('0x1b')],_0x2ecc6f;if(_0x256bf2>=_0x267995){_0x256bf2=_0x267995;_0x2ecc6f=0xc8;}else{_0x2ecc6f=0xce;}_0x1c3e45['status'](_0x2ecc6f);return _0x1c3e45[_0x5c28('0x1c')](_0x5c28('0x1d'),_0x1cdf93+'-'+_0x256bf2+'/'+_0x267995)[_0x5c28('0x1e')](_0x11e4cd);}return null;};}function patchUpdates(_0x32440b){return function(_0x102530){try{jsonpatch[_0x5c28('0x1f')](_0x102530,_0x32440b,!![]);}catch(_0xd0c429){return BPromise[_0x5c28('0x20')](_0xd0c429);}return _0x102530[_0x5c28('0x21')]();};}function saveUpdates(_0x3719d1,_0x188d60){return function(_0x50d069){if(_0x50d069){return _0x50d069[_0x5c28('0x22')](_0x3719d1)['then'](function(_0xd7c937){return _0xd7c937;});}return null;};}function removeEntity(_0xaf3662,_0x165a3f){return function(_0x4238d7){if(_0x4238d7){return _0x4238d7['destroy']()[_0x5c28('0x23')](function(){_0xaf3662[_0x5c28('0x18')](0xcc)[_0x5c28('0x19')]();});}};}function handleEntityNotFound(_0x34a694,_0x58e54c){return function(_0x2add09){if(!_0x2add09){_0x34a694['sendStatus'](0x194);}return _0x2add09;};}function handleError(_0x196e4d,_0x5dafd7){_0x5dafd7=_0x5dafd7||0x1f4;return function(_0x2ab484){logger[_0x5c28('0x24')](_0x2ab484['stack']);if(_0x2ab484[_0x5c28('0x25')]){delete _0x2ab484[_0x5c28('0x25')];}_0x196e4d[_0x5c28('0x18')](_0x5dafd7)[_0x5c28('0x26')](_0x2ab484);};}exports[_0x5c28('0x27')]=function(_0x55fb96,_0x565ff7){var _0x9c1fbd={},_0x4ed78f={},_0x18c9d3={'count':0x0,'rows':[]};var _0x3dfbef=_[_0x5c28('0x28')](db['FreshsalesField'][_0x5c28('0x29')],function(_0x245544){return{'name':_0x245544[_0x5c28('0x2a')],'type':_0x245544[_0x5c28('0x2b')][_0x5c28('0x2c')]};});_0x4ed78f[_0x5c28('0x2d')]=_[_0x5c28('0x28')](_0x3dfbef,'name');_0x4ed78f['query']=_[_0x5c28('0x2e')](_0x55fb96[_0x5c28('0x2f')]);_0x4ed78f[_0x5c28('0x30')]=_['intersection'](_0x4ed78f[_0x5c28('0x2d')],_0x4ed78f[_0x5c28('0x2f')]);_0x9c1fbd[_0x5c28('0x31')]=_[_0x5c28('0x32')](_0x4ed78f[_0x5c28('0x2d')],qs[_0x5c28('0x33')](_0x55fb96[_0x5c28('0x2f')][_0x5c28('0x33')]));_0x9c1fbd['attributes']=_0x9c1fbd[_0x5c28('0x31')][_0x5c28('0x34')]?_0x9c1fbd[_0x5c28('0x31')]:_0x4ed78f[_0x5c28('0x2d')];if(!_0x55fb96['query'][_0x5c28('0x35')](_0x5c28('0x36'))){_0x9c1fbd[_0x5c28('0x1b')]=qs['limit'](_0x55fb96[_0x5c28('0x2f')]['limit']);_0x9c1fbd[_0x5c28('0x1a')]=qs[_0x5c28('0x1a')](_0x55fb96[_0x5c28('0x2f')][_0x5c28('0x1a')]);}_0x9c1fbd['order']=qs['sort'](_0x55fb96[_0x5c28('0x2f')][_0x5c28('0x37')]);_0x9c1fbd[_0x5c28('0x38')]=qs[_0x5c28('0x30')](_['pick'](_0x55fb96[_0x5c28('0x2f')],_0x4ed78f['filters']),_0x3dfbef);if(_0x55fb96[_0x5c28('0x2f')][_0x5c28('0x39')]){_0x9c1fbd[_0x5c28('0x38')]=_[_0x5c28('0x3a')](_0x9c1fbd[_0x5c28('0x38')],{'$or':_[_0x5c28('0x28')](_0x3dfbef,function(_0x521025){if(_0x521025[_0x5c28('0x2b')]!=='VIRTUAL'){var _0xf3b0cf={};_0xf3b0cf[_0x521025[_0x5c28('0x25')]]={'$like':'%'+_0x55fb96[_0x5c28('0x2f')][_0x5c28('0x39')]+'%'};return _0xf3b0cf;}})});}_0x9c1fbd=_['merge']({},_0x9c1fbd,_0x55fb96[_0x5c28('0x3b')]);var _0x4faae7={'where':_0x9c1fbd[_0x5c28('0x38')]};return db[_0x5c28('0x3c')][_0x5c28('0x3d')](_0x4faae7)[_0x5c28('0x23')](function(_0x2f78be){_0x18c9d3[_0x5c28('0x3d')]=_0x2f78be;if(_0x55fb96[_0x5c28('0x2f')]['includeAll']){_0x9c1fbd[_0x5c28('0x3e')]=[{'all':!![]}];}return db[_0x5c28('0x3c')][_0x5c28('0x3f')](_0x9c1fbd);})['then'](function(_0xa27ba7){_0x18c9d3[_0x5c28('0x40')]=_0xa27ba7;return _0x18c9d3;})[_0x5c28('0x23')](respondWithFilteredResult(_0x565ff7,_0x9c1fbd))[_0x5c28('0x41')](handleError(_0x565ff7,null));};exports[_0x5c28('0x42')]=function(_0x38792c,_0x5c8efc){var _0x5b14d6={'raw':!![],'where':{'id':_0x38792c[_0x5c28('0x43')]['id']}},_0x49ccf2={};_0x49ccf2['model']=_[_0x5c28('0x2e')](db[_0x5c28('0x3c')][_0x5c28('0x29')]);_0x49ccf2['query']=_['keys'](_0x38792c[_0x5c28('0x2f')]);_0x49ccf2[_0x5c28('0x30')]=_[_0x5c28('0x32')](_0x49ccf2[_0x5c28('0x2d')],_0x49ccf2[_0x5c28('0x2f')]);_0x5b14d6[_0x5c28('0x31')]=_['intersection'](_0x49ccf2[_0x5c28('0x2d')],qs[_0x5c28('0x33')](_0x38792c['query'][_0x5c28('0x33')]));_0x5b14d6[_0x5c28('0x31')]=_0x5b14d6['attributes']['length']?_0x5b14d6[_0x5c28('0x31')]:_0x49ccf2[_0x5c28('0x2d')];if(_0x38792c[_0x5c28('0x2f')]['includeAll']){_0x5b14d6[_0x5c28('0x3e')]=[{'all':!![]}];}_0x5b14d6=_[_0x5c28('0x3a')]({},_0x5b14d6,_0x38792c[_0x5c28('0x3b')]);return db[_0x5c28('0x3c')][_0x5c28('0x44')](_0x5b14d6)['then'](handleEntityNotFound(_0x5c8efc,null))['then'](respondWithResult(_0x5c8efc,null))['catch'](handleError(_0x5c8efc,null));};exports[_0x5c28('0x45')]=function(_0x58c4b7,_0x153dc6){return db[_0x5c28('0x3c')]['create'](_0x58c4b7[_0x5c28('0x46')],{})[_0x5c28('0x23')](respondWithResult(_0x153dc6,0xc9))[_0x5c28('0x41')](handleError(_0x153dc6,null));};exports[_0x5c28('0x22')]=function(_0x7b4615,_0x1ee94b){if(_0x7b4615[_0x5c28('0x46')]['id']){delete _0x7b4615[_0x5c28('0x46')]['id'];}return db[_0x5c28('0x3c')][_0x5c28('0x44')]({'where':{'id':_0x7b4615['params']['id']}})[_0x5c28('0x23')](handleEntityNotFound(_0x1ee94b,null))['then'](saveUpdates(_0x7b4615[_0x5c28('0x46')],null))['then'](respondWithResult(_0x1ee94b,null))[_0x5c28('0x41')](handleError(_0x1ee94b,null));};exports[_0x5c28('0x47')]=function(_0x2ce2d7,_0x90ef2e){return db['FreshsalesField']['find']({'where':{'id':_0x2ce2d7[_0x5c28('0x43')]['id']}})[_0x5c28('0x23')](handleEntityNotFound(_0x90ef2e,null))[_0x5c28('0x23')](removeEntity(_0x90ef2e,null))[_0x5c28('0x41')](handleError(_0x90ef2e,null));};
\ No newline at end of file
+var _0x0c2c=['FreshsalesField','fieldName','key','model','query','keys','filters','intersection','attributes','fields','length','hasOwnProperty','order','sort','filter','where','type','VIRTUAL','merge','includeAll','findAll','rows','catch','show','params','rawAttributes','include','find','create','body','eml-format','rimraf','zip-dir','fast-json-patch','request-promise','moment','bluebird','mustache','path','sox','to-csv','fs-extra','crypto','jsforce','desk.js','querystring','papaparse','ioredis','../../components/parsers/qs','../../components/parsers/advancedSearch','../../config/license/hardware','../../config/logger','api','../../config/utils','../../config/environment','../../config/license/util','../../mysqldb','json','offset','undefined','limit','count','status','Content-Range','apply','reject','save','update','destroy','then','sendStatus','error','stack','name','send','index','map'];(function(_0x2b4411,_0x2625ed){var _0x8e41ef=function(_0x2aa8c1){while(--_0x2aa8c1){_0x2b4411['push'](_0x2b4411['shift']());}};_0x8e41ef(++_0x2625ed);}(_0x0c2c,0x1ec));var _0xc0c2=function(_0x307086,_0x3bfe4e){_0x307086=_0x307086-0x0;var _0x699043=_0x0c2c[_0x307086];return _0x699043;};'use strict';var emlformat=require(_0xc0c2('0x0'));var rimraf=require(_0xc0c2('0x1'));var zipdir=require(_0xc0c2('0x2'));var jsonpatch=require(_0xc0c2('0x3'));var rp=require(_0xc0c2('0x4'));var moment=require(_0xc0c2('0x5'));var BPromise=require(_0xc0c2('0x6'));var Mustache=require(_0xc0c2('0x7'));var util=require('util');var path=require(_0xc0c2('0x8'));var sox=require(_0xc0c2('0x9'));var csv=require(_0xc0c2('0xa'));var ejs=require('ejs');var fs=require('fs');var fs_extra=require(_0xc0c2('0xb'));var _=require('lodash');var squel=require('squel');var crypto=require(_0xc0c2('0xc'));var jsforce=require(_0xc0c2('0xd'));var deskjs=require(_0xc0c2('0xe'));var toCsv=require('to-csv');var querystring=require(_0xc0c2('0xf'));var Papa=require(_0xc0c2('0x10'));var Redis=require(_0xc0c2('0x11'));var authService=require('../../components/auth/service');var qs=require(_0xc0c2('0x12'));var as=require(_0xc0c2('0x13'));var hardwareService=require(_0xc0c2('0x14'));var logger=require(_0xc0c2('0x15'))(_0xc0c2('0x16'));var utils=require(_0xc0c2('0x17'));var config=require(_0xc0c2('0x18'));var licenseUtil=require(_0xc0c2('0x19'));var db=require(_0xc0c2('0x1a'))['db'];function respondWithStatusCode(_0x202c8f,_0x3808e9){_0x3808e9=_0x3808e9||0xcc;return function(_0x302c1a){if(_0x302c1a){return _0x202c8f['sendStatus'](_0x3808e9);}return _0x202c8f['status'](_0x3808e9)['end']();};}function respondWithResult(_0x10a453,_0x29b40a){_0x29b40a=_0x29b40a||0xc8;return function(_0x39f3c0){if(_0x39f3c0){return _0x10a453['status'](_0x29b40a)[_0xc0c2('0x1b')](_0x39f3c0);}};}function respondWithFilteredResult(_0x2a8ded,_0x3a6b26){return function(_0x517a12){if(_0x517a12){var _0xa06763=typeof _0x3a6b26[_0xc0c2('0x1c')]===_0xc0c2('0x1d')&&typeof _0x3a6b26[_0xc0c2('0x1e')]===_0xc0c2('0x1d');var _0x221b8f=_0x517a12[_0xc0c2('0x1f')];var _0x105aa7=_0xa06763?0x0:_0x3a6b26[_0xc0c2('0x1c')];var _0x278eb8=_0xa06763?_0x517a12[_0xc0c2('0x1f')]:_0x3a6b26[_0xc0c2('0x1c')]+_0x3a6b26[_0xc0c2('0x1e')];var _0x563121;if(_0x278eb8>=_0x221b8f){_0x278eb8=_0x221b8f;_0x563121=0xc8;}else{_0x563121=0xce;}_0x2a8ded[_0xc0c2('0x20')](_0x563121);return _0x2a8ded['set'](_0xc0c2('0x21'),_0x105aa7+'-'+_0x278eb8+'/'+_0x221b8f)['json'](_0x517a12);}return null;};}function patchUpdates(_0x2caa30){return function(_0x1f2494){try{jsonpatch[_0xc0c2('0x22')](_0x1f2494,_0x2caa30,!![]);}catch(_0x4d15db){return BPromise[_0xc0c2('0x23')](_0x4d15db);}return _0x1f2494[_0xc0c2('0x24')]();};}function saveUpdates(_0x199e57,_0x363b5e){return function(_0x1cff95){if(_0x1cff95){return _0x1cff95[_0xc0c2('0x25')](_0x199e57)['then'](function(_0x57375d){return _0x57375d;});}return null;};}function removeEntity(_0x11ccd6,_0x1232e0){return function(_0x3e5d3a){if(_0x3e5d3a){return _0x3e5d3a[_0xc0c2('0x26')]()[_0xc0c2('0x27')](function(){_0x11ccd6[_0xc0c2('0x20')](0xcc)['end']();});}};}function handleEntityNotFound(_0x4c4673,_0x4e14e3){return function(_0x335b74){if(!_0x335b74){_0x4c4673[_0xc0c2('0x28')](0x194);}return _0x335b74;};}function handleError(_0x4ac1c6,_0x5cd504){_0x5cd504=_0x5cd504||0x1f4;return function(_0x37b673){logger[_0xc0c2('0x29')](_0x37b673[_0xc0c2('0x2a')]);if(_0x37b673[_0xc0c2('0x2b')]){delete _0x37b673['name'];}_0x4ac1c6[_0xc0c2('0x20')](_0x5cd504)[_0xc0c2('0x2c')](_0x37b673);};}exports[_0xc0c2('0x2d')]=function(_0x5f5441,_0x1b36ba){var _0x1f41dc={},_0x51a6df={},_0x4ce71f={'count':0x0,'rows':[]};var _0x481786=_[_0xc0c2('0x2e')](db[_0xc0c2('0x2f')]['rawAttributes'],function(_0x4f685c){return{'name':_0x4f685c[_0xc0c2('0x30')],'type':_0x4f685c['type'][_0xc0c2('0x31')]};});_0x51a6df[_0xc0c2('0x32')]=_[_0xc0c2('0x2e')](_0x481786,_0xc0c2('0x2b'));_0x51a6df[_0xc0c2('0x33')]=_[_0xc0c2('0x34')](_0x5f5441['query']);_0x51a6df[_0xc0c2('0x35')]=_[_0xc0c2('0x36')](_0x51a6df['model'],_0x51a6df['query']);_0x1f41dc[_0xc0c2('0x37')]=_[_0xc0c2('0x36')](_0x51a6df[_0xc0c2('0x32')],qs[_0xc0c2('0x38')](_0x5f5441['query']['fields']));_0x1f41dc[_0xc0c2('0x37')]=_0x1f41dc[_0xc0c2('0x37')][_0xc0c2('0x39')]?_0x1f41dc[_0xc0c2('0x37')]:_0x51a6df[_0xc0c2('0x32')];if(!_0x5f5441[_0xc0c2('0x33')][_0xc0c2('0x3a')]('nolimit')){_0x1f41dc['limit']=qs[_0xc0c2('0x1e')](_0x5f5441[_0xc0c2('0x33')][_0xc0c2('0x1e')]);_0x1f41dc[_0xc0c2('0x1c')]=qs[_0xc0c2('0x1c')](_0x5f5441[_0xc0c2('0x33')][_0xc0c2('0x1c')]);}_0x1f41dc[_0xc0c2('0x3b')]=qs[_0xc0c2('0x3c')](_0x5f5441[_0xc0c2('0x33')]['sort']);_0x1f41dc['where']=qs[_0xc0c2('0x35')](_['pick'](_0x5f5441[_0xc0c2('0x33')],_0x51a6df['filters']),_0x481786);if(_0x5f5441[_0xc0c2('0x33')][_0xc0c2('0x3d')]){_0x1f41dc['where']=_['merge'](_0x1f41dc[_0xc0c2('0x3e')],{'$or':_[_0xc0c2('0x2e')](_0x481786,function(_0x420115){if(_0x420115[_0xc0c2('0x3f')]!==_0xc0c2('0x40')){var _0x386c08={};_0x386c08[_0x420115['name']]={'$like':'%'+_0x5f5441[_0xc0c2('0x33')][_0xc0c2('0x3d')]+'%'};return _0x386c08;}})});}_0x1f41dc=_[_0xc0c2('0x41')]({},_0x1f41dc,_0x5f5441['options']);var _0x5311c4={'where':_0x1f41dc['where']};return db[_0xc0c2('0x2f')][_0xc0c2('0x1f')](_0x5311c4)['then'](function(_0x6d817d){_0x4ce71f[_0xc0c2('0x1f')]=_0x6d817d;if(_0x5f5441[_0xc0c2('0x33')][_0xc0c2('0x42')]){_0x1f41dc['include']=[{'all':!![]}];}return db['FreshsalesField'][_0xc0c2('0x43')](_0x1f41dc);})[_0xc0c2('0x27')](function(_0x4bd4b3){_0x4ce71f[_0xc0c2('0x44')]=_0x4bd4b3;return _0x4ce71f;})[_0xc0c2('0x27')](respondWithFilteredResult(_0x1b36ba,_0x1f41dc))[_0xc0c2('0x45')](handleError(_0x1b36ba,null));};exports[_0xc0c2('0x46')]=function(_0x177cb6,_0x49dca4){var _0x4aca7c={'raw':!![],'where':{'id':_0x177cb6[_0xc0c2('0x47')]['id']}},_0x5d133a={};_0x5d133a['model']=_[_0xc0c2('0x34')](db[_0xc0c2('0x2f')][_0xc0c2('0x48')]);_0x5d133a[_0xc0c2('0x33')]=_[_0xc0c2('0x34')](_0x177cb6[_0xc0c2('0x33')]);_0x5d133a[_0xc0c2('0x35')]=_[_0xc0c2('0x36')](_0x5d133a[_0xc0c2('0x32')],_0x5d133a[_0xc0c2('0x33')]);_0x4aca7c[_0xc0c2('0x37')]=_[_0xc0c2('0x36')](_0x5d133a['model'],qs[_0xc0c2('0x38')](_0x177cb6[_0xc0c2('0x33')][_0xc0c2('0x38')]));_0x4aca7c[_0xc0c2('0x37')]=_0x4aca7c['attributes'][_0xc0c2('0x39')]?_0x4aca7c['attributes']:_0x5d133a['model'];if(_0x177cb6[_0xc0c2('0x33')][_0xc0c2('0x42')]){_0x4aca7c[_0xc0c2('0x49')]=[{'all':!![]}];}_0x4aca7c=_[_0xc0c2('0x41')]({},_0x4aca7c,_0x177cb6['options']);return db['FreshsalesField'][_0xc0c2('0x4a')](_0x4aca7c)[_0xc0c2('0x27')](handleEntityNotFound(_0x49dca4,null))[_0xc0c2('0x27')](respondWithResult(_0x49dca4,null))[_0xc0c2('0x45')](handleError(_0x49dca4,null));};exports[_0xc0c2('0x4b')]=function(_0x4d7bc3,_0x3ac87e){return db[_0xc0c2('0x2f')][_0xc0c2('0x4b')](_0x4d7bc3['body'],{})[_0xc0c2('0x27')](respondWithResult(_0x3ac87e,0xc9))['catch'](handleError(_0x3ac87e,null));};exports[_0xc0c2('0x25')]=function(_0x31344a,_0x3212ff){if(_0x31344a[_0xc0c2('0x4c')]['id']){delete _0x31344a[_0xc0c2('0x4c')]['id'];}return db['FreshsalesField'][_0xc0c2('0x4a')]({'where':{'id':_0x31344a[_0xc0c2('0x47')]['id']}})[_0xc0c2('0x27')](handleEntityNotFound(_0x3212ff,null))[_0xc0c2('0x27')](saveUpdates(_0x31344a[_0xc0c2('0x4c')],null))[_0xc0c2('0x27')](respondWithResult(_0x3212ff,null))['catch'](handleError(_0x3212ff,null));};exports['destroy']=function(_0x31997e,_0x2e93f7){return db[_0xc0c2('0x2f')]['find']({'where':{'id':_0x31997e[_0xc0c2('0x47')]['id']}})[_0xc0c2('0x27')](handleEntityNotFound(_0x2e93f7,null))[_0xc0c2('0x27')](removeEntity(_0x2e93f7,null))[_0xc0c2('0x45')](handleError(_0x2e93f7,null));};
\ No newline at end of file