[Bps-public-commit] rt-extension-commentoncreate branch, master, updated. 0.01-2-gce8de39

Kevin Falcone falcone at bestpractical.com
Wed Mar 3 17:45:35 EST 2010


The branch, master has been updated
       via  ce8de3964ddbef72dfee13337670e2ca34d19262 (commit)
       via  9100624c2b80439a43d81a7f0cd489c59b1a4ed8 (commit)
      from  acee66823aaf03c0774f937b1a45012a209fec47 (commit)

Summary of changes:
 .../Ticket/Create.html/AfterMessageBox             |   16 ++++++++++++++--
 lib/RT/Extension/CommentOnCreate.pm                |   10 ++++++++++
 2 files changed, 24 insertions(+), 2 deletions(-)

- Log -----------------------------------------------------------------
commit 9100624c2b80439a43d81a7f0cd489c59b1a4ed8
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Tue Mar 2 18:42:59 2010 -0500

    Revised contributed patch to add Height and Width config options

diff --git a/html/Callbacks/RT-Extension-CommentOnCreate/Ticket/Create.html/AfterMessageBox b/html/Callbacks/RT-Extension-CommentOnCreate/Ticket/Create.html/AfterMessageBox
index 7337875..8ac1df5 100644
--- a/html/Callbacks/RT-Extension-CommentOnCreate/Ticket/Create.html/AfterMessageBox
+++ b/html/Callbacks/RT-Extension-CommentOnCreate/Ticket/Create.html/AfterMessageBox
@@ -49,10 +49,22 @@
 <tr><td colspan="6">Include an optional Comment below</td></tr>
 <tr><td colspan="6">
 % if (exists $ARGS{CommentContent}) {
-<& /Elements/MessageBox, Name => 'CommentContent', Default => $ARGS{CommentContent}, IncludeSignature => 0 &>
+<& /Elements/MessageBox, Name => 'CommentContent',
+                         Default => $ARGS{CommentContent},
+                         IncludeSignature => 0,
+                         ($width ? (Width => $width) : ()),
+                         ($height ? (Height => $height) : ())
+&>
 % } else {
-<& /Elements/MessageBox, Name => 'CommentContent', &>
+<& /Elements/MessageBox, Name => 'CommentContent',
+                         ($width ? (Width => $width) : ()),
+                         ($height ? (Height => $height) : ())
+&>
 % }
 <%ARGS>
 $QueueObj => undef
 </%ARGS>
+<%INIT>
+my $width = RT->Config->Get('CommentOnCreateWidth');
+my $height = RT->Config->Get('CommentOnCreateHeight');
+</%INIT>
diff --git a/lib/RT/Extension/CommentOnCreate.pm b/lib/RT/Extension/CommentOnCreate.pm
index ec894f1..1b7c0db 100644
--- a/lib/RT/Extension/CommentOnCreate.pm
+++ b/lib/RT/Extension/CommentOnCreate.pm
@@ -27,6 +27,13 @@ RT::Extension::CommentOnCreate - Adds an optional Comment box to Ticket Creation
          rm -rf /opt/rt3/var/mason_data/obj
     7. Restart your webserver
 
+=head1 CONFIGURATION
+
+Optional configuration options to control the width and height of the Comment textbox
+
+    Set($CommentOnCreateWidth, 80);
+    Set($CommentOnCreateHeight, 190);
+
 =head1 BUGS AND LIMITATIONS
 
 No bugs have been reported.

commit ce8de3964ddbef72dfee13337670e2ca34d19262
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Wed Mar 3 17:44:37 2010 -0500

    Note that these only work for !richtext

diff --git a/lib/RT/Extension/CommentOnCreate.pm b/lib/RT/Extension/CommentOnCreate.pm
index 1b7c0db..8ba6283 100644
--- a/lib/RT/Extension/CommentOnCreate.pm
+++ b/lib/RT/Extension/CommentOnCreate.pm
@@ -34,6 +34,9 @@ Optional configuration options to control the width and height of the Comment te
     Set($CommentOnCreateWidth, 80);
     Set($CommentOnCreateHeight, 190);
 
+These only apply if you have MessageBoxRichText enabled, otherwise it will inherit the global 
+MessageBoxRichTextHeight attribute.
+
 =head1 BUGS AND LIMITATIONS
 
 No bugs have been reported.

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



More information about the Bps-public-commit mailing list