|
dolibarr 18.0.8
|
Class of dictionary of nature of product (used by imports) More...
Public Member Functions | |
| __construct ($db) | |
| Constructor. | |
| create ($user, $notrigger=0) | |
| Create object into database. | |
| fetch ($id, $code='') | |
| Load object in memory from database. | |
| fetchAll ($sortorder='', $sortfield='', $limit=0, $offset=0, array $filter=array(), $filtermode='AND') | |
| Load list of objects in memory from the database. | |
| update ($user=null, $notrigger=0) | |
| Update object into database. | |
| delete ($user, $notrigger=0) | |
| Delete object in database. | |
| getProductNatureFromCode ($code, $mode='code') | |
| Get unit from code. | |
Class of dictionary of nature of product (used by imports)
Definition at line 29 of file cproductnature.class.php.
| CProductNature::__construct | ( | $db | ) |
Constructor.
| DoliDb | $db | Database handler |
Definition at line 87 of file cproductnature.class.php.
| CProductNature::create | ( | $user, | |
| $notrigger = 0 ) |
Create object into database.
Definition at line 100 of file cproductnature.class.php.
References dol_syslog().
| CProductNature::delete | ( | $user, | |
| $notrigger = 0 ) |
Delete object in database.
Definition at line 300 of file cproductnature.class.php.
References dol_syslog().
| CProductNature::fetch | ( | $id, | |
| $code = '' ) |
Load object in memory from database.
| int | $id | Id of CUnit object to fetch (rowid) |
| string | $code | Code |
Definition at line 142 of file cproductnature.class.php.
| CProductNature::fetchAll | ( | $sortorder = '', | |
| $sortfield = '', | |||
| $limit = 0, | |||
| $offset = 0, | |||
| array | $filter = array(), | ||
| $filtermode = 'AND' ) |
Load list of objects in memory from the database.
| string | $sortorder | Sort Order |
| string | $sortfield | Sort field |
| int | $limit | limit |
| int | $offset | Offset |
| array | $filter | Filter array. Example array('field'=>'valueforlike', 'customurl'=>...) |
| string | $filtermode | Filter mode (AND or OR) |
Definition at line 194 of file cproductnature.class.php.
References dol_syslog().
| CProductNature::getProductNatureFromCode | ( | $code, | |
| $mode = 'code' ) |
Get unit from code.
| int | $code | code of unit |
| string | $mode | 0= id , short_label=Use short label as value, code=use code |
Definition at line 331 of file cproductnature.class.php.
References dol_getIdFromCode().
| CProductNature::update | ( | $user = null, | |
| $notrigger = 0 ) |
Update object into database.
Definition at line 265 of file cproductnature.class.php.
References dol_syslog().