X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=fs_signup%2Ffs_signup_server;h=d6eb4a8d554bfcbba64741f35b4b658a42840954;hp=4b7e898f6e23ddfb20e6fa1bcdda54124e492f75;hb=db69a9fb0dd93bf13b8b7501ef4829a568d2f6d8;hpb=3b6dc7455da7e713b7400bc543921e7e4b620152 diff --git a/fs_signup/fs_signup_server b/fs_signup/fs_signup_server index 4b7e898f6..d6eb4a8d5 100755 --- a/fs_signup/fs_signup_server +++ b/fs_signup/fs_signup_server @@ -14,6 +14,8 @@ use FS::Conf; use FS::Record qw( qsearch qsearchs ); use FS::cust_main_county; use FS::cust_main; +use FS::cust_bill; +use FS::cust_pkg; use FS::Msgcat qw(gettext); use vars qw( $opt $Debug ); @@ -25,6 +27,11 @@ my $user = shift or die &usage; my $conf = new FS::Conf; +if ($conf->exists('signup_server-quiet')) { + $FS::cust_bill::quiet = 1; + $FS::cust_pkg::quiet = 1; +} + #my @payby = qw(CARD PREPAY); my @payby = $conf->config('signup_server-payby'); my $smtpmachine = $conf->config('smtpmachine'); @@ -94,7 +101,11 @@ while (1) { 'msgcat' => { map { $_=>gettext($_) } qw( passwords_dont_match invalid_card unknown_card_type not_a - ) } + ) }, + + 'statedefault' => $conf->config('statedefault') || 'CA', + + 'countrydefault' => $conf->config('countrydefault') || 'US', }; @@ -132,7 +143,7 @@ while (1) { map { $_ => $signup_data->{$_} } qw( last first ss company address1 address2 city county state zip country - daytime night fax payby payinfo paydate payname referral_custnum + daytime night fax payby payinfo paydate payname referral_custnum comments ), } ); @@ -151,7 +162,7 @@ while (1) { my $part_pkg = qsearchs( 'part_pkg', { 'pkgpart' => $pkgpart } ) or $error ||= "WARNING: unknown pkgpart: $pkgpart"; - my $svcpart = $part_pkg->svcpart unless $error; + my $svcpart = $part_pkg->svcpart('svc_acct') unless $error; my $cust_pkg = new FS::cust_pkg ( { #later#'custnum' => $custnum,