<select name="<% $col_from->name | h %>" class="<% $class %>">
% unless ( $fk->from_is_dependent ) {
 <option value=""></option>
% }
% foreach my $item (@list) {
 <option value="<% $item->select( $col_to->name ) %>" <% defined $current && $item->select( $col_to->name ) == $current ? 'selected="selected"' : '' %>><% $item->select( $display_col->name ) | h %></option>
% }
</select>
<%args>
$row   => undef
@list  => ()
$fk
$class => $m->base_comp->attr_if_exists('fk_to_one_select_class_default')
$display_col => undef
</%args>
<%init>
# I'm a wuss.  Don't know how to handle this.
my @col_from = $fk->columns_from;
return if @col_from > 1;

my $col_from = shift @col_from;
my $col_to   = $fk->columns_to;

@list = $col_to->table->all_rows->all_rows unless @list;

my $current;
$current = $row->select( $col_from->name ) if $row;

$display_col = $col_to unless defined $display_col;
</%init>