dolibarr 19.0.3
|
Public Member Functions | |
__construct () | |
Constructor. | |
index ($sortfield="t.rowid", $sortorder='ASC', $limit=100, $page=0, $sqlfilters='', $properties='') | |
List Currencies. | |
get ($id) | |
Get properties of a Currency object. | |
getByCode ($code) | |
Get properties of a Currency object by code. | |
getRates ($id) | |
List Currency rates. | |
post ($request_data=null) | |
Create Currency object. | |
put ($id, $request_data=null) | |
Update Currency. | |
delete ($id) | |
Delete Currency. | |
updateRate ($id, $request_data=null) | |
Update Currency rate @url PUT {id}/rates. | |
Public Member Functions inherited from DolibarrApi | |
__construct ($db, $cachedir='', $refreshCache=false) | |
Constructor. | |
Protected Member Functions | |
_cleanObjectDatas ($object) | |
Clean sensible object datas. | |
_cleanObjectDatasRate ($object) | |
Clean sensible MultiCurrencyRate object datas. | |
Protected Member Functions inherited from DolibarrApi | |
_checkValForAPI ($field, $value, $object) | |
Check and convert a string depending on its type/name. | |
_filterObjectProperties ($object, $properties) | |
Filter properties that will be returned on object. | |
_checkFilters ($sqlfilters, &$error='') | |
Return if a $sqlfilters parameter is valid Function no more used. | |
Additional Inherited Members | |
Static Protected Member Functions inherited from DolibarrApi | |
static | _checkAccessToResource ($resource, $resource_id=0, $dbtablename='', $feature2='', $dbt_keyfield='fk_soc', $dbt_select='rowid') |
Check access by user to a given resource. | |
static | _forge_criteria_callback ($matches) |
Function to forge a SQL criteria from a Generic filter string. | |
Definition at line 29 of file api_multicurrencies.class.php.
|
protected |
Clean sensible object datas.
MultiCurrency | $object | Object to clean |
Reimplemented from DolibarrApi.
Definition at line 348 of file api_multicurrencies.class.php.
References _cleanObjectDatasRate().
Referenced by get(), getByCode(), index(), and updateRate().
|
protected |
Clean sensible MultiCurrencyRate object datas.
MultiCurrency | $object | Object to clean |
Definition at line 374 of file api_multicurrencies.class.php.
Referenced by _cleanObjectDatas(), and getRates().
MultiCurrencies::delete | ( | $id | ) |
Delete Currency.
int | $id | Currency ID |
RestException |
Definition at line 283 of file api_multicurrencies.class.php.
MultiCurrencies::get | ( | $id | ) |
Get properties of a Currency object.
Return an array with Currency informations
int | $id | ID of Currency |
RestException |
Definition at line 119 of file api_multicurrencies.class.php.
References _cleanObjectDatas().
MultiCurrencies::getByCode | ( | $code | ) |
Get properties of a Currency object by code.
Return an array with Currency informations @url GET /bycode/{code}
string | $code | Code of Currency (ex: EUR) |
RestException |
Definition at line 144 of file api_multicurrencies.class.php.
References _cleanObjectDatas().
MultiCurrencies::getRates | ( | $id | ) |
List Currency rates.
Get a list of Currency rates
@url GET {id}/rates
int | $id | ID of Currency |
RestException |
Definition at line 169 of file api_multicurrencies.class.php.
References _cleanObjectDatasRate().
MultiCurrencies::index | ( | $sortfield = "t.rowid", | |
$sortorder = 'ASC', | |||
$limit = 100, | |||
$page = 0, | |||
$sqlfilters = '', | |||
$properties = '' ) |
List Currencies.
Get a list of Currencies
string | $sortfield | Sort field |
string | $sortorder | Sort order |
int | $limit | Limit for list |
int | $page | Page number |
string | $sqlfilters | Other criteria to filter answers separated by a comma. Syntax example "(t.product_id:=:1) and (t.date_creation:<:'20160101')" |
string | $properties | Restrict the data returned to theses properties. Ignored if empty. Comma separated list of properties names |
RestException |
Definition at line 56 of file api_multicurrencies.class.php.
References DolibarrApi\_checkFilters(), _cleanObjectDatas(), and DolibarrApi\_filterObjectProperties().
MultiCurrencies::post | ( | $request_data = null | ) |
Create Currency object.
array | $request_data | Request data |
RestException |
Definition at line 200 of file api_multicurrencies.class.php.
MultiCurrencies::put | ( | $id, | |
$request_data = null ) |
Update Currency.
int | $id | Id of Currency to update |
array | $request_data | Datas |
RestException |
Definition at line 244 of file api_multicurrencies.class.php.
MultiCurrencies::updateRate | ( | $id, | |
$request_data = null ) |
Update Currency rate @url PUT {id}/rates.
int | $id | Currency ID |
array | $request_data | Request data |
RestException |
Definition at line 317 of file api_multicurrencies.class.php.
References _cleanObjectDatas().