-%
-% my( $agentnum, %opt ) = @_;
-%
-% $opt{'records'} = delete $opt{'agents'}
-% if $opt{'agents'};
-%
-%
<% include( '/elements/select-table.html',
'table' => 'agent',
'name_col' => 'agent',
%opt,
)
%>
+<%init>
+
+my %opt = @_;
+my $agentnum = $opt{'curr_value'} || $opt{'value'};
+
+$opt{'records'} = delete $opt{'agents'}
+ if $opt{'agents'};
+
+</%init>