[Bps-public-commit] rt-extension-formtools branch, master, updated. 2afaf49a4595387540d2db3bf84488b7f6533e2e

Shawn Moore sartak at bestpractical.com
Fri Nov 12 17:20:25 EST 2010


The branch, master has been updated
       via  2afaf49a4595387540d2db3bf84488b7f6533e2e (commit)
      from  0f47eaee94104e8d54cbd272c53c142fb016cdd4 (commit)

Summary of changes:
 html/FormTools/Field |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

- Log -----------------------------------------------------------------
commit 2afaf49a4595387540d2db3bf84488b7f6533e2e
Author: Matt Zagrabelny <mzagrabe at d.umn.edu>
Date:   Fri Nov 12 17:20:40 2010 -0500

    add flag to omit label

diff --git a/html/FormTools/Field b/html/FormTools/Field
index 1ca475d..3bcfd5e 100644
--- a/html/FormTools/Field
+++ b/html/FormTools/Field
@@ -8,6 +8,7 @@ $cols => undef
 $rows => undef
 $empty_allowed => 1
 $show_validation => 0
+$show_label => 1
 </%args>
 <%init>
 use RT::Extension::FormTools;
@@ -76,7 +77,7 @@ unless ( $default ) {
 
 % } else {
 
-% if ($render_as ne 'hidden') { # no label if hidden
+% if ($render_as ne 'hidden' && $show_label) { # no label if hidden
 <table style="display: inline; "><tr><th valign="top"><label><%$field_label%></label></th><td style="display:block;">
 % }
 
@@ -194,7 +195,7 @@ unless ( $default ) {
 %}
 
 % }
-% if ($render_as ne 'hidden') {
+% if ($render_as ne 'hidden' && $show_label) {
 </td></tr></table>
 % }
 % }

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



More information about the Bps-public-commit mailing list