Defect #11880
closedAlternate theme colors by issue priority in issue list is wrong
0%
Description
The issue list is using priority-4 for the normal priority issue (fresh Redmine installation uses priority-2)
Is this a bug? I noticed it after upgrading to Redmine 2.1.0. Changing the theme to the default theme doesn't fix it. I'm also not using any plugin.
Ruby version 1.9.3 (i686-linux) RubyGems version 1.8.19 Rack version 1.4 Rails version 3.2.8 Active Record version 3.2.8 Action Pack version 3.2.8 Active Resource version 3.2.8 Action Mailer version 3.2.8 Active Support version 3.2.8 Middleware Rack::Cache, ActionDispatch::Static, Rack::Lock, #<ActiveSupport::Cache::Strategy::LocalCache::Middleware:0x861fc44>, Rack::Runtime, Rack::MethodOverride, ActionDispatch::RequestId, Rails::Rack::Logger, ActionDispatch::ShowExceptions, ActionDispatch::DebugExceptions, ActionDispatch::RemoteIp, ActionDispatch::Callbacks, ActiveRecord::ConnectionAdapters::ConnectionManagement, ActiveRecord::QueryCache, ActionDispatch::Cookies, ActionDispatch::Session::CookieStore, ActionDispatch::Flash, ActionDispatch::ParamsParser, ActionDispatch::Head, Rack::ConditionalGet, Rack::ETag, ActionDispatch::BestStandardsSupport, OpenIdAuthentication Application root /opt/redmine Environment production Database adapter mysql2 Database schema version 20120731164049
Files
Related issues
Updated by amree woot about 12 years ago
This is my current table for enumerations:
mysql> select * from enumerations; +----+-------------------------+----------+------------+-------------------+--------+------------+-----------+ | id | name | position | is_default | type | active | project_id | parent_id | +----+-------------------------+----------+------------+-------------------+--------+------------+-----------+ | 1 | User documentation | 1 | 0 | DocumentCategory | 1 | NULL | NULL | | 2 | Technical documentation | 2 | 0 | DocumentCategory | 1 | NULL | NULL | | 3 | Low | 1 | 0 | IssuePriority | 1 | NULL | NULL | | 4 | Normal | 2 | 1 | IssuePriority | 1 | NULL | NULL | | 5 | High | 3 | 0 | IssuePriority | 1 | NULL | NULL | | 6 | Urgent | 4 | 0 | IssuePriority | 1 | NULL | NULL | | 7 | Immediate | 5 | 0 | IssuePriority | 1 | NULL | NULL | | 8 | Design | 1 | 0 | TimeEntryActivity | 1 | NULL | NULL | | 9 | Development | 2 | 0 | TimeEntryActivity | 1 | NULL | NULL | +----+-------------------------+----------+------------+-------------------+--------+------------+-----------+
Updated by Etienne Massip about 12 years ago
- Subject changed from Issue row list is generating wrong css class for the priority to Alternate theme colors by issue priority in issue list is wrong
- Status changed from New to Confirmed
- Priority changed from Low to Normal
- Target version set to 2.1.1
Updated by Julien Petit about 12 years ago
- File application.css application.css added
If it can be of use to someone, i've patched the css. It works on my installation with the same table that amree woot is sharing here.
Updated by amree woot about 12 years ago
Working good for me (I'm using basecamp theme)
Updated by Miklós Balázs about 12 years ago
The problem is that when generating the CSS class to use, it takes into account the ID of the enumeration instead of the position field.
Updated by Julien Petit about 12 years ago
Miklós Balázs wrote:
The problem is that when generating the CSS class to use, it takes into account the ID of the enumeration instead of the position field.
This is not a problem, this is a change in the last releases because re-ordering position add the effect of changing status colors. The id is less likely to change.
Updated by Jean-Philippe Lang about 12 years ago
- Status changed from Confirmed to Closed
- Target version deleted (
2.1.1) - Resolution set to Wont fix
The theme is OK when creating default priorities with 2.1.0.
If you use this theme with priorities created previously, you'll have to adjust the css manually according to your priority ids.
Updated by John Reynolds about 12 years ago
I just saw this closed (suprised) and thought I should add that I've never once changed the order or setup of the issue priority enumerations and yet the problem exists for me. I guess if the statement is, 'adjust your css' then ok, but it's not a result of custom setup I think?
Updated by Anonymous about 12 years ago
I agree with John Reynolds, please see A1
Updated by Eric Platon about 12 years ago
I am also surprised that this ticket is closed. Comparing the code of 1.2.2 and 2.1.2, this appears to be a bug. Priorities were based on position before, and it seems a better choice than ID, which is just a default value set by the install script and may depend on the DB engine. My DB has been modified, after years of usage, and the match does not exist anymore.
Shifting the priority index in themes will work as long as priorities are not customized in Redmine.
For the record, I have tried 4 themes, and they all break consistently from 2.1.
Updated by Clemens Bergmann almost 12 years ago
hi,
for all that have this BUG i attach a patch against stable 2.1 which changes the behavior back. The rows now get the position and not the ID as css class.
Updated by Mischa The Evil about 11 years ago
- Has duplicate Defect #13840: Style issues by priority position, not id added
Updated by Vaclav Fiser almost 10 years ago
Hi,
We're facing this issue again in Redmine version 2.6.0 with custom theme. Unfortunately provided patch isn't compatible with latest version.
Can someone please help us ? Thank you