use of org.jaffa.presentation.portlet.FormKey in project jaffa-framework by jaffa-projects.
the class QueueListAction method do_Refresh_Clicked.
public FormKey do_Refresh_Clicked() {
FormKey fk = null;
QueueListForm myForm = (QueueListForm) form;
QueueListComponent myComp = (QueueListComponent) myForm.getComponent();
try {
fk = myComp.displayResults();
} catch (ApplicationExceptions e) {
if (log.isDebugEnabled())
log.debug("Refresh Failed");
myForm.raiseError(request, ActionMessages.GLOBAL_MESSAGE, e);
} catch (FrameworkException e) {
log.error(null, e);
myForm.raiseError(request, ActionMessages.GLOBAL_MESSAGE, "error.framework.general");
}
// Direct User back to current form
if (fk == null)
fk = myComp.getResultsFormKey();
return fk;
}
use of org.jaffa.presentation.portlet.FormKey in project jaffa-framework by jaffa-projects.
the class QueueViewerAction method do_Refresh_Clicked.
public FormKey do_Refresh_Clicked() {
FormKey fk = null;
QueueViewerForm myForm = (QueueViewerForm) form;
QueueViewerComponent myComp = (QueueViewerComponent) myForm.getComponent();
try {
if (myForm.doValidate(request))
myComp.doInquiry();
} catch (ApplicationExceptions e) {
if (log.isDebugEnabled())
log.debug("Refresh Failed");
myForm.raiseError(request, ActionMessages.GLOBAL_MESSAGE, e);
} catch (FrameworkException e) {
log.error(null, e);
myForm.raiseError(request, ActionMessages.GLOBAL_MESSAGE, "error.framework.general");
}
// Direct User back to current form
if (fk == null)
fk = myComp.getViewerFormKey();
return fk;
}
use of org.jaffa.presentation.portlet.FormKey in project jaffa-framework by jaffa-projects.
the class QueueViewerAction method do_RelatedQueueHeader_Delete_Clicked.
public FormKey do_RelatedQueueHeader_Delete_Clicked(String rowNum) {
FormKey fk = null;
QueueViewerForm myForm = (QueueViewerForm) form;
QueueViewerComponent myComp = (QueueViewerComponent) myForm.getComponent();
try {
// This will stop double submits
performTokenValidation(request);
GridModel model = (GridModel) myForm.getRelatedQueueHeaderWM();
GridModelRow selectedRow = model.getRow(Integer.parseInt(rowNum));
if (selectedRow != null)
fk = myComp.deleteMessage((java.lang.String) selectedRow.get("messageId"));
// Invoke QueueView Listener
myComp.invokeQueueViewerListeners();
} catch (ApplicationExceptions e) {
if (log.isDebugEnabled())
log.debug("RelatedQueueHeader_Delete Failed");
myForm.raiseError(request, ActionMessages.GLOBAL_MESSAGE, e);
} catch (FrameworkException e) {
log.error(null, e);
myForm.raiseError(request, ActionMessages.GLOBAL_MESSAGE, "error.framework.general");
}
// Direct User back to current form
if (fk == null)
fk = myComp.getViewerFormKey();
return fk;
}
use of org.jaffa.presentation.portlet.FormKey in project jaffa-framework by jaffa-projects.
the class QueueViewerAction method do_RelatedQueueHeader_View_Clicked.
public FormKey do_RelatedQueueHeader_View_Clicked(String rowNum) {
FormKey fk = null;
QueueViewerForm myForm = (QueueViewerForm) form;
QueueViewerComponent myComp = (QueueViewerComponent) myForm.getComponent();
try {
GridModel model = (GridModel) myForm.getRelatedQueueHeaderWM();
GridModelRow selectedRow = model.getRow(Integer.parseInt(rowNum));
if (selectedRow != null)
fk = myComp.viewMessage((java.lang.String) selectedRow.get("messageId"));
} catch (ApplicationExceptions e) {
if (log.isDebugEnabled())
log.debug("RelatedQueueHeader_View Failed");
myForm.raiseError(request, ActionMessages.GLOBAL_MESSAGE, e);
} catch (FrameworkException e) {
log.error(null, e);
myForm.raiseError(request, ActionMessages.GLOBAL_MESSAGE, "error.framework.general");
}
// The Viewer will be rendered in a new window
// We don't want to see the existing HistoryNav in that window
// Hence, initialize the HistoryNav
HistoryNav.initializeHistoryNav(request);
// Direct User back to current form
if (fk == null)
fk = myComp.getViewerFormKey();
return fk;
}
use of org.jaffa.presentation.portlet.FormKey in project jaffa-framework by jaffa-projects.
the class DefaultValueEditorAction method do_Save_Clicked.
/**
* Clicked event handler for the field Save.
* @return The FormKey.
*/
public FormKey do_Save_Clicked() {
FormKey fk = null;
DefaultValueEditorForm myForm = (DefaultValueEditorForm) form;
DefaultValueEditorComponent myComp = (DefaultValueEditorComponent) myForm.getComponent();
try {
if (invokeDoValidateForScreen(myComp.getCurrentScreenCounter())) {
myComp.saveDefaultValues();
}
} catch (FrameworkException e) {
log.error(null, e);
myForm.raiseError(request, ActionMessages.GLOBAL_MESSAGE, "error.framework.general");
}
fk = myComp.determineFormKey();
return fk;
}
Aggregations