2019-06-10 06:13:55 +12:00
|
|
|
const Service = require('../service.js');
|
|
|
|
|
|
|
|
class Locale extends Service {
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Get User Locale
|
|
|
|
*
|
2019-10-09 17:16:38 +13:00
|
|
|
* /docs/references/locale/get-locale.md
|
2019-06-10 06:13:55 +12:00
|
|
|
*
|
|
|
|
* @throws Exception
|
|
|
|
* @return {}
|
|
|
|
*/
|
|
|
|
async getLocale() {
|
|
|
|
let path = '/locale';
|
|
|
|
|
|
|
|
return await this.client.call('get', path, {'content-type': 'application/json'},
|
|
|
|
{
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* List Countries
|
|
|
|
*
|
2019-10-09 17:16:38 +13:00
|
|
|
* /docs/references/locale/get-countires.md
|
2019-06-10 06:13:55 +12:00
|
|
|
*
|
|
|
|
* @throws Exception
|
|
|
|
* @return {}
|
|
|
|
*/
|
|
|
|
async getCountries() {
|
|
|
|
let path = '/locale/countries';
|
|
|
|
|
|
|
|
return await this.client.call('get', path, {'content-type': 'application/json'},
|
|
|
|
{
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* List EU Countries
|
|
|
|
*
|
2019-10-09 17:16:38 +13:00
|
|
|
* /docs/references/locale/get-countries-eu.md
|
2019-06-10 06:13:55 +12:00
|
|
|
*
|
|
|
|
* @throws Exception
|
|
|
|
* @return {}
|
|
|
|
*/
|
|
|
|
async getCountriesEU() {
|
|
|
|
let path = '/locale/countries/eu';
|
|
|
|
|
|
|
|
return await this.client.call('get', path, {'content-type': 'application/json'},
|
|
|
|
{
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* List Countries Phone Codes
|
|
|
|
*
|
2019-10-09 17:16:38 +13:00
|
|
|
* /docs/references/locale/get-countries-phones.md
|
2019-06-10 06:13:55 +12:00
|
|
|
*
|
|
|
|
* @throws Exception
|
|
|
|
* @return {}
|
|
|
|
*/
|
|
|
|
async getCountriesPhones() {
|
|
|
|
let path = '/locale/countries/phones';
|
|
|
|
|
|
|
|
return await this.client.call('get', path, {'content-type': 'application/json'},
|
|
|
|
{
|
|
|
|
});
|
|
|
|
}
|
2019-08-23 09:10:32 +12:00
|
|
|
|
|
|
|
/**
|
|
|
|
* List of currencies
|
|
|
|
*
|
2019-10-09 17:16:38 +13:00
|
|
|
* /docs/references/locale/get-currencies.md
|
2019-08-23 09:10:32 +12:00
|
|
|
*
|
|
|
|
* @throws Exception
|
|
|
|
* @return {}
|
|
|
|
*/
|
|
|
|
async getCurrencies() {
|
|
|
|
let path = '/locale/currencies';
|
|
|
|
|
|
|
|
return await this.client.call('get', path, {'content-type': 'application/json'},
|
|
|
|
{
|
|
|
|
});
|
|
|
|
}
|
2019-06-10 06:13:55 +12:00
|
|
|
}
|
|
|
|
|
|
|
|
module.exports = Locale;
|