feat: burg group editor - form

This commit is contained in:
Azgaar 2024-10-02 03:12:45 +02:00
parent 32808605b3
commit d8009f84ad
8 changed files with 156 additions and 53 deletions

View file

@ -414,7 +414,7 @@ function overviewMilitary() {
function applyMilitaryOptions() {
const unitLines = Array.from(tableBody.querySelectorAll("tr"));
const names = unitLines.map(r => r.querySelector("input").value.replace(/[&\/\\#, +()$~%.'":*?<>{}]/g, "_"));
const names = unitLines.map(r => sanitizeId(r.querySelector("input").value));
if (new Set(names).size !== names.length) return tip("All units should have unique names", false, "error");
$("#militaryOptions").dialog("close");