8 <& /util/import_javascript.mas, classes => [ 'jquery.iframe-post-form','CXGN.BreedersToolbox.AddTrial','CXGN.BreedersToolbox.UploadTrial','CXGN.BreedersToolbox.Trial', 'jstree.dist.jstree', 'CXGN.Trial', 'CXGN.BreedersToolbox.HTMLSelect' ] &>
10 <& /breeders_toolbox/folder/folder_set.mas &>
11 <& /breeders_toolbox/folder/folder_new.mas &>
13 <table class="table table-bordered">
17 <th>Breeding Programs -- -- Trials</th>
23 <h4>Download Trial</h4>
24 <button class="btn btn-primary" id="download_button" disabled="disabled" title="First Select a Trial to Download">Excel</button>
25 <button class="btn btn-primary" id="download_button_csv" disabled="disabled" title="First Select a Trial to Download">CSV</button><br />
27 <h5><i>Double click<br />trial to view</i></h5>
30 <button class="btn btn-sm btn-primary" id="new_folder_dialog_link">Create new folder</button>
31 <button class="btn btn-sm btn-primary" id="open_folder_dialog_link">Add trial to folder</button>
34 <!--<button id="delete" disabled="disabled" >Delete</button -->
38 <div id="trial_list" >[loading...]</div>
47 jQuery(document).ready(function($) {
50 url: '/ajax/breeders/get_trials_with_folders',
51 success: function(response) {
52 var html = '<ul>'+response.html+'</ul>';
54 jQuery('#trial_list').html(html);
56 jQuery('#trial_list').jstree( {
57 "valid_children" : [ "folder", "trial", "breeding_program" ],
59 "breeding_program" : {
60 "icon": 'glyphicon glyphicon-briefcase text-info',
63 "icon": 'glyphicon glyphicon-folder-open text-danger',
66 "icon": 'glyphicon glyphicon-leaf text-success',
69 "plugins" : ["html_data","types"]
74 error: function(response) {
75 alert("An error occurred while loading the trial data.");
81 $('#trial_list').on("changed.jstree", function (e, data) {
83 if ($('#trial_list').jstree('is_leaf', data.node) && data.node.data.jstree.type == 'trial') {
84 $('#download_button').removeAttr('disabled');
85 $('#download_button_csv').removeAttr('disabled');
88 $('#download_button').attr('disabled', 'disabled');
89 $('#download_button_csv').attr('disabled', 'disabled');
96 $('#download_button').on('click', function () {
97 var selected = $('#trial_list').jstree('get_bottom_selected');
98 if (selected.length !== 0) {
99 window.open('/breeders/trials/phenotype/download/'+selected.join(","));
101 else { alert("No leaf nodes selected for download."); }
105 $('#download_button_csv').on('click', function () {
106 var selected = $('#trial_list').jstree('get_bottom_selected');
107 if (selected.length !== 0) {
108 window.open('/breeders/trials/phenotype/download/'+selected.join(",")+'?format=csv');
110 else { alert("No leaf nodes selected for download."); }
114 $("#trial_list").delegate("li", "dblclick", function(){
115 var node = $("#trial_list").jstree("get_node", this);
117 if (node.id.substr(0,1) !== 'j') {
118 if (node.type == 'folder') {
119 window.open('/folder/'+node.id);
120 } else if (node.type == 'trial') {
121 window.open('/breeders_toolbox/trial/'+node.id);
129 <div class="modal fade" id="add_project_dialog" name="add_project_dialog" tabindex="-1" role="dialog" aria-labelledby="addProjectDialog">
130 <div class="modal-dialog modal-lg" role="document">
131 <div class="modal-content">
132 <div class="modal-header">
133 <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
134 <h4 class="modal-title" id="addProjectDialog">Add New Trial</h4>
136 <div class="modal-body">
137 <div class="container-fluid">
138 <form class="form-horizontal" role="form" method="post" enctype="multipart/form-data" encoding="multipart/form-data" id="create_new_trial_form" name="create_new_trial_form">
139 <div class="form-group">
140 <label class="col-sm-3 control-label">Trial Name: </label>
141 <div class="col-sm-9">
142 <input class="form-control" id="new_trial_name" name="new_trial_name" type="text" />
145 <div class="form-group">
146 <label class="col-sm-3 control-label">Year(s): </label>
147 <div class="col-sm-9">
148 <input class="form-control" id="add_project_year" name="add_project_year" type="text" />
151 <div class="form-group">
152 <label class="col-sm-3 control-label">Location: </label>
153 <div class="col-sm-9">
154 <select class="form-control" id="add_project_location" name="add_project_location">
155 <%perl>foreach my $location (@locations) { print "
156 <option value=".'"'.@$location[1].'"'.">".@$location[1]."</option>"; }
161 <div class="form-group">
162 <label class="col-sm-3 control-label">Breeding Program: </label>
163 <div class="col-sm-9">
164 <select class="form-control" id="select_breeding_program" name="select_breeding_program">
165 <%perl>foreach my $program (@$breeding_programs) {
166 print "<option value=".@$program[1].">".@$program[1]."</option>"; }
171 <div class="form-group">
172 <label class="col-sm-3 control-label">Description: </label>
173 <div class="col-sm-9">
174 <textarea class="form-control" id="add_project_description" name="add_project_description" form="create_new_trial_form" ></textarea>
177 <div id="format_type_radio" style="display: none">
178 <div class="form-group">
179 <label class="col-sm-2 control-label">Create Using Trial Design Tool: </label>
180 <div class="col-sm-10">
181 <input type="radio" class="format_type" id="format_radio3" name="radio" value="create_with_design_tool" checked="checked" />
184 <div class="form-group">
185 <label class="col-sm-2 control-label">Create From Uploaded File: </label>
186 <div class="col-sm-10">
187 <input type="radio" class="format_type" id="format_radio2" name="radio" value="create_with_upload" />
190 <div class="form-group">
191 <label class="col-sm-2 control-label">Create Empty Trial: </label>
192 <div class="col-sm-10">
193 <input type="radio" class="format_type" id="format_radio1" name="radio" value="empty" />
197 <div id="get_file_upload_data" style="display: none">
198 <div class="form-group">
199 <label class="col-sm-2 control-label">Upload File: </label>
200 <div class="col-sm-10">
201 <input type="file" name="trial_upload_file" id="trial_upload_file" encoding="multipart/form-data" />
205 <div id="trial_design_info" style="display: none">
207 <div class="form-group">
208 <label class="col-sm-3 control-label">Design Type: </label>
209 <div class="col-sm-9">
210 <select class="form-control" id="select_design_method" name="select_design_method">
211 <option title="generates completely a randomized design with equal or different repetition, using the methods of random number generation in R." value=CRD>Completely Randomized</option>
212 <option title="generates Randomized Complete Block Design, using the methods of random number generation in R." value=RCBD>Complete Block</option>
213 <option title="creates alpha designs starting from the alpha design fixing under the 4 series formulated by Patterson and Williams." value=Alpha>Alpha Lattice</option>
214 <option title="some treatments (checks) are replicate r times and other treatments (new) are replicated once." value=Augmented>Augmented</option>
215 <option title="Adjustments are calculated using data from all checks" value=MAD>Modified Augmented Design </option>
217 <!--<option value=MADIII>MADIII</option>-->
218 <!--<option value=MADIV>MADIV</option>-->
219 <!--<option value=MADV>MADV</option>-->
224 <div id="trial_design_more_info" style="display: none">
225 <div class="form-group form-group-sm" >
226 <label class="col-sm-7 control-label">List of Stocks to Include (Required): <br/><button name="lists_link" class="btn btn-info btn-sm" style="margin:6px 0px 0px 0px" type="button" >Manage Lists</button></label>
227 <div class="col-sm-5" id="select_list" name="select_list">
230 <div class="form-group form-group-sm" id="show_list_of_checks_section" style="display: none" >
231 <label class="col-sm-7 control-label">List of Checks to Include (Required): </label>
232 <div class="col-sm-5" id="list_of_checks_section" >
235 <div id="design_info" name="design_info">
236 <div class="form-group form-group-sm" id="rep_count_section" style="display: none">
237 <label class="col-sm-7 control-label">Number of Replicates (Required): </label>
238 <div class="col-sm-5" >
239 <input class="form-control" id="rep_count" name="rep_count" />
242 <div class="form-group form-group-sm" id="block_number_section" style="display: none">
243 <label class="col-sm-7 control-label">Number of Blocks (Required): </label>
244 <div class="col-sm-5" >
245 <input class="form-control" id="block_number" name="block_number" />
248 <div class="form-group form-group-sm" id="row_number_section" style="display: none">
249 <label class="col-sm-7 control-label">Number of Field Rows (Required): </label>
250 <div class="col-sm-5" >
251 <input class="form-control" id="row_number" name="row_number" />
254 <div class="form-group form-group-sm" id="row_number_per_block_section" style="display: none">
255 <label class="col-sm-7 control-label">Number of Rows Per Block (Optional): </label>
256 <div class="col-sm-5" >
257 <input class="form-control" id="row_number_per_block" name="row_number_per_block" />
260 <div id="other_parameter_section" style="display:none">
262 <div class="form-group">
263 <label class="col-sm-4 control-label">Show Optional Parameters: </label>
264 <div class="col-sm-8" >
265 <input type="checkbox" id="show_other_parameter_options" />
268 <div id="other_parameter_options" style="display:none">
269 <div class="form-group form-group-sm">
270 <label class="col-sm-7 control-label">Column Number Per Block: </label>
271 <div class="col-sm-5" >
272 <input type="text" class="form-control" id="col_number_per_block" name="col_number_per_block" />
275 <div class="form-group form-group-sm">
276 <label class="col-sm-7 control-label">Number of Field Columns: </label>
277 <div class="col-sm-5" >
278 <input type="text" class="form-control" id="col_number" name="col_number" />
283 <div class="form-group form-group-sm" id="block_size_section" style="display: none">
284 <label class="col-sm-7 control-label">Block Size (Required): </label>
285 <div class="col-sm-5" >
286 <input type="text" class="form-control" id="block_size" name="block_size" />
289 <div class="form-group form-group-sm" id="max_block_size_section" style="display: none">
290 <label class="col-sm-7 control-label">Maximum Block Size (Required): </label>
291 <div class="col-sm-5" >
292 <input type="text" class="form-control" id="max_block_size" name="block_size" />
296 <div class="form-group" >
297 <label class="col-sm-4 control-label">Custom Plot Naming/Numbering: </label>
298 <div class="col-sm-8" >
299 <input type="checkbox" id="show_plot_naming_options" />
302 <div id="plot_naming_options" style="display: none">
303 <div class="form-group form-group-sm" >
304 <label class="col-sm-7 control-label">Plot Prefix: </label>
305 <div class="col-sm-5" >
306 <input type="text" class="form-control" id="plot_prefix" name="plot_prefix" />
309 <div class="form-group form-group-sm" >
310 <label class="col-sm-7 control-label">Plot Start Number: </label>
311 <div class="col-sm-5" >
312 <input type="text" class="form-control" id="start_number" name="start_number" />
315 <div class="form-group form-group-sm" >
316 <label class="col-sm-7 control-label">Plot Number Increment: </label>
317 <div class="col-sm-5" >
318 <input type="text" class="form-control" id="increment" name="increment" />
327 <div class="modal-footer">
328 <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
329 <button type="button" class="btn btn-primary" name="new_trial_submit" id="new_trial_submit">Add Trial</button>
336 <div id="add_project_dialog" class="ui-widget">
337 <form method="post" enctype="multipart/form-data" encoding="multipart/form-data" id="create_new_trial_form" name="create_new_trial_form">
338 <label for="new_trial_name" style="display: inline-block; width: 100px;">Trial name:</label>
339 <input id="new_trial_name" name="new_trial_name" />
341 <label for="add_project_year" style="display: inline-block; width: 100px;">Year(s):</label>
342 <input id="add_project_year" name="add_project_year" />
344 <label for="add_project_location" style="display: inline-block; width: 100px;">Location:</label>
345 <select id="add_project_location" name="add_project_location">
346 <%perl>foreach my $location (@locations) { print "
347 <option value=".'"'.@$location[1].'"'.">".@$location[1]."</option>"; }
351 <label for="select_breeding_program" style="display: inline-block; width: 100px;">Breeding Program:</label>
352 <select id="select_breeding_program" name="select_breeding_program">
354 foreach my $program (@$breeding_programs) {
355 print "<option value=".@$program[1].">".@$program[1]."</option>";
361 <label for="add_project_description" style="display: inline-block; vertical-align:top; width: 100px;">Description:</label>
362 <textarea id="add_project_description" name="add_project_description" form="create_new_trial_form" cols="40"></textarea>
363 <div id="format_type_radio" style="display: none">
364 <input type="radio" id="format_radio3" name="radio" class="format_type" value="create_with_design_tool" checked="checked" />
365 <label for="radio3">Create using trial design tool</label>
367 <input type="radio" id="format_radio2" name="radio" class="format_type" value="create_with_upload" style="display: none"/>
368 <label for="radio2" style="display: none">Create from uploaded file</label>
370 <input type="radio" id="format_radio1" name="radio" class="format_type" value="empty" style="display: none"/>
371 <label for="radio1" style="display: none">Create empty trial</label>
374 <div id="get_file_upload_data" style="display: none">
376 <label for="trial_upload_file" style="display: inline-block; width: 100px;">Upload file:</label>
377 <input type="file" name="trial_upload_file" id="trial_upload_file" encoding="multipart/form-data" />
381 <div id="trial_design_info" style="display: none">
383 <label for="select_design_method" style="display: inline-block; width: 300px;">Design type:</label>
384 <select id="select_design_method" name="select_design_method">
385 <option value=CRD>Completely Randomized</option>
386 <option value=RCBD>Complete Block</option>
387 <option value=Alpha>Alpha Lattice</option>
388 <option value=Augmented>Augmented</option>
389 <option value=MAD>Modified Augmented Design </option>
391 <option value=MADIII>MADIII</option>
392 <option value=MADIV>MADIV</option>
393 <option value=MADV>MADV</option>
403 <div id="trial_design_more_info" style="display: none">
405 <div id="select_list" name="select_list">
406 <label id="select_list_label" for="select_list_list_select" style="display: inline-block; width: 300px;">List of stocks to include:<br>
411 <div id="list_of_checks_section" style="display: none">
412 <label id="select_list_of_checks_label" for="select_list_of_checks_list_select" style="display: inline-block; width: 300px;">List of checks:<br>
418 <div id="design_info" name="design_info">
419 <div id="rep_count_section" style="display: none">
420 <label for="rep_count" style="display: inline-block; width: 300px;">Number of replicates:<br>
423 <input id="rep_count" name="rep_count" />
427 <div id="block_number_section" style="display: none">
428 <label for="block_number" style="display: inline-block; width: 300px;">Number of blocks:<br>
431 <input id="block_number" name="block_number" />
435 <div id="row_number_section" style="display: none">
436 <label for="row_number" style="display: inline-block; width: 300px;">Number of field rows:<br>
439 <input id="row_number" name="row_number" />
443 <div id="row_number_per_block_section" style="display: none">
444 <label for="row_number_per_block" style="display: inline-block; width: 300px;">Row Number Per Block:<br>
447 <input id="row_number_per_block" name="row_number_per_block" />
451 <div id="other_parameter_section" style="display:none">
452 <label for="show_other_parameter_options">Other optional parameters</label>
453 <input type="checkbox" id="show_other_parameter_options">
454 <div id="other_parameter_options" style="display:none">
456 <label for="col_number_per_block" style="display: inline-block; width: 300px;">Col Number Per Block:</label>
457 <input id="col_number_per_block" name="col_number_per_block" />
459 <label for="col_number" style="display: inline-block; width: 300px;">Number of field columns:</label>
460 <input id="col_number" name="col_number" />
465 <div id="block_size_section" style="display: none">
466 <label for="block_size" style="display: inline-block; width: 300px;">Block size:<br>
469 <input id="block_size" name="block_size" />
473 <div id="max_block_size_section" style="display: none">
474 <label for="max_block_size" style="display: inline-block; width: 300px;">Maximum block size:<br>
477 <input id="max_block_size" name="block_size" />
483 <label for="show_plot_naming_options">Custom plot naming/numbering</label>
484 <input type="checkbox" id="show_plot_naming_options">
486 <div id="plot_naming_options" style="display: none">
488 <label for="plot_prefix" style="display: inline-block; width: 300px;">Plot name prefix:</label>
489 <input id="plot_prefix" name="plot_prefix" />
491 <label for="start_number" style="display: inline-block; width: 300px;">Plot start number:</label>
492 <input id="start_number" name="start_number" />
494 <label for="increment" style="display: inline-block; width: 300px;">Plot number increment:</label>
495 <input id="increment" name="increment" />
506 <div class="modal fade" id="upload_trial_error_display" name="upload_trial_error_display" tabindex="-1" role="dialog" aria-labelledby="uploadTrialErrorDialog">
507 <div class="modal-dialog modal-lg" role="document">
508 <div class="modal-content">
509 <div class="modal-header">
510 <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
511 <h4 class="modal-title" id="uploadTrialErrorDialog">Errors In Uploaded File</h4>
513 <div class="modal-body">
514 <div class="container-fluid">
520 <div class="modal-footer">
521 <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
528 <div id="upload_trial_error_display" class="ui-widget">
535 <div class="modal fade" id="trial_design_confirm" name="trial_design_confirm" tabindex="-1" role="dialog" aria-labelledby="addTrialConfirmDialog">
536 <div class="modal-dialog modal-lg" role="document">
537 <div class="modal-content">
538 <div class="modal-header">
539 <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
540 <h4 class="modal-title" id="addTrialConfirmDialog">Confirm Trial Design</h4>
542 <div class="modal-body">
543 <div class="container-fluid">
544 <p><span class="ui-icon ui-icon-check"></span>Trial Is Valid<br>The following trial will be added</p>
545 <button class="btn btn-info btn-sm" id="view_trial_layout_button" >View Trial Layout</button>
547 <div id="trial_design_information">
551 <div class="modal-footer">
552 <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
553 <button type="button" class="btn btn-primary" name="new_trial_confirm_submit" id="new_trial_confirm_submit">Confirm</button>
560 <div id="trial_design_confirm" title="Confirm trial design">
561 <p><span class="ui-icon ui-icon-check"></span>Trial is valid<br>The following trial will be added</p>
562 <button id="view_trial_layout_button" class="ui-widget">View trial layout</button>
564 <div id="trial_design_information" class="ui-widget"></div>
568 <div class="modal fade" id="trial_design_view_layout" name="trial_design_view_layout" tabindex="-1" role="dialog" aria-labelledby="addTrialDesignViewDialog">
569 <div class="modal-dialog modal-lg" role="document">
570 <div class="modal-content">
571 <div class="modal-header">
572 <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
573 <h4 class="modal-title" id="addTrialDesignViewDialog">Trial Design Layout</h4>
575 <div class="modal-body">
576 <div class="container-fluid">
577 <p><span class="ui-icon ui-icon-info"></span>Trial Layout</p>
578 <div id="trial_design_view_layout_return">
582 <div class="modal-footer">
583 <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
590 <div id="trial_design_view_layout" title="Trial design layout">
591 <p><span class="ui-icon ui-icon-info"></span>Trial layout</p>
596 <div id="trial_saving_dialog" title="Saving">
599 <span style="float: center;"><img src="/img/wheel.gif"/></span>
605 #progressbar .ui-progressbar-value {
606 background-color: #ccc;
610 <div class="modal fade" id="trial_saved_dialog_message" name="trial_saved_dialog_message" tabindex="-1" role="dialog" aria-labelledby="addTrialSavedDialog">
611 <div class="modal-dialog modal-lg" role="document">
612 <div class="modal-content">
613 <div class="modal-header">
614 <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
615 <h4 class="modal-title" id="addTrialSavedDialog">Trial Saved</h4>
617 <div class="modal-body">
618 <div class="container-fluid">
620 <span class="ui-icon ui-icon-circle-check" style="float: left; margin: 0 7px 50px 0;"></span>
621 The trial was saved successfully
625 <div class="modal-footer">
626 <button id="trial_saved_dialog_message_ok_button" type="button" class="btn btn-default" data-dismiss="modal">Close</button>
633 <div id="trial_saved_dialog_message" title="Trial saved">
635 <span class="ui-icon ui-icon-circle-check" style="float: left; margin: 0 7px 50px 0;"></span>
636 The trial was saved successfully
641 <div class="modal fade" id="upload_trial_dialog" name="upload_trial_dialog" tabindex="-1" role="dialog" aria-labelledby="uploadTrialDialog">
642 <div class="modal-dialog " role="document">
643 <div class="modal-content">
644 <div class="modal-header">
645 <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
646 <h4 class="modal-title" id="uploadTrialDialog">Upload Trial</h4>
648 <div class="modal-body">
649 <div class="container-fluid">
650 <&| /page/explanation.mas, title=>'Template information' &>
652 <b>File format information</b>
654 <a id="trial_upload_spreadsheet_format_info">Spreadsheet format</a>
658 <form class="form-horizontal" role="form" method="post" enctype="multipart/form-data" encoding="multipart/form-data" id="upload_trial_form" name="upload_trial_form">
659 <div class="form-group">
660 <label class="col-sm-3 control-label">Breeding Program: </label>
661 <div class="col-sm-9">
662 <select class="form-control" id="trial_upload_breeding_program" name="trial_upload_breeding_program">
664 foreach my $program (@$breeding_programs) {
665 print "<option value=".@$program[1].">".@$program[1]."</option>";
671 <div class="form-group form-group-sm">
672 <label class="col-sm-3 control-label">Location: </label>
673 <div class="col-sm-9" >
674 <select class="form-control" id="trial_upload_location" name="trial_upload_location">
675 <%perl>foreach my $location (@locations) { print "
676 <option value=".'"'.@$location[1].'"'.">".@$location[1]."</option>"; }
681 <div class="form-group form-group-sm">
682 <label class="col-sm-3 control-label">Trial Name: </label>
683 <div class="col-sm-9" >
684 <input type="text" class="form-control" id="trial_upload_name" name="trial_upload_name" />
687 <div class="form-group form-group-sm">
688 <label class="col-sm-3 control-label">Year(s): </label>
689 <div class="col-sm-9" >
690 <input type="text" class="form-control" id="trial_upload_year" name="trial_upload_year" />
693 <div class="form-group form-group-sm">
694 <label class="col-sm-3 control-label">Description: </label>
695 <div class="col-sm-9" >
696 <textarea class="form-control" id="trial_upload_description" name="trial_upload_description" form="upload_trial_form" ></textarea>
699 <div class="form-group form-group-sm">
700 <label class="col-sm-3 control-label">Design Type: </label>
701 <div class="col-sm-9" >
702 <select class="form-control" id="trial_upload_design_method" name="trial_upload_design_method">
703 <option value=CRD>Completely Randomized</option>
704 <option value=RCBD>Complete Block</option>
705 <option value=Alpha>Alpha Lattice</option>
706 <option value=Augmented>Augmented</option>
707 <option value=MAD>Modified Augmented Design</option>
709 <!-- <option value=MADIII>MADIII</option> -->
710 <!-- <option value=MADIV>MADIV</option> -->
711 <!-- <option value=MADV>MADV</option> -->
715 <div class="form-group form-group-sm">
716 <label class="col-sm-3 control-label">Upload File: </label>
717 <div class="col-sm-9" >
718 <input type="file" name="trial_uploaded_file" id="trial_uploaded_file" encoding="multipart/form-data" />
724 <div class="modal-footer">
725 <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
726 <button type="button" class="btn btn-primary" name="upload_trial_submit" id="upload_trial_submit">Upload Trial</button>
733 <div id="upload_trial_dialog" title="Upload trial">
735 <&| /page/explanation.mas, title=>'Template information' &>
737 <b>File format information</b>
739 <a id="trial_upload_spreadsheet_format_info">Spreadsheet format</a>
743 <form method="post" enctype="multipart/form-data" encoding="multipart/form-data" id="upload_trial_form" name="upload_trial_form">
745 <label for="trial_upload_breeding_program" style="display: inline-block; width: 100px;">Breeding Program:</label>
746 <select id="trial_upload_breeding_program" name="trial_upload_breeding_program">
748 foreach my $program (@$breeding_programs) {
749 print "<option value=".@$program[1].">".@$program[1]."</option>";
755 <label for="trial_upload_location" style="display: inline-block; width: 100px;">Location:</label>
756 <select id="trial_upload_location" name="trial_upload_location">
757 <%perl>foreach my $location (@locations) { print "
758 <option value=".'"'.@$location[1].'"'.">".@$location[1]."</option>"; }
763 <label for="trial_upload_name" style="display: inline-block; width: 100px;">Trial name:</label>
764 <input id="trial_upload_name" name="trial_upload_name" />
767 <label for="trial_upload_year" style="display: inline-block; width: 100px;">Year(s):</label>
768 <input id="trial_upload_year" name="trial_upload_year" />
771 <label for="trial_upload_description" style="display: inline-block; vertical-align:top; width: 100px;">Description:</label>
772 <textarea id="trial_upload_description" name="trial_upload_description" form="upload_trial_form" cols="40"></textarea>
775 <label for="trial_upload_design_method" style="display: inline-block; width: 100px;">Design type:</label>
776 <select id="trial_upload_design_method" name="trial_upload_design_method">
777 <option value=CRD>Completely Randomized</option>
778 <option value=RCBD>Complete Block</option>
779 <option value=Alpha>Alpha Lattice</option>
780 <option value=Augmented>Augmented</option>
781 <option value=MAD>Modified Augmented Design</option>
784 <option value=MADIII>MADIII</option>
785 <option value=MADIV>MADIV</option>
786 <option value=MADV>MADV</option>
791 <label for="trial_uploaded_file" style="display: inline-block; width: 100px;">Upload file:</label>
792 <input type="file" name="trial_uploaded_file" id="trial_uploaded_file" encoding="multipart/form-data" />
799 <div class="modal fade" id="trial_upload_spreadsheet_info_dialog" name="trial_upload_spreadsheet_info_dialog" tabindex="-1" role="dialog" aria-labelledby="uploadTrialInfoDialog">
800 <div class="modal-dialog modal-lg" role="document">
801 <div class="modal-content">
802 <div class="modal-header">
803 <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
804 <h4 class="modal-title" id="uploadTrialInfoDialog">Upload Template Information</h4>
806 <div class="modal-body">
807 <div class="container-fluid">
808 <&| /breeders_toolbox/trial/trial_spreadsheet_upload_format_info.mas &>
812 <div class="modal-footer">
813 <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
820 <div id="trial_upload_spreadsheet_info_dialog" title="Format for uploading trials in a spreadsheet">
821 <&| /breeders_toolbox/trial/trial_spreadsheet_upload_format_info.mas &>
826 <div class="modal fade" id="trial_upload_success_dialog_message" name="trial_upload_success_dialog_message" tabindex="-1" role="dialog" aria-labelledby="uploadTrialSuccessDialog">
827 <div class="modal-dialog modal-lg" role="document">
828 <div class="modal-content">
829 <div class="modal-header">
830 <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
831 <h4 class="modal-title" id="uploadTrialSuccessDialog">Upload Successful</h4>
833 <div class="modal-body">
834 <div class="container-fluid">
836 <span class="ui-icon ui-icon-circle-check" style="float: left; margin: 0 7px 50px 0;"></span>
837 The trial file was uploaded successfully
841 <div class="modal-footer">
842 <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
848 <div id="trial_upload_success_dialog_message" title="Trial file uploaded">
850 <span class="ui-icon ui-icon-circle-check" style="float: left; margin: 0 7px 50px 0;"></span>
851 The trial file was uploaded successfully