Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordonald.g.dunne2018-11-12 19:55:51 -0500
committerdonald.g.dunne2018-11-13 15:21:07 -0500
commitb851f71f3adafb9a09d730240eb0e368597361a0 (patch)
tree76a1b333fbed95ac299179b1623a0c1905a42ac3
parent884fd1c91c6bdb14e60c7434d6ce2b94a7da4f42 (diff)
downloadorg.eclipse.osee-b851f71f3adafb9a09d730240eb0e368597361a0.tar.gz
org.eclipse.osee-b851f71f3adafb9a09d730240eb0e368597361a0.tar.xz
org.eclipse.osee-b851f71f3adafb9a09d730240eb0e368597361a0.zip
bug[ats_TW11516]: Disable Mass edit of artifact if branch access denied
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/massEditor/MassXViewer.java10
1 files changed, 10 insertions, 0 deletions
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/massEditor/MassXViewer.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/massEditor/MassXViewer.java
index 5b21ce29ed..1c17ab9a75 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/massEditor/MassXViewer.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/massEditor/MassXViewer.java
@@ -43,6 +43,7 @@ import org.eclipse.osee.framework.ui.plugin.util.AWorkbench;
import org.eclipse.osee.framework.ui.skynet.ArtifactDoubleClick;
import org.eclipse.osee.framework.ui.skynet.artifact.ArtifactPromptChange;
import org.eclipse.osee.framework.ui.skynet.artifact.ArtifactTransfer;
+import org.eclipse.osee.framework.ui.skynet.change.ChangeUiUtil;
import org.eclipse.osee.framework.ui.skynet.internal.Activator;
import org.eclipse.osee.framework.ui.skynet.render.RendererManager;
import org.eclipse.osee.framework.ui.skynet.widgets.dialog.FilteredCheckboxAttributeTypeDialog;
@@ -315,6 +316,11 @@ public class MassXViewer extends XViewer implements IMassViewerEventHandler {
try {
if (e.data instanceof ArtifactData) {
Artifact[] artsToAdd = ((ArtifactData) e.data).getArtifacts();
+ for (int x = 0; x < artsToAdd.length; x++) {
+ if (ChangeUiUtil.permissionsDeniedWithDialog(artsToAdd[x].getBranch())) {
+ return;
+ }
+ }
add(Arrays.asList(artsToAdd));
}
refresh();
@@ -330,6 +336,10 @@ public class MassXViewer extends XViewer implements IMassViewerEventHandler {
return;
}
Artifact artifact = artifacts.iterator().next();
+ if (ChangeUiUtil.permissionsDeniedWithDialog(artifact.getBranch())) {
+ return;
+ }
+
PresentationType type = ArtifactDoubleClick.getPresentationType(artifact);
PermissionEnum perEnum = ArtifactDoubleClick.getPermissionEnum(artifact);
if (AccessControlManager.hasPermission(artifacts, perEnum)) {

Back to the top