X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=httemplate%2Fedit%2Fsvc_acct.cgi;h=f1b8b800b3d6120be05abf387e898f9898f6d442;hp=d4c9a738dc4043053c0f54fcb0d16256b700a9ba;hb=a5c64e8089d4e6c76ee070102e3a67baf1485181;hpb=f4ea75e514763082b64e1b3654cfbbba2ddf1c01 diff --git a/httemplate/edit/svc_acct.cgi b/httemplate/edit/svc_acct.cgi index d4c9a738d..f1b8b800b 100755 --- a/httemplate/edit/svc_acct.cgi +++ b/httemplate/edit/svc_acct.cgi @@ -35,8 +35,6 @@ if ( $cgi->param('error') ) { } else { #adding - $svc_acct = new FS::svc_acct({}); - foreach $_ (split(/-/,$query)) { $pkgnum=$1 if /^pkgnum(\d+)$/; $svcpart=$1 if /^svcpart(\d+)$/; @@ -44,6 +42,8 @@ if ( $cgi->param('error') ) { $part_svc = qsearchs( 'part_svc', { 'svcpart' => $svcpart } ); die "No part_svc entry for svcpart $svcpart!" unless $part_svc; + $svc_acct = new FS::svc_acct({svcpart => $svcpart}); + $svcnum=''; #set gecos @@ -244,7 +244,16 @@ my($quota,$slipip)=( $svc_acct->slipip, ); -print qq!!; +if ( $part_svc->part_svc_column('quota')->columnflag eq "F" ) +{ + print qq!!; +} else { + print <Quota: + + +END +} if ( $part_svc->part_svc_column('slipip')->columnflag eq "F" ) { print qq!!; @@ -272,6 +281,14 @@ if ( $part_svc->part_svc_column('usergroup')->columnflag eq "F" ) { } print ''; +foreach my $field ($svc_acct->virtual_fields) { + if ( $part_svc->part_svc_column($field)->columnflag ne 'F' ) { + # If the flag is X, it won't even show up in $svc_acct->virtual_fields. + print $svc_acct->pvf($field)->widget('HTML', 'edit', + $svc_acct->getfield($field)); + } +} + #submit print qq!
!;