<!DOCTYPE html>

{% load static %}

<html>
    <head>
    {% include "chlamdb/header.html" %}
    <head>
        
        
        <div class="container-fluid" id="main_container">
            <div class="row">
              <div id="wrapper">
                  <div id="page-content-wrapper">
                    <div class="row">
                      <div class="col-lg-12">
                            {% include "chlamdb/menu.html" %}


                            <ul id="tabs" class="nav nav-tabs" data-tabs="tabs">
                                <li class="active"><a href="#tab0" data-toggle="tab">Genomes</a></li>
                                <li><a href="#tab1" data-toggle="tab">Phylogeny</a></li>
                            </ul>


                            <div id="my-tab-content" class="tab-content">
                                <div class="tab-pane active" id="tab0">

                                    <div id="export_bouttons">
                                        <a download="biodb_search.xls" href="#" onclick="return ExcellentExport.excel(this, 'genomes_table', 'search');" style="background-color:#DCFFF0;color:black;padding:2px;border:1px solid black;">Export to Excel</a>

                                        <a download="biodb_search.csv" href="#" onclick="return ExcellentExport.csv(this, 'genomes_table');" style="background-color:#DCFFF0;color:black;padding:2px;border:1px solid black;"">Export to CSV</a>
                                        <br/>
                                    </div>

                                    <table  class="sortable table table-striped" cellspacing="0" border="0" id="genomes_table"> <!-- class="sortable" cellspacing="0" border="0" id="genomes_table" -->
                                        <thead>


                                            <tr>
                                                <th>Accession</th>
                                                <th>GC</th>
                                                <th>N proteins</th>
                                                <th>N contigs</th>
                                                <th>Size</th>
                                                <th>N tRNA</th>
                                                <th>N 16S</th>
                                                <th>N 23S</th>
                                                <th>N 5S</th>
                                                <th>Percent non coding</th>
                                                <th>Organism</th>
                                                <th>Browse Online</th>
                                                <th colspan="5">Download</th>

                                            </tr>
                                        </thead>
                                        <tbody>
                                        {% for values in genomes_data %}

                                            <tr>
                                                <td><a href="http://www.ncbi.nlm.nih.gov/nuccore/{{values.0}}">{{values.0}}</a></td>
                                                <td>{{values.1}}</td>
                                                <td>{{values.2}}</td>
                                                <td>{{values.3}}</td>
                                                <td>{{values.4}}</td>
                                                <td>{{values.5}}</td>
                                                <td>{{values.6}}</td>
                                                <td>{{values.7}}</td>
                                                <td>{{values.8}}</td>
                                                <td>{{values.9}}</td>
                                                <td>{{values.13}}</td>
                                                <td><a href="{% url 'genome_annotation' values.0 %}">{{values.0}}</a></td>

                                                <td style="vertical-align:top" nowrap>
                                                    <a  style="text-decoration:none;" href="/assets/{{biodb}}/gbk/{{values.0}}.gbk">
                                                    <span style="background-color:#DCFFF0;color:black;padding:1px;">GBK</span></a>
                                                </td>

                                                <td nowrap>
                                                    <a  style="text-decoration:none;" href="/assets/{{biodb}}/faa/{{values.0}}.faa">
                                                    <span style="background-color:#DCFFF0;color:black;padding:1px;">FAA</span></a>
                                                </td>

                                                <td nowrap>
                                                    <a  style="text-decoration:none;" href="/assets/{{biodb}}/fna/{{values.0}}.fna">
                                                    <span style="background-color:#DCFFF0;color:black;padding:1px;">FNA</span></a>
                                                </td>

                                                <td nowrap>
                                                    <a  style="text-decoration:none;" href="/assets/{{biodb}}/ffn/{{values.0}}.ffn">
                                                    <span style="background-color:#DCFFF0;color:black;padding:1px;">FFN</span></a>
                                                </td>

                                                <td nowrap>
                                                    <a  style="text-decoration:none;" href="/assets/{{biodb}}/tab/{{values.0}}.tab">
                                                    <span style="background-color:#DCFFF0;color:black;padding:1px;">TAB</span></a>

                                            </tr>

                                        {% endfor %}

                                        </tbody>
                                    </table>


                                </div>
                                <div class="tab-pane" id="tab1">
                                    <object type="image/svg+xml" data="{% static asset_path %}" id="cog_tree" style="width:60%"></object>
                                </div>
                            </div>
                            <!--<img src="{% static 'chlam_tree.png' %}" width="80%"-->
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>


<script>

$('.dropdown-toggle').dropdown()

</script>
{% include "chlamdb/style_menu.html" %}
</body>
</html>

