autogenerated name metadata table
[sgn.git] / mason / homepage / phenotype_uploads.mas
blobf9cde891a36e6614b89f16403855a3d8be9f2b25
1 <%args>
2 $phenotype_files => undef
3 </%args>
5 <div class="container-fluid">
6     <div class="row">
7         <div class="col-sm-12">
8             <div class="panel panel-default">
9                 <div class="panel-heading">Phenotype Files Uploaded</div>
10                     <div class="panel-body">
11                         <table class="table table-bordered" id="homepage_phenotype_uploads" alt="">
12                             <thead>
13                                 <tr><th>Filename</th><th>Date Uploaded</th><th>Uploaded By</th><th>File Type</th><th>Options</th><th>Trial</th></tr>
14                             </thead>
15                             <tbody>
16 % foreach my $f (@$phenotype_files) {
17                                 <tr>
18                                     <td><% $f->{metadata}->[4] %></td>
19                                     <td><% $f->{metadata}->[1] %></td>
20                                     <td><a href="/solpeople/profile/<% $f->{metadata}->[2] %>"><% $f->{metadata}->[3] %></a></td>
21                                     <td><% $f->{metadata}->[6] %></td>
22                                     <td><a href="/breeders/phenotyping/view/<% $f->{metadata}->[0] %>">View</a> | <a href="/breeders/phenotyping/download/<% $f->{metadata}->[0] %>">Download</a></td>
23                                     <td>
24 % foreach my $p (keys %{$f->{project_ids}}) {
25                                         <a href='/breeders/trial/<% $p %>'><% $f->{project_ids}->{$p} %></a>&nbsp;&nbsp;
26 % }
27                                     </td>
28                                 </tr>
29 % }
30                             </tbody>
31                         </table>
32                     </div>
33                 </div>
34             </div>
35         </div>
36     </div>
37 </div>
39 <script>
40 jQuery(document).ready(function() {
41     jQuery('#homepage_phenotype_uploads').DataTable({
42         "ordering": false,
43     });
44 });
45 </script>