Express router for barcode related routes
Methods
(static) get/fabscan/roll/barcodes/:PO/details() → {barcodePoDetails}
Route for fetching the details from SAGE DB required to generate barcodes and store them in MySQL.
Parameters:
| Name | Type | Description |
|---|---|---|
req.params.PO |
String | The PO number that the user has entered |
req.query.itemNo |
String | The item number that the user has selected |
Returns:
The object that is returned module:routers/v7/fabscan/roll/barcodes~barcodePoDetails
- Type
- barcodePoDetails
(static) get/fabscan/roll/barcodes/:PO/items() → {Array.<poItemDetails>}
Route for fetching item details associated with a specific PO number from the MSSql DB
Parameters:
| Name | Type | Description |
|---|---|---|
req.params.PO |
String | The PO number that the user has entered |
Returns:
The list of item details returned module:routers/v7/fabscan/roll/barcodes~poItemDetails
- Type
- Array.<poItemDetails>
(static) get/fabscan/roll/barcodes/:PO/quantity() → {poQuantities}
Route for fetching the ordered PO quantity and the current PO quantity for which
barcodes have been generated
Parameters:
| Name | Type | Description |
|---|---|---|
req.params.PO |
String | The PO number |
req.query.ItemNo |
String | The item code |
Returns:
The fetched quantities module:routers/v7/fabscan/roll/barcodes~poQuantities
- Type
- poQuantities
(static) get/fabscan/roll/barcodes/:PO/validate() → {Boolean}
Route for validating the PO number against MSSql/Sage DB
Parameters:
| Name | Type | Description |
|---|---|---|
req.params.PO |
String | The PO number that the user has entered |
Returns:
- Type
- Boolean
(static) post/fabscan/roll/barcodes/:PO/details() → {Boolean}
Route for updating the MySQL DB with the barcodes generated and their associated data
Parameters:
| Name | Type | Description |
|---|---|---|
req.body.OC |
String | The OC number that was fetched from Sage DB |
req.params.PO |
String | The PO number that the user entered |
req.body.custName |
String | The buyer name fetched from Sage DB |
req.body.styleNo |
String | The style number that was fetched from Sage DB |
req.body.styleDesc |
String | The style description fetched from Sage DB |
req.body.itemNo |
String | The item number that the user has selected |
req.body.itemDesc |
String | The item description that the user has selected |
req.body.tableData |
Array.<poBarcodeData> | The array of barcode data that the user has entered module:routers/v7/fabscan/roll/barcodes~poBarcodeData |
req.body.name |
String | The name of the user who sent the request |
Returns:
- Type
- Boolean
Type Definitions
barcodePoDetails
Type:
- Object
Properties:
| Name | Type | Description |
|---|---|---|
barcodePoDetails.ocNumber |
String | The OC number |
barcodePoDetails.customer |
String | The customer name |
barcodePoDetails.styleNumber |
String | The style number |
barcodePoDetails.styleDescription |
String | The style description |
barcodePoDetails.itemDescription |
String | The item description |
poBarcodeData
Type:
- Object
Properties:
| Name | Type | Description |
|---|---|---|
poBarcodeData.roll |
String | The barcode roll number |
poBarcodeData.length |
Number | The roll length |
poBarcodeData.supplierRollNo |
String | The suppier roll number |
poItemDetails
Type:
- Object
Properties:
| Name | Type | Description |
|---|---|---|
poItemDetails.ITEMNO |
String | The item number |
poItemDetails.ITEMDESC |
String | The item description |
poQuantities
Type:
- Object
Properties:
| Name | Type | Description |
|---|---|---|
poQuantities.ordQty |
Number | The associated order quantity |
poQuantities.currQty |
Number | The associated current quantity |