Skip to content
Snippets Groups Projects
Commit 96336ddb authored by Winnie's avatar Winnie
Browse files

Update

- Fix bug where previous ranks without following subranks would not
update with blank dropdowns
parent 0788de7f
No related branches found
No related tags found
No related merge requests found
...@@ -33,11 +33,18 @@ function callUpdateSci(object){ ...@@ -33,11 +33,18 @@ function callUpdateSci(object){
function populateDropdown(childTagID, nodeList, subnode){ function populateDropdown(childTagID, nodeList, subnode){
var x, y, content=""; var x, y, content="";
for (var i in nodeList[subnode]["taxonName"]){ console.log(nodeList[subnode]);
x = nodeList[subnode]["taxonId"][i]; if(nodeList[subnode] != null){
y = nodeList[subnode]["taxonName"][i]; for (var i in nodeList[subnode]["taxonName"]){
content += '"<option value="' + x + '">' + y + '</option>'; x = nodeList[subnode]["taxonId"][i];
y = nodeList[subnode]["taxonName"][i];
content += '"<option value="' + x + '">' + y + '</option>';
}
} }
// else {
// content
// }
document.getElementById(childTagID).innerHTML = content; document.getElementById(childTagID).innerHTML = content;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment