Index: app/models/issue.rb =================================================================== --- app/models/issue.rb (revision 13182) +++ app/models/issue.rb (working copy) @@ -1093,6 +1093,7 @@ s << ' child' if child? s << ' parent' unless leaf? s << ' private' if is_private? + s << ' has_attachments' unless attachments == [] if user.logged? s << ' created-by-me' if author_id == user.id s << ' assigned-to-me' if assigned_to_id == user.id Index: public/stylesheets/application.css =================================================================== --- public/stylesheets/application.css (revision 13182) +++ public/stylesheets/application.css (working copy) @@ -154,6 +154,7 @@ tr.issue td.relations { text-align: left; } tr.issue td.done_ratio table.progress { margin-left:auto; margin-right: auto;} tr.issue td.relations span {white-space: nowrap;} +tr.issue.has_attachments td.subject {padding-left: 18px; background: url(../images/attachment.png) no-repeat 0 50%;} table.issues td.description {color:#777; font-size:90%; padding:4px 4px 4px 24px; text-align:left; white-space:normal;} table.issues td.description pre {white-space:normal;} Index: test/unit/issue_test.rb =================================================================== --- test/unit/issue_test.rb (revision 13182) +++ test/unit/issue_test.rb (working copy) @@ -2279,6 +2279,17 @@ assert_include 'assigned-to-me', issue2.css_classes(user) end + def test_css_classes_should_include_attachments + set_tmp_attachments_directory + issue = Issue.generate! + assert_not_include 'has_attachments', issue.css_classes.split(' ') + issue.save_attachments({ + '1' => {'file' => mock_file_with_options(:original_filename => 'foo')} + }) + issue.attach_saved_attachments + assert_include 'has_attachments', issue.css_classes.split(' ') + end + def test_save_attachments_with_hash_should_save_attachments_in_keys_order set_tmp_attachments_directory issue = Issue.generate!