Added functionality to permenently delete or restore deleted organisations

This commit is contained in:
2022-02-10 15:52:57 +00:00
parent c3cf97ea50
commit 57dfed304f
10 changed files with 603 additions and 17 deletions

View File

@@ -8,20 +8,31 @@
*/
$(document).ready(function() {
if ($("#widget-organisations").length) {
$("#widget-organisations").ufTable({
dataUrl: site.uri.public + "/api/organisations",
useLoadingTransition: site.uf_table.use_loading_transition
});
$("#widget-organisations").ufTable({
dataUrl: site.uri.public + "/api/organisations",
useLoadingTransition: site.uf_table.use_loading_transition
});
// Bind creation button
bindOrganisationCreationButton($("#widget-organisations"));
// Bind creation button
bindOrganisationCreationButton($("#widget-organisations"));
// Bind registration button
bindOrganisationRegistrationButton($("#widget-organisations"));
// Bind registration button
bindOrganisationRegistrationButton($("#widget-organisations"));
// Bind table buttons
$("#widget-organisations").on("pagerComplete.ufTable", function () {
bindOrganisationButtons($(this));
});
} else {
$("#widget-deleted-organisations").ufTable({
dataUrl: site.uri.public + "/api/organisations/deleted",
useLoadingTransition: site.uf_table.use_loading_transition
});
// Bind table buttons
$("#widget-organisations").on("pagerComplete.ufTable", function () {
bindOrganisationButtons($(this));
});
// Bind table buttons
$("#widget-deleted-organisations").on("pagerComplete.ufTable", function () {
bindOrganisationButtons($(this));
});
}
});