schedule pd changes

This commit is contained in:
gandhimathi 2019-01-26 12:17:57 +05:30
parent b78fe9c7ca
commit bce50abd92

View File

@ -66,12 +66,11 @@ export class SchedulePdComponent implements OnInit, OnDestroy {
ngOnInit() {
this.validateTime = setInterval(() => {
let currentTime:any = new Date();
currentTime = currentTime.getFullYear()+'-'+currentTime.getMonth()+'-'+currentTime.getDay()+currentTime.getHours()+'-'+currentTime.getMinutes();
currentTime = currentTime.getFullYear()+'-'+currentTime.getMonth()+'-'+currentTime.getDay()+'-'+currentTime.getHours()+'-'+currentTime.getMinutes();
let existTime:any = this.selectedMoment.getFullYear()+'-'+this.selectedMoment.getMonth()+'-'+this.selectedMoment.getDay() +'-'+this.selectedMoment.getHours()+'-'+this.selectedMoment.getMinutes();
if(existTime < currentTime) {
this.selectedMoment = new Date();
this.min = new Date();
}
},1000);
}