7bdd8ee684fcf85c2fb880825eb9e1f307b04221
[motion2.git] / server / api / intSalesforceField / intSalesforceField.model.js
1 // *************************************************************************
2 // *                                                                       *
3 // * xCALLY Motion -  The Omnichannel Contact Center                       *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved                     *
5 // *                                                                       *
6 // *************************************************************************
7 // *                                                                       *
8 // * Email: info@xcally.com                                                *
9 // * Website: https://www.xcally.com                                       *
10 // *                                                                       *
11 // *************************************************************************
12 // *                                                                       *
13 // * The SOFTWARE PRODUCT is protected by copyright laws and international *
14 // * copyright treaties, as well as other intellectual property laws and   *
15 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                         *
16 // *                                                                       *
17 // *************************************************************************
18 var _0x28eb=['request-promise','path','exports','define','SalesforceField','int_salesforce_fields','salesforce_unique_index','idField','FieldId','api'];(function(_0x5cc48f,_0x491bad){var _0x23ead9=function(_0x38d773){while(--_0x38d773){_0x5cc48f['push'](_0x5cc48f['shift']());}};_0x23ead9(++_0x491bad);}(_0x28eb,0x1f3));var _0xb28e=function(_0x439c17,_0x8de656){_0x439c17=_0x439c17-0x0;var _0x43d72b=_0x28eb[_0x439c17];return _0x43d72b;};'use strict';var _=require('lodash');var util=require('util');var logger=require('../../config/logger')(_0xb28e('0x0'));var moment=require('moment');var BPromise=require('bluebird');var rp=require(_0xb28e('0x1'));var fs=require('fs');var path=require(_0xb28e('0x2'));var rimraf=require('rimraf');var config=require('../../config/environment');var attributes=require('./intSalesforceField.attributes');module[_0xb28e('0x3')]=function(_0x31d99b,_0x1b3f0e){return _0x31d99b[_0xb28e('0x4')](_0xb28e('0x5'),attributes,{'tableName':_0xb28e('0x6'),'paranoid':![],'indexes':[{'name':_0xb28e('0x7'),'fields':[_0xb28e('0x8'),_0xb28e('0x9')],'unique':!![]}],'timestamps':!![]});};