Package org.openwms.tms.api
Interface TransportOrderApi
- All Known Implementing Classes:
TransportationFacade
@FeignClient(name="tms-service",
dismiss404=true,
qualifiers="transportOrderApi")
public interface TransportOrderApi
A TransportOrderApi is a part of the Transportation Service' public RESTful API.
- Author:
- Heiko Scherrer
-
Method Summary
Modifier and TypeMethodDescriptionvoid
changeState
(String pKey, String state) Request to change the state of an existingTransportOrder
.void
Create aTransportOrder
for aTransportUnit
identified by the givenbarcode
to the giventarget
.void
Create aTransportOrder
for aTransportUnit
identified by the givenbarcode
to the giventarget
and the givenpriority
.Find and return allTransportOrder
s in a particularstate
for theTransportUnit
with the givenbarcode
.findByPKey
(String pKey) Find and return aTransportOrder
identified by its persistent key.void
updateTO
(String pKey, UpdateTransportOrderVO transportOrder) Request to update an existingTransportOrder
.
-
Method Details
-
findBy
@GetMapping(value="/v1/transport-orders", params={"barcode","state"}) List<TransportOrderVO> findBy(@RequestParam("barcode") String barcode, @RequestParam("state") String state) Find and return allTransportOrder
s in a particularstate
for theTransportUnit
with the givenbarcode
.- Parameters:
barcode
- The business identifier of the TransportUnitstate
- The TransportOrder state- Returns:
- A List implementation of the result instances, never null
-
findByPKey
@GetMapping("/v1/transport-orders/{pKey}") TransportOrderVO findByPKey(@PathVariable("pKey") String pKey) Find and return aTransportOrder
identified by its persistent key.- Parameters:
pKey
- The persistent key of the TransportOrder (not the primary key)- Returns:
- The instance
- Throws:
org.ameba.exception.NotFoundException
- if no TransportOrder with that id exists
-
createTO
@PostMapping(value="/v1/transport-orders", params={"barcode","target"}) @ResponseStatus(CREATED) void createTO(@RequestParam("barcode") String barcode, @RequestParam("target") String target) Create aTransportOrder
for aTransportUnit
identified by the givenbarcode
to the giventarget
.- Parameters:
barcode
- The business identifier of the TransportUnittarget
- Either a Location of a LocationGroup
-
createTO
@PostMapping(value="/v1/transport-orders", params={"barcode","target"}) @ResponseStatus(CREATED) void createTO(@RequestParam("barcode") String barcode, @RequestParam("target") String target, @RequestParam(value="priority",required=false) String priority) Create aTransportOrder
for aTransportUnit
identified by the givenbarcode
to the giventarget
and the givenpriority
.- Parameters:
barcode
- The business identifier of the TransportUnittarget
- Either a Location of a LocationGrouppriority
- The priority of the TransportOrder
-
changeState
@PostMapping(value="/v1/transport-orders/{pKey}", params="state") void changeState(@PathVariable("pKey") String pKey, @RequestParam("state") String state) Request to change the state of an existingTransportOrder
.- Parameters:
pKey
- The persistent key of the TransportOrder (not the primary key)state
- The requested TransportOrder state
-
updateTO
@PatchMapping("/v1/transport-orders/{pKey}") @ResponseStatus(NO_CONTENT) void updateTO(@PathVariable("pKey") String pKey, @RequestBody UpdateTransportOrderVO transportOrder) Request to update an existingTransportOrder
.- Parameters:
pKey
- The persistent key of the TransportOrder (not the primary key)transportOrder
- The minimal necessary structure of the change set
-