Added entity/searchdomain name to deletion confirmation warning for searchdomain and entity

This commit is contained in:
2025-12-21 14:17:02 +01:00
parent fbfaff2953
commit b5545bb5c8
3 changed files with 21 additions and 2 deletions

View File

@@ -275,7 +275,8 @@
</div>
<div class="modal-body">
<p>@T["Are you sure you want to delete this searchdomain? This action cannot be undone."]</p>
<p>@Html.Raw(T["GenericDeleteConfirmation", "deleteSearchdomainConfirmationModalName"])</p>
<p>@T["IrreversibleActionWarning"]</p>
</div>
<div class="modal-footer">
@@ -408,7 +409,8 @@
</div>
<div class="modal-body">
<p>@T["Are you sure you want to delete this entity? This action cannot be undone."]</p>
<p>@Html.Raw(T["GenericDeleteConfirmation", "deleteEntityConfirmationModalName"])</p>
<p>@T["IrreversibleActionWarning"]</p>
</div>
<div class="modal-footer">
@@ -475,6 +477,9 @@
document.getElementById('deleteSearchdomainModal')
);
modal.show();
let searchdomain = domains[getSelectedDomainKey()];
let deleteSearchdomainConfirmationModalName = document.getElementById('deleteSearchdomainConfirmationModalName');
deleteSearchdomainConfirmationModalName.textContent = searchdomain;
});
document
.getElementById('searchdomainConfirmDelete')
@@ -964,6 +969,8 @@
modal.show();
let entityConfirmDelete = document.getElementById('EntityConfirmDelete');
entityConfirmDelete.setAttribute('data-name', entity.Name);
let deleteEntityConfirmationModalName = document.getElementById('deleteEntityConfirmationModalName');
deleteEntityConfirmationModalName.textContent = entity.Name;
});
actionCell.appendChild(detailsButton);