mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
Improve form validation
This commit is contained in:
@@ -342,9 +342,13 @@ export class NewEventPage implements OnInit {
|
||||
console.log(this.postEvent);
|
||||
|
||||
|
||||
let loader = this.toastService.loading()
|
||||
|
||||
this.eventService.postEventMd(this.postEvent, this.postEvent.CalendarName).subscribe(
|
||||
async (id) => {
|
||||
|
||||
loader.remove()
|
||||
|
||||
this.showLoader = false
|
||||
|
||||
const eventId: any = id;
|
||||
@@ -382,6 +386,8 @@ export class NewEventPage implements OnInit {
|
||||
|
||||
},
|
||||
error => {
|
||||
|
||||
loader.remove()
|
||||
this.showLoader = false
|
||||
this.toastService.badRequest('Evento não criado')
|
||||
});
|
||||
|
||||
@@ -70,7 +70,7 @@ export class NewActionPage implements OnInit {
|
||||
}
|
||||
|
||||
get dateValid() {
|
||||
if (window.innerWidth <= 800) {
|
||||
if (window.innerWidth >= 800) {
|
||||
return this.folder.DateBegin < this.folder.DateEnd? ['ok']: []
|
||||
} else {
|
||||
return ['ok']
|
||||
|
||||
Reference in New Issue
Block a user