Fix for ALF-11490 - It is impossible to rename or delete the category.

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@31977 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Kevin Roast
2011-11-15 12:15:46 +00:00
parent 9f5436bf80
commit 02c964a5f8

View File

@@ -485,7 +485,8 @@ public class CategoriesDialog extends BaseDialogBean implements IContextListener
} }
else else
{ {
handler=new CategoryBreadcrumbHandler (getCategory().getNodeRef(), Repository.getNameForNode(getNodeService(), getCategory().getNodeRef())); handler = new CategoryBreadcrumbHandler(
getCategory().getNodeRef(), Repository.getNameForNode(getNodeService(), getCategory().getNodeRef()));
location.set(location.size() - 1, handler); location.set(location.size() - 1, handler);
this.setCurrentCategory(handler.nodeRef); this.setCurrentCategory(handler.nodeRef);
} }
@@ -590,7 +591,7 @@ public class CategoriesDialog extends BaseDialogBean implements IContextListener
// when selected we set the current category Id and return // when selected we set the current category Id and return
setCurrentCategory(this.nodeRef); setCurrentCategory(this.nodeRef);
setLocation((List)breadcrumb.getValue()); setLocation((List)breadcrumb.getValue());
return null; return null;
} }
@@ -625,14 +626,14 @@ public class CategoriesDialog extends BaseDialogBean implements IContextListener
public void restored() public void restored()
{ {
Object categoryToRemove = FacesContext.getCurrentInstance().getExternalContext(). Object categoryToRemove = FacesContext.getCurrentInstance().getExternalContext().
getRequestMap().get(KEY_CATEGORY); getRequestMap().get(KEY_CATEGORY);
if (categoryToRemove != null) if (categoryToRemove != null)
{ {
if (logger.isDebugEnabled()) if (logger.isDebugEnabled())
logger.debug("Removing group '" + categoryToRemove + "' from breadcrumb"); logger.debug("Removing group '" + categoryToRemove + "' from breadcrumb");
removeFromBreadcrumb((String)categoryToRemove); removeFromBreadcrumb((String)categoryToRemove);
} }
contextUpdated(); contextUpdated();
} }