Definition at line 36 of file api_mos.class.php.
◆ _cleanObjectDatas()
Mos::_cleanObjectDatas |
( |
|
$object | ) |
|
|
protected |
Clean sensible object datas.
- Parameters
-
Object | $object | Object to clean |
- Returns
- Object Object with cleaned properties
Reimplemented from DolibarrApi.
Definition at line 649 of file api_mos.class.php.
◆ _validate()
Validate fields before create or update object.
- Parameters
-
array | $data | Array of data to validate |
- Returns
- array
- Exceptions
-
Definition at line 712 of file api_mos.class.php.
◆ delete()
◆ get()
Get properties of a MO object.
Return an array with MO informations
- Parameters
-
- Returns
- array|mixed data without useless information
@url GET {id}
- Exceptions
-
Definition at line 64 of file api_mos.class.php.
◆ index()
Mos::index |
( |
|
$sortfield = "t.rowid" , |
|
|
|
$sortorder = 'ASC' , |
|
|
|
$limit = 100 , |
|
|
|
$page = 0 , |
|
|
|
$sqlfilters = '' |
|
) |
| |
List Mos.
Get a list of MOs
- Parameters
-
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.ref:like:'SO-%') and (t.date_creation:<:'20160101')" |
- Returns
- array Array of order objects
- Exceptions
-
Definition at line 97 of file api_mos.class.php.
◆ post()
Mos::post |
( |
|
$request_data = null | ) |
|
Create MO object.
- Parameters
-
array | $request_data | Request datas |
- Returns
- int ID of MO
Definition at line 195 of file api_mos.class.php.
◆ produceAndConsume()
Mos::produceAndConsume |
( |
|
$id, |
|
|
|
$request_data = null |
|
) |
| |
Produce and consume.
Example: { "inventorylabel": "Produce and consume using API", "inventorycode": "PRODUCEAPI-YY-MM-DD", "autoclose": 1, "arraytoconsume": [], "arraytoproduce": [] }
- Parameters
-
int | $id | ID of state |
array | $request_data | Request datas |
@url POST {id}/produceandconsume
- Returns
- int ID of MO
Definition at line 301 of file api_mos.class.php.
◆ put()
Mos::put |
( |
|
$id, |
|
|
|
$request_data = null |
|
) |
| |
Update MO.
- Parameters
-
int | $id | Id of MO to update |
array | $request_data | Datas |
- Returns
- int
Definition at line 220 of file api_mos.class.php.
The documentation for this class was generated from the following file: