[Rt-commit] rt branch, 4.4/sig-move, created. rt-4.4.0-83-gfa119c6

Rachel Kelly rachel at bestpractical.com
Thu May 5 16:12:55 EDT 2016


The branch, 4.4/sig-move has been created
        at  fa119c66052a226b24bf19859f36b88d5f175851 (commit)

- Log -----------------------------------------------------------------
commit fa119c66052a226b24bf19859f36b88d5f175851
Author: Rachel Kelly <rachel at bestpractical.com>
Date:   Tue May 3 22:30:34 2016 +0000

    Add signature-above-quote option
    
    Fixes: I#31877

diff --git a/etc/RT_Config.pm.in b/etc/RT_Config.pm.in
index 6852ff2..8fc8982 100644
--- a/etc/RT_Config.pm.in
+++ b/etc/RT_Config.pm.in
@@ -2474,6 +2474,16 @@ minutes.  Note that this only effects entry, not display.
 
 Set($DefaultTimeUnitsToHours, 0);
 
+=item C<$SignatureAboveQuote>
+
+By default RT places the signature at the bottom of the quoted text in
+the message box for ticket replies.  Set this to 1 to place the signature
+above the quoted text.
+
+=cut
+
+Set($SignatureAboveQuote, 0);
+
 =item C<$TimeInICal>
 
 By default, events in the iCal feed on the ticket search page
diff --git a/lib/RT/Config.pm b/lib/RT/Config.pm
index 2aad19c..93a981e 100644
--- a/lib/RT/Config.pm
+++ b/lib/RT/Config.pm
@@ -319,6 +319,15 @@ our %META;
         WidgetArguments => {
             Description => 'Enter time in hours by default', #loc
             Hints       => 'Only for entry, not display', #loc
+        },    
+    },
+    SignatureAboveQuote => {
+        Section         => 'Ticket composition', #loc
+        Overridable     => 1,
+        SortOrder       => 10,
+        Widget          => '/Widgets/Form/Boolean',
+        WidgetArguments => {
+            Description => 'Place signature above quote', #loc
         },
     },
     SearchResultsRefreshInterval => {
diff --git a/share/html/Elements/MessageBox b/share/html/Elements/MessageBox
index b61f1e7..df858b1 100644
--- a/share/html/Elements/MessageBox
+++ b/share/html/Elements/MessageBox
@@ -48,7 +48,13 @@
 <textarea autocomplete="off" class="messagebox <% $Type eq 'text/html' ? 'richtext' : '' %>" <% $width_attr %>="<% $Width %>" rows="<% $Height %>" <% $wrap_type |n %> name="<% $Name %>" id="<% $Name %>">\
 % $m->comp('/Articles/Elements/IncludeArticle', %ARGS) if $IncludeArticle;
 % $m->callback( %ARGS, SignatureRef => \$signature, DefaultRef => \$Default, MessageRef => $message );
+% if (RT->Config->Get("SignatureAboveQuote", $session{'CurrentUser'})) {
+<% $Default || '' %><% $signature %><% $message %></textarea>
+% }
+% else {
 <% $Default || '' %><% $message %><% $signature %></textarea>
+% }
+
 % $m->callback( %ARGS, CallbackName => 'AfterTextArea' );
 
 % if (!$SuppressAttachmentWarning) {

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


More information about the rt-commit mailing list