about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--uploader/templates/phenotypes/view-phenotype.html52
1 files changed, 22 insertions, 30 deletions
diff --git a/uploader/templates/phenotypes/view-phenotype.html b/uploader/templates/phenotypes/view-phenotype.html
index 18ac202..b42f680 100644
--- a/uploader/templates/phenotypes/view-phenotype.html
+++ b/uploader/templates/phenotypes/view-phenotype.html
@@ -16,7 +16,7 @@
            species_id=species.SpeciesId,
            population_id=population.Id,
            dataset_id=dataset.Id,
-           xref_id=xref_id)}}">View Datasets</a>
+           xref_id=xref_id)}}">View Phenotype</a>
 </li>
 {%endblock%}
 
@@ -62,36 +62,28 @@
 {%if "group:resource:edit-resource" in privileges
 or "group:resource:delete-resource" in privileges%}
 <div class="row">
-  <form action="#edit-delete-phenotype"
-        method="POST"
-        id="frm-delete-phenotype">
-
-    <input type="hidden" name="species_id" value="{{species.SpeciesId}}" />
-    <input type="hidden" name="population_id" value="{{population.Id}}" />
-    <input type="hidden" name="dataset_id" value="{{dataset.Id}}" />
-    <input type="hidden" name="phenotype_id" value="{{phenotype.Id}}" />
-
-    <div class="btn-group btn-group-justified">
-      <div class="btn-group">
-        {%if "group:resource:edit-resource" in privileges%}
-        <input type="submit"
-               title="Edit the values for the phenotype. This is meant to be used when you need to update only a few values."
-               class="btn btn-primary not-implemented"
-               value="edit" />
-        {%endif%}
-      </div>
-      <div class="btn-group"></div>
-      <div class="btn-group">
-        {%if "group:resource:delete-resource" in privileges%}
-        <input type="submit"
-               title="Delete the entire phenotype. This is useful when you need to change data for most or all of the fields for this phenotype."
-               class="btn btn-danger not-implemented"
-               disabled="disabled"
-               value="delete" />
-        {%endif%}
-      </div>
+  <div class="btn-group btn-group-justified">
+    <div class="btn-group">
+      {%if "group:resource:edit-resource" in privileges%}
+      <a href="{{url_for('species.populations.phenotypes.edit_phenotype_data',
+               species_id=species.SpeciesId,
+               population_id=population.Id,
+               dataset_id=dataset.Id,
+               xref_id=xref_id)}}"
+         title="Edit the values for the phenotype. This is meant to be used when you need to update only a few values."
+         class="btn btn-primary">Edit</a>
+      {%endif%}
     </div>
-  </form>
+    <div class="btn-group"></div>
+    <div class="btn-group">
+      {%if "group:resource:delete-resource" in privileges%}
+      <a href="#"
+         title="Delete the entire phenotype. This is useful when you need to change data for most or all of the fields for this phenotype."
+         class="btn btn-danger not-implemented"
+         disabled="disabled">delete</a>
+      {%endif%}
+    </div>
+  </div>
 </div>
 {%endif%}