|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object info.magnolia.cms.servlets.MVCServletHandlerImpl info.magnolia.module.admininterface.DialogMVCHandler
public class DialogMVCHandler
This is the MVCHandler for dialogs. You can make a subclass to take influence on creation or saving.
Field Summary | |
---|---|
protected static String |
COMMAND_SAVE
|
protected static String |
COMMAND_SELECT_PARAGRAPH
|
protected static String |
COMMAND_SHOW_DIALOG
|
protected info.magnolia.cms.beans.runtime.MultipartForm |
form
The posted multipart form. |
protected info.magnolia.cms.core.HierarchyManager |
hm
|
protected String |
locale
|
protected info.magnolia.cms.i18n.Messages |
msgs
|
protected String |
nodeName
the node containing the date for this dialog |
protected info.magnolia.cms.util.RequestFormUtil |
params
|
protected String |
path
Path to the node containing the data |
protected String |
repository
|
protected String |
richE
|
protected String |
richEPaste
|
protected info.magnolia.cms.core.Content |
storageNode
|
protected String |
treeBasePath
|
protected static String |
VIEW_CLOSE_WINDOW
|
protected static String |
VIEW_SHOW_DIALOG
|
Fields inherited from class info.magnolia.cms.servlets.MVCServletHandlerImpl |
---|
exception, request, response, VIEW_ERROR, VIEW_SUCCESS |
Fields inherited from interface info.magnolia.cms.servlets.MVCServletHandler |
---|
VIEW_NOTHING |
Constructor Summary | |
---|---|
DialogMVCHandler(String name,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Initialize the used parameters: path, nodeCollectionName, nodeName, .. |
Method Summary | |
---|---|
protected void |
configureDialog(info.magnolia.cms.gui.dialog.Dialog dialog)
|
protected void |
configureSaveHandler(SaveHandler saveHandler)
Configure the save control |
protected info.magnolia.cms.gui.dialog.Dialog |
createDialog(info.magnolia.cms.core.Content configNode,
info.magnolia.cms.core.Content storageNode)
Is called during showDialog(). |
protected void |
createSaveHandler()
If there is the property saveHandler defined in the config it instantiates the configured save handler. |
String |
getCommand()
|
info.magnolia.cms.core.Content |
getConfigNode()
Returns the node with the dialog definition. |
info.magnolia.cms.gui.dialog.Dialog |
getDialog()
|
String |
getItemType()
|
String |
getJsExecutedAfterSaving()
|
String |
getRepository()
|
protected SaveHandler |
getSaveHandler()
Returns the save handler used by this dialog handler. |
info.magnolia.cms.core.Content |
getStorageNode()
Defines the node/page containing the data editing in this dialog. |
protected boolean |
onPostSave(SaveHandler control)
|
protected boolean |
onPreSave(SaveHandler control)
|
protected boolean |
onSave(SaveHandler control)
|
protected String |
onSaveFailed()
Called if the save failed. |
void |
removeSessionAttributes()
|
void |
renderHtml(String view)
|
String |
save()
Uses the SaveControl. |
void |
setDialog(info.magnolia.cms.gui.dialog.Dialog dialog)
|
void |
setItemType(String itemType)
|
void |
setJsExecutedAfterSaving(String jsExecutedAfterSaving)
|
String |
showDialog()
Calls createDialog and sets the common parameters on the dialog |
protected boolean |
validate()
|
Methods inherited from class info.magnolia.cms.servlets.MVCServletHandlerImpl |
---|
execute, getException, getExceptionStackTrace, getName, getRequest, getResponse, init, populateFromRequest, setCommand, setRequest, setResponse |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final String COMMAND_SAVE
protected static final String COMMAND_SELECT_PARAGRAPH
protected static final String COMMAND_SHOW_DIALOG
protected static final String VIEW_CLOSE_WINDOW
protected static final String VIEW_SHOW_DIALOG
protected info.magnolia.cms.beans.runtime.MultipartForm form
protected String path
protected String nodeName
protected String richE
protected String richEPaste
protected String repository
protected String locale
protected info.magnolia.cms.core.HierarchyManager hm
protected info.magnolia.cms.i18n.Messages msgs
protected info.magnolia.cms.util.RequestFormUtil params
protected info.magnolia.cms.core.Content storageNode
protected String treeBasePath
Constructor Detail |
---|
public DialogMVCHandler(String name, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
request
- response
- Method Detail |
---|
public String getCommand()
getCommand
in interface info.magnolia.cms.servlets.MVCServletHandler
getCommand
in class info.magnolia.cms.servlets.MVCServletHandlerImpl
public String showDialog()
protected void configureDialog(info.magnolia.cms.gui.dialog.Dialog dialog)
protected info.magnolia.cms.gui.dialog.Dialog createDialog(info.magnolia.cms.core.Content configNode, info.magnolia.cms.core.Content storageNode) throws javax.jcr.RepositoryException
configNode
- storageNode
-
javax.jcr.RepositoryException
public String save()
protected boolean validate()
protected String onSaveFailed()
protected SaveHandler getSaveHandler()
protected void createSaveHandler()
protected void configureSaveHandler(SaveHandler saveHandler)
protected boolean onPreSave(SaveHandler control)
protected boolean onSave(SaveHandler control)
protected boolean onPostSave(SaveHandler control)
public info.magnolia.cms.core.Content getStorageNode()
public info.magnolia.cms.core.Content getConfigNode()
public void renderHtml(String view) throws IOException
IOException
MVCServletHandler.renderHtml(java.lang.String)
public String getRepository()
public void removeSessionAttributes()
public void setDialog(info.magnolia.cms.gui.dialog.Dialog dialog)
dialog
- The dialog to set.public info.magnolia.cms.gui.dialog.Dialog getDialog()
public String getJsExecutedAfterSaving()
public void setJsExecutedAfterSaving(String jsExecutedAfterSaving)
public String getItemType()
public void setItemType(String itemType)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |