add all message datatable and alertboxes instead of toast

This commit is contained in:
amazuecos
2025-03-25 20:14:07 +01:00
parent 20db840bf9
commit d15bbb42f1
10 changed files with 62 additions and 41 deletions

View File

@ -52,11 +52,11 @@ class ChatDepartmentForm {
_handleUserToDepartmentSuccess(response) {
this.btnAddUserToDepartment.removeAttr("disabled")
this.chatDepartmentUsersDatatable.datatable.ajax.reload()
alertSuccess(response.message).fire()
popSuccessAlert(response.message);
this.seletChatDepartmentUser.reset()
}
_handleUserToDepartmentError(response) {
alertError(response.message ?? "").fire()
popErrorAlert(response.message);
this.btnAddUserToDepartment.removeAttr("disabled")
}
@ -76,12 +76,12 @@ class ChatDepartmentForm {
}
__handleUpdateDepartmentSuccess(response) {
this.btnUpdate.removeAttr("disabled")
alertSuccess(response.message).fire()
popSuccessAlert(response.message);
this.updateFormData(response.data)
}
_handleUpdateDepartmentError(response) {
this.btnUpdate.removeAttr("disabled")
alertError(response.message ?? "").fire()
popErrorAlert(response.message);
}