Org

Functions

#

fetch() → {Org}

Fetch Org

object

Org
Example

SampleCopycopied

var org = ZDK.Apps.CRM.Org.fetch();

#

enableMultiCurrency(Currency) → {CRMResponses}

Enable Multi Currency

Parameters:
Name Type Description
Currency Currencies

object

response object

CRMResponses
Example

SampleCopycopied

var currency = new ZDK.Apps.CRM.Org.Models.Currencies();
currency.prefix_sybmol = true;
currency.name = "Algerian Dinar - DZD";
currency.iso_code = "DZD";
currency.symbol = "DA";
currency.exchange_rate = "1.00000000";
currency.format = {"decimal_separator": "Period", "thousand_separator": "Comma", "decimal_places": "2"};
var response = ZDK.Apps.CRM.Org.enableMultiCurrency(currency);

#

updateHomeCurrency(Currency) → {CRMResponses}

Update Home Currency

Parameters:
Name Type Description
Currency Currencies

object

response object

CRMResponses
Example

SampleCopycopied

var currency = new ZDK.Apps.CRM.Org.Models.Currencies();
currency.id = "423383000005267580";
currency.name = "US Dollar - USD";
currency.iso_code = "USD";
currency.symbol = "$";
currency.exchange_rate = "80.00000000";
currency.format = {"decimal_separator": "Period", "thousand_separator": "Comma", "decimal_places": "2"};
var response = ZDK.Apps.CRM.Org.updateHomeCurrency(currency);

#

fetchCurrencies() → {array}

Fetch Currencies

Currencies object array

array
Example

SampleCopycopied

var currencies = ZDK.Apps.CRM.Org.fetchCurrencies();

#

fetchCurrencyById(id) → {Currencies}

Fetch Currency By Id

Parameters:
Name Type Description
id String

id

Currency object

Currencies
Example

SampleCopycopied

var currencies = ZDK.Apps.CRM.Org.fetchCurrencyById("423383000005261048");

#

createCurrencies(arrayOfObjects) → {array}

Create Currencies

Parameters:
Name Type Description
arrayOfObjects Array.<Currencies>

object array

CRMResponses object array

array
Example

SampleCopycopied

var currency = new ZDK.Apps.CRM.Org.Models.Currencies();
currency.prefix_symol = true;
currency.name = "Algerian Dinar - DZD";
currency.iso_code = "DZD";
currency.symbol = "DA";
currency.exchange_rate = "1.00000000";
currency.format = {"decimal_separator": "Period", "thousand_separator": "Comma", "decimal_places": "2"};
var response = ZDK.Apps.CRM.Org.createCurrencies([currency]);

#

updateCurrencies() → {array}

Update Currencies

CRMResponses object array

  • @param {Currencies[]} arrayOfObjects object array
array
Example

SampleCopycopied

var currency = ZDK.Apps.CRM.Org.Models.fetchCurrencyById("423383000005261048");
currency.prefix_symol = true;
currency.exchange_rate = "1.30000400";
var response = ZDK.Apps.CRM.Org.updateCurrencies([currency]);

#

updateCurrencyById(Currency, currency_id) → {CRMResponses}

Update Currency By Id

Parameters:
Name Type Description
Currency Currencies

object

currency_id String

response object

CRMResponses
Example

SampleCopycopied

var currency = ZDK.Apps.CRM.Org.Models.fetchCurrencyById("423383000005261048");
currency.prefix_symol = true;
currency.exchange_rate = "1.30000400";
var response = ZDK.Apps.CRM.Org.updateCurrencyById(currency, "423383000005261048");