Class CentralWarehouseService
java.lang.Object
overit.geocallapp.utilities.rs.common.PrivateService
overit.geocallapp.wfm.inventory.rs2.warehouse.central.CentralWarehouseService
@RestController
@RequestMapping("inventory/r2/warehouses/centrals")
@Resource(logging=true)
public class CentralWarehouseService
extends PrivateService
Services to manage central warehouses.
- Since:
- 19.0
- GCApi:
- rest
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.http.ResponseEntity<Void> Activates the required central warehouse by calling theCentralWarehouseActivateEvent.org.springframework.http.ResponseEntity<DTOCentralWarehouse> Retrieves the required central warehouse by calling theCentralWarehouseLoadEvent.org.springframework.http.ResponseEntity<PageResponse<DTOCentralWarehouse>> getCollection(@NotNull @Valid Page page, @Valid @NotNull DTOCentralWarehouseSearchFilter filter) Returns the collection of all the stored central warehouses by calling theCentralWarehouseSearchEvent.org.springframework.http.ResponseEntity<Void> patch(Long id, @Valid DTOCentralWarehouseUpdate dto) Updates the required central warehouse by calling theCentralWarehouseUpdateEvent.org.springframework.http.ResponseEntity<DTOIdentifier<Long>> Create a new central warehouse by calling theCentralWarehouseInsertEvent
-
Constructor Details
-
CentralWarehouseService
public CentralWarehouseService()
-
-
Method Details
-
getCollection
@GetMapping(produces="application/json") public org.springframework.http.ResponseEntity<PageResponse<DTOCentralWarehouse>> getCollection(@RequestParam("page") @NotNull @Valid @NotNull @Valid Page page, @RequestParam("filter") @Valid @NotNull @Valid @NotNull DTOCentralWarehouseSearchFilter filter) throws DAValidateException, DAException Returns the collection of all the stored central warehouses by calling theCentralWarehouseSearchEvent.- Parameters:
page- thePagethat will contain the paginated resultfilter- theDTOCentralWarehouseSearchFilter- Returns:
- the
ResponseEntitycontaining the collection ofDTOCentralWarehouse - Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
get
@GetMapping(value="{id:[0-9]+}", produces="application/json") public org.springframework.http.ResponseEntity<DTOCentralWarehouse> get(@PathVariable("id") Long id, @RequestParam(required=false,name="language",defaultValue="user") String language) throws DAValidateException, DAException Retrieves the required central warehouse by calling theCentralWarehouseLoadEvent.- Parameters:
id- central warehouse idlanguage- the language of the user- Returns:
- the
ResponseEntitycontaining the loadedDTOCentralWarehouse - Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
post
@PostMapping(consumes="application/json", produces="application/json") public org.springframework.http.ResponseEntity<DTOIdentifier<Long>> post(@Valid @RequestBody @Valid DTOCentralWarehouseInsert dto) throws DAValidateException, DAException Create a new central warehouse by calling theCentralWarehouseInsertEvent- Parameters:
dto- theDTOCentralWarehouseInsert- Returns:
- the
ResponseEntitycontaining the created central warehouse id - Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
patch
@PatchMapping(value="{id:[0-9]+}", consumes="application/json", produces="application/json") public org.springframework.http.ResponseEntity<Void> patch(@PathVariable("id") Long id, @Valid @RequestBody @Valid DTOCentralWarehouseUpdate dto) throws DAValidateException, DAException Updates the required central warehouse by calling theCentralWarehouseUpdateEvent.- Parameters:
id- the central warehouse iddto- theDTOCentralWarehouseUpdate- Returns:
- the
ResponseEntity - Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
activate
@PostMapping(value="{id:[0-9]+}/actions/activate", produces="application/json") public org.springframework.http.ResponseEntity<Void> activate(@PathVariable("id") Long id) throws DAValidateException, DAException Activates the required central warehouse by calling theCentralWarehouseActivateEvent.- Parameters:
id- the central warehouse id- Returns:
- the
ResponseEntity - Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-