I’m trying to use ion-datetime with presentation=“time” and I want to set min and max values. But it doesn’t work. I’ve used the following code:
<ion-datetime-button [disabled]="complete && !edit" datetime="moreDayEndTime"></ion-datetime-button>
<ion-modal [keepContentsMounted]="true">
<ng-template>
<ion-datetime id="moreDayEndTime" [(ngModel)]="endTime" presentation="time" [showDefaultButtons]="true" cancelText="Abbruch" doneText="OK" hourValues="7,8,9,10,11,12,13,14,15,16,17" minuteValues="0,5,10,15,20,25,30,35,40,45,50,55" max="17:00"></ion-datetime>
</ng-template>
</ion-modal>
I’ve already tried to use [max]="maxTime"
and setting this.maxTime = this.date + "T17:00:00"
.
Can you help me, please? Thanks in advance!