Next phase of forums functionality
Simple dialog framework implementation git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@2056 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
@@ -319,6 +319,9 @@ edit_forum_description=Modify the forum properties then click OK.
|
|||||||
edit_topic_description=Modify the topic properties then click OK.
|
edit_topic_description=Modify the topic properties then click OK.
|
||||||
edit_post_description=Modify the message then click OK.
|
edit_post_description=Modify the message then click OK.
|
||||||
edit_post_finish=To save the message click Post.
|
edit_post_finish=To save the message click Post.
|
||||||
|
start_discussion=Start Discussion
|
||||||
|
discuss=Discuss
|
||||||
|
discussion_for={0} discussion
|
||||||
|
|
||||||
# Common Wizard messages
|
# Common Wizard messages
|
||||||
steps=Steps
|
steps=Steps
|
||||||
@@ -828,6 +831,7 @@ title_create_forum=Create Forum
|
|||||||
title_forums_details=Forum Space Details
|
title_forums_details=Forum Space Details
|
||||||
title_forum_details=Forum Details
|
title_forum_details=Forum Details
|
||||||
title_create_topic=Create Topic
|
title_create_topic=Create Topic
|
||||||
|
title_create_discussion=Create Discussion
|
||||||
title_topic_details=Topic Details
|
title_topic_details=Topic Details
|
||||||
title_create_post=Post Message
|
title_create_post=Post Message
|
||||||
title_create_reply=Create Reply
|
title_create_reply=Create Reply
|
||||||
|
@@ -33,6 +33,8 @@
|
|||||||
<config evaluator="string-compare" condition="fm:topic">
|
<config evaluator="string-compare" condition="fm:topic">
|
||||||
<icons>
|
<icons>
|
||||||
<icon name="topic_large" path="/images/icons/topic_large.gif" />
|
<icon name="topic_large" path="/images/icons/topic_large.gif" />
|
||||||
|
<icon name="topic_exclamation_large" path="/images/icons/topic_exclamation_large.gif" />
|
||||||
|
<icon name="topic_question_large" path="/images/icons/topic_question_large.gif" />
|
||||||
</icons>
|
</icons>
|
||||||
</config>
|
</config>
|
||||||
|
|
||||||
|
@@ -153,7 +153,6 @@
|
|||||||
<property-sheet>
|
<property-sheet>
|
||||||
<show-property name="name"/>
|
<show-property name="name"/>
|
||||||
<show-property name="description"/>
|
<show-property name="description"/>
|
||||||
<show-property name="fm:status"/>
|
|
||||||
</property-sheet>
|
</property-sheet>
|
||||||
|
|
||||||
<navigation>
|
<navigation>
|
||||||
@@ -167,7 +166,6 @@
|
|||||||
<config evaluator="node-type" condition="fm:topic">
|
<config evaluator="node-type" condition="fm:topic">
|
||||||
<property-sheet>
|
<property-sheet>
|
||||||
<show-property name="name" displayLabelId="subject" />
|
<show-property name="name" displayLabelId="subject" />
|
||||||
<show-property name="fm:type"/>
|
|
||||||
</property-sheet>
|
</property-sheet>
|
||||||
|
|
||||||
<navigation>
|
<navigation>
|
||||||
@@ -325,7 +323,7 @@
|
|||||||
|
|
||||||
<config evaluator="string-compare" condition="Custom Folder Types">
|
<config evaluator="string-compare" condition="Custom Folder Types">
|
||||||
<folder-types>
|
<folder-types>
|
||||||
<!-- <type name="fm:forums" icon="/images/icons/forums_large.gif" descriptionMsgId="forums_desc" /> -->
|
<type name="fm:forums" icon="/images/icons/create_forums_large.gif" descriptionMsgId="forums_desc" />
|
||||||
</folder-types>
|
</folder-types>
|
||||||
</config>
|
</config>
|
||||||
|
|
||||||
|
@@ -17,6 +17,8 @@
|
|||||||
*/
|
*/
|
||||||
package org.alfresco.web.app;
|
package org.alfresco.web.app;
|
||||||
|
|
||||||
|
import java.util.Stack;
|
||||||
|
|
||||||
import javax.faces.application.NavigationHandler;
|
import javax.faces.application.NavigationHandler;
|
||||||
import javax.faces.application.ViewHandler;
|
import javax.faces.application.ViewHandler;
|
||||||
import javax.faces.component.UIViewRoot;
|
import javax.faces.component.UIViewRoot;
|
||||||
@@ -38,7 +40,12 @@ import org.springframework.web.jsf.FacesContextUtils;
|
|||||||
*/
|
*/
|
||||||
public class AlfrescoNavigationHandler extends NavigationHandler
|
public class AlfrescoNavigationHandler extends NavigationHandler
|
||||||
{
|
{
|
||||||
|
public final static String DIALOG_SEPARATOR = ":";
|
||||||
|
public final static String DIALOG_PREXIX = "dialog" + DIALOG_SEPARATOR;
|
||||||
|
public final static String CLOSE_DIALOG_OUTCOME = DIALOG_PREXIX + "close";
|
||||||
|
|
||||||
private final static Log logger = LogFactory.getLog(AlfrescoNavigationHandler.class);
|
private final static Log logger = LogFactory.getLog(AlfrescoNavigationHandler.class);
|
||||||
|
private final static String VIEW_STACK = "_alfViewStack";
|
||||||
|
|
||||||
// The original navigation handler
|
// The original navigation handler
|
||||||
private NavigationHandler origHandler;
|
private NavigationHandler origHandler;
|
||||||
@@ -58,102 +65,228 @@ public class AlfrescoNavigationHandler extends NavigationHandler
|
|||||||
* @see javax.faces.application.NavigationHandler#handleNavigation(javax.faces.context.FacesContext, java.lang.String, java.lang.String)
|
* @see javax.faces.application.NavigationHandler#handleNavigation(javax.faces.context.FacesContext, java.lang.String, java.lang.String)
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
|
@SuppressWarnings("unchecked")
|
||||||
public void handleNavigation(FacesContext context, String fromAction, String outcome)
|
public void handleNavigation(FacesContext context, String fromAction, String outcome)
|
||||||
{
|
{
|
||||||
if (logger.isDebugEnabled())
|
if (logger.isDebugEnabled())
|
||||||
logger.debug("handleNavigation (fromAction=" + fromAction + ", outcome=" + outcome + ")");
|
logger.debug("handleNavigation (fromAction=" + fromAction + ", outcome=" + outcome + ")");
|
||||||
|
|
||||||
boolean useOriginalNavHandler = true;
|
boolean useOriginalNavHandler = true;
|
||||||
String finalOutcome = outcome;
|
boolean closingDialog = false;
|
||||||
String viewId = context.getViewRoot().getViewId();
|
String viewId = context.getViewRoot().getViewId();
|
||||||
|
|
||||||
if (logger.isDebugEnabled())
|
if (logger.isDebugEnabled())
|
||||||
logger.debug("Current view id: " + viewId);
|
logger.debug("Current view id: " + viewId);
|
||||||
|
|
||||||
NavigationBean navBean = (NavigationBean)context.getExternalContext().
|
// determine if we are dealing with a dialog
|
||||||
getSessionMap().get("NavigationBean");
|
if (outcome != null && outcome.startsWith(DIALOG_PREXIX))
|
||||||
|
|
||||||
// only continue if we have some dispatching context
|
|
||||||
if (navBean != null && navBean.getDispatchContextNode() != null)
|
|
||||||
{
|
{
|
||||||
Node node = navBean.getDispatchContextNode();
|
// determine whether it's being closed or opened
|
||||||
|
closingDialog = outcome.startsWith(CLOSE_DIALOG_OUTCOME);
|
||||||
if (logger.isDebugEnabled())
|
|
||||||
logger.debug("Found node in dispatch context: " + node);
|
// remove the dialog prefix
|
||||||
|
outcome = outcome.substring(DIALOG_PREXIX.length());
|
||||||
|
|
||||||
// see if there is any navigation config for the node type
|
if (closingDialog)
|
||||||
ConfigService configSvc = (ConfigService)FacesContextUtils.getRequiredWebApplicationContext(
|
|
||||||
context).getBean(Application.BEAN_CONFIG_SERVICE);
|
|
||||||
|
|
||||||
Config nodeConfig = configSvc.getConfig(node);
|
|
||||||
NavigationConfigElement navigationCfg = (NavigationConfigElement)nodeConfig.
|
|
||||||
getConfigElement(NavigationElementReader.ELEMENT_NAVIGATION);
|
|
||||||
|
|
||||||
if (navigationCfg != null)
|
|
||||||
{
|
{
|
||||||
// see if there is config for the current view state
|
// if we are closing the dialog take the view off the
|
||||||
NavigationResult navResult = navigationCfg.getOverride(viewId, outcome);
|
// top of the stack then decide whether to use the view
|
||||||
|
// or any overridden outcome that may be present
|
||||||
if (navResult != null)
|
if (getViewStack(context).empty() == false)
|
||||||
{
|
{
|
||||||
if (logger.isDebugEnabled())
|
String newViewId = (String)getViewStack(context).pop();
|
||||||
logger.debug("Found navigation config: " + navResult);
|
|
||||||
|
// is there an overiddent outcome?
|
||||||
if (navResult.isOutcome())
|
int idx = outcome.indexOf(DIALOG_SEPARATOR);
|
||||||
|
if (idx == -1)
|
||||||
{
|
{
|
||||||
finalOutcome = navResult.getResult();
|
// there isn't an overidden outcome so go back to the previous view
|
||||||
|
if (logger.isDebugEnabled())
|
||||||
|
logger.debug("Closing dialog, going back to view id: " + newViewId);
|
||||||
|
|
||||||
|
goToView(context, newViewId);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
String newViewId = navResult.getResult();
|
// there is an overidden outcome so extract it
|
||||||
|
outcome = outcome.substring(idx+1, outcome.length());
|
||||||
|
|
||||||
|
if (logger.isDebugEnabled())
|
||||||
|
logger.debug("Closing dialog with an overridden outcome of '" + outcome + "'");
|
||||||
|
|
||||||
if (newViewId.equals(viewId) == false)
|
this.origHandler.handleNavigation(context, fromAction, outcome);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// we are trying to close a dialog when one hasn't been opened!
|
||||||
|
// log a warning and return a null outcome to stay on the same page
|
||||||
|
if (logger.isWarnEnabled())
|
||||||
|
{
|
||||||
|
logger.warn("Attempting to close a dialog with an empty view stack, returning 'browse' outcome");
|
||||||
|
}
|
||||||
|
|
||||||
|
// TODO: change this back to returning null outcome as that
|
||||||
|
// will highlight any areas we have neglected to launch
|
||||||
|
// in a dilaog, for backwards compatibility for the short
|
||||||
|
// term return 'browse' outcome.
|
||||||
|
|
||||||
|
this.origHandler.handleNavigation(context, fromAction, "browse");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// if we are opening a dialog push the current view id
|
||||||
|
// on to the stack, but only if it is different than the
|
||||||
|
// current view at the top (you can't launch a dialog from
|
||||||
|
// the same page 2 times in a row!)
|
||||||
|
|
||||||
|
// TODO: This wouldn't happen if we could be sure a dialog is
|
||||||
|
// ALWAYS exited properly, look into a way of ensuring
|
||||||
|
// dialogs get closed if a user navigates away from the page,
|
||||||
|
// would a PhaseListener help in any way??
|
||||||
|
|
||||||
|
if (getViewStack(context).empty() ||
|
||||||
|
viewId.equals(getViewStack(context).peek()) == false)
|
||||||
|
{
|
||||||
|
getViewStack(context).push(viewId);
|
||||||
|
|
||||||
|
if (logger.isDebugEnabled())
|
||||||
|
logger.debug("Pushed current view to stack: " + viewId);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (getViewStack(context).empty() == false && logger.isDebugEnabled())
|
||||||
|
{
|
||||||
|
logger.debug("current view is already top the view stack!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (logger.isDebugEnabled())
|
||||||
|
logger.debug("view stack: " + getViewStack(context));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (closingDialog == false)
|
||||||
|
{
|
||||||
|
NavigationBean navBean = (NavigationBean)context.getExternalContext().
|
||||||
|
getSessionMap().get("NavigationBean");
|
||||||
|
|
||||||
|
// only continue if we have some dispatching context
|
||||||
|
if (navBean != null && navBean.getDispatchContextNode() != null)
|
||||||
|
{
|
||||||
|
Node node = navBean.getDispatchContextNode();
|
||||||
|
|
||||||
|
if (logger.isDebugEnabled())
|
||||||
|
logger.debug("Found node with type '" + node.getType().toString() +
|
||||||
|
"' in dispatch context");
|
||||||
|
|
||||||
|
// see if there is any navigation config for the node type
|
||||||
|
ConfigService configSvc = (ConfigService)FacesContextUtils.getRequiredWebApplicationContext(
|
||||||
|
context).getBean(Application.BEAN_CONFIG_SERVICE);
|
||||||
|
|
||||||
|
Config nodeConfig = configSvc.getConfig(node);
|
||||||
|
NavigationConfigElement navigationCfg = (NavigationConfigElement)nodeConfig.
|
||||||
|
getConfigElement(NavigationElementReader.ELEMENT_NAVIGATION);
|
||||||
|
|
||||||
|
if (navigationCfg != null)
|
||||||
|
{
|
||||||
|
// see if there is config for the current view state
|
||||||
|
NavigationResult navResult = navigationCfg.getOverride(viewId, outcome);
|
||||||
|
|
||||||
|
if (navResult != null)
|
||||||
|
{
|
||||||
|
if (logger.isDebugEnabled())
|
||||||
|
logger.debug("Found navigation config: " + navResult);
|
||||||
|
|
||||||
|
if (navResult.isOutcome())
|
||||||
{
|
{
|
||||||
useOriginalNavHandler = false;
|
outcome = navResult.getResult();
|
||||||
|
|
||||||
if (logger.isDebugEnabled())
|
|
||||||
logger.debug("Dispatching to new view id: " + newViewId);
|
|
||||||
|
|
||||||
ViewHandler viewHandler = context.getApplication().getViewHandler();
|
|
||||||
UIViewRoot viewRoot = viewHandler.createView(context, newViewId);
|
|
||||||
viewRoot.setViewId(newViewId);
|
|
||||||
context.setViewRoot(viewRoot);
|
|
||||||
context.renderResponse();
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (logger.isDebugEnabled())
|
String newViewId = navResult.getResult();
|
||||||
logger.debug("New view id is the same as the current one so setting outcome to null");
|
|
||||||
|
|
||||||
finalOutcome = null;
|
if (newViewId.equals(viewId) == false)
|
||||||
|
{
|
||||||
|
useOriginalNavHandler = false;
|
||||||
|
|
||||||
|
if (logger.isDebugEnabled())
|
||||||
|
logger.debug("Dispatching to new view id: " + newViewId);
|
||||||
|
|
||||||
|
goToView(context, newViewId);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (logger.isDebugEnabled())
|
||||||
|
logger.debug("New view id is the same as the current one so setting outcome to null");
|
||||||
|
|
||||||
|
outcome = null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if (logger.isDebugEnabled())
|
||||||
|
{
|
||||||
|
logger.debug("No override configuration found for current view or outcome");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (logger.isDebugEnabled())
|
else if (logger.isDebugEnabled())
|
||||||
{
|
{
|
||||||
logger.debug("No override configuration found for current view or outcome");
|
logger.debug("No navigation configuration found for node");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// reset the dispatch context
|
||||||
|
navBean.resetDispatchContext();
|
||||||
}
|
}
|
||||||
else if (logger.isDebugEnabled())
|
else if (logger.isDebugEnabled())
|
||||||
{
|
{
|
||||||
logger.debug("No navigation configuration found for node");
|
logger.debug("No dispatch context found");
|
||||||
}
|
}
|
||||||
|
|
||||||
// reset the dispatch context
|
// do the appropriate navigation handling
|
||||||
navBean.resetDispatchContext();
|
if (useOriginalNavHandler)
|
||||||
}
|
{
|
||||||
else if (logger.isDebugEnabled())
|
if (logger.isDebugEnabled())
|
||||||
{
|
logger.debug("Passing outcome '" + outcome + "' to original navigation handler");
|
||||||
logger.debug("No dispatch context found");
|
|
||||||
}
|
this.origHandler.handleNavigation(context, fromAction, outcome);
|
||||||
|
}
|
||||||
// do the appropriate navigation handling
|
|
||||||
if (useOriginalNavHandler)
|
|
||||||
{
|
|
||||||
if (logger.isDebugEnabled())
|
|
||||||
logger.debug("Passing outcome '" + finalOutcome + "' to original navigation handler");
|
|
||||||
|
|
||||||
this.origHandler.handleNavigation(context, fromAction, finalOutcome);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Dispatches to the given view id
|
||||||
|
*
|
||||||
|
* @param context Faces context
|
||||||
|
* @param viewId The view id to go to
|
||||||
|
*/
|
||||||
|
private void goToView(FacesContext context, String viewId)
|
||||||
|
{
|
||||||
|
ViewHandler viewHandler = context.getApplication().getViewHandler();
|
||||||
|
UIViewRoot viewRoot = viewHandler.createView(context, viewId);
|
||||||
|
viewRoot.setViewId(viewId);
|
||||||
|
context.setViewRoot(viewRoot);
|
||||||
|
context.renderResponse();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns the view stack for the current user.
|
||||||
|
*
|
||||||
|
* @param context FacesContext
|
||||||
|
* @return A Stack representing the views that have launched dialogs in
|
||||||
|
* the users session, will never be null
|
||||||
|
*/
|
||||||
|
@SuppressWarnings("unchecked")
|
||||||
|
private Stack getViewStack(FacesContext context)
|
||||||
|
{
|
||||||
|
Stack viewStack = (Stack)context.getExternalContext().getSessionMap().get(VIEW_STACK);
|
||||||
|
|
||||||
|
if (viewStack == null)
|
||||||
|
{
|
||||||
|
viewStack = new Stack();
|
||||||
|
context.getExternalContext().getSessionMap().put(VIEW_STACK, viewStack);
|
||||||
|
}
|
||||||
|
|
||||||
|
return viewStack;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -28,6 +28,7 @@ import javax.faces.event.ActionEvent;
|
|||||||
import javax.transaction.UserTransaction;
|
import javax.transaction.UserTransaction;
|
||||||
|
|
||||||
import org.alfresco.model.ContentModel;
|
import org.alfresco.model.ContentModel;
|
||||||
|
import org.alfresco.model.ForumModel;
|
||||||
import org.alfresco.service.cmr.dictionary.DictionaryService;
|
import org.alfresco.service.cmr.dictionary.DictionaryService;
|
||||||
import org.alfresco.service.cmr.dictionary.TypeDefinition;
|
import org.alfresco.service.cmr.dictionary.TypeDefinition;
|
||||||
import org.alfresco.service.cmr.lock.LockService;
|
import org.alfresco.service.cmr.lock.LockService;
|
||||||
@@ -43,6 +44,8 @@ import org.alfresco.service.cmr.search.ResultSetRow;
|
|||||||
import org.alfresco.service.cmr.search.SearchService;
|
import org.alfresco.service.cmr.search.SearchService;
|
||||||
import org.alfresco.service.cmr.security.PermissionService;
|
import org.alfresco.service.cmr.security.PermissionService;
|
||||||
import org.alfresco.service.namespace.QName;
|
import org.alfresco.service.namespace.QName;
|
||||||
|
import org.alfresco.service.namespace.RegexQNamePattern;
|
||||||
|
import org.alfresco.web.app.AlfrescoNavigationHandler;
|
||||||
import org.alfresco.web.app.Application;
|
import org.alfresco.web.app.Application;
|
||||||
import org.alfresco.web.app.context.IContextListener;
|
import org.alfresco.web.app.context.IContextListener;
|
||||||
import org.alfresco.web.app.context.UIContextService;
|
import org.alfresco.web.app.context.UIContextService;
|
||||||
@@ -399,6 +402,7 @@ public class BrowseBean implements IContextListener
|
|||||||
node.addPropertyResolver("size", this.resolverSize);
|
node.addPropertyResolver("size", this.resolverSize);
|
||||||
node.addPropertyResolver("cancelCheckOut", this.resolverCancelCheckOut);
|
node.addPropertyResolver("cancelCheckOut", this.resolverCancelCheckOut);
|
||||||
node.addPropertyResolver("checkIn", this.resolverCheckIn);
|
node.addPropertyResolver("checkIn", this.resolverCheckIn);
|
||||||
|
node.addPropertyResolver("beingDiscussed", this.resolverBeingDiscussed);
|
||||||
node.addPropertyResolver("editLinkType", this.resolverEditLinkType);
|
node.addPropertyResolver("editLinkType", this.resolverEditLinkType);
|
||||||
node.addPropertyResolver("webdavUrl", this.resolverWebdavUrl);
|
node.addPropertyResolver("webdavUrl", this.resolverWebdavUrl);
|
||||||
node.addPropertyResolver("cifsPath", this.resolverCifsPath);
|
node.addPropertyResolver("cifsPath", this.resolverCifsPath);
|
||||||
@@ -490,9 +494,9 @@ public class BrowseBean implements IContextListener
|
|||||||
// build a NodeRef for the specified Id and our store
|
// build a NodeRef for the specified Id and our store
|
||||||
parentRef = new NodeRef(Repository.getStoreRef(), parentNodeId);
|
parentRef = new NodeRef(Repository.getStoreRef(), parentNodeId);
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: can we improve the Get here with an API call for children of a specific type?
|
List<ChildAssociationRef> childRefs = this.nodeService.getChildAssocs(parentRef,
|
||||||
List<ChildAssociationRef> childRefs = this.nodeService.getChildAssocs(parentRef);
|
ContentModel.ASSOC_CONTAINS, RegexQNamePattern.MATCH_ALL);
|
||||||
this.containerNodes = new ArrayList<Node>(childRefs.size());
|
this.containerNodes = new ArrayList<Node>(childRefs.size());
|
||||||
this.contentNodes = new ArrayList<Node>(childRefs.size());
|
this.contentNodes = new ArrayList<Node>(childRefs.size());
|
||||||
for (ChildAssociationRef ref: childRefs)
|
for (ChildAssociationRef ref: childRefs)
|
||||||
@@ -517,6 +521,7 @@ public class BrowseBean implements IContextListener
|
|||||||
// create our Node representation
|
// create our Node representation
|
||||||
MapNode node = new MapNode(nodeRef, this.nodeService, true);
|
MapNode node = new MapNode(nodeRef, this.nodeService, true);
|
||||||
node.addPropertyResolver("icon", this.resolverSpaceIcon);
|
node.addPropertyResolver("icon", this.resolverSpaceIcon);
|
||||||
|
node.addPropertyResolver("beingDiscussed", this.resolverBeingDiscussed);
|
||||||
|
|
||||||
this.containerNodes.add(node);
|
this.containerNodes.add(node);
|
||||||
}
|
}
|
||||||
@@ -632,6 +637,7 @@ public class BrowseBean implements IContextListener
|
|||||||
node.addPropertyResolver("path", this.resolverPath);
|
node.addPropertyResolver("path", this.resolverPath);
|
||||||
node.addPropertyResolver("displayPath", this.resolverDisplayPath);
|
node.addPropertyResolver("displayPath", this.resolverDisplayPath);
|
||||||
node.addPropertyResolver("icon", this.resolverSpaceIcon);
|
node.addPropertyResolver("icon", this.resolverSpaceIcon);
|
||||||
|
node.addPropertyResolver("beingDiscussed", this.resolverBeingDiscussed);
|
||||||
|
|
||||||
this.containerNodes.add(node);
|
this.containerNodes.add(node);
|
||||||
}
|
}
|
||||||
@@ -732,6 +738,12 @@ public class BrowseBean implements IContextListener
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
public NodePropertyResolver resolverBeingDiscussed = new NodePropertyResolver() {
|
||||||
|
public Object get(Node node) {
|
||||||
|
return node.hasAspect(ForumModel.ASPECT_DISCUSSABLE);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
public NodePropertyResolver resolverDownload = new NodePropertyResolver() {
|
public NodePropertyResolver resolverDownload = new NodePropertyResolver() {
|
||||||
public Object get(Node node) {
|
public Object get(Node node) {
|
||||||
return DownloadContentServlet.generateDownloadURL(node.getNodeRef(), node.getName());
|
return DownloadContentServlet.generateDownloadURL(node.getNodeRef(), node.getName());
|
||||||
@@ -865,9 +877,7 @@ public class BrowseBean implements IContextListener
|
|||||||
try
|
try
|
||||||
{
|
{
|
||||||
NodeRef ref = new NodeRef(Repository.getStoreRef(), id);
|
NodeRef ref = new NodeRef(Repository.getStoreRef(), id);
|
||||||
|
clickSpace(ref);
|
||||||
// refresh UI based on node selection
|
|
||||||
updateUILocation(ref);
|
|
||||||
}
|
}
|
||||||
catch (InvalidNodeRefException refErr)
|
catch (InvalidNodeRefException refErr)
|
||||||
{
|
{
|
||||||
@@ -877,6 +887,17 @@ public class BrowseBean implements IContextListener
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Action called when a folder space is clicked.
|
||||||
|
*
|
||||||
|
* @param nodeRef The node being clicked
|
||||||
|
*/
|
||||||
|
public void clickSpace(NodeRef nodeRef)
|
||||||
|
{
|
||||||
|
// refresh UI based on node selection
|
||||||
|
updateUILocation(nodeRef);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Handler called when a path element is clicked - navigate to the appropriate Space
|
* Handler called when a path element is clicked - navigate to the appropriate Space
|
||||||
*/
|
*/
|
||||||
|
@@ -48,7 +48,7 @@ public class ExportBean
|
|||||||
private static final String ALL_SPACES = "all";
|
private static final String ALL_SPACES = "all";
|
||||||
private static final String CURRENT_SPACE = "current";
|
private static final String CURRENT_SPACE = "current";
|
||||||
|
|
||||||
private static final String DEFAULT_OUTCOME = "browse";
|
private static final String DEFAULT_OUTCOME = "dialog:close";
|
||||||
|
|
||||||
private static final String MSG_ERROR = "error_export";
|
private static final String MSG_ERROR = "error_export";
|
||||||
|
|
||||||
|
@@ -17,11 +17,15 @@
|
|||||||
package org.alfresco.web.bean;
|
package org.alfresco.web.bean;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
import java.io.Writer;
|
||||||
import java.text.MessageFormat;
|
import java.text.MessageFormat;
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
import java.util.Date;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
import javax.faces.component.UIComponent;
|
import javax.faces.component.UIComponent;
|
||||||
import javax.faces.context.FacesContext;
|
import javax.faces.context.FacesContext;
|
||||||
@@ -29,6 +33,7 @@ import javax.faces.context.ResponseWriter;
|
|||||||
import javax.faces.event.ActionEvent;
|
import javax.faces.event.ActionEvent;
|
||||||
import javax.transaction.UserTransaction;
|
import javax.transaction.UserTransaction;
|
||||||
|
|
||||||
|
import org.alfresco.error.AlfrescoRuntimeException;
|
||||||
import org.alfresco.model.ContentModel;
|
import org.alfresco.model.ContentModel;
|
||||||
import org.alfresco.model.ForumModel;
|
import org.alfresco.model.ForumModel;
|
||||||
import org.alfresco.service.cmr.dictionary.DictionaryService;
|
import org.alfresco.service.cmr.dictionary.DictionaryService;
|
||||||
@@ -44,6 +49,8 @@ import org.alfresco.service.cmr.search.QueryParameterDefinition;
|
|||||||
import org.alfresco.service.cmr.search.SearchService;
|
import org.alfresco.service.cmr.search.SearchService;
|
||||||
import org.alfresco.service.namespace.NamespaceService;
|
import org.alfresco.service.namespace.NamespaceService;
|
||||||
import org.alfresco.service.namespace.QName;
|
import org.alfresco.service.namespace.QName;
|
||||||
|
import org.alfresco.service.namespace.RegexQNamePattern;
|
||||||
|
import org.alfresco.web.app.AlfrescoNavigationHandler;
|
||||||
import org.alfresco.web.app.Application;
|
import org.alfresco.web.app.Application;
|
||||||
import org.alfresco.web.app.context.IContextListener;
|
import org.alfresco.web.app.context.IContextListener;
|
||||||
import org.alfresco.web.app.context.UIContextService;
|
import org.alfresco.web.app.context.UIContextService;
|
||||||
@@ -53,6 +60,7 @@ import org.alfresco.web.bean.repository.NodePropertyResolver;
|
|||||||
import org.alfresco.web.bean.repository.Repository;
|
import org.alfresco.web.bean.repository.Repository;
|
||||||
import org.alfresco.web.config.ClientConfigElement;
|
import org.alfresco.web.config.ClientConfigElement;
|
||||||
import org.alfresco.web.ui.common.Utils;
|
import org.alfresco.web.ui.common.Utils;
|
||||||
|
import org.alfresco.web.ui.common.component.UIActionLink;
|
||||||
import org.alfresco.web.ui.common.component.UIModeList;
|
import org.alfresco.web.ui.common.component.UIModeList;
|
||||||
import org.alfresco.web.ui.common.component.data.UIColumn;
|
import org.alfresco.web.ui.common.component.data.UIColumn;
|
||||||
import org.alfresco.web.ui.common.component.data.UIRichList;
|
import org.alfresco.web.ui.common.component.data.UIRichList;
|
||||||
@@ -428,8 +436,8 @@ public class ForumsBean implements IContextListener
|
|||||||
parentRef = new NodeRef(Repository.getStoreRef(), parentNodeId);
|
parentRef = new NodeRef(Repository.getStoreRef(), parentNodeId);
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: can we improve the Get here with an API call for children of a specific type?
|
List<ChildAssociationRef> childRefs = this.nodeService.getChildAssocs(parentRef,
|
||||||
List<ChildAssociationRef> childRefs = this.nodeService.getChildAssocs(parentRef);
|
ContentModel.ASSOC_CONTAINS, RegexQNamePattern.MATCH_ALL);
|
||||||
this.forums = new ArrayList<Node>(childRefs.size());
|
this.forums = new ArrayList<Node>(childRefs.size());
|
||||||
this.topics = new ArrayList<Node>(childRefs.size());
|
this.topics = new ArrayList<Node>(childRefs.size());
|
||||||
this.posts = new ArrayList<Node>(childRefs.size());
|
this.posts = new ArrayList<Node>(childRefs.size());
|
||||||
@@ -596,6 +604,13 @@ public class ForumsBean implements IContextListener
|
|||||||
|
|
||||||
// push the view mode into the lists
|
// push the view mode into the lists
|
||||||
setForumsViewMode(viewMode);
|
setForumsViewMode(viewMode);
|
||||||
|
|
||||||
|
// get the default for the forum page
|
||||||
|
this.forumsPageSize = this.clientConfig.getDefaultPageSize(PAGE_NAME_FORUMS,
|
||||||
|
this.forumsViewMode);
|
||||||
|
|
||||||
|
if (logger.isDebugEnabled())
|
||||||
|
logger.debug("Set default forums page size to: " + this.forumsPageSize);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -612,6 +627,13 @@ public class ForumsBean implements IContextListener
|
|||||||
|
|
||||||
// push the view mode into the lists
|
// push the view mode into the lists
|
||||||
setForumViewMode(viewMode);
|
setForumViewMode(viewMode);
|
||||||
|
|
||||||
|
// get the default for the forum page
|
||||||
|
this.forumPageSize = this.clientConfig.getDefaultPageSize(PAGE_NAME_FORUM,
|
||||||
|
this.forumViewMode);
|
||||||
|
|
||||||
|
if (logger.isDebugEnabled())
|
||||||
|
logger.debug("Set default forum page size to: " + this.forumPageSize);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -628,6 +650,137 @@ public class ForumsBean implements IContextListener
|
|||||||
|
|
||||||
// push the view mode into the lists
|
// push the view mode into the lists
|
||||||
setTopicViewMode(viewMode);
|
setTopicViewMode(viewMode);
|
||||||
|
|
||||||
|
// change the default page size if necessary
|
||||||
|
this.topicPageSize = this.clientConfig.getDefaultPageSize(PAGE_NAME_TOPIC,
|
||||||
|
this.topicViewMode);
|
||||||
|
|
||||||
|
if (logger.isDebugEnabled())
|
||||||
|
logger.debug("Set default topic page size to: " + this.topicPageSize);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Event handler called when a user wants to view or participate
|
||||||
|
* in a discussion on an object
|
||||||
|
*
|
||||||
|
* @param event ActionEvent
|
||||||
|
*/
|
||||||
|
public void discuss(ActionEvent event)
|
||||||
|
{
|
||||||
|
UIActionLink link = (UIActionLink)event.getComponent();
|
||||||
|
Map<String, String> params = link.getParameterMap();
|
||||||
|
String id = params.get("id");
|
||||||
|
if (id == null || id.length() == 0)
|
||||||
|
{
|
||||||
|
throw new AlfrescoRuntimeException("discuss called without an id");
|
||||||
|
}
|
||||||
|
|
||||||
|
FacesContext context = FacesContext.getCurrentInstance();
|
||||||
|
|
||||||
|
NodeRef nodeRef = new NodeRef(Repository.getStoreRef(), id);
|
||||||
|
|
||||||
|
if (this.nodeService.hasAspect(nodeRef, ForumModel.ASPECT_DISCUSSABLE) == false)
|
||||||
|
{
|
||||||
|
throw new AlfrescoRuntimeException("discuss called for an object that does not have a discussion!");
|
||||||
|
}
|
||||||
|
|
||||||
|
// as the node has the discussable aspect there must be a discussions child assoc
|
||||||
|
List<ChildAssociationRef> children = this.nodeService.getChildAssocs(nodeRef,
|
||||||
|
ForumModel.ASSOC_DISCUSSION, RegexQNamePattern.MATCH_ALL);
|
||||||
|
|
||||||
|
// there should only be one child, retrieve it if there is
|
||||||
|
if (children.size() == 1)
|
||||||
|
{
|
||||||
|
NodeRef forumNodeRef = children.get(0).getChildRef();
|
||||||
|
|
||||||
|
// query for the number of topics there are
|
||||||
|
String repliesXPath = "./*[(subtypeOf('" + ForumModel.TYPE_TOPIC + "'))]";
|
||||||
|
List<NodeRef> topics = searchService.selectNodes(forumNodeRef, repliesXPath,
|
||||||
|
new QueryParameterDefinition[] {}, this.namespaceService, false);
|
||||||
|
if (topics.size() == 1)
|
||||||
|
{
|
||||||
|
// if the forum has only one topic go straight into the topic by
|
||||||
|
// setting the context and navigating to it
|
||||||
|
NodeRef topicNodeRef = topics.get(0);
|
||||||
|
this.browseBean.clickSpace(topicNodeRef);
|
||||||
|
context.getApplication().getNavigationHandler().handleNavigation(context, null, "showTopic");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// if the forum has more than one topic we need to setup the context
|
||||||
|
// for the forum and navigate to the forum page
|
||||||
|
this.browseBean.clickSpace(forumNodeRef);
|
||||||
|
context.getApplication().getNavigationHandler().handleNavigation(context, null, "showForum");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Called when the user confirms they wish to delete a forum space
|
||||||
|
*
|
||||||
|
* @return The outcome
|
||||||
|
*/
|
||||||
|
public String deleteForumsOK()
|
||||||
|
{
|
||||||
|
String outcome = "browse";
|
||||||
|
|
||||||
|
// find out what the parent type of the node being deleted
|
||||||
|
Node node = this.browseBean.getActionSpace();
|
||||||
|
ChildAssociationRef assoc = this.nodeService.getPrimaryParent(node.getNodeRef());
|
||||||
|
if (assoc != null)
|
||||||
|
{
|
||||||
|
NodeRef parent = assoc.getParentRef();
|
||||||
|
QName parentType = this.nodeService.getType(parent);
|
||||||
|
if (parentType.equals(ForumModel.TYPE_FORUMS))
|
||||||
|
{
|
||||||
|
outcome = "forumsDeleted";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// call the generic handler
|
||||||
|
this.browseBean.deleteSpaceOK();
|
||||||
|
|
||||||
|
// return an overidden outcome which closes the dialog with an outcome
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME +
|
||||||
|
AlfrescoNavigationHandler.DIALOG_SEPARATOR + outcome;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Called when the user confirms they wish to delete a forum space
|
||||||
|
*
|
||||||
|
* @return The outcome
|
||||||
|
*/
|
||||||
|
public String deleteForumOK()
|
||||||
|
{
|
||||||
|
this.browseBean.deleteSpaceOK();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME +
|
||||||
|
AlfrescoNavigationHandler.DIALOG_SEPARATOR + "forumDeleted";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Called when the user confirms they wish to delete a forum space
|
||||||
|
*
|
||||||
|
* @return The outcome
|
||||||
|
*/
|
||||||
|
public String deleteTopicOK()
|
||||||
|
{
|
||||||
|
this.browseBean.deleteSpaceOK();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME +
|
||||||
|
AlfrescoNavigationHandler.DIALOG_SEPARATOR + "topicDeleted";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Called when the user confirms they wish to delete a forum space
|
||||||
|
*
|
||||||
|
* @return The outcome
|
||||||
|
*/
|
||||||
|
public String deletePostOK()
|
||||||
|
{
|
||||||
|
this.browseBean.deleteFileOK();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
|
||||||
}
|
}
|
||||||
|
|
||||||
// ------------------------------------------------------------------------------
|
// ------------------------------------------------------------------------------
|
||||||
@@ -703,6 +856,25 @@ public class ForumsBean implements IContextListener
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Creates a file name for the message being posted
|
||||||
|
*
|
||||||
|
* @return The file name for the post
|
||||||
|
*/
|
||||||
|
public static String createPostFileName()
|
||||||
|
{
|
||||||
|
StringBuilder name = new StringBuilder("posted-");
|
||||||
|
|
||||||
|
// add a timestamp
|
||||||
|
SimpleDateFormat dateFormat = new SimpleDateFormat("dd-MM-yyyy-hh:mm:ss");
|
||||||
|
name.append(dateFormat.format(new Date()));
|
||||||
|
|
||||||
|
// add the HTML file extension
|
||||||
|
name.append(".html");
|
||||||
|
|
||||||
|
return name.toString();
|
||||||
|
}
|
||||||
|
|
||||||
// ------------------------------------------------------------------------------
|
// ------------------------------------------------------------------------------
|
||||||
// Private helpers
|
// Private helpers
|
||||||
|
|
||||||
@@ -839,6 +1011,124 @@ public class ForumsBean implements IContextListener
|
|||||||
out.write("</td></tr>");
|
out.write("</td></tr>");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Renders the top part of the bubble i.e. before the header
|
||||||
|
*
|
||||||
|
* @param out The writer to output to
|
||||||
|
* @param contextPath Context path of the application
|
||||||
|
* @param colour The colour of the bubble
|
||||||
|
* @param titleBgColour Background colour of the header area
|
||||||
|
*/
|
||||||
|
public static void renderBubbleTop(Writer out, String contextPath,
|
||||||
|
String colour, String titleBgColour) throws IOException
|
||||||
|
{
|
||||||
|
out.write("<table border='0' cellpadding='0' cellspacing='0' width='100%'><tr>");
|
||||||
|
out.write("<td style='background: url(");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("header_1.gif) no-repeat #FFFFFF;' width='24' height='24'></td>");
|
||||||
|
out.write("<td style='background: url(");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("header_2.gif) repeat-x ");
|
||||||
|
out.write(titleBgColour);
|
||||||
|
out.write("'>");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Renders the middle part of the bubble i.e. after the header and before the body
|
||||||
|
*
|
||||||
|
* @param out The writer to output to
|
||||||
|
* @param contextPath Context path of the application
|
||||||
|
* @param colour The colour of the bubble
|
||||||
|
*/
|
||||||
|
public static void renderBubbleMiddle(Writer out, String contextPath, String colour)
|
||||||
|
throws IOException
|
||||||
|
{
|
||||||
|
out.write("</td>");
|
||||||
|
out.write("<td style='background: url(");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("header_3.gif) no-repeat #FFFFFF;' width='24' height='24'></td>");
|
||||||
|
out.write("</tr><tr>");
|
||||||
|
out.write("<td width='24' height='13'><img width='24' height='13' alt='' src='");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("body_1.gif' /></td>");
|
||||||
|
out.write("<td background='");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("body_2.gif'><img width='21' height='13' alt='' src='");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("body_2.gif' /></td>");
|
||||||
|
out.write("<td width='24' height='13'><img width='24' height='13' alt='' src='");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("body_3.gif' /></td>");
|
||||||
|
out.write("</tr><tr>");
|
||||||
|
out.write("<td width='24' height='13' background='");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("body_4.gif'><img width='24' height='4' alt='' src='");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("body_4.gif' /></td>");
|
||||||
|
out.write("<td>");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Renders the bottom part of the bubble i.e. after the body
|
||||||
|
*
|
||||||
|
* @param out The writer to output to
|
||||||
|
* @param contextPath Context path of the application
|
||||||
|
* @param colour The colour of the bubble
|
||||||
|
*/
|
||||||
|
public static void renderBubbleBottom(Writer out, String contextPath, String colour)
|
||||||
|
throws IOException
|
||||||
|
{
|
||||||
|
out.write("</td>");
|
||||||
|
out.write("<td width='24' height='13' background='");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("body_6.gif'><img width='24' height='3' alt='' src='");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("body_6.gif' /></td>");
|
||||||
|
out.write("</tr><tr>");
|
||||||
|
out.write("<td width='24' height='13'><img width='24' height='13' alt='' src='");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("body_7.gif' /></td>");
|
||||||
|
out.write("<td background='");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("body_8.gif'><img width='20' height='13' alt='' src='");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("body_8.gif' /></td>");
|
||||||
|
out.write("<td width='24' height='13'><img width='24' height='13' alt='' src='");
|
||||||
|
out.write(contextPath);
|
||||||
|
out.write("/images/parts/");
|
||||||
|
out.write(colour);
|
||||||
|
out.write("body_9.gif' /></td>");
|
||||||
|
out.write("</tr></table>");
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Renders the new post speech bubble
|
* Renders the new post speech bubble
|
||||||
*
|
*
|
||||||
@@ -852,13 +1142,22 @@ public class ForumsBean implements IContextListener
|
|||||||
private void renderNewPostBubble(FacesContext context, ResponseWriter out, Node node,
|
private void renderNewPostBubble(FacesContext context, ResponseWriter out, Node node,
|
||||||
UIColumn primaryColumn, UIColumn actionsColumn, UIColumn[] columns) throws IOException
|
UIColumn primaryColumn, UIColumn actionsColumn, UIColumn[] columns) throws IOException
|
||||||
{
|
{
|
||||||
|
String contextPath = context.getExternalContext().getRequestContextPath();
|
||||||
|
String colour = "orange";
|
||||||
|
|
||||||
out.write("<td><table border='0' cellpadding='0' cellspacing='0' width='100%'><tr>");
|
out.write("<td><table border='0' cellpadding='0' cellspacing='0' width='100%'><tr>");
|
||||||
out.write("<td><img src='");
|
out.write("<td><img src='");
|
||||||
out.write(context.getExternalContext().getRequestContextPath());
|
out.write(contextPath);
|
||||||
out.write("/images/icons/user_large.gif'/><br/>");
|
out.write("/images/icons/user_large.gif'/><br/>");
|
||||||
out.write((String)node.getProperties().get("creator"));
|
out.write((String)node.getProperties().get("creator"));
|
||||||
out.write("</td><td width='100%'>");
|
out.write("</td><td width='100%'>");
|
||||||
renderBubble(context, out, "orange", "#FCC75E", primaryColumn, actionsColumn, columns);
|
|
||||||
|
renderBubbleTop(out, contextPath, colour, "#FCC75E");
|
||||||
|
renderHeaderContents(context, out, primaryColumn, actionsColumn, columns);
|
||||||
|
renderBubbleMiddle(out, contextPath, colour);
|
||||||
|
renderBodyContents(context, primaryColumn);
|
||||||
|
renderBubbleBottom(out, contextPath, colour);
|
||||||
|
|
||||||
out.write("</td><td><div style='width:32px;' /></td></table></td>");
|
out.write("</td><td><div style='width:32px;' /></td></table></td>");
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -875,48 +1174,28 @@ public class ForumsBean implements IContextListener
|
|||||||
private void renderReplyToBubble(FacesContext context, ResponseWriter out, Node node,
|
private void renderReplyToBubble(FacesContext context, ResponseWriter out, Node node,
|
||||||
UIColumn primaryColumn, UIColumn actionsColumn, UIColumn[] columns) throws IOException
|
UIColumn primaryColumn, UIColumn actionsColumn, UIColumn[] columns) throws IOException
|
||||||
{
|
{
|
||||||
|
String contextPath = context.getExternalContext().getRequestContextPath();
|
||||||
|
String colour = "yellow";
|
||||||
|
|
||||||
out.write("<td width='100%'><table border='0' cellpadding='0' cellspacing='0' width='100%'><tr>");
|
out.write("<td width='100%'><table border='0' cellpadding='0' cellspacing='0' width='100%'><tr>");
|
||||||
out.write("<td><div style='width:32px;' /></td><td width='100%'>");
|
out.write("<td><div style='width:32px;' /></td><td width='100%'>");
|
||||||
renderBubble(context, out, "yellow", "#FFF5A3", primaryColumn, actionsColumn, columns);
|
|
||||||
|
renderBubbleTop(out, contextPath, colour, "#FFF5A3");
|
||||||
|
renderHeaderContents(context, out, primaryColumn, actionsColumn, columns);
|
||||||
|
renderBubbleMiddle(out, contextPath, colour);
|
||||||
|
renderBodyContents(context, primaryColumn);
|
||||||
|
renderBubbleBottom(out, contextPath, colour);
|
||||||
|
|
||||||
out.write("</td><td><img src='");
|
out.write("</td><td><img src='");
|
||||||
out.write(context.getExternalContext().getRequestContextPath());
|
out.write(contextPath);
|
||||||
out.write("/images/icons/user_large.gif'/><br/>");
|
out.write("/images/icons/user_large.gif'/><br/>");
|
||||||
out.write((String)node.getProperties().get("creator"));
|
out.write((String)node.getProperties().get("creator"));
|
||||||
out.write("</td></table></td>");
|
out.write("</td></table></td>");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
private void renderHeaderContents(FacesContext context, ResponseWriter out,
|
||||||
* Renders the speech bubble
|
UIColumn primaryColumn, UIColumn actionsColumn, UIColumn[] columns) throws IOException
|
||||||
*
|
|
||||||
* @param context Faces context
|
|
||||||
* @param out The response writer
|
|
||||||
* @param colour The colour of the bubble
|
|
||||||
* @param titleBgColour The colour of the background of the title area (#rrggbb)
|
|
||||||
* @param primaryColumn The primary column containing the message content
|
|
||||||
* @param actionsColumn The actions column containing all the actions
|
|
||||||
* @param columns All configured columns
|
|
||||||
*/
|
|
||||||
private void renderBubble(FacesContext context, ResponseWriter out,
|
|
||||||
String colour, String titleBgColour,
|
|
||||||
UIColumn primaryColumn, UIColumn actionsColumn, UIColumn[] columns)
|
|
||||||
throws IOException
|
|
||||||
{
|
{
|
||||||
String contextPath = context.getExternalContext().getRequestContextPath();
|
|
||||||
|
|
||||||
out.write("<table border='0' cellpadding='0' cellspacing='0' width='100%'><tr>");
|
|
||||||
out.write("<td style='background: url(");
|
|
||||||
out.write(contextPath);
|
|
||||||
out.write("/images/parts/");
|
|
||||||
out.write(colour);
|
|
||||||
out.write("header_1.gif) no-repeat #FFFFFF;' width='24' height='24'></td>");
|
|
||||||
out.write("<td style='background: url(");
|
|
||||||
out.write(contextPath);
|
|
||||||
out.write("/images/parts/");
|
|
||||||
out.write(colour);
|
|
||||||
out.write("header_2.gif) repeat-x ");
|
|
||||||
out.write(titleBgColour);
|
|
||||||
out.write("'>");
|
|
||||||
|
|
||||||
// render the header area with the configured columns
|
// render the header area with the configured columns
|
||||||
out.write("<table width='100%' cellpadding='2' cellspacing='2' border='0'><tr>");
|
out.write("<table width='100%' cellpadding='2' cellspacing='2' border='0'><tr>");
|
||||||
|
|
||||||
@@ -948,73 +1227,28 @@ public class ForumsBean implements IContextListener
|
|||||||
}
|
}
|
||||||
|
|
||||||
// render the actions column
|
// render the actions column
|
||||||
out.write("<td align='right' width='100%'>");
|
out.write("<td align='right' width='100%'><nobr>");
|
||||||
if (actionsColumn != null && actionsColumn.getChildCount() != 0)
|
if (actionsColumn != null && actionsColumn.getChildCount() != 0)
|
||||||
{
|
{
|
||||||
Utils.encodeRecursive(context, actionsColumn);
|
Utils.encodeRecursive(context, actionsColumn);
|
||||||
}
|
}
|
||||||
out.write("</td></tr></table>");
|
out.write("</nobr></td></tr></table>");
|
||||||
|
}
|
||||||
out.write("</td>");
|
|
||||||
out.write("<td style='background: url(");
|
/**
|
||||||
out.write(contextPath);
|
* Renders the body contents for the bubble using the given primary coumn
|
||||||
out.write("/images/parts/");
|
*
|
||||||
out.write(colour);
|
* @param context Faces context
|
||||||
out.write("header_3.gif) no-repeat #FFFFFF;' width='24' height='24'></td>");
|
* @param primaryColumn The primary column holding the message text
|
||||||
out.write("</tr></tr>");
|
*/
|
||||||
out.write("<td style='background: url(");
|
private void renderBodyContents(FacesContext context, UIColumn primaryColumn)
|
||||||
out.write(contextPath);
|
throws IOException
|
||||||
out.write("/images/parts/");
|
{
|
||||||
out.write(colour);
|
|
||||||
out.write("body_1.gif) no-repeat #FFFFFF;' width='24' height='13'></td>");
|
|
||||||
out.write("<td style='background: url(");
|
|
||||||
out.write(contextPath);
|
|
||||||
out.write("/images/parts/");
|
|
||||||
out.write(colour);
|
|
||||||
out.write("body_2.gif) repeat-x #FFFFFF;'></td>");
|
|
||||||
out.write("<td style='background: url(");
|
|
||||||
out.write(contextPath);
|
|
||||||
out.write("/images/parts/");
|
|
||||||
out.write(colour);
|
|
||||||
out.write("body_3.gif) no-repeat #FFFFFF;' width='24' height='13'></td>");
|
|
||||||
out.write("</tr><tr>");
|
|
||||||
out.write("<td style='background: url(");
|
|
||||||
out.write(contextPath);
|
|
||||||
out.write("/images/parts/");
|
|
||||||
out.write(colour);
|
|
||||||
out.write("body_4.gif) repeat-y #FFFFFF;' width='24' height='13'></td>");
|
|
||||||
out.write("<td>");
|
|
||||||
|
|
||||||
// render the primary column
|
// render the primary column
|
||||||
if (primaryColumn != null && primaryColumn.getChildCount() != 0)
|
if (primaryColumn != null && primaryColumn.getChildCount() != 0)
|
||||||
{
|
{
|
||||||
Utils.encodeRecursive(context, primaryColumn);
|
Utils.encodeRecursive(context, primaryColumn);
|
||||||
}
|
}
|
||||||
|
|
||||||
out.write("</td>");
|
|
||||||
|
|
||||||
out.write("<td style='background: url(");
|
|
||||||
out.write(contextPath);
|
|
||||||
out.write("/images/parts/");
|
|
||||||
out.write(colour);
|
|
||||||
out.write("body_6.gif) repeat-y #FFFFFF;' width='24' height='13'></td>");
|
|
||||||
out.write("</tr><tr>");
|
|
||||||
out.write("<td style='background: url(");
|
|
||||||
out.write(contextPath);
|
|
||||||
out.write("/images/parts/");
|
|
||||||
out.write(colour);
|
|
||||||
out.write("body_7.gif) no-repeat #FFFFFF;' width='24' height='13'></td>");
|
|
||||||
out.write("<td style='background: url(");
|
|
||||||
out.write(contextPath);
|
|
||||||
out.write("/images/parts/");
|
|
||||||
out.write(colour);
|
|
||||||
out.write("body_8.gif) repeat-x #FFFFFF;'></td>");
|
|
||||||
out.write("<td style='background: url(");
|
|
||||||
out.write(contextPath);
|
|
||||||
out.write("/images/parts/");
|
|
||||||
out.write(colour);
|
|
||||||
out.write("body_9.gif) no-repeat #FFFFFF;' width='24' height='13'></td>");
|
|
||||||
out.write("</tr></table>");
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -53,7 +53,7 @@ public class ImportBean
|
|||||||
{
|
{
|
||||||
private static final Log logger = LogFactory.getLog(ImportBean.class);
|
private static final Log logger = LogFactory.getLog(ImportBean.class);
|
||||||
|
|
||||||
private static final String DEFAULT_OUTCOME = "browse";
|
private static final String DEFAULT_OUTCOME = "dialog:close";
|
||||||
|
|
||||||
private static final String MSG_ERROR = "error_import";
|
private static final String MSG_ERROR = "error_import";
|
||||||
private static final String MSG_ERROR_NO_FILE = "error_import_no_file";
|
private static final String MSG_ERROR_NO_FILE = "error_import_no_file";
|
||||||
|
@@ -34,6 +34,7 @@ import org.alfresco.service.cmr.repository.TemplateImageResolver;
|
|||||||
import org.alfresco.service.cmr.repository.TemplateNode;
|
import org.alfresco.service.cmr.repository.TemplateNode;
|
||||||
import org.alfresco.service.cmr.security.PermissionService;
|
import org.alfresco.service.cmr.security.PermissionService;
|
||||||
import org.alfresco.service.namespace.NamespaceService;
|
import org.alfresco.service.namespace.NamespaceService;
|
||||||
|
import org.alfresco.web.app.AlfrescoNavigationHandler;
|
||||||
import org.alfresco.web.app.Application;
|
import org.alfresco.web.app.Application;
|
||||||
import org.alfresco.web.bean.repository.Node;
|
import org.alfresco.web.bean.repository.Node;
|
||||||
import org.alfresco.web.bean.repository.Repository;
|
import org.alfresco.web.bean.repository.Repository;
|
||||||
@@ -208,6 +209,7 @@ public class SpaceDetailsBean
|
|||||||
*
|
*
|
||||||
* @return model containing current current space info.
|
* @return model containing current current space info.
|
||||||
*/
|
*/
|
||||||
|
@SuppressWarnings("unchecked")
|
||||||
public Map getTemplateModel()
|
public Map getTemplateModel()
|
||||||
{
|
{
|
||||||
HashMap model = new HashMap(1, 1.0f);
|
HashMap model = new HashMap(1, 1.0f);
|
||||||
@@ -402,6 +404,6 @@ public class SpaceDetailsBean
|
|||||||
public String closeDialog()
|
public String closeDialog()
|
||||||
{
|
{
|
||||||
this.navigator.resetCurrentNodeProperties();
|
this.navigator.resetCurrentNodeProperties();
|
||||||
return "browse";
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -0,0 +1,132 @@
|
|||||||
|
/*
|
||||||
|
* Copyright (C) 2005 Alfresco, Inc.
|
||||||
|
*
|
||||||
|
* Licensed under the GNU Lesser General Public License as
|
||||||
|
* published by the Free Software Foundation; either version
|
||||||
|
* 2.1 of the License, or (at your option) any later version.
|
||||||
|
* You may obtain a copy of the License at
|
||||||
|
*
|
||||||
|
* http://www.gnu.org/licenses/lgpl.txt
|
||||||
|
*
|
||||||
|
* Unless required by applicable law or agreed to in writing,
|
||||||
|
* software distributed under the License is distributed on an
|
||||||
|
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
|
||||||
|
* either express or implied. See the License for the specific
|
||||||
|
* language governing permissions and limitations under the
|
||||||
|
* License.
|
||||||
|
*/
|
||||||
|
package org.alfresco.web.bean.wizard;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.text.MessageFormat;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
import javax.faces.context.FacesContext;
|
||||||
|
import javax.faces.event.ActionEvent;
|
||||||
|
import javax.transaction.UserTransaction;
|
||||||
|
|
||||||
|
import org.alfresco.error.AlfrescoRuntimeException;
|
||||||
|
import org.alfresco.model.ContentModel;
|
||||||
|
import org.alfresco.model.ForumModel;
|
||||||
|
import org.alfresco.service.cmr.repository.ChildAssociationRef;
|
||||||
|
import org.alfresco.service.cmr.repository.NodeRef;
|
||||||
|
import org.alfresco.service.namespace.QName;
|
||||||
|
import org.alfresco.web.app.Application;
|
||||||
|
import org.alfresco.web.bean.repository.Repository;
|
||||||
|
import org.alfresco.web.ui.common.Utils;
|
||||||
|
import org.alfresco.web.ui.common.component.UIActionLink;
|
||||||
|
import org.apache.commons.logging.Log;
|
||||||
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Backing bean class used to create discussions for documents
|
||||||
|
*
|
||||||
|
* @author gavinc
|
||||||
|
*/
|
||||||
|
public class NewDiscussionWizard extends NewTopicWizard
|
||||||
|
{
|
||||||
|
private static final Log logger = LogFactory.getLog(NewDiscussionWizard.class);
|
||||||
|
|
||||||
|
private NodeRef discussingNodeRef;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#startWizard(javax.faces.event.ActionEvent)
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void startWizard(ActionEvent event)
|
||||||
|
{
|
||||||
|
UIActionLink link = (UIActionLink)event.getComponent();
|
||||||
|
Map<String, String> params = link.getParameterMap();
|
||||||
|
String id = params.get("id");
|
||||||
|
if (id == null || id.length() == 0)
|
||||||
|
{
|
||||||
|
throw new AlfrescoRuntimeException("startDiscussion called without an id");
|
||||||
|
}
|
||||||
|
|
||||||
|
FacesContext context = FacesContext.getCurrentInstance();
|
||||||
|
UserTransaction tx = null;
|
||||||
|
NodeRef forumNodeRef = null;
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
tx = Repository.getUserTransaction(context);
|
||||||
|
tx.begin();
|
||||||
|
|
||||||
|
this.discussingNodeRef = new NodeRef(Repository.getStoreRef(), id);
|
||||||
|
|
||||||
|
if (this.nodeService.hasAspect(this.discussingNodeRef, ForumModel.ASPECT_DISCUSSABLE))
|
||||||
|
{
|
||||||
|
throw new AlfrescoRuntimeException("startDiscussion called for an object that already has a discussion!");
|
||||||
|
}
|
||||||
|
|
||||||
|
// add the discussable aspect
|
||||||
|
this.nodeService.addAspect(this.discussingNodeRef, ForumModel.ASPECT_DISCUSSABLE, null);
|
||||||
|
|
||||||
|
// create a child forum space using the child association just introduced by
|
||||||
|
// adding the discussable aspect
|
||||||
|
String name = (String)this.nodeService.getProperty(this.discussingNodeRef,
|
||||||
|
ContentModel.PROP_NAME);
|
||||||
|
String msg = Application.getMessage(FacesContext.getCurrentInstance(), "discussion_for");
|
||||||
|
String forumName = MessageFormat.format(msg, new Object[] {name});
|
||||||
|
|
||||||
|
Map<QName, Serializable> forumProps = new HashMap<QName, Serializable>(1);
|
||||||
|
forumProps.put(ContentModel.PROP_NAME, forumName);
|
||||||
|
ChildAssociationRef childRef = this.nodeService.createNode(this.discussingNodeRef,
|
||||||
|
ForumModel.ASSOC_DISCUSSION,
|
||||||
|
QName.createQName(ForumModel.FORUMS_MODEL_URI, "discussion"),
|
||||||
|
ForumModel.TYPE_FORUM, forumProps);
|
||||||
|
|
||||||
|
forumNodeRef = childRef.getChildRef();
|
||||||
|
|
||||||
|
// apply the uifacets aspect
|
||||||
|
Map<QName, Serializable> uiFacetsProps = new HashMap<QName, Serializable>(5);
|
||||||
|
uiFacetsProps.put(ContentModel.PROP_ICON, "forum_large");
|
||||||
|
this.nodeService.addAspect(forumNodeRef, ContentModel.ASPECT_UIFACETS, uiFacetsProps);
|
||||||
|
|
||||||
|
if (logger.isDebugEnabled())
|
||||||
|
logger.debug("created forum for content: " + forumNodeRef.toString());
|
||||||
|
|
||||||
|
// commit the transaction
|
||||||
|
tx.commit();
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
// rollback the transaction
|
||||||
|
try { if (tx != null) {tx.rollback();} } catch (Exception ex) {}
|
||||||
|
Utils.addErrorMessage(MessageFormat.format(Application.getMessage(
|
||||||
|
context, Repository.ERROR_GENERIC), e.getMessage()), e);
|
||||||
|
}
|
||||||
|
|
||||||
|
// finally setup the context for the forum we just created
|
||||||
|
if (forumNodeRef != null)
|
||||||
|
{
|
||||||
|
this.browseBean.clickSpace(forumNodeRef);
|
||||||
|
|
||||||
|
// now initialise the wizard and navigate to it
|
||||||
|
super.startWizard(event);
|
||||||
|
context.getApplication().getNavigationHandler().handleNavigation(context, null, "dialog:createDiscussion");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@@ -17,12 +17,8 @@
|
|||||||
*/
|
*/
|
||||||
package org.alfresco.web.bean.wizard;
|
package org.alfresco.web.bean.wizard;
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
import javax.faces.context.FacesContext;
|
|
||||||
|
|
||||||
import org.alfresco.model.ForumModel;
|
import org.alfresco.model.ForumModel;
|
||||||
import org.alfresco.web.ui.common.component.UIListItem;
|
import org.alfresco.web.app.AlfrescoNavigationHandler;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Wizard bean used for creating and editing forum spaces
|
* Wizard bean used for creating and editing forum spaces
|
||||||
@@ -31,30 +27,6 @@ import org.alfresco.web.ui.common.component.UIListItem;
|
|||||||
*/
|
*/
|
||||||
public class NewForumWizard extends NewSpaceWizard
|
public class NewForumWizard extends NewSpaceWizard
|
||||||
{
|
{
|
||||||
protected String forumStatus;
|
|
||||||
|
|
||||||
protected List<UIListItem> forumIcons;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Returns the status of the forum
|
|
||||||
*
|
|
||||||
* @return The status of the forum
|
|
||||||
*/
|
|
||||||
public String getForumStatus()
|
|
||||||
{
|
|
||||||
return this.forumStatus;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Sets the status of the forum
|
|
||||||
*
|
|
||||||
* @param forumStatus The status
|
|
||||||
*/
|
|
||||||
public void setForumStatus(String forumStatus)
|
|
||||||
{
|
|
||||||
this.forumStatus = forumStatus;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#init()
|
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#init()
|
||||||
*/
|
*/
|
||||||
@@ -63,15 +35,27 @@ public class NewForumWizard extends NewSpaceWizard
|
|||||||
super.init();
|
super.init();
|
||||||
|
|
||||||
this.spaceType = ForumModel.TYPE_FORUM.toString();
|
this.spaceType = ForumModel.TYPE_FORUM.toString();
|
||||||
this.forumStatus = "0";
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#finish()
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String finish()
|
||||||
|
{
|
||||||
|
super.finish();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see org.alfresco.web.bean.wizard.NewSpaceWizard#performCustomProcessing(javax.faces.context.FacesContext)
|
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#cancel()
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
protected void performCustomProcessing(FacesContext context)
|
public String cancel()
|
||||||
{
|
{
|
||||||
// add or update the ForumModel.PROP_STATUS property depending on the editMode
|
super.cancel();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -17,10 +17,8 @@
|
|||||||
*/
|
*/
|
||||||
package org.alfresco.web.bean.wizard;
|
package org.alfresco.web.bean.wizard;
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
import org.alfresco.model.ForumModel;
|
import org.alfresco.model.ForumModel;
|
||||||
import org.alfresco.web.ui.common.component.UIListItem;
|
import org.alfresco.web.app.AlfrescoNavigationHandler;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Wizard bean used for creating and editing forums spaces
|
* Wizard bean used for creating and editing forums spaces
|
||||||
@@ -29,8 +27,6 @@ import org.alfresco.web.ui.common.component.UIListItem;
|
|||||||
*/
|
*/
|
||||||
public class NewForumsWizard extends NewSpaceWizard
|
public class NewForumsWizard extends NewSpaceWizard
|
||||||
{
|
{
|
||||||
protected List<UIListItem> forumsIcons;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#init()
|
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#init()
|
||||||
*/
|
*/
|
||||||
@@ -40,4 +36,26 @@ public class NewForumsWizard extends NewSpaceWizard
|
|||||||
|
|
||||||
this.spaceType = ForumModel.TYPE_FORUMS.toString();
|
this.spaceType = ForumModel.TYPE_FORUMS.toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#finish()
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String finish()
|
||||||
|
{
|
||||||
|
super.finish();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#cancel()
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String cancel()
|
||||||
|
{
|
||||||
|
super.cancel();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -25,6 +25,8 @@ import org.alfresco.model.ForumModel;
|
|||||||
import org.alfresco.service.cmr.repository.ContentReader;
|
import org.alfresco.service.cmr.repository.ContentReader;
|
||||||
import org.alfresco.service.cmr.repository.ContentWriter;
|
import org.alfresco.service.cmr.repository.ContentWriter;
|
||||||
import org.alfresco.util.GUID;
|
import org.alfresco.util.GUID;
|
||||||
|
import org.alfresco.web.app.AlfrescoNavigationHandler;
|
||||||
|
import org.alfresco.web.bean.ForumsBean;
|
||||||
import org.alfresco.web.bean.repository.Node;
|
import org.alfresco.web.bean.repository.Node;
|
||||||
import org.alfresco.web.bean.repository.Repository;
|
import org.alfresco.web.bean.repository.Repository;
|
||||||
import org.alfresco.web.ui.common.Utils;
|
import org.alfresco.web.ui.common.Utils;
|
||||||
@@ -56,7 +58,8 @@ public class NewPostWizard extends CreateContentWizard
|
|||||||
public void startWizardForEdit(ActionEvent event)
|
public void startWizardForEdit(ActionEvent event)
|
||||||
{
|
{
|
||||||
// TODO: Allow action link to have multiple action listeners
|
// TODO: Allow action link to have multiple action listeners
|
||||||
// then we wouldn't need to have this coupling in here
|
// then we wouldn't need to have this coupling back
|
||||||
|
// to the browse bean in here
|
||||||
|
|
||||||
// we need to setup the content in the browse bean first
|
// we need to setup the content in the browse bean first
|
||||||
this.browseBean.setupContentAction(event);
|
this.browseBean.setupContentAction(event);
|
||||||
@@ -101,17 +104,18 @@ public class NewPostWizard extends CreateContentWizard
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// create appropriate values for filename, title and content type
|
// create appropriate values for filename and content type
|
||||||
this.fileName = GUID.generate() + ".html";
|
this.fileName = ForumsBean.createPostFileName();
|
||||||
this.contentType = Repository.getMimeTypeForFileName(
|
this.contentType = Repository.getMimeTypeForFileName(
|
||||||
FacesContext.getCurrentInstance(), this.fileName);
|
FacesContext.getCurrentInstance(), this.fileName);
|
||||||
this.title = this.fileName;
|
|
||||||
|
|
||||||
// remove link breaks and replace with <br/>
|
// remove link breaks and replace with <br/>
|
||||||
this.content = Utils.replaceLineBreaks(this.content);
|
this.content = Utils.replaceLineBreaks(this.content);
|
||||||
}
|
}
|
||||||
|
|
||||||
return super.finish();
|
super.finish();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -120,16 +124,28 @@ public class NewPostWizard extends CreateContentWizard
|
|||||||
@Override
|
@Override
|
||||||
protected void performCustomProcessing()
|
protected void performCustomProcessing()
|
||||||
{
|
{
|
||||||
// update the content
|
if (this.editMode)
|
||||||
Node currentDocument = this.browseBean.getDocument();
|
|
||||||
|
|
||||||
ContentWriter writer = this.contentService.getWriter(currentDocument.getNodeRef(),
|
|
||||||
ContentModel.PROP_CONTENT, true);
|
|
||||||
if (writer != null)
|
|
||||||
{
|
{
|
||||||
writer.putContent(this.content);
|
// update the content
|
||||||
|
Node currentDocument = this.browseBean.getDocument();
|
||||||
|
|
||||||
|
ContentWriter writer = this.contentService.getWriter(currentDocument.getNodeRef(),
|
||||||
|
ContentModel.PROP_CONTENT, true);
|
||||||
|
if (writer != null)
|
||||||
|
{
|
||||||
|
writer.putContent(this.content);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#cancel()
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String cancel()
|
||||||
|
{
|
||||||
|
super.cancel();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -20,6 +20,7 @@ package org.alfresco.web.bean.wizard;
|
|||||||
import javax.faces.event.ActionEvent;
|
import javax.faces.event.ActionEvent;
|
||||||
|
|
||||||
import org.alfresco.model.ContentModel;
|
import org.alfresco.model.ContentModel;
|
||||||
|
import org.alfresco.web.app.AlfrescoNavigationHandler;
|
||||||
import org.alfresco.web.ui.common.Utils;
|
import org.alfresco.web.ui.common.Utils;
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
@@ -55,7 +56,9 @@ public class NewReplyWizard extends NewPostWizard
|
|||||||
// remove link breaks and replace with <br/>
|
// remove link breaks and replace with <br/>
|
||||||
this.content = Utils.replaceLineBreaks(this.content);
|
this.content = Utils.replaceLineBreaks(this.content);
|
||||||
|
|
||||||
return super.finish();
|
super.finish();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -79,4 +82,15 @@ public class NewReplyWizard extends NewPostWizard
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#cancel()
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String cancel()
|
||||||
|
{
|
||||||
|
super.cancel();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -80,10 +80,10 @@ public class NewSpaceWizard extends AbstractWizardBean
|
|||||||
private static final String DEFAULT_SPACE_TYPE_ICON = "/images/icons/space.gif";
|
private static final String DEFAULT_SPACE_TYPE_ICON = "/images/icons/space.gif";
|
||||||
|
|
||||||
// new space wizard specific properties
|
// new space wizard specific properties
|
||||||
private SearchService searchService;
|
protected SearchService searchService;
|
||||||
private NamespaceService namespaceService;
|
protected NamespaceService namespaceService;
|
||||||
private DictionaryService dictionaryService;
|
protected DictionaryService dictionaryService;
|
||||||
private ConfigService configService;
|
protected ConfigService configService;
|
||||||
|
|
||||||
protected String spaceType;
|
protected String spaceType;
|
||||||
protected String icon;
|
protected String icon;
|
||||||
@@ -996,7 +996,7 @@ public class NewSpaceWizard extends AbstractWizardBean
|
|||||||
*
|
*
|
||||||
* @param context Faces context
|
* @param context Faces context
|
||||||
*/
|
*/
|
||||||
protected void performCustomProcessing(FacesContext context)
|
protected void performCustomProcessing(FacesContext context) throws Exception
|
||||||
{
|
{
|
||||||
// used by subclasses if necessary
|
// used by subclasses if necessary
|
||||||
}
|
}
|
||||||
|
@@ -18,26 +18,22 @@
|
|||||||
package org.alfresco.web.bean.wizard;
|
package org.alfresco.web.bean.wizard;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import javax.faces.context.FacesContext;
|
import javax.faces.context.FacesContext;
|
||||||
import javax.faces.model.SelectItem;
|
|
||||||
|
|
||||||
import org.alfresco.model.ContentModel;
|
import org.alfresco.model.ContentModel;
|
||||||
import org.alfresco.model.ForumModel;
|
import org.alfresco.model.ForumModel;
|
||||||
import org.alfresco.service.cmr.repository.ChildAssociationRef;
|
import org.alfresco.service.cmr.model.FileInfo;
|
||||||
import org.alfresco.service.cmr.repository.ContentService;
|
import org.alfresco.service.cmr.repository.ContentService;
|
||||||
import org.alfresco.service.cmr.repository.ContentWriter;
|
import org.alfresco.service.cmr.repository.ContentWriter;
|
||||||
import org.alfresco.service.cmr.repository.NodeRef;
|
import org.alfresco.service.cmr.repository.NodeRef;
|
||||||
import org.alfresco.service.namespace.NamespaceService;
|
|
||||||
import org.alfresco.service.namespace.QName;
|
import org.alfresco.service.namespace.QName;
|
||||||
import org.alfresco.util.GUID;
|
import org.alfresco.web.app.AlfrescoNavigationHandler;
|
||||||
|
import org.alfresco.web.bean.ForumsBean;
|
||||||
import org.alfresco.web.bean.repository.Repository;
|
import org.alfresco.web.bean.repository.Repository;
|
||||||
import org.alfresco.web.ui.common.Utils;
|
import org.alfresco.web.ui.common.Utils;
|
||||||
import org.alfresco.web.ui.common.component.UIListItem;
|
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
|
||||||
@@ -51,51 +47,8 @@ public class NewTopicWizard extends NewSpaceWizard
|
|||||||
private static final Log logger = LogFactory.getLog(NewTopicWizard.class);
|
private static final Log logger = LogFactory.getLog(NewTopicWizard.class);
|
||||||
|
|
||||||
protected String message;
|
protected String message;
|
||||||
protected String topicType;
|
|
||||||
protected List<UIListItem> topicIcons;
|
|
||||||
protected List<SelectItem> topicTypes;
|
|
||||||
|
|
||||||
protected ContentService contentService;
|
protected ContentService contentService;
|
||||||
|
|
||||||
/**
|
|
||||||
* Returns a list of topic types for the user to select from
|
|
||||||
*
|
|
||||||
* @return The topic types
|
|
||||||
*/
|
|
||||||
public List<SelectItem> getTopicTypes()
|
|
||||||
{
|
|
||||||
if (this.topicTypes == null)
|
|
||||||
{
|
|
||||||
this.topicTypes = new ArrayList<SelectItem>(3);
|
|
||||||
|
|
||||||
// TODO: change this to be based on categories
|
|
||||||
this.topicTypes.add(new SelectItem("1", "Announcement"));
|
|
||||||
this.topicTypes.add(new SelectItem("0", "Normal"));
|
|
||||||
this.topicTypes.add(new SelectItem("2", "Sticky"));
|
|
||||||
}
|
|
||||||
|
|
||||||
return this.topicTypes;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Returns the type of the topic
|
|
||||||
*
|
|
||||||
* @return The type of topic
|
|
||||||
*/
|
|
||||||
public String getTopicType()
|
|
||||||
{
|
|
||||||
return this.topicType;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Sets the type of the topic
|
|
||||||
*
|
|
||||||
* @param topicType The type of the topic
|
|
||||||
*/
|
|
||||||
public void setTopicType(String topicType)
|
|
||||||
{
|
|
||||||
this.topicType = topicType;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the message entered by the user for the first post
|
* Returns the message entered by the user for the first post
|
||||||
@@ -133,7 +86,6 @@ public class NewTopicWizard extends NewSpaceWizard
|
|||||||
super.init();
|
super.init();
|
||||||
|
|
||||||
this.spaceType = ForumModel.TYPE_TOPIC.toString();
|
this.spaceType = ForumModel.TYPE_TOPIC.toString();
|
||||||
this.topicType = "0";
|
|
||||||
this.message = null;
|
this.message = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -141,34 +93,19 @@ public class NewTopicWizard extends NewSpaceWizard
|
|||||||
* @see org.alfresco.web.bean.wizard.NewSpaceWizard#performCustomProcessing(javax.faces.context.FacesContext)
|
* @see org.alfresco.web.bean.wizard.NewSpaceWizard#performCustomProcessing(javax.faces.context.FacesContext)
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
protected void performCustomProcessing(FacesContext context)
|
protected void performCustomProcessing(FacesContext context) throws Exception
|
||||||
{
|
{
|
||||||
if (this.editMode == false)
|
if (this.editMode == false)
|
||||||
{
|
{
|
||||||
// *************************
|
|
||||||
// TODO: Add or update the ForumModel.PROP_TYPE property depending on the editMode
|
|
||||||
// *************************
|
|
||||||
|
|
||||||
// get the node ref of the node that will contain the content
|
// get the node ref of the node that will contain the content
|
||||||
NodeRef containerNodeRef = this.createdNode;
|
NodeRef containerNodeRef = this.createdNode;
|
||||||
|
|
||||||
// create a unique file name for the message content
|
// create a unique file name for the message content
|
||||||
String fileName = GUID.generate() + ".txt";
|
String fileName = ForumsBean.createPostFileName();
|
||||||
|
|
||||||
// create properties for content type
|
FileInfo fileInfo = this.fileFolderService.create(containerNodeRef,
|
||||||
Map<QName, Serializable> contentProps = new HashMap<QName, Serializable>(5, 1.0f);
|
fileName, ForumModel.TYPE_POST);
|
||||||
contentProps.put(ContentModel.PROP_NAME, fileName);
|
NodeRef postNodeRef = fileInfo.getNodeRef();
|
||||||
|
|
||||||
// create the node to represent the content
|
|
||||||
String assocName = QName.createValidLocalName(fileName);
|
|
||||||
ChildAssociationRef assocRef = this.nodeService.createNode(
|
|
||||||
containerNodeRef,
|
|
||||||
ContentModel.ASSOC_CONTAINS,
|
|
||||||
QName.createQName(NamespaceService.CONTENT_MODEL_1_0_URI, assocName),
|
|
||||||
Repository.resolveToQName(ForumModel.TYPE_POST.toString()),
|
|
||||||
contentProps);
|
|
||||||
|
|
||||||
NodeRef postNodeRef = assocRef.getChildRef();
|
|
||||||
|
|
||||||
if (logger.isDebugEnabled())
|
if (logger.isDebugEnabled())
|
||||||
logger.debug("Created post node with filename: " + fileName);
|
logger.debug("Created post node with filename: " + fileName);
|
||||||
@@ -196,4 +133,26 @@ public class NewTopicWizard extends NewSpaceWizard
|
|||||||
writer.putContent(Utils.replaceLineBreaks(this.message));
|
writer.putContent(Utils.replaceLineBreaks(this.message));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#finish()
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String finish()
|
||||||
|
{
|
||||||
|
super.finish();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see org.alfresco.web.bean.wizard.AbstractWizardBean#cancel()
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String cancel()
|
||||||
|
{
|
||||||
|
super.cancel();
|
||||||
|
|
||||||
|
return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -27,6 +27,7 @@ import org.alfresco.service.cmr.dictionary.DictionaryService;
|
|||||||
import org.alfresco.service.cmr.repository.ChildAssociationRef;
|
import org.alfresco.service.cmr.repository.ChildAssociationRef;
|
||||||
import org.alfresco.service.cmr.repository.NodeRef;
|
import org.alfresco.service.cmr.repository.NodeRef;
|
||||||
import org.alfresco.service.cmr.repository.NodeService;
|
import org.alfresco.service.cmr.repository.NodeService;
|
||||||
|
import org.alfresco.service.namespace.RegexQNamePattern;
|
||||||
import org.alfresco.web.app.Application;
|
import org.alfresco.web.app.Application;
|
||||||
import org.alfresco.web.bean.repository.Repository;
|
import org.alfresco.web.bean.repository.Repository;
|
||||||
import org.alfresco.web.ui.repo.WebResources;
|
import org.alfresco.web.ui.repo.WebResources;
|
||||||
@@ -83,7 +84,8 @@ public class UISpaceSelector extends AbstractItemSelector
|
|||||||
public Collection<ChildAssociationRef> getChildrenForNode(FacesContext context)
|
public Collection<ChildAssociationRef> getChildrenForNode(FacesContext context)
|
||||||
{
|
{
|
||||||
NodeRef nodeRef = new NodeRef(Repository.getStoreRef(), this.navigationId);
|
NodeRef nodeRef = new NodeRef(Repository.getStoreRef(), this.navigationId);
|
||||||
List<ChildAssociationRef> allKids = getNodeService(context).getChildAssocs(nodeRef);
|
List<ChildAssociationRef> allKids = getNodeService(context).getChildAssocs(nodeRef,
|
||||||
|
ContentModel.ASSOC_CONTAINS, RegexQNamePattern.MATCH_ALL);
|
||||||
DictionaryService dd = getDictionaryService(context);
|
DictionaryService dd = getDictionaryService(context);
|
||||||
NodeService service = getNodeService(context);
|
NodeService service = getNodeService(context);
|
||||||
|
|
||||||
|
@@ -34,6 +34,7 @@ import org.alfresco.service.cmr.repository.ChildAssociationRef;
|
|||||||
import org.alfresco.service.cmr.repository.NodeRef;
|
import org.alfresco.service.cmr.repository.NodeRef;
|
||||||
import org.alfresco.service.cmr.repository.NodeService;
|
import org.alfresco.service.cmr.repository.NodeService;
|
||||||
import org.alfresco.service.namespace.QName;
|
import org.alfresco.service.namespace.QName;
|
||||||
|
import org.alfresco.service.namespace.RegexQNamePattern;
|
||||||
import org.alfresco.web.bean.repository.Repository;
|
import org.alfresco.web.bean.repository.Repository;
|
||||||
import org.alfresco.web.ui.common.Utils;
|
import org.alfresco.web.ui.common.Utils;
|
||||||
import org.alfresco.web.ui.common.renderer.BaseRenderer;
|
import org.alfresco.web.ui.common.renderer.BaseRenderer;
|
||||||
@@ -115,7 +116,8 @@ public class NodeDescendantsLinkRenderer extends BaseRenderer
|
|||||||
// calculate the number of displayed child refs
|
// calculate the number of displayed child refs
|
||||||
if (service.exists(parentRef) == true)
|
if (service.exists(parentRef) == true)
|
||||||
{
|
{
|
||||||
List<ChildAssociationRef> childRefs = service.getChildAssocs(parentRef);
|
List<ChildAssociationRef> childRefs = service.getChildAssocs(parentRef,
|
||||||
|
ContentModel.ASSOC_CONTAINS, RegexQNamePattern.MATCH_ALL);
|
||||||
List<ChildAssociationRef> refs = new ArrayList<ChildAssociationRef>(childRefs.size());
|
List<ChildAssociationRef> refs = new ArrayList<ChildAssociationRef>(childRefs.size());
|
||||||
for (int index=0; index<childRefs.size(); index++)
|
for (int index=0; index<childRefs.size(); index++)
|
||||||
{
|
{
|
||||||
|
@@ -158,6 +158,18 @@
|
|||||||
<from-outcome>previewSpace</from-outcome>
|
<from-outcome>previewSpace</from-outcome>
|
||||||
<to-view-id>/jsp/dialog/preview-space.jsp</to-view-id>
|
<to-view-id>/jsp/dialog/preview-space.jsp</to-view-id>
|
||||||
</navigation-case>
|
</navigation-case>
|
||||||
|
<navigation-case>
|
||||||
|
<from-outcome>startDiscussion</from-outcome>
|
||||||
|
<to-view-id>/jsp/forums/create-topic.jsp</to-view-id>
|
||||||
|
</navigation-case>
|
||||||
|
<navigation-case>
|
||||||
|
<from-outcome>showForum</from-outcome>
|
||||||
|
<to-view-id>/jsp/forums/forum.jsp</to-view-id>
|
||||||
|
</navigation-case>
|
||||||
|
<navigation-case>
|
||||||
|
<from-outcome>showTopic</from-outcome>
|
||||||
|
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
||||||
|
</navigation-case>
|
||||||
</navigation-rule>
|
</navigation-rule>
|
||||||
|
|
||||||
<!-- Admin Console rules -->
|
<!-- Admin Console rules -->
|
||||||
@@ -900,14 +912,6 @@
|
|||||||
<from-view-id>/jsp/forums/*</from-view-id>
|
<from-view-id>/jsp/forums/*</from-view-id>
|
||||||
<!-- NOTE: we can't have a case for browse in here otherwise you can -->
|
<!-- NOTE: we can't have a case for browse in here otherwise you can -->
|
||||||
<!-- never navigate back to the main browse screen -->
|
<!-- never navigate back to the main browse screen -->
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>cancel</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/forums.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>finish</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/forums.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
<navigation-case>
|
||||||
<from-outcome>createForums</from-outcome>
|
<from-outcome>createForums</from-outcome>
|
||||||
<to-view-id>/jsp/forums/create-forums.jsp</to-view-id>
|
<to-view-id>/jsp/forums/create-forums.jsp</to-view-id>
|
||||||
@@ -976,14 +980,22 @@
|
|||||||
<from-outcome>manageInvitedUsers</from-outcome>
|
<from-outcome>manageInvitedUsers</from-outcome>
|
||||||
<to-view-id>/jsp/roles/manage-invited-users.jsp</to-view-id>
|
<to-view-id>/jsp/roles/manage-invited-users.jsp</to-view-id>
|
||||||
</navigation-case>
|
</navigation-case>
|
||||||
|
<navigation-case>
|
||||||
|
<from-outcome>import</from-outcome>
|
||||||
|
<to-view-id>/jsp/dialog/import.jsp</to-view-id>
|
||||||
|
</navigation-case>
|
||||||
|
<navigation-case>
|
||||||
|
<from-outcome>export</from-outcome>
|
||||||
|
<to-view-id>/jsp/dialog/export.jsp</to-view-id>
|
||||||
|
</navigation-case>
|
||||||
|
<navigation-case>
|
||||||
|
<from-outcome>createDiscussion</from-outcome>
|
||||||
|
<to-view-id>/jsp/forums/create-discussion.jsp</to-view-id>
|
||||||
|
</navigation-case>
|
||||||
</navigation-rule>
|
</navigation-rule>
|
||||||
|
|
||||||
<navigation-rule>
|
<navigation-rule>
|
||||||
<from-view-id>/jsp/forums/forums-details.jsp</from-view-id>
|
<from-view-id>/jsp/forums/forums-details.jsp</from-view-id>
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>browse</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/forums.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
<navigation-case>
|
||||||
<from-outcome>nextItem</from-outcome>
|
<from-outcome>nextItem</from-outcome>
|
||||||
<to-view-id>/jsp/forums/forums-details.jsp</to-view-id>
|
<to-view-id>/jsp/forums/forums-details.jsp</to-view-id>
|
||||||
@@ -996,10 +1008,6 @@
|
|||||||
|
|
||||||
<navigation-rule>
|
<navigation-rule>
|
||||||
<from-view-id>/jsp/forums/forum-details.jsp</from-view-id>
|
<from-view-id>/jsp/forums/forum-details.jsp</from-view-id>
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>browse</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/forum.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
<navigation-case>
|
||||||
<from-outcome>nextItem</from-outcome>
|
<from-outcome>nextItem</from-outcome>
|
||||||
<to-view-id>/jsp/forums/forum-details.jsp</to-view-id>
|
<to-view-id>/jsp/forums/forum-details.jsp</to-view-id>
|
||||||
@@ -1009,153 +1017,45 @@
|
|||||||
<to-view-id>/jsp/forums/forum-details.jsp</to-view-id>
|
<to-view-id>/jsp/forums/forum-details.jsp</to-view-id>
|
||||||
</navigation-case>
|
</navigation-case>
|
||||||
</navigation-rule>
|
</navigation-rule>
|
||||||
|
|
||||||
|
<navigation-rule>
|
||||||
|
<from-view-id>/jsp/forums/topic-details.jsp</from-view-id>
|
||||||
|
<navigation-case>
|
||||||
|
<from-outcome>nextItem</from-outcome>
|
||||||
|
<to-view-id>/jsp/forums/topic-details.jsp</to-view-id>
|
||||||
|
</navigation-case>
|
||||||
|
<navigation-case>
|
||||||
|
<from-outcome>previousItem</from-outcome>
|
||||||
|
<to-view-id>/jsp/forums/topic-details.jsp</to-view-id>
|
||||||
|
</navigation-case>
|
||||||
|
</navigation-rule>
|
||||||
|
|
||||||
|
<navigation-rule>
|
||||||
|
<from-view-id>/jsp/forums/delete-forums.jsp</from-view-id>
|
||||||
|
<navigation-case>
|
||||||
|
<from-outcome>forumsDeleted</from-outcome>
|
||||||
|
<to-view-id>/jsp/forums/forums.jsp</to-view-id>
|
||||||
|
</navigation-case>
|
||||||
|
<navigation-case>
|
||||||
|
<from-outcome>browse</from-outcome>
|
||||||
|
<to-view-id>/jsp/browse/browse.jsp</to-view-id>
|
||||||
|
</navigation-case>
|
||||||
|
</navigation-rule>
|
||||||
|
|
||||||
<navigation-rule>
|
<navigation-rule>
|
||||||
<from-view-id>/jsp/forums/delete-forum.jsp</from-view-id>
|
<from-view-id>/jsp/forums/delete-forum.jsp</from-view-id>
|
||||||
<navigation-case>
|
<navigation-case>
|
||||||
<from-outcome>browse</from-outcome>
|
<from-outcome>forumDeleted</from-outcome>
|
||||||
<to-view-id>/jsp/forums/forums.jsp</to-view-id>
|
<to-view-id>/jsp/forums/forums.jsp</to-view-id>
|
||||||
</navigation-case>
|
</navigation-case>
|
||||||
</navigation-rule>
|
</navigation-rule>
|
||||||
|
|
||||||
<navigation-rule>
|
|
||||||
<from-view-id>/jsp/forums/create-topic.jsp</from-view-id>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>cancel</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/forum.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>finish</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/forum.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
</navigation-rule>
|
|
||||||
|
|
||||||
<navigation-rule>
|
<navigation-rule>
|
||||||
<from-view-id>/jsp/forums/delete-topic.jsp</from-view-id>
|
<from-view-id>/jsp/forums/delete-topic.jsp</from-view-id>
|
||||||
<navigation-case>
|
<navigation-case>
|
||||||
<from-outcome>browse</from-outcome>
|
<from-outcome>topicDeleted</from-outcome>
|
||||||
<to-view-id>/jsp/forums/forum.jsp</to-view-id>
|
<to-view-id>/jsp/forums/forum.jsp</to-view-id>
|
||||||
</navigation-case>
|
</navigation-case>
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>cancel</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/forum.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>finish</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/forum.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
</navigation-rule>
|
|
||||||
|
|
||||||
<navigation-rule>
|
|
||||||
<from-view-id>/jsp/forums/topic-details.jsp</from-view-id>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>browse</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>cancel</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>finish</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>nextItem</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic-details.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>previousItem</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic-details.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
</navigation-rule>
|
|
||||||
|
|
||||||
<navigation-rule>
|
|
||||||
<from-view-id>/jsp/forums/create-post.jsp</from-view-id>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>cancel</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>finish</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
</navigation-rule>
|
|
||||||
|
|
||||||
<navigation-rule>
|
|
||||||
<from-view-id>/jsp/forums/create-reply.jsp</from-view-id>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>cancel</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>finish</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
</navigation-rule>
|
|
||||||
|
|
||||||
<navigation-rule>
|
|
||||||
<from-view-id>/jsp/forums/delete-post.jsp</from-view-id>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>browse</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>cancel</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>finish</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
</navigation-rule>
|
|
||||||
|
|
||||||
<navigation-rule>
|
|
||||||
<from-view-id>/jsp/forums/edit-forums.jsp</from-view-id>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>cancel</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/forums-details.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>finish</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/forums-details.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
</navigation-rule>
|
|
||||||
|
|
||||||
<navigation-rule>
|
|
||||||
<from-view-id>/jsp/forums/edit-forum.jsp</from-view-id>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>cancel</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/forum-details.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>finish</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/forum-details.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
</navigation-rule>
|
|
||||||
|
|
||||||
<navigation-rule>
|
|
||||||
<from-view-id>/jsp/forums/edit-topic.jsp</from-view-id>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>cancel</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic-details.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>finish</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic-details.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
</navigation-rule>
|
|
||||||
|
|
||||||
<navigation-rule>
|
|
||||||
<from-view-id>/jsp/forums/edit-post.jsp</from-view-id>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>cancel</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
<navigation-case>
|
|
||||||
<from-outcome>finish</from-outcome>
|
|
||||||
<to-view-id>/jsp/forums/topic.jsp</to-view-id>
|
|
||||||
</navigation-case>
|
|
||||||
</navigation-rule>
|
</navigation-rule>
|
||||||
|
|
||||||
</faces-config>
|
</faces-config>
|
||||||
|
@@ -1279,6 +1279,51 @@
|
|||||||
<value>#{DictionaryService}</value>
|
<value>#{DictionaryService}</value>
|
||||||
</managed-property>
|
</managed-property>
|
||||||
</managed-bean>
|
</managed-bean>
|
||||||
|
|
||||||
|
<managed-bean>
|
||||||
|
<description>
|
||||||
|
The bean that backs up the Create Discussion Dialog
|
||||||
|
</description>
|
||||||
|
<managed-bean-name>CreateDiscussionDialog</managed-bean-name>
|
||||||
|
<managed-bean-class>org.alfresco.web.bean.wizard.NewDiscussionWizard</managed-bean-class>
|
||||||
|
<managed-bean-scope>session</managed-bean-scope>
|
||||||
|
<managed-property>
|
||||||
|
<property-name>nodeService</property-name>
|
||||||
|
<value>#{NodeService}</value>
|
||||||
|
</managed-property>
|
||||||
|
<managed-property>
|
||||||
|
<property-name>fileFolderService</property-name>
|
||||||
|
<value>#{FileFolderService}</value>
|
||||||
|
</managed-property>
|
||||||
|
<managed-property>
|
||||||
|
<property-name>searchService</property-name>
|
||||||
|
<value>#{SearchService}</value>
|
||||||
|
</managed-property>
|
||||||
|
<managed-property>
|
||||||
|
<property-name>navigator</property-name>
|
||||||
|
<value>#{NavigationBean}</value>
|
||||||
|
</managed-property>
|
||||||
|
<managed-property>
|
||||||
|
<property-name>browseBean</property-name>
|
||||||
|
<value>#{BrowseBean}</value>
|
||||||
|
</managed-property>
|
||||||
|
<managed-property>
|
||||||
|
<property-name>searchService</property-name>
|
||||||
|
<value>#{SearchService}</value>
|
||||||
|
</managed-property>
|
||||||
|
<managed-property>
|
||||||
|
<property-name>contentService</property-name>
|
||||||
|
<value>#{ContentService}</value>
|
||||||
|
</managed-property>
|
||||||
|
<managed-property>
|
||||||
|
<property-name>configService</property-name>
|
||||||
|
<value>#{configService}</value>
|
||||||
|
</managed-property>
|
||||||
|
<managed-property>
|
||||||
|
<property-name>namespaceService</property-name>
|
||||||
|
<value>#{NamespaceService}</value>
|
||||||
|
</managed-property>
|
||||||
|
</managed-bean>
|
||||||
|
|
||||||
<!-- ==================== LIFECYCLE ==================== -->
|
<!-- ==================== LIFECYCLE ==================== -->
|
||||||
|
|
||||||
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 585 B |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 649 B After Width: | Height: | Size: 631 B |
BIN
source/web/images/icons/create_forums_large.gif
Normal file
After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1018 B |
BIN
source/web/images/icons/create_post_large.gif
Normal file
After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 579 B |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.3 KiB |
BIN
source/web/images/icons/edit_post.gif
Normal file
After Width: | Height: | Size: 519 B |
BIN
source/web/images/icons/edit_post_large.gif
Normal file
After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1009 B |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 637 B After Width: | Height: | Size: 648 B |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 949 B After Width: | Height: | Size: 553 B |
BIN
source/web/images/icons/post_reply_large.gif
Normal file
After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 581 B |
BIN
source/web/images/icons/topic_exclamation.gif
Normal file
After Width: | Height: | Size: 591 B |
BIN
source/web/images/icons/topic_exclamation_large.gif
Normal file
After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.4 KiB |
BIN
source/web/images/icons/topic_question.gif
Normal file
After Width: | Height: | Size: 594 B |
BIN
source/web/images/icons/topic_question_large.gif
Normal file
After Width: | Height: | Size: 1.4 KiB |
@@ -106,14 +106,14 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<a:actionLink value="#{msg.import}" image="/images/icons/import.gif" action="import" actionListener="#{BrowseBean.setupSpaceAction}" styleClass="title">
|
<a:actionLink value="#{msg.import}" image="/images/icons/import.gif" action="dialog:import" actionListener="#{BrowseBean.setupSpaceAction}" styleClass="title">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<a:actionLink value="#{msg.export}" image="/images/icons/export.gif" action="export" actionListener="#{BrowseBean.setupSpaceAction}" styleClass="title">
|
<a:actionLink value="#{msg.export}" image="/images/icons/export.gif" action="dialog:export" actionListener="#{BrowseBean.setupSpaceAction}" styleClass="title">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</td>
|
</td>
|
||||||
|
@@ -103,7 +103,7 @@
|
|||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<%-- Current space More actions menu --%>
|
<%-- Current space More actions menu --%>
|
||||||
<a:menu id="spaceMenu" itemSpacing="4" label="#{msg.more_options}" image="/images/icons/more.gif" tooltip="#{msg.more_options_space}" menuStyleClass="moreActionsMenu" style="padding-left:20px">
|
<a:menu id="spaceMenu" itemSpacing="4" label="#{msg.more_options}" image="/images/icons/more.gif" tooltip="#{msg.more_options_space}" menuStyleClass="moreActionsMenu" style="padding-left:20px">
|
||||||
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" action="showSpaceDetails" actionListener="#{BrowseBean.setupSpaceAction}" id="link5">
|
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" action="dialog:showSpaceDetails" actionListener="#{BrowseBean.setupSpaceAction}" id="link5">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param6" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param6" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="Delete" id="eval4">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="Delete" id="eval4">
|
||||||
@@ -124,7 +124,7 @@
|
|||||||
<a:actionLink value="#{msg.advanced_space_wizard}" image="/images/icons/create_space.gif" action="createAdvancedSpace" actionListener="#{NewSpaceWizard.startWizard}" id="link9" />
|
<a:actionLink value="#{msg.advanced_space_wizard}" image="/images/icons/create_space.gif" action="createAdvancedSpace" actionListener="#{NewSpaceWizard.startWizard}" id="link9" />
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="ChangePermissions" id="eval3_1">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="ChangePermissions" id="eval3_1">
|
||||||
<a:actionLink value="#{msg.manage_invited_users}" image="/images/icons/invite.gif" id="link4" action="manageInvitedUsers" actionListener="#{BrowseBean.setupSpaceAction}">
|
<a:actionLink value="#{msg.manage_invited_users}" image="/images/icons/invite.gif" id="link4" action="dialog:manageInvitedUsers" actionListener="#{BrowseBean.setupSpaceAction}">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param6_1" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param6_1" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
@@ -315,9 +315,22 @@
|
|||||||
<f:param name="id" value="#{r.id}" />
|
<f:param name="id" value="#{r.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" showLink="false" styleClass="inlineAction" action="showSpaceDetails" actionListener="#{BrowseBean.setupSpaceAction}">
|
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" showLink="false" styleClass="inlineAction" action="dialog:showSpaceDetails" actionListener="#{BrowseBean.setupSpaceAction}">
|
||||||
<f:param name="id" value="#{r.id}" />
|
<f:param name="id" value="#{r.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
|
<%-- More actions menu --%>
|
||||||
|
<a:menu itemSpacing="4" image="/images/icons/more.gif" tooltip="#{msg.more_actions}" menuStyleClass="moreActionsMenu">
|
||||||
|
<a:booleanEvaluator value="#{r.beingDiscussed == false}">
|
||||||
|
<a:actionLink value="#{msg.start_discussion}" image="/images/icons/create_forum.gif" actionListener="#{CreateDiscussionDialog.startWizard}">
|
||||||
|
<f:param name="id" value="#{r.id}" />
|
||||||
|
</a:actionLink>
|
||||||
|
</a:booleanEvaluator>
|
||||||
|
<a:booleanEvaluator value="#{r.beingDiscussed == true}">
|
||||||
|
<a:actionLink value="#{msg.discuss}" image="/images/icons/forum.gif" actionListener="#{ForumsBean.discuss}">
|
||||||
|
<f:param name="id" value="#{r.id}" />
|
||||||
|
</a:actionLink>
|
||||||
|
</a:booleanEvaluator>
|
||||||
|
</a:menu>
|
||||||
</a:column>
|
</a:column>
|
||||||
|
|
||||||
<a:dataPager styleClass="pager" />
|
<a:dataPager styleClass="pager" />
|
||||||
@@ -461,7 +474,7 @@
|
|||||||
<f:param name="id" value="#{r.id}" />
|
<f:param name="id" value="#{r.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</a:booleanEvaluator>
|
</a:booleanEvaluator>
|
||||||
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" showLink="false" styleClass="inlineAction" actionListener="#{BrowseBean.setupContentAction}" action="showDocDetails">
|
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" showLink="false" styleClass="inlineAction" actionListener="#{BrowseBean.setupContentAction}" action="dialog:showDocDetails">
|
||||||
<f:param name="id" value="#{r.id}" />
|
<f:param name="id" value="#{r.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
<r:permissionEvaluator value="#{r}" allow="Delete">
|
<r:permissionEvaluator value="#{r}" allow="Delete">
|
||||||
@@ -506,6 +519,16 @@
|
|||||||
<a:actionLink value="#{msg.copy}" image="/images/icons/copy.gif" actionListener="#{ClipboardBean.copyNode}">
|
<a:actionLink value="#{msg.copy}" image="/images/icons/copy.gif" actionListener="#{ClipboardBean.copyNode}">
|
||||||
<f:param name="id" value="#{r.id}" />
|
<f:param name="id" value="#{r.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
|
<a:booleanEvaluator value="#{r.beingDiscussed == false}">
|
||||||
|
<a:actionLink value="#{msg.start_discussion}" image="/images/icons/create_forum.gif" actionListener="#{CreateDiscussionDialog.startWizard}">
|
||||||
|
<f:param name="id" value="#{r.id}" />
|
||||||
|
</a:actionLink>
|
||||||
|
</a:booleanEvaluator>
|
||||||
|
<a:booleanEvaluator value="#{r.beingDiscussed == true}">
|
||||||
|
<a:actionLink value="#{msg.discuss}" image="/images/icons/forum.gif" actionListener="#{ForumsBean.discuss}">
|
||||||
|
<f:param name="id" value="#{r.id}" />
|
||||||
|
</a:actionLink>
|
||||||
|
</a:booleanEvaluator>
|
||||||
</a:menu>
|
</a:menu>
|
||||||
</a:column>
|
</a:column>
|
||||||
|
|
||||||
|
@@ -94,11 +94,11 @@
|
|||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<a:menu itemSpacing="4" label="#{msg.more_options}" image="/images/icons/more.gif" tooltip="#{msg.more_options_space}" menuStyleClass="moreActionsMenu" style="padding-left:20px">
|
<a:menu itemSpacing="4" label="#{msg.more_options}" image="/images/icons/more.gif" tooltip="#{msg.more_options_space}" menuStyleClass="moreActionsMenu" style="padding-left:20px">
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Write">
|
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Write">
|
||||||
<a:actionLink value="#{msg.import}" image="/images/icons/import.gif" action="import" actionListener="#{BrowseBean.setupSpaceAction}">
|
<a:actionLink value="#{msg.import}" image="/images/icons/import.gif" action="dialog:import" actionListener="#{BrowseBean.setupSpaceAction}">
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<a:actionLink value="#{msg.export}" image="/images/icons/export.gif" action="export" actionListener="#{BrowseBean.setupSpaceAction}">
|
<a:actionLink value="#{msg.export}" image="/images/icons/export.gif" action="dialog:export" actionListener="#{BrowseBean.setupSpaceAction}">
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
<a:actionLink value="#{msg.create_shortcut}" image="/images/icons/shortcut.gif" actionListener="#{UserShortcutsBean.createShortcut}">
|
<a:actionLink value="#{msg.create_shortcut}" image="/images/icons/shortcut.gif" actionListener="#{UserShortcutsBean.createShortcut}">
|
||||||
|
202
source/web/jsp/forums/create-discussion.jsp
Normal file
@@ -0,0 +1,202 @@
|
|||||||
|
<%--
|
||||||
|
Copyright (C) 2005 Alfresco, Inc.
|
||||||
|
|
||||||
|
Licensed under the Mozilla Public License version 1.1
|
||||||
|
with a permitted attribution clause. You may obtain a
|
||||||
|
copy of the License at
|
||||||
|
|
||||||
|
http://www.alfresco.org/legal/license.txt
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing,
|
||||||
|
software distributed under the License is distributed on an
|
||||||
|
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
|
||||||
|
either express or implied. See the License for the specific
|
||||||
|
language governing permissions and limitations under the
|
||||||
|
License.
|
||||||
|
--%>
|
||||||
|
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
|
||||||
|
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
|
||||||
|
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
|
||||||
|
<%@ taglib uri="/WEB-INF/alfresco.tld" prefix="a" %>
|
||||||
|
<%@ taglib uri="/WEB-INF/repo.tld" prefix="r" %>
|
||||||
|
|
||||||
|
<%@ page buffer="32kb" contentType="text/html;charset=UTF-8" %>
|
||||||
|
<%@ page isELIgnored="false" %>
|
||||||
|
<%@ page import="org.alfresco.web.ui.common.PanelGenerator" %>
|
||||||
|
|
||||||
|
<r:page titleId="title_create_discussion">
|
||||||
|
|
||||||
|
<script language="JavaScript1.2">
|
||||||
|
function checkButtonState()
|
||||||
|
{
|
||||||
|
if (document.getElementById("create-discussion:subject").value.length == 0 ||
|
||||||
|
document.getElementById("create-discussion:message").value.length == 0)
|
||||||
|
{
|
||||||
|
document.getElementById("create-discussion:ok-button").disabled = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
document.getElementById("create-discussion:ok-button").disabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<f:view>
|
||||||
|
|
||||||
|
<%-- load a bundle of properties with I18N strings --%>
|
||||||
|
<f:loadBundle basename="alfresco.messages.webclient" var="msg"/>
|
||||||
|
|
||||||
|
<h:form acceptCharset="UTF-8" id="create-discussion">
|
||||||
|
|
||||||
|
<%-- Main outer table --%>
|
||||||
|
<table cellspacing="0" cellpadding="2">
|
||||||
|
|
||||||
|
<%-- Title bar --%>
|
||||||
|
<tr>
|
||||||
|
<td colspan="2">
|
||||||
|
<%@ include file="../parts/titlebar.jsp" %>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<%-- Main area --%>
|
||||||
|
<tr valign="top">
|
||||||
|
<%-- Shelf --%>
|
||||||
|
<td>
|
||||||
|
<%@ include file="../parts/shelf.jsp" %>
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<%-- Work Area --%>
|
||||||
|
<td width="100%">
|
||||||
|
<table cellspacing="0" cellpadding="0" width="100%">
|
||||||
|
<%-- Breadcrumb --%>
|
||||||
|
<%@ include file="../parts/breadcrumb.jsp" %>
|
||||||
|
|
||||||
|
<%-- Status and Actions --%>
|
||||||
|
<tr>
|
||||||
|
<td style="background-image: url(<%=request.getContextPath()%>/images/parts/statuspanel_4.gif)" width="4"></td>
|
||||||
|
<td bgcolor="#EEEEEE">
|
||||||
|
|
||||||
|
<%-- Status and Actions inner contents table --%>
|
||||||
|
<%-- Generally this consists of an icon, textual summary and actions for the current object --%>
|
||||||
|
<table cellspacing="4" cellpadding="0" width="100%">
|
||||||
|
<tr valign="top">
|
||||||
|
<td width="32">
|
||||||
|
<h:graphicImage id="wizard-logo" url="/images/icons/create_topic_large.gif" />
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<div class="mainSubTitle"><h:outputText value="#{NavigationBean.nodeProperties.name}" /></div>
|
||||||
|
<div class="mainTitle"><h:outputText value="#{msg.create_topic}" /></div>
|
||||||
|
<div class="mainSubText"><h:outputText value="#{msg.create_topic_description}" /></div>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td style="background-image: url(<%=request.getContextPath()%>/images/parts/statuspanel_6.gif)" width="4"></td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<%-- separator row with gradient shadow --%>
|
||||||
|
<tr>
|
||||||
|
<td><img src="<%=request.getContextPath()%>/images/parts/statuspanel_7.gif" width="4" height="9"></td>
|
||||||
|
<td style="background-image: url(<%=request.getContextPath()%>/images/parts/statuspanel_8.gif)"></td>
|
||||||
|
<td><img src="<%=request.getContextPath()%>/images/parts/statuspanel_9.gif" width="4" height="9"></td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<%-- Details --%>
|
||||||
|
<tr valign=top>
|
||||||
|
<td style="background-image: url(<%=request.getContextPath()%>/images/parts/whitepanel_4.gif)" width="4"></td>
|
||||||
|
<td>
|
||||||
|
<table cellspacing="0" cellpadding="3" border="0" width="100%">
|
||||||
|
<tr>
|
||||||
|
<td width="100%" valign="top">
|
||||||
|
|
||||||
|
<a:errors message="#{msg.error_create_forum_dialog}" styleClass="errorMessage" />
|
||||||
|
|
||||||
|
<% PanelGenerator.generatePanelStart(out, request.getContextPath(), "white", "white"); %>
|
||||||
|
<table cellpadding="2" cellspacing="2" border="0" width="100%">
|
||||||
|
<tr>
|
||||||
|
<td colspan="2" class="wizardSectionHeading"><h:outputText value="#{msg.topic_props}" /></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td><h:outputText value="#{msg.subject}" />:</td>
|
||||||
|
<td>
|
||||||
|
<h:inputText id="subject" value="#{CreateDiscussionDialog.name}" size="50" maxlength="1024"
|
||||||
|
onkeyup="javascript:checkButtonState();" onchange="javascript:checkButtonState();" /> *
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td><nobr><h:outputText value="#{msg.choose_icon}" />:</nobr></td>
|
||||||
|
<td>
|
||||||
|
<table border="0" cellpadding="0" cellspacing="0"><tr><td>
|
||||||
|
<% PanelGenerator.generatePanelStart(out, request.getContextPath(), "blue", "#D3E6FE"); %>
|
||||||
|
<a:imagePickerRadio columns="6" spacing="4" value="#{CreateDiscussionDialog.icon}">
|
||||||
|
<a:listItems value="#{CreateDiscussionDialog.icons}" />
|
||||||
|
</a:imagePickerRadio>
|
||||||
|
<% PanelGenerator.generatePanelEnd(out, request.getContextPath(), "blue"); %>
|
||||||
|
</td></tr></table>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr><td class="paddingRow"></td></tr>
|
||||||
|
<tr>
|
||||||
|
<td colspan="2" class="wizardSectionHeading"> <h:outputText value="#{msg.message}" /></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td><h:outputText value="#{msg.message}" />:</td>
|
||||||
|
<td valign="top">
|
||||||
|
<h:inputTextarea id="message" value="#{CreateDiscussionDialog.message}" rows="6" cols="70"
|
||||||
|
onkeyup="javascript:checkButtonState();" onchange="javascript:checkButtonState();" /> *
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr><td class="paddingRow"></td></tr>
|
||||||
|
<tr>
|
||||||
|
<td colspan="2"><h:outputText value="#{msg.create_topic_finish}" /></td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
<% PanelGenerator.generatePanelEnd(out, request.getContextPath(), "white"); %>
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<td valign="top">
|
||||||
|
<% PanelGenerator.generatePanelStart(out, request.getContextPath(), "blue", "#D3E6FE"); %>
|
||||||
|
<table cellpadding="1" cellspacing="1" border="0">
|
||||||
|
<tr>
|
||||||
|
<td align="center">
|
||||||
|
<h:commandButton id="ok-button" value="#{msg.create_topic}" action="#{CreateDiscussionDialog.finish}"
|
||||||
|
styleClass="wizardButton" disabled="true" />
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td align="center">
|
||||||
|
<h:commandButton value="#{msg.cancel}" action="#{CreateDiscussionDialog.cancel}" styleClass="wizardButton" />
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
<% PanelGenerator.generatePanelEnd(out, request.getContextPath(), "blue"); %>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</td>
|
||||||
|
<td style="background-image: url(<%=request.getContextPath()%>/images/parts/whitepanel_6.gif)" width="4"></td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<%-- separator row with bottom panel graphics --%>
|
||||||
|
<tr>
|
||||||
|
<td><img src="<%=request.getContextPath()%>/images/parts/whitepanel_7.gif" width="4" height="4"></td>
|
||||||
|
<td width="100%" align="center" style="background-image: url(<%=request.getContextPath()%>/images/parts/whitepanel_8.gif)"></td>
|
||||||
|
<td><img src="<%=request.getContextPath()%>/images/parts/whitepanel_9.gif" width="4" height="4"></td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
</table>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
</h:form>
|
||||||
|
|
||||||
|
<script language="JavaScript1.2">
|
||||||
|
document.getElementById("create-discussion:subject").focus();
|
||||||
|
</script>
|
||||||
|
|
||||||
|
</f:view>
|
||||||
|
|
||||||
|
</r:page>
|
@@ -90,7 +90,7 @@
|
|||||||
<table cellspacing="4" cellpadding="0" width="100%">
|
<table cellspacing="4" cellpadding="0" width="100%">
|
||||||
<tr valign="top">
|
<tr valign="top">
|
||||||
<td width="32">
|
<td width="32">
|
||||||
<h:graphicImage id="wizard-logo" url="/images/icons/create_forum_large.gif" />
|
<h:graphicImage id="wizard-logo" url="/images/icons/create_forums_large.gif" />
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<div class="mainSubTitle"><h:outputText value="#{NavigationBean.nodeProperties.name}" /></div>
|
<div class="mainSubTitle"><h:outputText value="#{NavigationBean.nodeProperties.name}" /></div>
|
||||||
|
@@ -81,7 +81,7 @@
|
|||||||
<table cellspacing="4" cellpadding="0" width="100%">
|
<table cellspacing="4" cellpadding="0" width="100%">
|
||||||
<tr valign="top">
|
<tr valign="top">
|
||||||
<td width="32">
|
<td width="32">
|
||||||
<h:graphicImage id="wizard-logo" url="/images/icons/file_large.gif" />
|
<h:graphicImage id="wizard-logo" url="/images/icons/create_post_large.gif" />
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<div class="mainSubTitle"><h:outputText value="#{NavigationBean.nodeProperties.name}" /></div>
|
<div class="mainSubTitle"><h:outputText value="#{NavigationBean.nodeProperties.name}" /></div>
|
||||||
|
@@ -81,7 +81,7 @@
|
|||||||
<table cellspacing="4" cellpadding="0" width="100%">
|
<table cellspacing="4" cellpadding="0" width="100%">
|
||||||
<tr valign="top">
|
<tr valign="top">
|
||||||
<td width="32">
|
<td width="32">
|
||||||
<h:graphicImage id="wizard-logo" url="/images/icons/file_large.gif" />
|
<h:graphicImage id="wizard-logo" url="/images/icons/post_reply_large.gif" />
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<div class="mainSubTitle"><h:outputText value="#{BrowseBean.actionSpace.name}" /></div>
|
<div class="mainSubTitle"><h:outputText value="#{BrowseBean.actionSpace.name}" /></div>
|
||||||
|
@@ -82,7 +82,7 @@
|
|||||||
<table cellspacing="4" cellpadding="0" width="100%">
|
<table cellspacing="4" cellpadding="0" width="100%">
|
||||||
<tr valign="top">
|
<tr valign="top">
|
||||||
<td width="32">
|
<td width="32">
|
||||||
<h:graphicImage id="wizard-logo" url="/images/icons/create_forum_large.gif" />
|
<h:graphicImage id="wizard-logo" url="/images/icons/create_topic_large.gif" />
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<div class="mainSubTitle"><h:outputText value="#{NavigationBean.nodeProperties.name}" /></div>
|
<div class="mainSubTitle"><h:outputText value="#{NavigationBean.nodeProperties.name}" /></div>
|
||||||
|
@@ -137,13 +137,13 @@
|
|||||||
<table cellpadding="1" cellspacing="1" border="0">
|
<table cellpadding="1" cellspacing="1" border="0">
|
||||||
<tr>
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<h:commandButton value="#{msg.yes}" action="#{BrowseBean.deleteSpaceOK}" styleClass="dialogControls" />
|
<h:commandButton value="#{msg.yes}" action="#{ForumsBean.deleteForumOK}" styleClass="dialogControls" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr><td class="dialogButtonSpacing"></td></tr>
|
<tr><td class="dialogButtonSpacing"></td></tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<h:commandButton value="#{msg.no}" action="cancel" styleClass="dialogControls" />
|
<h:commandButton value="#{msg.no}" action="dialog:close" styleClass="dialogControls" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
@@ -137,13 +137,13 @@
|
|||||||
<table cellpadding="1" cellspacing="1" border="0">
|
<table cellpadding="1" cellspacing="1" border="0">
|
||||||
<tr>
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<h:commandButton value="#{msg.yes}" action="#{BrowseBean.deleteSpaceOK}" styleClass="dialogControls" />
|
<h:commandButton value="#{msg.yes}" action="#{ForumsBean.deleteForumsOK}" styleClass="dialogControls" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr><td class="dialogButtonSpacing"></td></tr>
|
<tr><td class="dialogButtonSpacing"></td></tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<h:commandButton value="#{msg.no}" action="cancel" styleClass="dialogControls" />
|
<h:commandButton value="#{msg.no}" action="dialog:close" styleClass="dialogControls" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
@@ -137,13 +137,13 @@
|
|||||||
<table cellpadding="1" cellspacing="1" border="0">
|
<table cellpadding="1" cellspacing="1" border="0">
|
||||||
<tr>
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<h:commandButton value="#{msg.yes}" action="#{BrowseBean.deleteFileOK}" styleClass="dialogControls" />
|
<h:commandButton value="#{msg.yes}" action="#{ForumsBean.deletePostOK}" styleClass="dialogControls" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr><td class="dialogButtonSpacing"></td></tr>
|
<tr><td class="dialogButtonSpacing"></td></tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<h:commandButton value="#{msg.no}" action="cancel" styleClass="dialogControls" />
|
<h:commandButton value="#{msg.no}" action="dialog:close" styleClass="dialogControls" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
@@ -137,13 +137,13 @@
|
|||||||
<table cellpadding="1" cellspacing="1" border="0">
|
<table cellpadding="1" cellspacing="1" border="0">
|
||||||
<tr>
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<h:commandButton value="#{msg.yes}" action="#{BrowseBean.deleteSpaceOK}" styleClass="dialogControls" />
|
<h:commandButton value="#{msg.yes}" action="#{ForumsBean.deleteTopicOK}" styleClass="dialogControls" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr><td class="dialogButtonSpacing"></td></tr>
|
<tr><td class="dialogButtonSpacing"></td></tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<h:commandButton value="#{msg.no}" action="cancel" styleClass="dialogControls" />
|
<h:commandButton value="#{msg.no}" action="dialog:close" styleClass="dialogControls" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
@@ -80,7 +80,7 @@
|
|||||||
<table cellspacing="4" cellpadding="0" width="100%">
|
<table cellspacing="4" cellpadding="0" width="100%">
|
||||||
<tr valign="top">
|
<tr valign="top">
|
||||||
<td width="32">
|
<td width="32">
|
||||||
<h:graphicImage id="wizard-logo" url="/images/icons/create_space_large.gif" />
|
<h:graphicImage id="wizard-logo" url="/images/icons/#{BrowseBean.actionSpace.properties.icon}.gif" />
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<div class="mainSubTitle"><h:outputText value="#{BrowseBean.actionSpace.name}" /></div>
|
<div class="mainSubTitle"><h:outputText value="#{BrowseBean.actionSpace.name}" /></div>
|
||||||
|
@@ -80,7 +80,7 @@
|
|||||||
<table cellspacing="4" cellpadding="0" width="100%">
|
<table cellspacing="4" cellpadding="0" width="100%">
|
||||||
<tr valign="top">
|
<tr valign="top">
|
||||||
<td width="32">
|
<td width="32">
|
||||||
<h:graphicImage id="wizard-logo" url="/images/icons/create_space_large.gif" />
|
<h:graphicImage id="wizard-logo" url="/images/icons/#{BrowseBean.actionSpace.properties.icon}.gif" />
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<div class="mainSubTitle"><h:outputText value="#{BrowseBean.actionSpace.name}" /></div>
|
<div class="mainSubTitle"><h:outputText value="#{BrowseBean.actionSpace.name}" /></div>
|
||||||
|
@@ -81,7 +81,7 @@
|
|||||||
<table cellspacing="4" cellpadding="0" width="100%">
|
<table cellspacing="4" cellpadding="0" width="100%">
|
||||||
<tr valign="top">
|
<tr valign="top">
|
||||||
<td width="32">
|
<td width="32">
|
||||||
<h:graphicImage id="wizard-logo" url="/images/icons/file_large.gif" />
|
<h:graphicImage id="wizard-logo" url="/images/icons/edit_post_large.gif" />
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<div class="mainSubTitle"><h:outputText value="#{NavigationBean.nodeProperties.name}" /></div>
|
<div class="mainSubTitle"><h:outputText value="#{NavigationBean.nodeProperties.name}" /></div>
|
||||||
|
@@ -80,7 +80,7 @@
|
|||||||
<table cellspacing="4" cellpadding="0" width="100%">
|
<table cellspacing="4" cellpadding="0" width="100%">
|
||||||
<tr valign="top">
|
<tr valign="top">
|
||||||
<td width="32">
|
<td width="32">
|
||||||
<h:graphicImage id="wizard-logo" url="/images/icons/create_space_large.gif" />
|
<h:graphicImage id="wizard-logo" url="/images/icons/#{BrowseBean.actionSpace.properties.icon}.gif" />
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<div class="mainSubTitle"><h:outputText value="#{BrowseBean.actionSpace.name}" /></div>
|
<div class="mainSubTitle"><h:outputText value="#{BrowseBean.actionSpace.name}" /></div>
|
||||||
|
@@ -88,30 +88,10 @@
|
|||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Delete">
|
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Delete">
|
||||||
<a:actionLink value="#{msg.delete}" image="/images/icons/delete.gif" padding="4" action="deleteSpace" actionListener="#{BrowseBean.setupSpaceAction}">
|
<a:actionLink value="#{msg.delete}" image="/images/icons/delete.gif" padding="4" action="dialog:deleteSpace" actionListener="#{BrowseBean.setupSpaceAction}">
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<%--
|
|
||||||
<a:menu itemSpacing="4" label="#{msg.more_options}" image="/images/icons/more.gif" tooltip="#{msg.more_options_space}" menuStyleClass="moreActionsMenu" style="padding-left:20px">
|
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Write">
|
|
||||||
<a:actionLink value="#{msg.import}" image="/images/icons/import.gif" action="import" actionListener="#{BrowseBean.setupSpaceAction}">
|
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
|
||||||
</a:actionLink>
|
|
||||||
</r:permissionEvaluator>
|
|
||||||
<a:actionLink value="#{msg.export}" image="/images/icons/export.gif" action="export" actionListener="#{BrowseBean.setupSpaceAction}">
|
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
|
||||||
</a:actionLink>
|
|
||||||
<a:actionLink value="#{msg.create_shortcut}" image="/images/icons/shortcut.gif" actionListener="#{UserShortcutsBean.createShortcut}">
|
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
|
||||||
</a:actionLink>
|
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="ChangePermissions">
|
|
||||||
<a:actionLink value="#{msg.manage_invited_users}" image="/images/icons/invite.gif" action="manageInvitedUsers" actionListener="#{BrowseBean.setupSpaceAction}">
|
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
|
||||||
</a:actionLink>
|
|
||||||
</r:permissionEvaluator>
|
|
||||||
</a:menu>
|
|
||||||
--%>
|
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
<%-- Navigation --%>
|
<%-- Navigation --%>
|
||||||
@@ -150,7 +130,7 @@
|
|||||||
<f:facet name="title">
|
<f:facet name="title">
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Write">
|
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Write">
|
||||||
<a:actionLink id="titleLink1" value="#{msg.modify}" showLink="false" image="/images/icons/Change_details.gif"
|
<a:actionLink id="titleLink1" value="#{msg.modify}" showLink="false" image="/images/icons/Change_details.gif"
|
||||||
action="editForumProperties" actionListener="#{EditForumDialog.startWizardForEdit}" />
|
action="dialog:editForumProperties" actionListener="#{EditForumDialog.startWizardForEdit}" />
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
</f:facet>
|
</f:facet>
|
||||||
</h:column>
|
</h:column>
|
||||||
|
@@ -81,13 +81,13 @@
|
|||||||
<%-- Current object actions --%>
|
<%-- Current object actions --%>
|
||||||
<h:outputText style="padding-left:20px" styleClass="mainSubTitle" value="#{msg.actions}" id="msg5" /><br>
|
<h:outputText style="padding-left:20px" styleClass="mainSubTitle" value="#{msg.actions}" id="msg5" /><br>
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="CreateChildren" id="eval1">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="CreateChildren" id="eval1">
|
||||||
<a:actionLink value="#{msg.create_topic}" image="/images/icons/create_topic.gif" padding="4" action="createTopic" actionListener="#{CreateTopicDialog.startWizard}" id="link1" />
|
<a:actionLink value="#{msg.create_topic}" image="/images/icons/create_topic.gif" padding="4" action="dialog:createTopic" actionListener="#{CreateTopicDialog.startWizard}" id="link1" />
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" padding="4" action="showForumDetails" actionListener="#{BrowseBean.setupSpaceAction}" id="link2">
|
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" padding="4" action="dialog:showForumDetails" actionListener="#{BrowseBean.setupSpaceAction}" id="link2">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param1" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param1" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="Delete" id="eval2">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="Delete" id="eval2">
|
||||||
<a:actionLink value="#{msg.delete_forum}" image="/images/icons/delete.gif" padding="4" action="deleteForum" actionListener="#{BrowseBean.setupDeleteAction}" id="link3">
|
<a:actionLink value="#{msg.delete_forum}" image="/images/icons/delete.gif" padding="4" action="dialog:deleteForum" actionListener="#{BrowseBean.setupDeleteAction}" id="link3">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param2" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param2" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
@@ -105,7 +105,7 @@
|
|||||||
<a:actionLink value="#{msg.paste_all}" image="/images/icons/paste.gif" actionListener="#{ClipboardBean.pasteAll}" id="link6" />
|
<a:actionLink value="#{msg.paste_all}" image="/images/icons/paste.gif" actionListener="#{ClipboardBean.pasteAll}" id="link6" />
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="ChangePermissions" id="eval5">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="ChangePermissions" id="eval5">
|
||||||
<a:actionLink value="#{msg.manage_invited_users}" image="/images/icons/invite.gif" action="manageInvitedUsers" actionListener="#{BrowseBean.setupSpaceAction}" id="link7">
|
<a:actionLink value="#{msg.manage_invited_users}" image="/images/icons/invite.gif" action="dialog:manageInvitedUsers" actionListener="#{BrowseBean.setupSpaceAction}" id="link7">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param5" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param5" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
@@ -183,11 +183,19 @@
|
|||||||
<h:outputText value="#{msg.actions}"/>
|
<h:outputText value="#{msg.actions}"/>
|
||||||
</f:facet>
|
</f:facet>
|
||||||
<r:permissionEvaluator value="#{r}" allow="Delete">
|
<r:permissionEvaluator value="#{r}" allow="Delete">
|
||||||
<a:actionLink value="#{msg.delete_topic}" image="/images/icons/delete.gif" showLink="false" styleClass="inlineAction" action="deleteTopic" actionListener="#{BrowseBean.setupDeleteAction}">
|
<a:actionLink value="#{msg.cut}" image="/images/icons/cut.gif" showLink="false" styleClass="inlineAction" actionListener="#{ClipboardBean.cutNode}">
|
||||||
<f:param name="id" value="#{r.id}" />
|
<f:param name="id" value="#{r.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" showLink="false" styleClass="inlineAction" action="showTopicDetails" actionListener="#{BrowseBean.setupSpaceAction}">
|
<a:actionLink value="#{msg.copy}" image="/images/icons/copy.gif" showLink="false" styleClass="inlineAction" actionListener="#{ClipboardBean.copyNode}">
|
||||||
|
<f:param name="id" value="#{r.id}" />
|
||||||
|
</a:actionLink>
|
||||||
|
<r:permissionEvaluator value="#{r}" allow="Delete">
|
||||||
|
<a:actionLink value="#{msg.delete_topic}" image="/images/icons/delete.gif" showLink="false" styleClass="inlineAction" action="dialog:deleteTopic" actionListener="#{BrowseBean.setupDeleteAction}">
|
||||||
|
<f:param name="id" value="#{r.id}" />
|
||||||
|
</a:actionLink>
|
||||||
|
</r:permissionEvaluator>
|
||||||
|
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" showLink="false" styleClass="inlineAction" action="dialog:showTopicDetails" actionListener="#{BrowseBean.setupSpaceAction}">
|
||||||
<f:param name="id" value="#{r.id}" />
|
<f:param name="id" value="#{r.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</a:column>
|
</a:column>
|
||||||
|
@@ -88,30 +88,10 @@
|
|||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Delete">
|
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Delete">
|
||||||
<a:actionLink value="#{msg.delete}" image="/images/icons/delete.gif" padding="4" action="deleteSpace" actionListener="#{BrowseBean.setupSpaceAction}">
|
<a:actionLink value="#{msg.delete}" image="/images/icons/delete.gif" padding="4" action="dialog:deleteSpace" actionListener="#{BrowseBean.setupSpaceAction}">
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<%--
|
|
||||||
<a:menu itemSpacing="4" label="#{msg.more_options}" image="/images/icons/more.gif" tooltip="#{msg.more_options_space}" menuStyleClass="moreActionsMenu" style="padding-left:20px">
|
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Write">
|
|
||||||
<a:actionLink value="#{msg.import}" image="/images/icons/import.gif" action="import" actionListener="#{BrowseBean.setupSpaceAction}">
|
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
|
||||||
</a:actionLink>
|
|
||||||
</r:permissionEvaluator>
|
|
||||||
<a:actionLink value="#{msg.export}" image="/images/icons/export.gif" action="export" actionListener="#{BrowseBean.setupSpaceAction}">
|
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
|
||||||
</a:actionLink>
|
|
||||||
<a:actionLink value="#{msg.create_shortcut}" image="/images/icons/shortcut.gif" actionListener="#{UserShortcutsBean.createShortcut}">
|
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
|
||||||
</a:actionLink>
|
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="ChangePermissions">
|
|
||||||
<a:actionLink value="#{msg.manage_invited_users}" image="/images/icons/invite.gif" action="manageInvitedUsers" actionListener="#{BrowseBean.setupSpaceAction}">
|
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
|
||||||
</a:actionLink>
|
|
||||||
</r:permissionEvaluator>
|
|
||||||
</a:menu>
|
|
||||||
--%>
|
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
<%-- Navigation --%>
|
<%-- Navigation --%>
|
||||||
@@ -150,7 +130,7 @@
|
|||||||
<f:facet name="title">
|
<f:facet name="title">
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Write">
|
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Write">
|
||||||
<a:actionLink id="titleLink1" value="#{msg.modify}" showLink="false" image="/images/icons/Change_details.gif"
|
<a:actionLink id="titleLink1" value="#{msg.modify}" showLink="false" image="/images/icons/Change_details.gif"
|
||||||
action="editForumsProperties" actionListener="#{EditForumsDialog.startWizardForEdit}" />
|
action="dialog:editForumsProperties" actionListener="#{EditForumsDialog.startWizardForEdit}" />
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
</f:facet>
|
</f:facet>
|
||||||
</h:column>
|
</h:column>
|
||||||
|
@@ -82,18 +82,18 @@
|
|||||||
<%-- Current object actions --%>
|
<%-- Current object actions --%>
|
||||||
<h:outputText style="padding-left:20px" styleClass="mainSubTitle" value="#{msg.actions}" id="msg5" /><br>
|
<h:outputText style="padding-left:20px" styleClass="mainSubTitle" value="#{msg.actions}" id="msg5" /><br>
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="CreateChildren" id="eval1">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="CreateChildren" id="eval1">
|
||||||
<a:actionLink value="#{msg.create_forums}" image="/images/icons/create_forums.gif" padding="4" action="createForums" actionListener="#{CreateForumsDialog.startWizard}" id="link1" />
|
<a:actionLink value="#{msg.create_forums}" image="/images/icons/create_forums.gif" padding="4" action="dialog:createForums" actionListener="#{CreateForumsDialog.startWizard}" id="link1" />
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="CreateChildren" id="eval2">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="CreateChildren" id="eval2">
|
||||||
<a:actionLink value="#{msg.create_forum}" image="/images/icons/create_forum.gif" padding="4" action="createForum" actionListener="#{CreateForumDialog.startWizard}" id="link2" />
|
<a:actionLink value="#{msg.create_forum}" image="/images/icons/create_forum.gif" padding="4" action="dialog:createForum" actionListener="#{CreateForumDialog.startWizard}" id="link2" />
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" padding="4" action="showForumsDetails" actionListener="#{BrowseBean.setupSpaceAction}" id="link3">
|
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" padding="4" action="dialog:showForumsDetails" actionListener="#{BrowseBean.setupSpaceAction}" id="link3">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param1" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param1" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
<%-- Current space More actions menu --%>
|
<%-- Current space More actions menu --%>
|
||||||
<a:menu id="spaceMenu" itemSpacing="4" label="#{msg.more_options}" image="/images/icons/more.gif" tooltip="#{msg.more_options_space}" menuStyleClass="moreActionsMenu" style="padding-left:20px">
|
<a:menu id="spaceMenu" itemSpacing="4" label="#{msg.more_options}" image="/images/icons/more.gif" tooltip="#{msg.more_options_space}" menuStyleClass="moreActionsMenu" style="padding-left:20px">
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="Delete" id="eval3">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="Delete" id="eval3">
|
||||||
<a:actionLink value="#{msg.delete_forums}" image="/images/icons/delete.gif" action="deleteForums" actionListener="#{BrowseBean.setupDeleteAction}" id="link4">
|
<a:actionLink value="#{msg.delete_forums}" image="/images/icons/delete.gif" action="dialog:deleteForums" actionListener="#{BrowseBean.setupDeleteAction}" id="link4">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param2" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param2" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
<a:actionLink value="#{msg.cut}" image="/images/icons/cut.gif" actionListener="#{ClipboardBean.cutNode}" id="link5">
|
<a:actionLink value="#{msg.cut}" image="/images/icons/cut.gif" actionListener="#{ClipboardBean.cutNode}" id="link5">
|
||||||
@@ -107,10 +107,18 @@
|
|||||||
<a:actionLink value="#{msg.paste_all}" image="/images/icons/paste.gif" actionListener="#{ClipboardBean.pasteAll}" id="link7" />
|
<a:actionLink value="#{msg.paste_all}" image="/images/icons/paste.gif" actionListener="#{ClipboardBean.pasteAll}" id="link7" />
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="ChangePermissions" id="eval5">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="ChangePermissions" id="eval5">
|
||||||
<a:actionLink value="#{msg.manage_invited_users}" image="/images/icons/invite.gif" action="manageInvitedUsers" actionListener="#{BrowseBean.setupSpaceAction}" id="link8">
|
<a:actionLink value="#{msg.manage_invited_users}" image="/images/icons/invite.gif" action="dialog:manageInvitedUsers" actionListener="#{BrowseBean.setupSpaceAction}" id="link8">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param5" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param5" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="Write" id="eval6">
|
||||||
|
<a:actionLink value="#{msg.import}" image="/images/icons/import.gif" action="dialog:import" actionListener="#{BrowseBean.setupSpaceAction}" id="link9">
|
||||||
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" />
|
||||||
|
</a:actionLink>
|
||||||
|
</r:permissionEvaluator>
|
||||||
|
<a:actionLink value="#{msg.export}" image="/images/icons/export.gif" action="dialog:export" actionListener="#{BrowseBean.setupSpaceAction}" id="link10">
|
||||||
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" />
|
||||||
|
</a:actionLink>
|
||||||
</a:menu>
|
</a:menu>
|
||||||
</td>
|
</td>
|
||||||
</a:panel>
|
</a:panel>
|
||||||
@@ -244,11 +252,19 @@
|
|||||||
<h:outputText value="#{msg.actions}"/>
|
<h:outputText value="#{msg.actions}"/>
|
||||||
</f:facet>
|
</f:facet>
|
||||||
<r:permissionEvaluator value="#{r}" allow="Delete">
|
<r:permissionEvaluator value="#{r}" allow="Delete">
|
||||||
<a:actionLink value="#{msg.delete}" image="/images/icons/delete.gif" showLink="false" styleClass="inlineAction" action="deleteSpace" actionListener="#{BrowseBean.setupDeleteAction}">
|
<a:actionLink value="#{msg.cut}" image="/images/icons/cut.gif" showLink="false" styleClass="inlineAction" actionListener="#{ClipboardBean.cutNode}">
|
||||||
<f:param name="id" value="#{r.id}" />
|
<f:param name="id" value="#{r.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" showLink="false" styleClass="inlineAction" action="showSpaceDetails" actionListener="#{BrowseBean.setupSpaceAction}">
|
<a:actionLink value="#{msg.copy}" image="/images/icons/copy.gif" showLink="false" styleClass="inlineAction" actionListener="#{ClipboardBean.copyNode}">
|
||||||
|
<f:param name="id" value="#{r.id}" />
|
||||||
|
</a:actionLink>
|
||||||
|
<r:permissionEvaluator value="#{r}" allow="Delete">
|
||||||
|
<a:actionLink value="#{msg.delete}" image="/images/icons/delete.gif" showLink="false" styleClass="inlineAction" action="dialog:deleteSpace" actionListener="#{BrowseBean.setupDeleteAction}">
|
||||||
|
<f:param name="id" value="#{r.id}" />
|
||||||
|
</a:actionLink>
|
||||||
|
</r:permissionEvaluator>
|
||||||
|
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" showLink="false" styleClass="inlineAction" action="dialog:showSpaceDetails" actionListener="#{BrowseBean.setupSpaceAction}">
|
||||||
<f:param name="id" value="#{r.id}" />
|
<f:param name="id" value="#{r.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</a:column>
|
</a:column>
|
||||||
|
@@ -88,30 +88,10 @@
|
|||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Delete">
|
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Delete">
|
||||||
<a:actionLink value="#{msg.delete}" image="/images/icons/delete.gif" padding="4" action="deleteTopic" actionListener="#{BrowseBean.setupSpaceAction}">
|
<a:actionLink value="#{msg.delete}" image="/images/icons/delete.gif" padding="4" action="dialog:deleteTopic" actionListener="#{BrowseBean.setupSpaceAction}">
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<%--
|
|
||||||
<a:menu itemSpacing="4" label="#{msg.more_options}" image="/images/icons/more.gif" tooltip="#{msg.more_options_space}" menuStyleClass="moreActionsMenu" style="padding-left:20px">
|
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Write">
|
|
||||||
<a:actionLink value="#{msg.import}" image="/images/icons/import.gif" action="import" actionListener="#{BrowseBean.setupSpaceAction}">
|
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
|
||||||
</a:actionLink>
|
|
||||||
</r:permissionEvaluator>
|
|
||||||
<a:actionLink value="#{msg.export}" image="/images/icons/export.gif" action="export" actionListener="#{BrowseBean.setupSpaceAction}">
|
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
|
||||||
</a:actionLink>
|
|
||||||
<a:actionLink value="#{msg.create_shortcut}" image="/images/icons/shortcut.gif" actionListener="#{UserShortcutsBean.createShortcut}">
|
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
|
||||||
</a:actionLink>
|
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="ChangePermissions">
|
|
||||||
<a:actionLink value="#{msg.manage_invited_users}" image="/images/icons/invite.gif" action="manageInvitedUsers" actionListener="#{BrowseBean.setupSpaceAction}">
|
|
||||||
<f:param name="id" value="#{SpaceDetailsBean.id}" />
|
|
||||||
</a:actionLink>
|
|
||||||
</r:permissionEvaluator>
|
|
||||||
</a:menu>
|
|
||||||
--%>
|
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
<%-- Navigation --%>
|
<%-- Navigation --%>
|
||||||
@@ -150,7 +130,7 @@
|
|||||||
<f:facet name="title">
|
<f:facet name="title">
|
||||||
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Write">
|
<r:permissionEvaluator value="#{SpaceDetailsBean.space}" allow="Write">
|
||||||
<a:actionLink id="titleLink1" value="#{msg.modify}" showLink="false" image="/images/icons/Change_details.gif"
|
<a:actionLink id="titleLink1" value="#{msg.modify}" showLink="false" image="/images/icons/Change_details.gif"
|
||||||
action="editTopicProperties" actionListener="#{EditTopicDialog.startWizardForEdit}" />
|
action="dialog:editTopicProperties" actionListener="#{EditTopicDialog.startWizardForEdit}" />
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
</f:facet>
|
</f:facet>
|
||||||
</h:column>
|
</h:column>
|
||||||
|
@@ -68,7 +68,7 @@
|
|||||||
<%-- actions for forums --%>
|
<%-- actions for forums --%>
|
||||||
<a:panel id="topic-actions">
|
<a:panel id="topic-actions">
|
||||||
<td width=32>
|
<td width=32>
|
||||||
<h:graphicImage id="space-logo" url="/images/icons/topic_large.gif" width="32" height="32" />
|
<h:graphicImage id="space-logo" url="/images/icons/#{NavigationBean.nodeProperties.icon}.gif" width="32" height="32" />
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<%-- Summary --%>
|
<%-- Summary --%>
|
||||||
@@ -81,13 +81,13 @@
|
|||||||
<%-- Current object actions --%>
|
<%-- Current object actions --%>
|
||||||
<h:outputText style="padding-left:20px" styleClass="mainSubTitle" value="#{msg.actions}" id="msg5" /><br>
|
<h:outputText style="padding-left:20px" styleClass="mainSubTitle" value="#{msg.actions}" id="msg5" /><br>
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="CreateChildren" id="eval1">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="CreateChildren" id="eval1">
|
||||||
<a:actionLink value="#{msg.post_to_topic}" image="/images/icons/create_post.gif" padding="4" action="createPost" actionListener="#{CreatePostDialog.startWizard}" id="link1" />
|
<a:actionLink value="#{msg.post_to_topic}" image="/images/icons/create_post.gif" padding="4" action="dialog:createPost" actionListener="#{CreatePostDialog.startWizard}" id="link1" />
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" padding="4" action="showTopicDetails" actionListener="#{BrowseBean.setupSpaceAction}" id="link2">
|
<a:actionLink value="#{msg.view_details}" image="/images/icons/View_details.gif" padding="4" action="dialog:showTopicDetails" actionListener="#{BrowseBean.setupSpaceAction}" id="link2">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param1" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param1" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="Delete" id="eval2">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="Delete" id="eval2">
|
||||||
<a:actionLink value="#{msg.delete_topic}" image="/images/icons/delete.gif" padding="4" action="deleteTopic" actionListener="#{BrowseBean.setupDeleteAction}" id="link3">
|
<a:actionLink value="#{msg.delete_topic}" image="/images/icons/delete.gif" padding="4" action="dialog:deleteTopic" actionListener="#{BrowseBean.setupDeleteAction}" id="link3">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param2" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param2" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
@@ -105,7 +105,7 @@
|
|||||||
<a:actionLink value="#{msg.paste_all}" image="/images/icons/paste.gif" actionListener="#{ClipboardBean.pasteAll}" id="link6" />
|
<a:actionLink value="#{msg.paste_all}" image="/images/icons/paste.gif" actionListener="#{ClipboardBean.pasteAll}" id="link6" />
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="ChangePermissions" id="eval5">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="ChangePermissions" id="eval5">
|
||||||
<a:actionLink value="#{msg.manage_invited_users}" image="/images/icons/invite.gif" action="manageInvitedUsers" actionListener="#{BrowseBean.setupSpaceAction}" id="link7">
|
<a:actionLink value="#{msg.manage_invited_users}" image="/images/icons/invite.gif" action="dialog:manageInvitedUsers" actionListener="#{BrowseBean.setupSpaceAction}" id="link7">
|
||||||
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param5" />
|
<f:param name="id" value="#{NavigationBean.currentNodeId}" id="param5" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
@@ -217,17 +217,17 @@
|
|||||||
<h:outputText value="#{msg.actions}"/>
|
<h:outputText value="#{msg.actions}"/>
|
||||||
</f:facet>
|
</f:facet>
|
||||||
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="CreateChildren">
|
<r:permissionEvaluator value="#{NavigationBean.currentNode}" allow="CreateChildren">
|
||||||
<a:actionLink value="#{msg.post_reply}" image="/images/icons/post_reply.gif" showLink="false" styleClass="inlineAction" action="createReply" actionListener="#{CreateReplyDialog.startWizard}">
|
<a:actionLink value="#{msg.post_reply}" image="/images/icons/post_reply.gif" showLink="false" styleClass="inlineAction" action="dialog:createReply" actionListener="#{CreateReplyDialog.startWizard}">
|
||||||
<f:param name="id" value="#{r.id}" />
|
<f:param name="id" value="#{r.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<r:permissionEvaluator value="#{r}" allow="Write">
|
<r:permissionEvaluator value="#{r}" allow="Write">
|
||||||
<a:actionLink value="#{msg.edit_post}" image="/images/icons/edit_icon.gif" showLink="false" styleClass="inlineAction" action="editPost" actionListener="#{EditPostDialog.startWizardForEdit}">
|
<a:actionLink value="#{msg.edit_post}" image="/images/icons/edit_post.gif" showLink="false" styleClass="inlineAction" action="dialog:editPost" actionListener="#{EditPostDialog.startWizardForEdit}">
|
||||||
<f:param name="id" value="#{r.id}" />
|
<f:param name="id" value="#{r.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
<r:permissionEvaluator value="#{r}" allow="Delete">
|
<r:permissionEvaluator value="#{r}" allow="Delete">
|
||||||
<a:actionLink value="#{msg.delete_post}" image="/images/icons/delete.gif" showLink="false" styleClass="inlineAction" action="deletePost" actionListener="#{BrowseBean.setupContentAction}">
|
<a:actionLink value="#{msg.delete_post}" image="/images/icons/delete.gif" showLink="false" styleClass="inlineAction" action="dialog:deletePost" actionListener="#{BrowseBean.setupContentAction}">
|
||||||
<f:param name="id" value="#{r.id}" />
|
<f:param name="id" value="#{r.id}" />
|
||||||
</a:actionLink>
|
</a:actionLink>
|
||||||
</r:permissionEvaluator>
|
</r:permissionEvaluator>
|
||||||
|
@@ -173,7 +173,7 @@
|
|||||||
<table cellpadding="0" cellspacing="0" border="0">
|
<table cellpadding="0" cellspacing="0" border="0">
|
||||||
<tr>
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<h:commandButton value="#{msg.close}" action="browse" styleClass="wizardButton" />
|
<h:commandButton value="#{msg.close}" action="dialog:close" styleClass="wizardButton" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|