fix: [html] <option> tag wants to be inside <select> tag
This commit is contained in:
parent
01323c6c65
commit
c1d4f7c60a
1 changed files with 2 additions and 2 deletions
|
|
@ -15,7 +15,7 @@ function createHTML(addr, i) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Needs option to use value in js
|
// Needs option to use value in js
|
||||||
let name = `<option id="name${addr.ID}" value="${addr.Name}">${addr.Name}</option>`;
|
let name = `<select><option id="name${addr.ID}" value="${addr.Name}">${addr.Name}</option></select>`;
|
||||||
if (edit == 1) {
|
if (edit == 1) {
|
||||||
name = `<input id="name${addr.ID}" onchange="editForm(${addr.ID},'')" type="text" class="form-control" value="${addr.Name}">`;
|
name = `<input id="name${addr.ID}" onchange="editForm(${addr.ID},'')" type="text" class="form-control" value="${addr.Name}">`;
|
||||||
}
|
}
|
||||||
|
|
@ -85,4 +85,4 @@ async function editForm(id, known) {
|
||||||
// console.log(url);
|
// console.log(url);
|
||||||
|
|
||||||
await fetch(url);
|
await fetch(url);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue