Skip to content
Permalink
Browse files

Merge pull request #6 from daniel-beck/JENKINS-20523

[FIXED JENKINS-20523] Provide views list in breadcrumb bar
  • Loading branch information...
jglick committed Feb 17, 2014
2 parents 2bbf9ee + 63b5a29 commit ac59f5238b0807041d6d60b1a9419db25d7b4173
Showing with 10 additions and 1 deletion.
  1. +10 −1 src/main/java/com/cloudbees/hudson/plugins/folder/Folder.java
@@ -110,13 +110,14 @@
import java.util.concurrent.atomic.AtomicInteger;
import jenkins.model.DirectlyModifiableTopLevelItemGroup;
import jenkins.model.Jenkins;
import jenkins.model.ModelObjectWithChildren;
import org.kohsuke.stapler.interceptor.RequirePOST;

/**
* {@link Item} that contains other {@link Item}s, without modeling dependency.
*/
public class Folder extends AbstractItem
implements DirectlyModifiableTopLevelItemGroup, ViewGroup, TopLevelItem, StaplerOverridable, StaplerFallback {
implements DirectlyModifiableTopLevelItemGroup, ViewGroup, TopLevelItem, StaplerOverridable, StaplerFallback, ModelObjectWithChildren {

/**
* @see #getNewPronoun
@@ -641,6 +642,14 @@ public FormValidation doCheckJobName(@QueryParameter String value) {
}
}

public ContextMenu doChildrenContextMenu(StaplerRequest request, StaplerResponse response) {
ContextMenu menu = new ContextMenu();
for (View view : getViews()) {
menu.add(view.getAbsoluteUrl(),view.getDisplayName());
}
return menu;
}

/**
* Copies an existing {@link TopLevelItem} to into this folder with a new name.
*/

0 comments on commit ac59f52

Please sign in to comment.
You can’t perform that action at this time.