Class ForecastActivityService
java.lang.Object
overit.geocallapp.utilities.rs.common.PrivateService
overit.geocallapp.wfm.forecastcapacity.rs1.forecast.activity.forecastactivity.ForecastActivityService
@RestController
@RequestMapping("planning/forecast-capacity/r1/activity-forecasts/{activityForecastId:[0-9]+}/activities")
@Resource(logging=true)
public class ForecastActivityService
extends PrivateService
Services to manage a
BOForecastActivity object. - Since:
- 15.0
- GCApi:
- rest
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.http.ResponseEntity<Void> Deletes the requiredBOForecastActivityobject from a givenBOActivityForecastHeaderobject by calling theForecastActivityDeleteEventeventorg.springframework.http.ResponseEntity<DTOForecastActivity> get(Long forecastHeaderId, Long id, Collection<String> fields) Retrieves the requiredBOForecastActivityobject by calling theForecastActivityLoadEventeventorg.springframework.http.ResponseEntity<PageResponse<DTOForecastActivity>> getCollection(@Valid Page page, String order, Collection<String> fields, Long forecastHeaderId, @Valid DTOForecastActivitySearchFilter filter) Returns the collection of all the storedBOForecastActivityobjects by calling theForecastActivitySearchEventeventorg.springframework.http.ResponseEntity<Void> importFromCo(Long forecastHeaderId, @Valid DTOForecastActivityImportFromCO dto) Import a real activity as aBOForecastActivityobject by calling theForecastActivityImportOperationActivityEventeventorg.springframework.http.ResponseEntity<Void> patch(Long forecastHeaderId, Long id, @Valid DTOForecastActivityUpdate dto) Updates aBOForecastActivityobject by calling theForecastActivityUpdateEvent.org.springframework.http.ResponseEntity<DTOIdentifier<Long>> post(Long forecastHeaderId, @Valid DTOForecastActivityInsert dto) Creates a newBOForecastActivityobject by calling theForecastActivityInsertEventevent
-
Constructor Details
-
ForecastActivityService
public ForecastActivityService()
-
-
Method Details
-
getCollection
@GetMapping(produces="application/json") public org.springframework.http.ResponseEntity<PageResponse<DTOForecastActivity>> getCollection(@RequestParam("_page") @Valid @Valid Page page, @RequestParam(required=false,value="_order") String order, @RequestParam(required=false,value="_fields") Collection<String> fields, @PathVariable("activityForecastId") Long forecastHeaderId, @Valid @Valid DTOForecastActivitySearchFilter filter) throws DAValidateException, DAException Returns the collection of all the storedBOForecastActivityobjects by calling theForecastActivitySearchEventevent- Parameters:
forecastHeaderId- theBOForecastActivity's forecastHeader fieldfilter- theDTOForecastActivitySearchFilterobject- Returns:
- the collection of
DTOForecastActivitys - Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
get
@GetMapping(value="{activityId:[0-9]+}", produces="application/json") public org.springframework.http.ResponseEntity<DTOForecastActivity> get(@PathVariable("activityForecastId") Long forecastHeaderId, @PathVariable("activityId") Long id, @RequestParam(required=false,value="_fields") Collection<String> fields) throws DAValidateException, DAException Retrieves the requiredBOForecastActivityobject by calling theForecastActivityLoadEventevent- Parameters:
forecastHeaderId- theBOForecastActivityobject's forecastHeader fieldid- theBOForecastActivityobject's id field- Returns:
- the response containing the loaded
DTOForecastActivity - 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(@PathVariable("activityForecastId") Long forecastHeaderId, @Valid @RequestBody @Valid DTOForecastActivityInsert dto) throws DAValidateException, DAException Creates a newBOForecastActivityobject by calling theForecastActivityInsertEventevent- Parameters:
forecastHeaderId- theBOForecastActivityobject 's forecastHeader fielddto- theDTOForecastActivityInsertobject- Returns:
- the response containing the ID of the newly created
BOForecastActivity - Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
patch
@PatchMapping(value="{activityId:[0-9]+}", consumes="application/json", produces="application/json") public org.springframework.http.ResponseEntity<Void> patch(@PathVariable("activityForecastId") Long forecastHeaderId, @PathVariable("activityId") Long id, @Valid @RequestBody @Valid DTOForecastActivityUpdate dto) throws DAValidateException, DAException Updates aBOForecastActivityobject by calling theForecastActivityUpdateEvent.- Parameters:
forecastHeaderId- theBOForecastActivityobject's forecastHeader fieldid- the id of theBOForecastActivityobject to updatedto- theDTOForecastActivityUpdateobject- Returns:
- the standard response
- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
importFromCo
@PostMapping(value="import-from-operation-centers", consumes="application/json", produces="application/json") public org.springframework.http.ResponseEntity<Void> importFromCo(@PathVariable("activityForecastId") Long forecastHeaderId, @Valid @RequestBody @Valid DTOForecastActivityImportFromCO dto) throws DAValidateException, DAException Import a real activity as aBOForecastActivityobject by calling theForecastActivityImportOperationActivityEventevent- Parameters:
forecastHeaderId- theBOForecastActivityobject 's forecastHeader fielddto- theDTOForecastActivityImportFromCOobject- Returns:
- the standard response
- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
delete
@DeleteMapping(value="{activityId:[0-9]+}", produces="application/json") public org.springframework.http.ResponseEntity<Void> delete(@PathVariable("activityForecastId") Long forecastHeaderId, @PathVariable("activityId") Long id) throws DAValidateException, DAException Deletes the requiredBOForecastActivityobject from a givenBOActivityForecastHeaderobject by calling theForecastActivityDeleteEventevent- Parameters:
forecastHeaderId- theBOForecastActivityobject's forecastHeader fieldid- the id of theBOForecastActivityobject to delete- Returns:
- the DTO response
- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-