diff options
author | ddunne | 2011-09-01 23:04:28 +0000 |
---|---|---|
committer | Ryan D. Brooks | 2011-09-01 23:04:28 +0000 |
commit | 4c2f7d65ec2f172fbf992f353f5984fee1c19b09 (patch) | |
tree | 81e7a05e79fbe3c5df3ea73f99805186fa67bb15 | |
parent | 6f85b98166a9650c68413d74a1ca0619fa67d82e (diff) | |
download | org.eclipse.osee-4c2f7d65ec2f172fbf992f353f5984fee1c19b09.tar.gz org.eclipse.osee-4c2f7d65ec2f172fbf992f353f5984fee1c19b09.tar.xz org.eclipse.osee-4c2f7d65ec2f172fbf992f353f5984fee1c19b09.zip |
refinement: Update CreateActionUsingAllActionableItems to prompt if too many workflows created
-rw-r--r-- | plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/CreateActionUsingAllActionableItems.java | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/CreateActionUsingAllActionableItems.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/CreateActionUsingAllActionableItems.java index 850838376c8..824eb2cf135 100644 --- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/CreateActionUsingAllActionableItems.java +++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/CreateActionUsingAllActionableItems.java @@ -46,8 +46,14 @@ public class CreateActionUsingAllActionableItems extends XNavigateItemAction { } try { ActionArtifact action = createActionWithAllAis(); - AWorkbench.popup("Completed", "Completed"); - AtsUtil.openATSAction(action, AtsOpenOption.OpenAll); + int numWfs = action.getTeams().size(); + if (numWfs > 30) { + AWorkbench.popup(numWfs + " Workflows were created. Only opening one."); + AtsUtil.openATSAction(action.getTeams().iterator().next(), AtsOpenOption.OpenOneOrPopupSelect); + } else { + AWorkbench.popup("Completed", "Completed"); + AtsUtil.openATSAction(action, AtsOpenOption.OpenAll); + } } catch (Exception ex) { OseeLog.log(Activator.class, OseeLevel.SEVERE_POPUP, ex); } @@ -63,8 +69,8 @@ public class CreateActionUsingAllActionableItems extends XNavigateItemAction { SkynetTransaction transaction = new SkynetTransaction(AtsUtil.getAtsBranch(), "Create Action using all AIs"); ActionArtifact action = - ActionManager.createAction(null, "Big Action", "Description", ChangeType.Improvement, "1", false, null, aias, - new Date(), UserManager.getUser(), null, transaction); + ActionManager.createAction(null, "Big Action Test - Delete Me", "Description", ChangeType.Improvement, "1", + false, null, aias, new Date(), UserManager.getUser(), null, transaction); transaction.execute(); return action; } |