28 lines
1.3 KiB
HTML
28 lines
1.3 KiB
HTML
<div md-dialog-title>
|
|
<p>Add Event</p>
|
|
</div>
|
|
<div md-dialog-content>
|
|
<form #addEventForm="ngForm" (ngSubmit)="onSubmit()">
|
|
<mat-form-field class="full-width">
|
|
<input matInput placeholder="Title" required [(ngModel)]="eventTitle" name="title" >
|
|
</mat-form-field>
|
|
<mat-form-field class="full-width">
|
|
<input matInput placeholder="Start Date" required [ngModel]="eventStartDate | date:'yyyy-MM-ddTHH:mm'" (ngModelChange)="eventStartDate = $event" name="startDate" type="datetime-local">
|
|
</mat-form-field>
|
|
<mat-form-field class="full-width">
|
|
<input matInput placeholder="End Date" required [ngModel]="eventEndDate | date:'yyyy-MM-ddTHH:mm'" (ngModelChange)="eventEndDate = $event" name="endDate" type="datetime-local">
|
|
</mat-form-field>
|
|
<mat-form-field class="full-width">
|
|
<input matInput placeholder="Description" required [(ngModel)]="eventDescription" name="description" >
|
|
</mat-form-field>
|
|
|
|
<br><br>
|
|
<div *ngIf="errorMessages.length > 0" class="errorMessages">
|
|
<p *ngFor="let error of errorMessages">
|
|
{{error}}
|
|
</p>
|
|
</div>
|
|
<button mat-raised-button class="first" (click)="cancel($event)" >Cancel</button><!--
|
|
--><button mat-raised-button type="submit" [disabled]="!addEventForm.form.valid || addEventButtonDisabled">{{ addEventButtonText }}</button>
|
|
</form>
|
|
</div> |