protected String _containerID(WOContext context) { return ERXWOContext.safeIdentifierName(context, false); }
public static void setUpdateContainerID(WORequest request, String updateContainerID) { if (updateContainerID != null) { ERXWOContext.contextDictionary().setObjectForKey(updateContainerID, ERXAjaxApplication.KEY_UPDATE_CONTAINER_ID); } }
String linkID = (String)valueForBinding("id", component); if (linkID == null) { linkID=ERXWOContext.safeIdentifierName(context, false); NSMutableDictionary userInfo = ERXWOContext.contextDictionary(); if (!userInfo.containsKey("er.ajax.AjaxModalContainer.init")) { AjaxUtils.appendScriptHeader(response);
public WOActionResults performAction() { return WOApplication.application().handleException(_result, ERXWOContext.currentContext()); }
public String id(WOComponent component, WOContext context) { String id = null; if (_id != null) { id = (String) _id.valueInComponent(component); } if (id == null) { id = ERXWOContext.safeIdentifierName(context, false); } return id; }
/** * Remove this dialog instance from the context, replacing the previous one if any. * @see #pushDialog() */ protected void popDialog() { if (outerDialog != null) { ERXWOContext.contextDictionary().setObjectForKey(outerDialog, AjaxModalDialog.class.getName()); } else { ERXWOContext.contextDictionary().removeObjectForKey(AjaxModalDialog.class.getName()); } }
public String id(WOComponent component, WOContext context) { String id = null; if (_id != null) { id = (String) _id.valueInComponent(component); } if (id == null) { id = ERXWOContext.safeIdentifierName(context, false); } return id; }
public static void setCurrentUpdateContainerID(String updateContainerID) { if (updateContainerID == null) { ERXWOContext.contextDictionary().removeObjectForKey(AjaxUpdateContainer.CURRENT_UPDATE_CONTAINER_ID_KEY); } else { ERXWOContext.contextDictionary().setObjectForKey(updateContainerID, AjaxUpdateContainer.CURRENT_UPDATE_CONTAINER_ID_KEY); } }
public String headerID() { return ERXWOContext.safeIdentifierName(context(), false) + "Header"; }
public static boolean isAjaxUpdatePass(WORequest request) { return ERXWOContext.contextDictionary().valueForKey(AjaxResponse.AJAX_UPDATE_PASS) != null; }
public String contentID() { return ERXWOContext.safeIdentifierName(context(), false) + "Content"; } }
public static String currentUpdateContainerID() { return (String) ERXWOContext.contextDictionary().objectForKey(AjaxUpdateContainer.CURRENT_UPDATE_CONTAINER_ID_KEY); }
public String id() { String id = _id; if (id == null) { id = (String) valueForBinding("id"); if (id == null) { id = ERXWOContext.safeIdentifierName(context(), true); } _id = id; } return id; }
public static String updateContainerID(WORequest request) { return (String) ERXWOContext.contextDictionary().objectForKey(ERXAjaxApplication.KEY_UPDATE_CONTAINER_ID); }
public String id() { String id = _id; if (id == null) { id = (String) valueForBinding("id"); if (id == null) { id = ERXWOContext.safeIdentifierName(context(), true); } _id = id; } return id; }
/** * @param context the current WOContext * @return the AjaxModalDialog currently being processed * @throws RuntimeException if no AjaxModalDialog is currently being processed */ public static AjaxModalDialog _currentDialog(WOContext context) { AjaxModalDialog currentDialog = (AjaxModalDialog) ERXWOContext.contextDictionary().objectForKey(AjaxModalDialog.class.getName()); if (currentDialog == null) { currentDialog = (AjaxModalDialog) ERXResponseRewriter.pageUserInfo(context).objectForKey(AjaxModalDialog.class.getName()); } return currentDialog; }
public String id() { if (_id == null) { _id = (String) valueForBinding("id"); if (_id == null) { _id = ERXWOContext.safeIdentifierName(context(), true); } } return _id; }
/** * Stash this dialog instance in the context so we can access it from the static methods. If there is one AMD * nested in another (a rather dubious thing to do that we warn about but it may have its uses), we need to remember * the outer one while processing this inner one * @see #popDialog() */ protected void pushDialog() { outerDialog = (AjaxModalDialog) ERXWOContext.contextDictionary().objectForKey(AjaxModalDialog.class.getName()); ERXWOContext.contextDictionary().setObjectForKey(this, AjaxModalDialog.class.getName()); if ( ! hasWarnedOnNesting && outerDialog != null) { hasWarnedOnNesting = true; if (! ERXComponentUtilities.booleanValueForBinding(this, "ignoreNesting", false)) { log.warn("AjaxModalDialog {} is nested inside of {}. Are you sure you want to do this?", id(), outerDialog.id()); } } }
@Override protected String _containerID(WOContext context) { String id = (String) valueForBinding("id", context.component()); if (id == null) { id = ERXWOContext.safeIdentifierName(context, false); } return id; }
public static HighlightMetadata highlightMetadataForObject(Object obj) { HighlightMetadata metadata = null; if (obj != null) { NSMutableDictionary highlightedObjects = (NSMutableDictionary) ERXWOContext.contextDictionary().valueForKey(AjaxHighlight.HIGHLIGHTED_KEY); if (highlightedObjects != null) { metadata = (HighlightMetadata) highlightedObjects.objectForKey(highlightedValue(obj)); } } return metadata; }