Feature: Labels page. Index page
This commit is contained in:
parent
14bd9c9228
commit
3dd7703b80
7 changed files with 81 additions and 1 deletions
25
app/controllers/labels_controller.rb
Normal file
25
app/controllers/labels_controller.rb
Normal file
|
@ -0,0 +1,25 @@
|
|||
class LabelsController < ApplicationController
|
||||
before_filter :authenticate_user!
|
||||
before_filter :project
|
||||
before_filter :module_enabled
|
||||
|
||||
layout "project"
|
||||
|
||||
# Authorize
|
||||
before_filter :add_project_abilities
|
||||
|
||||
# Allow read any issue
|
||||
before_filter :authorize_read_issue!
|
||||
|
||||
respond_to :js, :html
|
||||
|
||||
def index
|
||||
@labels = Issue.tag_counts_on(:labels)
|
||||
end
|
||||
|
||||
protected
|
||||
|
||||
def module_enabled
|
||||
return render_404 unless @project.issues_enabled
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue