From 1918ae1ef4b40ff88f3331c72ae4440c3bbe7d48 Mon Sep 17 00:00:00 2001 From: ivan Date: Mon, 8 Sep 2008 21:23:02 +0000 Subject: [PATCH] also hide fixed+blank fields on service view, RT#3829 --- httemplate/view/elements/svc_Common.html | 48 +++++++++++++++++--------------- 1 file changed, 26 insertions(+), 22 deletions(-) diff --git a/httemplate/view/elements/svc_Common.html b/httemplate/view/elements/svc_Common.html index b6d8e652f..a0b4e37b2 100644 --- a/httemplate/view/elements/svc_Common.html +++ b/httemplate/view/elements/svc_Common.html @@ -46,37 +46,40 @@ Service #<% $svcnum %>
<% ntable("#cccccc") %><% ntable("#cccccc",2) %> + % foreach my $f ( @$fields ) { % -% my( $field, $type); -% if ( ref($f) ) { -% $field = $f->{'field'}, -% $type = $f->{'type'} || 'text', -% } else { -% $field = $f; -% $type = 'text'; -% } +% my($field, $type); +% if ( ref($f) ) { +% $field = $f->{'field'}, +% $type = $f->{'type'} || 'text', +% } else { +% $field = $f; +% $type = 'text'; +% } % +% my $columndef = $part_svc->part_svc_column($field); +% unless ($columndef->columnflag eq 'F' && !length($columndef->columnvalue)) { + + + <% ( $opt{labels} && exists $opt{labels}->{$field} ) + ? $opt{labels}->{$field} + : $field + %> + - - - <% ( $opt{labels} && exists $opt{labels}->{$field} ) - ? $opt{labels}->{$field} - : $field - %> - -% -% #eventually more options for , etc. fields + <% $svc_x->$field %> - <% $svc_x->$field %> + - +% } +% % } -% foreach (sort { $a cmp $b } $svc_x->virtual_fields) { +% foreach (sort { $a cmp $b } $svc_x->virtual_fields) { <% $svc_x->pvf($_)->widget('HTML', 'view', $svc_x->getfield($_)) %> % } @@ -95,7 +98,6 @@ Service #<% $svcnum %> % } - <% joblisting({'svcnum'=>$svcnum}, 1) %> <% include('/elements/footer.html') %> @@ -134,6 +136,8 @@ my $svc_x = qsearchs({ my $cust_svc = $svc_x->cust_svc; my($label, $value, $svcdb) = $cust_svc->label; +my $part_svc = $cust_svc->part_svc; + my $pkgnum = $cust_svc->pkgnum; my($cust_pkg, $custnum); -- 2.11.0