Commit c82a0d2a authored by jplang's avatar jplang

Adds a project specific css class to body (#14767).

git-svn-id: https://svn.redmine.org/redmine/trunk@12170 e93f8b46-1217-0410-a6f0-8f06a7374b81
parent 5dd1dce1
......@@ -488,6 +488,7 @@ module ApplicationHelper
css << 'theme-' + theme.name
end
css << 'project-' + @project.identifier if @project && @project.identifier.present?
css << 'controller-' + controller_name
css << 'action-' + action_name
css.join(' ')
......
......@@ -589,4 +589,9 @@ class ProjectsControllerTest < ActionController::TestCase
assert_response :success
assert_template 'show'
end
def test_body_should_have_project_css_class
get :show, :id => 1
assert_select 'body.project-ecookbook'
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment