Class BTTransferRequestCancel
java.lang.Object
overit.geocall.bl.BusinessTask<TransferRequestCancelEvent>
overit.geocallapp.utilities.core.bl.common.validexecution.ValidExecutionBusinessTask<TransferRequestCancelEvent>
overit.geocallapp.utilities.core.bl.common.validexecution.ValidPermissionBusinessTask<TransferRequestCancelEvent>
overit.geocallapp.wfm.inventory.bl.task.BTInventoryManagement<TransferRequestCancelEvent>
overit.geocallapp.wfm.inventory.bl.warehouse.transfer.request.task.BTTransferRequestCancel
- All Implemented Interfaces:
Serializable,Tool,ValidExecution
@Event(TransferRequestCancelEvent.class)
public class BTTransferRequestCancel
extends BTInventoryManagement<TransferRequestCancelEvent>
Business task in order to cancel a
When the
TransferRequest. When the
TransferRequestCancelEvent is launched
the BT notices the call and changes the TransferRequest state to
BOTransferRequestState.Values.CANCELLED basing on the event's input. - Since:
- 14.0
- See Also:
- GCApi:
- task
-
Field Summary
Fields inherited from class overit.geocallapp.utilities.core.bl.common.validexecution.ValidPermissionBusinessTask
LOG -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidexecute(TransferRequestCancelEvent event, PoolKit poolKit) Updates the state of the transfer request toBOTransferRequestState.Values.CANCELLED.booleanChecks if the execution is valid.protected voidnotifyStateChange(Long transferRequestId, PoolKit poolKit) Notifies the change of theTransferRequeststate.Prepares the filter data.Prepares the update data.protected voidupdate(TransferRequestCancelInput input, PoolKit poolKit) Updates the state of the currentTransferRequest.protected voidvalidateData(Long transferRequestId, PoolKit poolKit) Validates the data before the state change.Methods inherited from class overit.geocallapp.wfm.inventory.bl.task.BTInventoryManagement
checkValidExecutionMethods inherited from class overit.geocallapp.utilities.core.bl.common.validexecution.ValidPermissionBusinessTask
getException, throwExceptionIfInvalidMethods inherited from class overit.geocallapp.utilities.core.bl.common.validexecution.ValidExecutionBusinessTask
body, getEventMethods inherited from class overit.geocall.bl.BusinessTask
start, start, startAlone, startInBackground
-
Constructor Details
-
BTTransferRequestCancel
public BTTransferRequestCancel()
-
-
Method Details
-
execute
protected void execute(TransferRequestCancelEvent event, PoolKit poolKit) throws DAException, DAValidateException Updates the state of the transfer request toBOTransferRequestState.Values.CANCELLED.- Specified by:
executein classValidExecutionBusinessTask<TransferRequestCancelEvent>- Parameters:
event- theTransferRequestCancelEventpoolKit- thePoolKit- Throws:
DAException- the DA exceptionDAValidateException- the DA validate exception
-
validateData
protected void validateData(Long transferRequestId, PoolKit poolKit) throws DAValidateException, DAException Validates the data before the state change.- Parameters:
transferRequestId- theBOTransferRequestHeaderidpoolKit- thePoolKit- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
update
protected void update(TransferRequestCancelInput input, PoolKit poolKit) throws DAException, DAValidateException Updates the state of the currentTransferRequest.- Parameters:
input- theTransferRequestCancelInputpoolKit- thePoolKit- Throws:
DAException- the DA exceptionDAValidateException- the DA validate exception
-
prepareFilterData
Prepares the filter data.- Parameters:
input- theTransferRequestCancelInput- Returns:
- the map containing the filter for the update
-
prepareUpdateData
Prepares the update data.- Parameters:
input- theTransferRequestCancelInput- Returns:
- the map containing the values for the update
-
isValidExecution
public boolean isValidExecution()Checks if the execution is valid.- Returns:
- true, if successful
-
notifyStateChange
protected void notifyStateChange(Long transferRequestId, PoolKit poolKit) throws DAValidateException, DAException Notifies the change of theTransferRequeststate.- Parameters:
transferRequestId- theTransferRequestidpoolKit- thePoolKit- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-