public class ReturnCancellationController
extends DefaultWidgetController
| Modifier and Type | Field and Description |
|---|---|
protected static Object |
COMPLETED |
protected static String |
IN_SOCKET |
protected static Logger |
LOGGER |
protected static String |
OUT_CONFIRM |
| Constructor and Description |
|---|
ReturnCancellationController() |
| Modifier and Type | Method and Description |
|---|---|
void |
confirmCancelReturn()
Confirm the return approval request
|
protected CockpitEventQueue |
getCockpitEventQueue() |
protected BackofficeLocaleService |
getCockpitLocaleService() |
Textbox |
getCustomerName() |
protected EnumerationService |
getEnumerationService() |
ReturnCallbackService |
getReturnCallbackService() |
protected ReturnRequestModel |
getReturnRequest() |
Textbox |
getReturnRequestCode() |
protected Optional<CancelReason> |
getSelectedCancelReason(Event event)
Gets the label for the selected cancel reason in case the event has a target of Combobox
|
protected void |
handleGlobalCancelReason(Event event)
Applies a global reason to all individual entries after an event is triggered
|
void |
initCancelReturnForm(ReturnRequestModel inputObject)
Initialize the popup to choose cancellation reason
|
protected Optional<CancelReason> |
matchingComboboxCancelReason(String cancelReasonLabel)
Retrieve the
CancelReason according to the selected label in the
combobox |
protected void |
processCancellation(Event event)
Process the cancellation only if the user confirmed it
|
void |
setCockpitEventQueue(CockpitEventQueue cockpitEventQueue) |
void |
setCockpitLocaleService(BackofficeLocaleService cockpitLocaleService) |
void |
setCustomerName(Textbox customerName) |
void |
setEnumerationService(EnumerationService enumerationService) |
void |
setReturnCallbackService(ReturnCallbackService returnCallbackService) |
void |
setReturnRequest(ReturnRequestModel returnRequest) |
void |
setReturnRequestCode(Textbox returnRequestCode) |
void |
undoCancelReturn()
Reinitialize the popup.
|
protected void |
validateRequest()
Check if the data provided by the form are compliant with the validation rules
|
protected static final Logger LOGGER
protected static final String IN_SOCKET
protected static final String OUT_CONFIRM
protected static final Object COMPLETED
public void initCancelReturnForm(ReturnRequestModel inputObject)
inputObject - the return request for which we want set the cancellation reasonprotected void handleGlobalCancelReason(Event event)
event - the on select event that was triggered by the userprotected Optional<CancelReason> matchingComboboxCancelReason(String cancelReasonLabel)
CancelReason according to the selected label in the
comboboxcancelReasonLabel - a String representation of the reasonprotected Optional<CancelReason> getSelectedCancelReason(Event event)
event - the event that was firedpublic void undoCancelReturn()
public void confirmCancelReturn()
throws InterruptedException
InterruptedExceptionprotected void processCancellation(Event event)
event - the confirmation event coming from the userprotected void validateRequest()
protected ReturnRequestModel getReturnRequest()
public void setReturnRequest(ReturnRequestModel returnRequest)
protected EnumerationService getEnumerationService()
public void setEnumerationService(EnumerationService enumerationService)
protected BackofficeLocaleService getCockpitLocaleService()
public void setCockpitLocaleService(BackofficeLocaleService cockpitLocaleService)
protected CockpitEventQueue getCockpitEventQueue()
public void setCockpitEventQueue(CockpitEventQueue cockpitEventQueue)
public Textbox getCustomerName()
public void setCustomerName(Textbox customerName)
public Textbox getReturnRequestCode()
public void setReturnRequestCode(Textbox returnRequestCode)
public ReturnCallbackService getReturnCallbackService()
public void setReturnCallbackService(ReturnCallbackService returnCallbackService)
Copyright © 2017 SAP SE. All Rights Reserved.