system.mes.productionOrder.getAllProductionOrders
Description
Retrieves a list of all Production Orders records in the system.
Syntax
system.mes.productionOrder.getAllProductionOrders()
Parameters
| Parameter | Type | Nullable | Description |
|---|---|---|---|
| None | - | - | This method does not take any parameters. |
Returns
Returns a list of JSON objects representing all production orders.
| Name | Type | Description |
|---|---|---|
name | String | The name of the production order. |
productId | String (ULID) | The ULID of the material produce to be produced. |
locationId | String (ULID) | The ULID of the location associated with this production order. |
status | String | The status of the production order. (e.g., IDLE, SCHEDULED, RUNNING, PAUSED, STOPPED, CLOSED, CANCELLED). |
schedulePriority | String | The schedule priority of the production order (e.g., LOW, NORMAL, HIGH, URGENT). |
quantity | Double | The total quantity to be produced in this production order. |
quantityProduced | Double | The quantity that has been already produced in this production order. |
quantityScheduled | Double | The quantity that has been scheduled to be produced in this production order. |
startDate | Instant | The date this production order started. |
endDate | Instant | The date this production order ended. |
dueDate | Instant | The date this production order is due. |
unitOfMeasureId | String (ULID) | The ULID of the unit of measure for this production order. |
shiftRecordId | String (ULID) | The ULID of the shift the production order started in. |
id | String (ULID) | The ULID of the production order. |
notes | String | Notes related to the production order. |
enabled | Boolean | Indicates if the production order is active and enabled. |
spare1 | String | Additional field for user-defined context. |
spare2 | String | Additional field for user-defined context. |
spare3 | String | Additional field for user-defined context. |
Code Examples
# Retrieve all production orders
allProductionOrders = system.mes.productionOrder.getAllProductionOrders()
# Output the list of production orders
print(allProductionOrders)