Affects Version/s: 5.1.2, 5.2.0
Fix Version/s: 5.2.1
Liferay Contributor's Agreement:Accept
Document Library Portlet.
Rights for document:
Owner - View, Update, Add Discussion
Some Other Role (Owner's not in it) - View, Update, Add Discussion
no other people have any permissions for the file.
Problem: owner doesn't have "Add reply" links.
Reason: html/taglib/ui/discussion/page.jsp, multiple "MBDiscussionPermission.contains(permissionChecker, scopeGroupId, className, classPK, ActionKeys.ADD_DISCUSSION)" calls do not check whether 'userId' (the param which is also passed by document library) is owner of "className+classPK'.
Solution: permissionChecker.hasOwnerPermission(fileEntry.getCompanyId() - ???, className, classPK, userId, ActionKeys.ADD_DISCUSSION).