annotate report_clonality/script.js @ 3:beaa487ecf43 draft

Uploaded
author davidvanzessen
date Wed, 07 Dec 2016 08:36:23 -0500
parents afe85eb6572e
children 124b7fd92a3e
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
1 function compareAdd(id){
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
2 var img = document.createElement('img');
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
3 img.setAttribute('src', 'HeatmapVD_' + id + '.png');
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
4 var td = document.createElement('td');
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
5 td.setAttribute('id', "comparison_vd_" + id);
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
6 td.appendChild(img)
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
7 $('#comparison_table_vd').append(td);
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
8
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
9 img = document.createElement('img');
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
10 img.setAttribute('src', 'HeatmapVJ_' + id + '.png');
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
11 td = document.createElement('td');
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
12 td.setAttribute('id', "comparison_vj_" + id);
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
13 td.appendChild(img)
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
14 $('#comparison_table_vj').append(td);
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
15
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
16 img = document.createElement('img');
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
17 img.setAttribute('src', 'HeatmapDJ_' + id + '.png');
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
18 td = document.createElement('td');
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
19 td.setAttribute('id', "comparison_dj_" + id);
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
20 td.appendChild(img)
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
21 $('#comparison_table_dj').append(td);
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
22
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
23 $('#compare_checkbox_' + id).attr('onchange', "javascript:compareRemove('" + id + "')");
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
24 }
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
25
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
26
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
27 function compareRemove(id){
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
28 $("#comparison_vd_" + id).remove()
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
29 $("#comparison_vj_" + id).remove()
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
30 $("#comparison_dj_" + id).remove()
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
31 $("#compare_checkbox_" + id).attr('onchange', "javascript:compareAdd('" + id + "')");
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
32 }
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
33
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
34 $( document ).ready(function () {
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
35 $('#junction_table').tablesorter();
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
36 })