fix missing pull of edit checkboxes
ci/woodpecker/push/woodpecker Pipeline was successful

This commit is contained in:
2026-05-12 15:52:20 -04:00
parent 7f5fcd0943
commit a7c5e1708c
+13 -9
View File
@@ -72,6 +72,8 @@ function renderAddBookView() {
volume: document.getElementById("volume").value,
year: document.getElementById("year").value,
coverURL: document.getElementById("coverURL").value,
childrens: document.getElementById("childrens").checked,
signed: document.getElementById("signed").checked,
});
});
}
@@ -114,8 +116,8 @@ function renderTable(bookList, sortField) {
}
bookList.sort((one, two) =>
(one[sortState.sortBy] + one["sortTitle"]).localeCompare(
two[sortState.sortBy] + two["sortTitle"]
)
two[sortState.sortBy] + two["sortTitle"],
),
);
if (sortState.sortOrder === "desc") {
bookList.reverse();
@@ -135,7 +137,7 @@ function renderTable(bookList, sortField) {
row.addEventListener("click", (e) => {
// add listener to swap current book
document.getElementById("current").innerHTML = BookTemplate(
bookList[e.currentTarget.id]
bookList[e.currentTarget.id],
);
});
});
@@ -146,7 +148,7 @@ function renderTable(bookList, sortField) {
// only add callback when there's a sortBy attribute
renderTable(bookList, e.target.dataset.sortBy);
});
}
},
);
// mark currently active column
bookElement
@@ -187,7 +189,7 @@ function search(searchBy, includeChildrensBooks) {
return inSearch && !childrens;
}
return inSearch;
}
},
);
}
@@ -218,7 +220,7 @@ function clearAddBookForm() {
document
.getElementById("newBookForm")
.childNodes.forEach((node) =>
node.nodeName === "LABEL" ? (node.lastChild.value = "") : null
node.nodeName === "LABEL" ? (node.lastChild.value = "") : null,
);
}
@@ -265,8 +267,10 @@ function TableRowTemplate({
return `<tr class="tRow" id="${rowNumber}">
<td class="title">
${title} ${
signed ? '<span class="signed" title="Signed by the author" >✒</span>' : ""
}
signed
? '<span class="signed" title="Signed by the author" >✒</span>'
: ""
}
</td>
<td class="author">${authors}</td>
<td class="publisher">${publisher}</td>
@@ -312,7 +316,7 @@ function AddBookTemplate() {
type="${field.type}"
name="${field.name.toLowerCase()}"
id="${field.id}"
/></label><br/>`
/></label><br/>`,
);
}, "")}
<input id="lookup" type="submit" value="look up">