Class BTInterventionTakeInCharge<T extends InterventionExecutionInput>
java.lang.Object
overit.geocall.bl.BusinessTask<SimpleBusinessEvent<T,Void>>
overit.geocallapp.utilities.core.bl.common.validexecution.ValidExecutionBusinessTask<SimpleBusinessEvent<T,Void>>
overit.geocallapp.utilities.core.bl.common.validexecution.ValidPermissionBusinessTask<SimpleBusinessEvent<T,Void>>
overit.geocallapp.wfm.orchestrator.workorders.bl.outcome.intervention.task.BTInterventionExecution<T>
overit.geocallapp.wfm.orchestrator.workorders.bl.outcome.intervention.task.BTInterventionTakeInCharge<T>
- All Implemented Interfaces:
Serializable,Tool,ValidExecution
@Event(InterventionTakeInChargeEvent.class)
public class BTInterventionTakeInCharge<T extends InterventionExecutionInput>
extends BTInterventionExecution<T>
Represents a business task class for taking in charge an intervention.
It is triggered by the
InterventionTakeInChargeEvent.- Since:
- 18.0
- See Also:
- GCApi:
- task
-
Field Summary
Fields inherited from class overit.geocallapp.wfm.orchestrator.workorders.bl.outcome.intervention.task.BTInterventionExecution
intervention, operationFields inherited from class overit.geocallapp.utilities.core.bl.common.validexecution.ValidPermissionBusinessTask
LOG -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidChecks the validity of the take in charge date provided in theInterventionExecutionInput.protected voidChecks the status of the intervention to ensure it is in a valid state for the take in charge action.protected voidperformInterventionAction(InterventionExecutionInput input, PoolKit poolKit) Takes in charge an intervention by updating the intervention outcome and sending a notification that will update the agenda status.Methods inherited from class overit.geocallapp.wfm.orchestrator.workorders.bl.outcome.intervention.task.BTInterventionExecution
execute, findInterventionsToBeRemoved, getIntegrationService, isValidExecution, notifyInterventionOutcome, recalculateWorkOrderOperationStatus, recalculateWorkOrderStatus, removeOtherInterventionsFromForeman, updateWorkOrderOperation, validateInputMethods inherited from class overit.geocallapp.utilities.core.bl.common.validexecution.ValidPermissionBusinessTask
checkValidExecution, 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
-
BTInterventionTakeInCharge
public BTInterventionTakeInCharge()
-
-
Method Details
-
checkDate
Checks the validity of the take in charge date provided in theInterventionExecutionInput. The date must not be null, must be after the minimum date for the intervention outcome, and must not be in the future.- Specified by:
checkDatein classBTInterventionExecution<T extends InterventionExecutionInput>- Parameters:
inputDate- The take in charge date to validate of theInterventionExecutionInput- Throws:
DAValidateException- If the date is invalid.
-
checkInterventionStatus
Checks the status of the intervention to ensure it is in a valid state for the take in charge action. The valid intervention statuses are OPEN, FIXED, SUBMITTED, and ACCEPTED. If the intervention status is not valid, aDAValidateExceptionis thrown.- Specified by:
checkInterventionStatusin classBTInterventionExecution<T extends InterventionExecutionInput>- Throws:
DAValidateException- if the intervention status is not valid for the take in charge action
-
performInterventionAction
protected void performInterventionAction(InterventionExecutionInput input, PoolKit poolKit) throws DAValidateException, DAException Takes in charge an intervention by updating the intervention outcome and sending a notification that will update the agenda status.- Specified by:
performInterventionActionin classBTInterventionExecution<T extends InterventionExecutionInput>- Parameters:
input- TheInterventionExecutionInputpoolKit- thePoolKit- Throws:
DAException- If any error occurs during the process.DAValidateException- If any validation error occurs.
-