Load Management
This page is auto-generated from cmd/web/routes.go.
Endpoint List
| Method | Path | Handler | Request |
|---|---|---|---|
| Post | /api/modules/create-load | handlers.Repo.CreateLoad | LoadRequest.LoadCreateRequest |
| Post | /api/modules/delete-load | handlers.Repo.DeleteLoad | requests.DeleteRequest |
| Post | /api/modules/list-load | handlers.Repo.ListLoad | requests.ListRequest |
| Post | /api/modules/list-load-category | handlers.Repo.ListLoadCategory | - |
| Post | /api/modules/list-load-dg-assessment | handlers.Repo.ListDGAssessments | - |
| Post | /api/modules/list-load-exemption-type | handlers.Repo.ListLoadExemptionType | - |
| Get | /api/modules/list-load-physical-type | handlers.Repo.ListLoadPhysicalType | - |
| Post | /api/modules/list-load-transport-unit | handlers.Repo.ListLoadTransportUnit | - |
| Post | /api/modules/list-load-unit | handlers.Repo.ListLoadUnit | - |
| Post | /api/modules/read-barcode-data-load | handlers.Repo.ReadLoadByBarcode | LoadRequest.LoadItemsByBarcodeRequest |
| Post | /api/modules/read-dg-content-load | handlers.Repo.ReadLoadContent | LoadRequest.LoadValue |
| Post | /api/modules/read-load | handlers.Repo.ReadLoad | requests.ReadRequest |
| Post | /api/modules/report-load | handlers.Repo.ReportLoad | - |
| Post | /api/modules/update-load | handlers.Repo.UpdateLoad | LoadRequest.LoadUpdateRequest |
Request Example: LoadRequest.LoadCreateRequest
{
"customer_id": 0,
"barcode": "string",
"stock_code": "string",
"stock_type_id": 0,
"shipment_category_id": 0,
"load_type_id": 0,
"load_description": "string",
"load_description_other": "string",
"transport_type_id": 0,
"physical_state_id": 0,
"is_dg": 0,
"un_no_id": "string",
"exemption_type_id": 0,
"exemption_description": "string",
"length": 0,
"width": 0,
"height": 0,
"weight": {},
"storage_code": "string",
"customs_code": "string",
"brand": "string",
"file_id": 0
}Fields:
| Field | Type | Required |
|---|---|---|
customer_id | int64 | no |
barcode | string | no |
stock_code | string | no |
stock_type_id | int64 | no |
shipment_category_id | int64 | no |
load_type_id | int64 | no |
load_description | string | no |
load_description_other | string | no |
transport_type_id | int64 | no |
physical_state_id | int64 | no |
is_dg | int | no |
un_no_id | string | no |
exemption_type_id | int | no |
exemption_description | string | no |
length | int | no |
width | int | no |
height | int | no |
weight | float64 | no |
storage_code | string | no |
customs_code | string | no |
brand | string | no |
file_id | int64 | no |
Request Example: requests.DeleteRequest
{
"id": 0
}Fields:
| Field | Type | Required |
|---|---|---|
id | int | yes |
Request Example: requests.ListRequest
{
"per_page": 0,
"page": 0,
"sort_column": "string",
"sort_order": "string"
}Fields:
| Field | Type | Required |
|---|---|---|
per_page | int | yes |
page | int | yes |
sort_column | string | no |
sort_order | string | no |
Request Example: LoadRequest.LoadItemsByBarcodeRequest
{
"barcode": "string"
}Fields:
| Field | Type | Required |
|---|---|---|
barcode | string | no |
Request Example: LoadRequest.LoadValue
{
"value": "string",
"key": "string"
}Fields:
| Field | Type | Required |
|---|---|---|
value | string | no |
key | string | no |
Request Example: requests.ReadRequest
{
"id": 0
}Fields:
| Field | Type | Required |
|---|---|---|
id | int | yes |
Request Example: LoadRequest.LoadUpdateRequest
{
"id": 0,
"customer_id": 0,
"barcode": "string",
"stock_code": "string",
"stock_type_id": 0,
"shipment_category_id": 0,
"load_type_id": 0,
"load_description": "string",
"load_description_other": "string",
"transport_type_id": 0,
"physical_state_id": 0,
"is_dg": 0,
"un_no_id": "string",
"exemption_type_id": 0,
"exemption_description": "string",
"length": 0,
"width": 0,
"height": 0,
"weight": {},
"storage_code": "string",
"customs_code": "string",
"brand": "string",
"file_id": 0
}Fields:
| Field | Type | Required |
|---|---|---|
id | int64 | no |
customer_id | int64 | no |
barcode | string | no |
stock_code | string | no |
stock_type_id | int64 | no |
shipment_category_id | int64 | no |
load_type_id | int64 | no |
load_description | string | no |
load_description_other | string | no |
transport_type_id | int64 | no |
physical_state_id | int64 | no |
is_dg | int | no |
un_no_id | string | no |
exemption_type_id | int | no |
exemption_description | string | no |
length | int | no |
width | int | no |
height | int | no |
weight | float64 | no |
storage_code | string | no |
customs_code | string | no |
brand | string | no |
file_id | int64 | no |
Response Examples
Create:
{
"status": "succeeded",
"message": "record created successfully",
"id": 1
}Delete:
{
"status": "succeeded",
"message": "deleted successfully"
}List:
{
"status": "succeeded",
"data": [ ],
"totalPage": 1,
"currentPage": 1,
"perPage": 10
}Read:
{
"status": "succeeded",
"data": { }
}Update:
{
"status": "succeeded",
"message": "updated successfully"
}Error (example):
{
"status": "invalid_request",
"message": "validation failed",
"errors": [ ]
}Last updated on