package SGN::View::Mason::Commands;
use strict;
use vars qw($m $c);
HTML::Mason::Component::FileBased->new(
'code' => sub {
use utf8; local $SGN::View::Mason::Commands::m = $HTML::Mason::Commands::m;
HTML::Mason::Exception::Params->throw
    ( error =>
      "Odd number of parameters passed to component expecting name/value pairs"
    ) if @_ % 2;
my ( $result, $selection_prediction_download, $training_pop_analyzed_traits, $training_pop_id, $training_pop_name, $selection_pop_id, $selection_pop_name, $list_of_prediction_pops, $selection_pop_analyzed_traits );
{
    my %pos;
    for ( my $x = 0; $x < @_; $x += 2 )
    {
        $pos{ $_[$x] } = $x + 1;
    }

    foreach my $arg ( qw( selection_prediction_download training_pop_analyzed_traits training_pop_id training_pop_name selection_pop_id ) )
    {
        HTML::Mason::Exception::Params->throw
            ( error => "no value sent for required parameter '$arg'" )
                unless exists $pos{$arg};
    }
#line 10 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
     $result = exists $pos{'result'} ? $_[ $pos{'result'} ] :  '';
#line 11 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
    $selection_prediction_download = $_[ $pos{'selection_prediction_download'} ];
#line 12 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
    $training_pop_analyzed_traits = $_[ $pos{'training_pop_analyzed_traits'} ];
#line 13 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
    $training_pop_id = $_[ $pos{'training_pop_id'} ];
#line 14 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
    $training_pop_name = $_[ $pos{'training_pop_name'} ];
#line 15 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
    $selection_pop_id = $_[ $pos{'selection_pop_id'} ];
#line 16 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
     $selection_pop_name = exists $pos{'selection_pop_name'} ? $_[ $pos{'selection_pop_name'} ] :  '';
#line 17 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
     $list_of_prediction_pops = exists $pos{'list_of_prediction_pops'} ? $_[ $pos{'list_of_prediction_pops'} ] :  '';
#line 18 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
     $selection_pop_analyzed_traits = exists $pos{'selection_pop_analyzed_traits'} ? $_[ $pos{'selection_pop_analyzed_traits'} ] :  '';
}
$m->debug_hook( $m->current_comp->path ) if ( HTML::Mason::Compiler::IN_PERL_DB() );

#line 7 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->print( '
' );
#line 21 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->print( '
' );
#line 22 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"


my $title;

if ($c->req->path =~ /solgs\/traits\/all\/population/) {
    $title = 'Predict GEBVs of a selection population using the models';
  } else {
 $title = 'Predict GEBVs of a selection population using the model';
}

#line 33 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->print( '

' );
#line 35 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->comp(   '/util/import_javascript.mas', classes => ["solGS.solGS", "solGS.Dataset", "jquery.dataTables", "solGS.selectionPopulations",  "solGS.ajaxAutocomplete"]   
); #line 35 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->print( '
' );
#line 36 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->comp(   '/util/import_css.mas', paths => ['/documents/inc/datatables/jquery.dataTables.css']   
); #line 36 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->print( '

' );
#line 38 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->comp( { content => sub {
#line 42 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->print( '

  <div  id="selection_pops_div">
    <div id="search_div" class="form-inline">
    <input  type="text"
	    class="form-control"
	    placeholder="search for a trial"
	    size="30" id="trial_search_box"/>

    <button type="submit"
	    class="btn btn-success"
	    id="search_selection_pop">
      <span class="glyphicon glyphicon-search"></span>
    </button>
    <div  id="form-feedback-search-trials" style="color:red"> </div>
  </div>

  <div id="selection_pops_message"  class="message"></div>
  ' );
#line 60 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->comp(   '/solgs/spinner/spinner.mas'  
); #line 60 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->print( '
  
  <div id="selection_pops_result" style="padding: 20px 0px 20px 0px;display:none;">
    <table class="table" id="selection_pops_table" style="text-align:left;">
      <thead>
	<tr>
	  <th>Selection population</th>
	  <th>Description</th>
	  <th>Year</th>
	  <th>More details</th>
	  <th>View GEBVs</th>
	</tr>
      </thead>
  </table>
  </div>

  ' );
#line 76 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->comp(   '/solgs/search/list_type_selection_population.mas'  
); #line 76 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->print( '
</div>
' );
#line 78 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
} }, '/page/info_section.mas',
    collapsible => 1,
    collapsed   => 0,
    title       => $title,
 );
#line 78 "/home/production/cxgn/sgn/mason/solgs/search/selection_populations.mas"
$m->print( '
' );
;return;
},
'declared_args' => {
  '$list_of_prediction_pops' => { default => ' \'\'' },
  '$result' => { default => ' \'\'' },
  '$selection_pop_analyzed_traits' => { default => ' \'\'' },
  '$selection_pop_id' => { default => undef },
  '$selection_pop_name' => { default => ' \'\'' },
  '$selection_prediction_download' => { default => undef },
  '$training_pop_analyzed_traits' => { default => undef },
  '$training_pop_id' => { default => undef },
  '$training_pop_name' => { default => undef }
},
'load_time' => 1763137176,

)
;