automatically add onclick functions to newly added stock crypto li items
This commit is contained in:
@@ -929,6 +929,12 @@ allFeaturesTextAddBtn.map((value, index) => {
|
|||||||
var tag = document.createElement("li");
|
var tag = document.createElement("li");
|
||||||
if (index == 2) {
|
if (index == 2) {
|
||||||
tag.innerHTML= document.getElementById("base-select").value + ',' + document.getElementById("quote-select").value;
|
tag.innerHTML= document.getElementById("base-select").value + ',' + document.getElementById("quote-select").value;
|
||||||
|
} else if (index == 0) {
|
||||||
|
tag.innerHTML = allFeaturesText[index].value;
|
||||||
|
tag.setAttribute("onclick", "getStockSymbol(this.innerText)");
|
||||||
|
} else if (index == 1) {
|
||||||
|
tag.innerHTML = allFeaturesText[index].value;
|
||||||
|
tag.setAttribute("onclick", "getCryptoSymbol(this.innerText)");
|
||||||
} else {
|
} else {
|
||||||
tag.innerHTML = allFeaturesText[index].value;
|
tag.innerHTML = allFeaturesText[index].value;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user