diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2012-07-26 16:55:40 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2012-07-26 16:55:40 +0000 |
commit | f03e21fb45e534e4747b5b9e21593ffb1b35ae70 (patch) | |
tree | 250169afbba13f5a9b8b9e7b15cd4daf11f408ed | |
parent | 88efd302a7ff0e1ca3c0ac5a3c3a5910cc7ca2c8 (diff) | |
download | redmine-f03e21fb45e534e4747b5b9e21593ffb1b35ae70.tar.gz redmine-f03e21fb45e534e4747b5b9e21593ffb1b35ae70.zip |
Changed issues css class from priority-{position} to status-{id} (#2071).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10079 e93f8b46-1217-0410-a6f0-8f06a7374b81
-rw-r--r-- | app/models/issue.rb | 2 | ||||
-rw-r--r-- | lib/redmine/default_data/loader.rb | 6 | ||||
-rw-r--r-- | test/unit/helpers/application_helper_test.rb | 6 |
3 files changed, 7 insertions, 7 deletions
diff --git a/app/models/issue.rb b/app/models/issue.rb index f5ff3fc08..a06378a5b 100644 --- a/app/models/issue.rb +++ b/app/models/issue.rb @@ -819,7 +819,7 @@ class Issue < ActiveRecord::Base # Returns a string of css classes that apply to the issue def css_classes - s = "issue status-#{status_id} priority-#{priority.position}" + s = "issue status-#{status_id} priority-#{priority_id}" s << ' closed' if closed? s << ' overdue' if overdue? s << ' child' if child? diff --git a/lib/redmine/default_data/loader.rb b/lib/redmine/default_data/loader.rb index 910a6a319..eabc35161 100644 --- a/lib/redmine/default_data/loader.rb +++ b/lib/redmine/default_data/loader.rb @@ -163,15 +163,15 @@ module Redmine } # Enumerations - DocumentCategory.create!(:name => l(:default_doc_category_user), :position => 1) - DocumentCategory.create!(:name => l(:default_doc_category_tech), :position => 2) - IssuePriority.create!(:name => l(:default_priority_low), :position => 1) IssuePriority.create!(:name => l(:default_priority_normal), :position => 2, :is_default => true) IssuePriority.create!(:name => l(:default_priority_high), :position => 3) IssuePriority.create!(:name => l(:default_priority_urgent), :position => 4) IssuePriority.create!(:name => l(:default_priority_immediate), :position => 5) + DocumentCategory.create!(:name => l(:default_doc_category_user), :position => 1) + DocumentCategory.create!(:name => l(:default_doc_category_tech), :position => 2) + TimeEntryActivity.create!(:name => l(:default_activity_design), :position => 1) TimeEntryActivity.create!(:name => l(:default_activity_development), :position => 2) end diff --git a/test/unit/helpers/application_helper_test.rb b/test/unit/helpers/application_helper_test.rb index 1740fbc52..d3832524e 100644 --- a/test/unit/helpers/application_helper_test.rb +++ b/test/unit/helpers/application_helper_test.rb @@ -228,9 +228,9 @@ RAW def test_redmine_links issue_link = link_to('#3', {:controller => 'issues', :action => 'show', :id => 3}, - :class => 'issue status-1 priority-1 overdue', :title => 'Error 281 when updating a recipe (New)') + :class => 'issue status-1 priority-4 overdue', :title => 'Error 281 when updating a recipe (New)') note_link = link_to('#3', {:controller => 'issues', :action => 'show', :id => 3, :anchor => 'note-14'}, - :class => 'issue status-1 priority-1 overdue', :title => 'Error 281 when updating a recipe (New)') + :class => 'issue status-1 priority-4 overdue', :title => 'Error 281 when updating a recipe (New)') changeset_link = link_to('r1', {:controller => 'repositories', :action => 'revision', :id => 'ecookbook', :rev => 1}, :class => 'changeset', :title => 'My very first commit') @@ -686,7 +686,7 @@ RAW expected = <<-EXPECTED <p><a href="/projects/ecookbook/wiki/CookBook_documentation" class="wiki-page">CookBook documentation</a></p> -<p><a href="/issues/1" class="issue status-1 priority-1" title="Can't print recipes (New)">#1</a></p> +<p><a href="/issues/1" class="issue status-1 priority-4" title="Can't print recipes (New)">#1</a></p> <pre> [[CookBook documentation]] |