summaryrefslogtreecommitdiff
path: root/httemplate/view/elements
diff options
context:
space:
mode:
authorIvan Kohler <ivan@freeside.biz>2013-03-10 22:28:34 -0700
committerIvan Kohler <ivan@freeside.biz>2013-03-10 22:28:34 -0700
commit57c5cf47f41739b57c563ddac09d0bd49d6d67b4 (patch)
tree187f1fdd593bbaeea03dfb2bd473a4dfe502f775 /httemplate/view/elements
parentf37b4c3e04f6dfc56ba967e270b5b49edafe81f6 (diff)
hide svc_phone.sip_password like svc_acct._password unless showpasswords config is on, RT#20862
Diffstat (limited to 'httemplate/view/elements')
-rw-r--r--httemplate/view/elements/svc_Common.html12
1 files changed, 8 insertions, 4 deletions
diff --git a/httemplate/view/elements/svc_Common.html b/httemplate/view/elements/svc_Common.html
index 46b9c28fa..a7f8f6df4 100644
--- a/httemplate/view/elements/svc_Common.html
+++ b/httemplate/view/elements/svc_Common.html
@@ -59,16 +59,20 @@ function areyousure(href) {
% foreach my $f ( @$fields ) {
%
-% my($field, $type, $value, $hack_strict_refs);
+% my($field, $type, $value);
% if ( ref($f) ) {
% $field = $f->{'field'};
-% $hack_strict_refs = \&{ $f->{'value'} } if $f->{'value'};
-% $value = $f->{'value'} ? &$hack_strict_refs($svc_x) : $svc_x->$field;
% $type = $f->{'type'} || 'text';
+% if ( $f->{'value_callback'} ) {
+% my $hack_strict_refs = \&{ $f->{'value_callback'} };
+% $value = &$hack_strict_refs($svc_x);
+% } else {
+% $value = exists($f->{'value'}) ? $f->{'value'} : $svc_x->$field;
+% }
% } else {
% $field = $f;
-% $value = $svc_x->$field;
% $type = 'text';
+% $value = $svc_x->$field;
% }
%
% my $columndef = $part_svc->part_svc_column($field);