rice-framework/krad-web/src/main/webapp/krad/scripts/krad.session.js
/**
 * Handles the users selection to the session timeout warning dialog
 *
 * <p>
 * User may select to continue work, in which case we will send a server call to reset the session. Or
 * the user may select to logout, in which case we redirect the user to the logout URL.
 * </p>
 *
 * <p>
 * A broadcast message is also sent so if the dialog is present in other windows, the users response will
 * be picked up there as well
 * </p>
 *
 * @param event instance of the dialog response event, contains the value for the response input
 */
Handles the users selection to the session timeout warning dialog


User may select to continue work, in which case we will send a server call to reset the session. Or
the user may select to logout, in which case we redirect the user to the logout URL.


A broadcast message is also sent so if the dialog is present in other windows, the users response will
be picked up there as well


@param event instance of the dialog response event, contains the value for the response input
Handles the users selection to the session timeout warning dialog User may select to continue work in which case we will send a server call to reset the session . Or the user may select to logout in which case we redirect the user to the logout URL . A broadcast message is also sent so if the dialog is present in other windows the users response will be picked up there as well @param event instance of the dialog response event contains the value for the response input
function handleTimeoutWarningResponse(event) {
    dismissDialog(kradVariables.SESSION_TIMEOUT_WARNING_DIALOG);
    if (event.response == 'continue') {
        var response = invokeServerListener(kradVariables.KEEP_SESSION_ALIVE_METHOD_TO_CALL);
        if (response.status == kradVariables.SUCCESS_RESPONSE) {
            resetSessionTimers();
        }
        broadcastSessionDialogResponse('continue');
    }
    else if (event.response == 'logout') {
        broadcastSessionDialogResponse('logout');
        logoutUser();
    }
}
function handleTimeoutWarningResponse ( event ) { dismissDialog ( kradVariables . SESSION_TIMEOUT_WARNING_DIALOG ) ; if ( event . response == 'continue' ) { var response = invokeServerListener ( kradVariables . KEEP_SESSION_ALIVE_METHOD_TO_CALL ) ; if ( response . status == kradVariables . SUCCESS_RESPONSE ) { resetSessionTimers ( ) ; } broadcastSessionDialogResponse ( 'continue' ) ; } else if ( event . response == 'logout' ) { broadcastSessionDialogResponse ( 'logout' ) ; logoutUser ( ) ; } }
Handles the users selection to the session timeout warning dialog
Handles the users selection to the session timeout warning dialog