From 5159789ec95e101084a81ec51b7c53ddbc3b702f Mon Sep 17 00:00:00 2001 From: jensp Date: Tue, 4 Nov 2014 15:08:07 +0000 Subject: [PATCH] BugFix for th Sponsors table: The check for edit permissions for the delete link of a sponsor association was done on the wrong object git-svn-id: https://svn.libreccm.org/ccm/trunk@2950 8810af33-2d31-482b-a856-94f89814c4df --- .../cms/contenttypes/ui/SciProjectSponsorSheet.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/ccm-sci-types-project/src/com/arsdigita/cms/contenttypes/ui/SciProjectSponsorSheet.java b/ccm-sci-types-project/src/com/arsdigita/cms/contenttypes/ui/SciProjectSponsorSheet.java index 494635e68..6b2e92ca6 100644 --- a/ccm-sci-types-project/src/com/arsdigita/cms/contenttypes/ui/SciProjectSponsorSheet.java +++ b/ccm-sci-types-project/src/com/arsdigita/cms/contenttypes/ui/SciProjectSponsorSheet.java @@ -241,13 +241,12 @@ public class SciProjectSponsorSheet extends Table { final int row, final int column) { final com.arsdigita.cms.SecurityManager securityManager = CMS.getSecurityManager(state); - final GenericOrganizationalUnit sponsor - = new GenericOrganizationalUnit((BigDecimal) key); + final SciProject project = (SciProject) itemModel.getSelectedObject(state); final boolean canEdit = securityManager.canAccess( state.getRequest(), com.arsdigita.cms.SecurityManager.EDIT_ITEM, - sponsor); + project); if (canEdit) { final ControlLink link = new ControlLink((Label)value); link.setConfirmation(SciProjectGlobalizationUtil.globalize(