|
|
@ -22,7 +22,9 @@ class IssuesController < ApplicationController
|
|
|
|
before_filter :find_issue, :only => [:show, :edit, :update]
|
|
|
|
before_filter :find_issue, :only => [:show, :edit, :update]
|
|
|
|
before_filter :find_issues, :only => [:bulk_edit, :bulk_update, :destroy]
|
|
|
|
before_filter :find_issues, :only => [:bulk_edit, :bulk_update, :destroy]
|
|
|
|
before_filter :find_project, :only => [:new, :create, :update_form]
|
|
|
|
before_filter :find_project, :only => [:new, :create, :update_form]
|
|
|
|
before_filter :authorize, :except => [:index]
|
|
|
|
#before_filter :authorize, :except => [:index, :show]
|
|
|
|
|
|
|
|
before_filter :authorize1, :except => [:index]
|
|
|
|
|
|
|
|
|
|
|
|
before_filter :find_optional_project, :only => [:index]
|
|
|
|
before_filter :find_optional_project, :only => [:index]
|
|
|
|
before_filter :check_for_default_issue_status, :only => [:new, :create]
|
|
|
|
before_filter :check_for_default_issue_status, :only => [:new, :create]
|
|
|
|
before_filter :build_new_issue_from_params, :only => [:new, :create, :update_form]
|
|
|
|
before_filter :build_new_issue_from_params, :only => [:new, :create, :update_form]
|
|
|
@ -107,7 +109,7 @@ class IssuesController < ApplicationController
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
def show
|
|
|
|
def show
|
|
|
|
|
|
|
|
|
|
|
|
@journals = @issue.journals.includes(:user, :details).reorder("#{Journal.table_name}.id ASC").all
|
|
|
|
@journals = @issue.journals.includes(:user, :details).reorder("#{Journal.table_name}.id ASC").all
|
|
|
|
@journals.each_with_index {|j,i| j.indice = i+1}
|
|
|
|
@journals.each_with_index {|j,i| j.indice = i+1}
|
|
|
|
@journals.reject!(&:private_notes?) unless User.current.allowed_to?(:view_private_notes, @issue.project)
|
|
|
|
@journals.reject!(&:private_notes?) unless User.current.allowed_to?(:view_private_notes, @issue.project)
|
|
|
|