| dolibarr 21.0.0-beta
    | 


| 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 30 of file api_multicurrencies.class.php.
| 
 | protected | 
Clean sensible object datas.
| MultiCurrency | $object | Object to clean | 
Reimplemented from DolibarrApi.
Definition at line 358 of file api_multicurrencies.class.php.
References $object, and _cleanObjectDatasRate().
Referenced by get(), getByCode(), index(), and updateRate().
| 
 | protected | 
Clean sensible MultiCurrencyRate object datas.
| MultiCurrency | $object | Object to clean | 
Definition at line 384 of file api_multicurrencies.class.php.
References $object.
Referenced by _cleanObjectDatas(), and getRates().
| MultiCurrencies::delete | ( | $id | ) | 
Delete Currency.
| int | $id | Currency ID | 
| RestException | 
Definition at line 293 of file api_multicurrencies.class.php.
References $id.
| MultiCurrencies::get | ( | $id | ) | 
Get properties of a Currency object.
Return an array with Currency information
| int | $id | ID of Currency | 
| RestException | 
Definition at line 120 of file api_multicurrencies.class.php.
References $id, and _cleanObjectDatas().
| MultiCurrencies::getByCode | ( | $code | ) | 
Get properties of a Currency object by code.
Return an array with Currency information @url GET /bycode/{code}
| string | $code | Code of Currency (ex: EUR) | 
| RestException | 
Definition at line 145 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 170 of file api_multicurrencies.class.php.
References $id, and _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 these properties. Ignored if empty. Comma separated list of properties names | 
| RestException | 
Definition at line 57 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 201 of file api_multicurrencies.class.php.
References DolibarrApi\_checkValForAPI(), and sanitizeVal().
| MultiCurrencies::put | ( | $id, | |
| $request_data = null ) | 
Update Currency.
| int | $id | Id of Currency to update | 
| array | $request_data | Datas | 
| RestException | 
Definition at line 254 of file api_multicurrencies.class.php.
References $id, DolibarrApi\_checkValForAPI(), and sanitizeVal().
| 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 327 of file api_multicurrencies.class.php.
References $id, and _cleanObjectDatas().