]> source.dussan.org Git - redmine.git/commitdiff
Adds tracker name to Redmine issue link titles (#13946).
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Mon, 21 Sep 2015 20:42:06 +0000 (20:42 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Mon, 21 Sep 2015 20:42:06 +0000 (20:42 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@14620 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/helpers/application_helper.rb
test/unit/helpers/application_helper_test.rb
test/unit/mailer_test.rb

index ce6142050ad7b669ab5ab944f84a8db1628e86f1..096363a35c3bbf0244a7c6599d647f306823c6fc 100644 (file)
@@ -781,7 +781,7 @@ module ApplicationHelper
                 link = link_to("##{oid}#{comment_suffix}",
                                issue_url(issue, :only_path => only_path, :anchor => anchor),
                                :class => issue.css_classes,
-                               :title => "#{issue.subject.truncate(100)} (#{issue.status.name})")
+                               :title => "#{issue.tracker.name}: #{issue.subject.truncate(100)} (#{issue.status.name})")
               end
             when 'document'
               if document = Document.visible.find_by_id(oid)
index c33314fde8f54a0375b01fe3f0b7f2c3b69cfe52..27c711ddac78c51e413b2b59da7894ca90b5dc08 100644 (file)
@@ -276,11 +276,11 @@ RAW
 
   def test_redmine_links
     issue_link = link_to('#3', {:controller => 'issues', :action => 'show', :id => 3},
-                               :class => Issue.find(3).css_classes, :title => 'Error 281 when updating a recipe (New)')
+                               :class => Issue.find(3).css_classes, :title => 'Bug: Error 281 when updating a recipe (New)')
     note_link = link_to('#3-14', {:controller => 'issues', :action => 'show', :id => 3, :anchor => 'note-14'},
-                               :class => Issue.find(3).css_classes, :title => 'Error 281 when updating a recipe (New)')
+                               :class => Issue.find(3).css_classes, :title => 'Bug: Error 281 when updating a recipe (New)')
     note_link2 = link_to('#3#note-14', {:controller => 'issues', :action => 'show', :id => 3, :anchor => 'note-14'},
-                               :class => Issue.find(3).css_classes, :title => 'Error 281 when updating a recipe (New)')
+                               :class => Issue.find(3).css_classes, :title => 'Bug: Error 281 when updating a recipe (New)')
 
     revision_link = link_to('r1', {:controller => 'repositories', :action => 'revision', :id => 'ecookbook', :rev => 1},
                                    :class => 'changeset', :title => 'My very first commit do not escaping #<>&')
@@ -964,7 +964,7 @@ RAW
     result2 = link_to('#1',
                       "/issues/1",
                       :class => Issue.find(1).css_classes,
-                      :title => "Cannot print recipes (New)")
+                      :title => "Bug: Cannot print recipes (New)")
 
     expected = <<-EXPECTED
 <p>#{result1}</p>
index 0b985c17108bc39a49265a299212a8a391e8e24f..f3742c2b5e3777ad2762f9d44de4ec491b73db89 100644 (file)
@@ -56,7 +56,7 @@ class MailerTest < ActiveSupport::TestCase
       # link to a referenced ticket
       assert_select 'a[href=?][title=?]',
                     'https://mydomain.foo/issues/1',
-                    "Cannot print recipes (New)",
+                    "Bug: Cannot print recipes (New)",
                     :text => '#1'
       # link to a changeset
       assert_select 'a[href=?][title=?]',
@@ -97,7 +97,7 @@ class MailerTest < ActiveSupport::TestCase
       # link to a referenced ticket
       assert_select 'a[href=?][title=?]',
                     'http://mydomain.foo/rdm/issues/1',
-                    "Cannot print recipes (New)",
+                    "Bug: Cannot print recipes (New)",
                     :text => '#1'
       # link to a changeset
       assert_select 'a[href=?][title=?]',
@@ -167,7 +167,7 @@ class MailerTest < ActiveSupport::TestCase
       # link to a referenced ticket
       assert_select 'a[href=?][title=?]',
                     'http://mydomain.foo/rdm/issues/1',
-                    "Cannot print recipes (New)",
+                    "Bug: Cannot print recipes (New)",
                     :text => '#1'
       # link to a changeset
       assert_select 'a[href=?][title=?]',