1 <% include('elements/process.html',
2 'table' => 'prospect_main',
3 'args_callback' => $args_callback,
7 'fields' => [qw( first last title comment )],
9 'redirect' => popurl(3). 'view/prospect_main.html?',
14 my $args_callback = sub {
15 my( $cgi, $object ) = @_;
17 $cgi->param('locationnum') =~ /^(\-?\d*)$/
18 or die 'illegal locationnum '. $cgi->param('locationnum');
21 return ( 'cust_location' => '' ) unless $locationnum;
23 my $cust_location = new FS::cust_location {
24 map { $_ => scalar($cgi->param($_)) }
25 qw( address1 address2 city county state zip country )
28 $cust_location->locationnum($locationnum) unless $locationnum == -1;
30 ( 'cust_location' => $cust_location );