Skip to content

Commit

Permalink
Merge pull request #138 from chance-nelson/viz-1-delete
Browse files Browse the repository at this point in the history
Fix viz 1 primer delete/re-add problem
  • Loading branch information
Alex-Lacy authored May 6, 2019
2 parents 2265f3d + 7a94d9f commit 76e54c1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/js/viz.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ function parse_data(direction, field) {
*/
function deleteRow(r) {
var i = r.parentNode.parentNode.rowIndex;
delete selected_labels[r.parentNode.parentNode.id.replace('trow','')];
table.deleteRow(i);
}

Expand Down Expand Up @@ -244,7 +245,6 @@ function create_viz_spec(direction, field, div) {
var value = selected_labels[d.text];
selected_labels[d.text] = value + 1;


var tr_to_update = document.getElementById(d.text + 'trow');
tr_to_update.cells[1].innerHTML = selected_labels[d.text];

Expand Down

0 comments on commit 76e54c1

Please sign in to comment.