mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
Improve
This commit is contained in:
@@ -22,7 +22,7 @@ export class ToastService {
|
||||
toast.present();
|
||||
}
|
||||
|
||||
async successMessage(message?: string) {
|
||||
async successMessage(message?: string, callback?) {
|
||||
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
@@ -61,12 +61,15 @@ export class ToastService {
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
|
||||
}
|
||||
|
||||
async badRequest(message?: string) {
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
@@ -104,6 +107,9 @@ export class ToastService {
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user