Skip to content

Commit

Permalink
Enable sorting for ontology-level mappings tabs
Browse files Browse the repository at this point in the history
Resolves #254
  • Loading branch information
jvendetti committed Apr 18, 2023
1 parent 3a72c18 commit 5e1b27d
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion app/assets/javascripts/bp_ontology_viewer.js.erb
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,17 @@ jQuery.bioportal.OntologyPage = function(id, location_path, error_string, page_n

jQuery.bioportal.ont_pages["summary"] = new jQuery.bioportal.OntologyPage("summary", "/ontologies/" + jQuery(document).data().bp.ont_viewer.ontology_id + "?p=summary&ajax=true", "Problem retrieving summary", jQuery(document).data().bp.ont_viewer.ontology_name + " - Summary", "Summary");

jQuery.bioportal.ont_pages["mappings"] = new jQuery.bioportal.OntologyPage("mappings", "/ontologies/" + jQuery(document).data().bp.ont_viewer.ontology_id + "?p=mappings&ajax=true", "Problem retrieving mappings", jQuery(document).data().bp.ont_viewer.ontology_name + " - Mappings", "Mappings", function() {
jQuery.bioportal.ont_pages["mappings"] = new jQuery.bioportal.OntologyPage("mappings",
"/ontologies/" + jQuery(document).data().bp.ont_viewer.ontology_id + "?p=mappings&ajax=true",
"Problem retrieving mappings", jQuery(document).data().bp.ont_viewer.ontology_name + " - Mappings",
"Mappings", function() {
if (! $.fn.DataTable.isDataTable('#ontology_content #mapping_count_table')) {
jQuery('#ontology_content #mapping_count_table').DataTable({
'order': [[1, 'desc'], [0, 'asc']],
'paging': false,
'searching': false
});
}
jQuery(".facebox").facebox();
});

Expand Down

0 comments on commit 5e1b27d

Please sign in to comment.