X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=httemplate%2Fedit%2Fagent_type.cgi;h=5438e5c3bcc47f5b3c973cf218f0939d73bffc8a;hp=f5afd3a96dd44897348fc989de643af36d70fac4;hb=3ce7691203a7737406bf2d4442f7fd84b81f847e;hpb=15e561850b61b10a92a46d8f3e316d53d4970087 diff --git a/httemplate/edit/agent_type.cgi b/httemplate/edit/agent_type.cgi index f5afd3a96..5438e5c3b 100755 --- a/httemplate/edit/agent_type.cgi +++ b/httemplate/edit/agent_type.cgi @@ -1,41 +1,43 @@ -<% - -my($agent_type); -if ( $cgi->param('error') ) { - $agent_type = new FS::agent_type ( { - map { $_, scalar($cgi->param($_)) } fields('agent') - } ); -} elsif ( $cgi->keywords ) { #editing - my( $query ) = $cgi->keywords; - $query =~ /^(\d+)$/; - $agent_type=qsearchs('agent_type',{'typenum'=>$1}); -} else { #adding - $agent_type = new FS::agent_type {}; -} -my $action = $agent_type->typenum ? 'Edit' : 'Add'; - -%><%= include("/elements/header.html","$action Agent Type", menubar( +% +% +%my($agent_type); +%if ( $cgi->param('error') ) { +% $agent_type = new FS::agent_type ( { +% map { $_, scalar($cgi->param($_)) } fields('agent') +% } ); +%} elsif ( $cgi->keywords ) { #editing +% my( $query ) = $cgi->keywords; +% $query =~ /^(\d+)$/; +% $agent_type=qsearchs('agent_type',{'typenum'=>$1}); +%} else { #adding +% $agent_type = new FS::agent_type {}; +%} +%my $action = $agent_type->typenum ? 'Edit' : 'Add'; +% +% +<% include("/elements/header.html","$action Agent Type", menubar( 'Main Menu' => "$p", 'View all agent types' => "${p}browse/agent_type.cgi", )) %> +% if ( $cgi->param('error') ) { -<% if ( $cgi->param('error') ) { %> - Error: <%= $cgi->param('error') %> -<% } %> + Error: <% $cgi->param('error') %> +% } -
- -Agent Type #<%= $agent_type->typenum || "(NEW)" %> + + + +Agent Type #<% $agent_type->typenum || "(NEW)" %>
Agent Type - +

Select which packages agents of this type may sell to customers
-<%= ntable("#cccccc", 2) %> -<%= include('/elements/checkboxes-table.html', +<% ntable("#cccccc", 2) %> +<% include('/elements/checkboxes-table.html', 'source_obj' => $agent_type, 'link_table' => 'type_pkgs', 'target_table' => 'part_pkg', @@ -48,8 +50,8 @@ Select which packages agents of this type may sell to customers

-"> +">
-<%= include('/elements/footer.html') %> +<% include('/elements/footer.html') %>