mx.services
workOrder
Method Summary
| package | void |
addWorkOrderItem (numeric WORK_ORDER_ID, numeric PART_ID, numeric QTY)
|
| remote | query |
getWorkOrderDetail (numeric WORK_ORDER_ID)
|
| remote | query |
getWorkOrderItems (numeric WORK_ORDER_ID)
|
| remote | query |
getWorkOrders ()
|
| package | void |
removeWorkOrderItems (numeric WORK_ORDER_ID)
|
| remote | boolean |
updateWorkOrder (numeric WORK_ORDER_ID, string REPAIR_DATE, numeric REPAIR_TIME, numeric REPAIR_LENGTH, numeric REPAIR_BAY, string NOTES, array items)
|
Method Details
addWorkOrderItem
package void addWorkOrderItem (numeric WORK_ORDER_ID, numeric PART_ID, numeric QTY)
Adds an item to a work order
- Parameters
WORK_ORDER_ID- the unique id of the work order (int)PART_ID- unique id of the part (int)QTY- quantity of the part (int)
getWorkOrderDetail
remote query getWorkOrderDetail (numeric WORK_ORDER_ID)
Gets the details of a work order
- Parameters
WORK_ORDER_ID- the unique id of the work order (int)
- Returns
- a query of one row containing the detail of the work order
getWorkOrderItems
remote query getWorkOrderItems (numeric WORK_ORDER_ID)
Gets the invoice items for a work order
- Parameters
WORK_ORDER_ID- the unique id of the work order (int)
- Returns
- a query containing all items of the order ordered by PART_ID in ascending order
getWorkOrders
remote query getWorkOrders ()
Get all of the work orders that are active.
- Returns
- a query containing all active orders ordered by WORK_ORDER_ID in ascending order
removeWorkOrderItems
package void removeWorkOrderItems (numeric WORK_ORDER_ID)
Remove all of the work order items. This method is called before adding items to a work order
- Parameters
WORK_ORDER_ID- the unique id of the work order (int)
updateWorkOrder
remote boolean updateWorkOrder (numeric WORK_ORDER_ID, string REPAIR_DATE, numeric REPAIR_TIME,
numeric REPAIR_LENGTH, numeric REPAIR_BAY, string NOTES, array items)
Update the work order with the new info, including invoice items
- Parameters
WORK_ORDER_ID- the unique id of the work order (int)REPAIR_DATE-REPAIR_TIME-REPAIR_LENGTH-REPAIR_BAY-NOTES-items- an array containing invoice items. Each item is a structure with the following keys: PART_ID, QTY, IN_STOCK_DATE
- Returns
- a boolean indicating sucessful operation (always true)