diff --git a/ippisite/ippidb/templates/base.html b/ippisite/ippidb/templates/base.html index 9b018e450a6b7070d7f3b7484d10cb9c47791181..d6e1f74a9caa84fd533332673dd846ade330abc7 100644 --- a/ippisite/ippidb/templates/base.html +++ b/ippisite/ippidb/templates/base.html @@ -113,7 +113,7 @@ backgroundColor: "rgba(211,211,211, 0.5)", data: otherFamiliesData }, - { label: '{{ compound.best_activity_ppi_name}} family', + { label: compoundFamily, borderColor: "rgba(54, 162, 235, 1)", backgroundColor: "rgba(54, 162, 235, 0.5)", data: currentFamilyData @@ -134,6 +134,14 @@ type: 'linear', position: 'bottom' }] + }, + tooltips: { + callbacks: { + label: function(tooltipItem, data) { + var dataItem = data.datasets[tooltipItem.datasetIndex].data[tooltipItem.index]; + return "compound " + dataItem.id + " on PPI " + dataItem.family_name; + } + } } } });