[Rt-commit] rt branch, 4.2/ticket-subject-on-modify, created. rt-4.2.14-8-g6cc09955f

Brian Duggan brian at bestpractical.com
Wed Feb 28 17:03:38 EST 2018


The branch, 4.2/ticket-subject-on-modify has been created
        at  6cc09955f2037a42705477be58979af92a761f15 (commit)

- Log -----------------------------------------------------------------
commit 6cc09955f2037a42705477be58979af92a761f15
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Mon Jul 22 16:15:37 2013 -0400

    Show the Ticket's Subject when modifying the ticket.
    
    This makes it a lot easier to remember what ticket you're on when using
    the Links page, and in general improves the usability of these pages.
    
    Fix up the reminders tests that look at the entire ticket title on the
    Modify page.
    
    Fixes Ticket/Update.html to have formatting consistent with the rest of
    the pages.

diff --git a/share/html/Ticket/Crypt.html b/share/html/Ticket/Crypt.html
index 9a1d1ba20..f23df4517 100644
--- a/share/html/Ticket/Crypt.html
+++ b/share/html/Ticket/Crypt.html
@@ -96,5 +96,5 @@ if ( $Encrypt || $Decrypt ) {
     $encrypted = !$encrypted if $done;
 }
 
-my $title = loc("Encrypt/Decrypt transaction #[_1] of ticket #[_2]", $id, $txn->Ticket);
+my $title = loc("Encrypt/Decrypt transaction #[_1] of ticket #[_2]: [_3]", $id, $txn->Ticket, $txn->TicketObj->Subject);
 </%INIT>
diff --git a/share/html/Ticket/Forward.html b/share/html/Ticket/Forward.html
index 47647a5a1..c75e7631c 100644
--- a/share/html/Ticket/Forward.html
+++ b/share/html/Ticket/Forward.html
@@ -119,8 +119,8 @@ if ( $Forward || $ForwardAndReturn ) {
 }
 
 my $Title = $txn
-    ? loc('Forward transaction #[_1]', $txn->id)
-    : loc('Forward ticket #[_1]', $TicketObj->id);
+    ? loc('Forward transaction #[_1]: [_2]', $txn->id, $TicketObj->Subject)
+    : loc('Forward ticket #[_1]: [_2]', $TicketObj->id, $TicketObj->Subject);
 
 my $from = RT::Interface::Email::GetForwardFrom(
     $txn ? ( Transaction => $txn ) : ( Ticket => $TicketObj ) );
diff --git a/share/html/Ticket/History.html b/share/html/Ticket/History.html
index b52279cec..c6045290f 100644
--- a/share/html/Ticket/History.html
+++ b/share/html/Ticket/History.html
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %#
 %# END BPS TAGGED BLOCK }}}
-<& /Elements/Header, Title => loc("Ticket History # [_1] [_2]", $Ticket->Id, $Ticket->Subject) &>
+<& /Elements/Header, Title => loc("Ticket History #[_1]: [_2]", $Ticket->Id, $Ticket->Subject) &>
 <& /Elements/Tabs &>
 
 % $m->callback( %ARGS, Ticket => $Ticket, CallbackName => 'BeforeActionList' );
diff --git a/share/html/Ticket/Modify.html b/share/html/Ticket/Modify.html
index 986bd13a4..34e684640 100644
--- a/share/html/Ticket/Modify.html
+++ b/share/html/Ticket/Modify.html
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %#
 %# END BPS TAGGED BLOCK }}}
-<& /Elements/Header, Title => loc('Modify ticket #[_1]', $TicketObj->Id) &>
+<& /Elements/Header, Title => loc('Modify ticket #[_1]: [_2]', $TicketObj->Id, $TicketObj->Subject) &>
 <& /Elements/Tabs &>
 
 % $m->callback(CallbackName => 'BeforeActionList', Actions => \@results, ARGSRef => \%ARGS, Ticket => $TicketObj);
diff --git a/share/html/Ticket/ModifyDates.html b/share/html/Ticket/ModifyDates.html
index 6dbdbc1b4..4a79ec1cf 100644
--- a/share/html/Ticket/ModifyDates.html
+++ b/share/html/Ticket/ModifyDates.html
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %#
 %# END BPS TAGGED BLOCK }}}
-<& /Elements/Header, Title => loc('Modify dates for ticket #[_1]', $TicketObj->Id) &>
+<& /Elements/Header, Title => loc('Modify dates for #[_1]: [_2]', $TicketObj->Id, $TicketObj->Subject) &>
 <& /Elements/Tabs &>
 
 % $m->callback(CallbackName => 'BeforeActionList', Actions => \@results, ARGSRef => \%ARGS, Ticket => $TicketObj);
diff --git a/share/html/Ticket/ModifyLinks.html b/share/html/Ticket/ModifyLinks.html
index 58d4a8c42..adab61151 100644
--- a/share/html/Ticket/ModifyLinks.html
+++ b/share/html/Ticket/ModifyLinks.html
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %#
 %# END BPS TAGGED BLOCK }}}
-<& /Elements/Header, Title => loc("Link ticket #[_1]", $Ticket->Id) &>
+<& /Elements/Header, Title => loc("Link ticket #[_1]: [_2]", $Ticket->Id, $Ticket->Subject) &>
 <& /Elements/Tabs &>
 
 % $m->callback(CallbackName => 'BeforeActionList', Actions => \@results, ARGSRef => \%ARGS, Ticket => $Ticket);
diff --git a/share/html/Ticket/ModifyPeople.html b/share/html/Ticket/ModifyPeople.html
index 661e787ff..b82b39ac6 100644
--- a/share/html/Ticket/ModifyPeople.html
+++ b/share/html/Ticket/ModifyPeople.html
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %#
 %# END BPS TAGGED BLOCK }}}
-<& /Elements/Header, Title => loc('Modify people related to ticket #[_1]', $Ticket->id) &>
+<& /Elements/Header, Title => loc('Modify people related to ticket #[_1]: [_2]', $Ticket->id, $Ticket->Subject) &>
 <& /Elements/Tabs &>
 
 % $m->callback(CallbackName => 'BeforeActionList', Actions => \@results, ARGSRef => \%ARGS, Ticket => $Ticket);
diff --git a/share/html/Ticket/Reminders.html b/share/html/Ticket/Reminders.html
index ced722bf4..ee4fce79a 100644
--- a/share/html/Ticket/Reminders.html
+++ b/share/html/Ticket/Reminders.html
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %#
 %# END BPS TAGGED BLOCK }}}
-<& /Elements/Header, Title => loc("Reminders for ticket #[_1]", $Ticket->Id) &>
+<& /Elements/Header, Title => loc("Reminders for ticket #[_1]: [_2]", $Ticket->Id, $Ticket->Subject) &>
 <& /Elements/Tabs &>
     
 % $m->callback(CallbackName => 'BeforeActionList', ARGSRef => \%ARGS, Ticket => $Ticket);
diff --git a/share/html/Ticket/Update.html b/share/html/Ticket/Update.html
index d70552955..061c86753 100644
--- a/share/html/Ticket/Update.html
+++ b/share/html/Ticket/Update.html
@@ -218,7 +218,7 @@ unless($DefaultStatus){
     $DefaultStatus=($ARGS{'Status'} ||$TicketObj->Status());
 }
 
-my $title = loc("Update ticket #[_1] ([_2])", $TicketObj->id, $TicketObj->Subject||'');
+my $title = loc("Update ticket #[_1]: [_2]", $TicketObj->id, $TicketObj->Subject);
 
 # Things needed in the template - we'll do the processing here, just
 # for the convenience:
diff --git a/t/web/reminder-permissions.t b/t/web/reminder-permissions.t
index dd859cd33..6f2049759 100644
--- a/t/web/reminder-permissions.t
+++ b/t/web/reminder-permissions.t
@@ -90,7 +90,7 @@ qr!<input[^/]+name="Complete-Reminder-$root_reminder_id"[^/]+disabled="disabled"
         'complete user_a reminder' );
 
     $m_a->follow_link_ok( { id => 'page-reminders' } );
-    $m_a->title_is( "Reminders for ticket #" . $ticket->id );
+    $m_a->title_is("Reminders for ticket #" . $ticket->id . ": " . $ticket->Subject);
     $m_a->content_contains( 'root reminder',   'can see root reminder' );
     $m_a->content_contains( 'user_a reminder', 'can see user_a reminder' );
     $m_a->content_lacks( 'New reminder:', 'can not create a new reminder' );
@@ -126,7 +126,7 @@ qr!<input[^/]+name="Complete-Reminder-$root_reminder_id"[^/]+disabled="disabled"
         'created user_a from display reminder' );
 
     $m_a->follow_link_ok( { id => 'page-reminders' } );
-    $m_a->title_is( "Reminders for ticket #" . $ticket->id );
+    $m_a->title_is("Reminders for ticket #" . $ticket->id . ": " . $ticket->Subject);
     $m_a->content_contains( 'New reminder:', 'can create a new reminder' );
     $m_a->content_like(
 qr!<input[^/]+name="Complete-Reminder-$root_reminder_id"[^/]+disabled="disabled"!,
diff --git a/t/web/reminders.t b/t/web/reminders.t
index 98a8d6954..e1eb46de6 100644
--- a/t/web/reminders.t
+++ b/t/web/reminders.t
@@ -17,7 +17,7 @@ $m->content_unlike(qr{Check box to complete}, "we don't display this text when t
 $m->content_unlike(qr{<th[^>]*>Reminders?</th>}, "no reminder titlebar");
 
 $m->follow_link_ok({id => 'page-reminders'});
-$m->title_is("Reminders for ticket #" . $ticket->id);
+$m->title_is("Reminders for ticket #" . $ticket->id . ": " . $ticket->Subject);
 $m->text_contains('New reminder:', 'can create a new reminder');
 $m->content_unlike(qr{Check box to complete}, "we don't display this text when there are no reminders");
 $m->content_unlike(qr{<th[^>]*>Reminders?</th>}, "no reminder titlebar");
@@ -63,7 +63,7 @@ $m->content_like(qr{<th[^>]*>Reminders?</th>}, "now we have a reminder titlebar"
 $m->text_contains("baby's first reminder", "display the reminder's subject");
 
 $m->follow_link_ok({id => 'page-reminders'});
-$m->title_is("Reminders for ticket #" . $ticket->id);
+$m->title_is("Reminders for ticket #" . $ticket->id . ": " . $ticket->Subject);
 $m->form_name('UpdateReminders');
 $m->field("Reminder-Subject-$reminder_id" => "changed the subject");
 $m->submit;
@@ -90,7 +90,7 @@ $m->content_unlike(qr{<th[^>]*>Reminders?</th>}, "no reminder titlebar");
 $m->content_unlike(qr{baby's first reminder}, "we don't display resolved reminders");
 
 $m->follow_link_ok({id => 'page-reminders'});
-$m->title_is("Reminders for ticket #" . $ticket->id);
+$m->title_is("Reminders for ticket #" . $ticket->id . ": " . $ticket->Subject);
 $m->text_contains('New reminder:', 'can create a new reminder');
 $m->text_contains('Check box to complete', "we DO display this text when there are reminders");
 $m->content_contains("changed the subject", "display the resolved reminder's subject");

-----------------------------------------------------------------------


More information about the rt-commit mailing list