diff --git a/src/Views/Home/Groups.cshtml b/src/Views/Home/Groups.cshtml index ba533d9..aa80e9c 100644 --- a/src/Views/Home/Groups.cshtml +++ b/src/Views/Home/Groups.cshtml @@ -281,6 +281,36 @@ if (result.success) { bootstrap.Modal.getInstance(createModalEl).hide(); createForm.reset(); + // Add the new group to the table + const tableBody = document.querySelector('tbody'); + const newRow = document.createElement('tr'); + + newRow.innerHTML = ` + ${jsonData.Cn} + ${jsonData.Permissions.includes("CanInventorize") ? "☑️" : "❌"} + ${jsonData.Permissions.includes("CanManageUsers") ? "☑️" : "❌"} + ${jsonData.Permissions.includes("CanManageLocations") ? "☑️" : "❌"} + ${jsonData.Permissions.includes("CanManageAssets") ? "☑️" : "❌"} + ${jsonData.Permissions.includes("CanManageGroups") ? "☑️" : "❌"} + +
+ + +
+ + `; + + tableBody.appendChild(newRow); showToast('@T["Group created successfully"]', 'success'); } else { let exception = result.exception;