Skip to content

Commit

Permalink
favorite: Fix page navigation bug when using favorite menu
Browse files Browse the repository at this point in the history
  • Loading branch information
doortts committed Sep 24, 2017
1 parent ea70650 commit a35a14e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions app/controllers/ProjectApp.java
Original file line number Diff line number Diff line change
Expand Up @@ -1285,17 +1285,17 @@ public static Result deletePushedBranch(String ownerId, String projectName, Long

@IsAllowed(Operation.READ)
@Transactional
public static Result goConventionMenu(String ownerId, String projectName)
public static Result goConventionMenu(String ownerId, String projectName, String state, String format, int pageNum)
throws IOException, ServletException, SVNException, GitAPIException, WriteException {
Project project = Project.findByOwnerAndProjectName(ownerId, projectName);
List<History> histories = null;

if( project.menuSetting.issue ) {
return IssueApp.issues(project.owner, project.name);
return IssueApp.issues(project.owner, project.name, state, format, pageNum);
}

if( project.menuSetting.board ) {
return redirect(routes.BoardApp.posts(project.owner, project.name, 1));
return redirect(routes.BoardApp.posts(project.owner, project.name, pageNum));
}

return redirect(routes.ProjectApp.project(project.owner, project.name));
Expand Down
2 changes: 1 addition & 1 deletion conf/routes
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ GET /:user/:project/changeVCS
POST /:user/:project/changeVCS controllers.ProjectApp.changeVCS(user, project)

# Project menu forwarding
GET /:user/:project/go controllers.ProjectApp.goConventionMenu(user, project)
GET /:user/:project/go controllers.ProjectApp.goConventionMenu(user, project, state:String ?= "", format:String ?= "html", pageNum: Int ?= 1)

# Project Review Menu
GET /:user/:project/reviews controllers.ReviewThreadApp.reviewThreads(user, project)
Expand Down

0 comments on commit a35a14e

Please sign in to comment.