required fields in project
This commit is contained in:
parent
da6c98cacd
commit
4f4d7087f3
|
@ -80,11 +80,10 @@
|
|||
</button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<form #newProjectForm="ngForm" (ngSubmit)="SaveProject()">
|
||||
<div class="form-group">
|
||||
<form #newProjectForm="ngForm" (ngSubmit)="SaveProject()" novalidate>
|
||||
|
||||
<label for="label-name" class="form-control-label">Label:</label>
|
||||
<input type="text" class="form-control" id="label-name" [(ngModel)]= "project.label" name = "label">
|
||||
</div>
|
||||
<input type="text" class="form-control" id="label-name" [(ngModel)]= "project.label" name = "label" required>
|
||||
<div class="form-group">
|
||||
<label for="abbreviation-text" class="form-control-label">Abbreviation:</label>
|
||||
<input class="form-control" id="abbreviation-text" [(ngModel)]= "project.abbreviation" name = "abbreviation">
|
||||
|
@ -99,11 +98,11 @@
|
|||
</div>
|
||||
<div class="form-group">
|
||||
<label for="start-date" class="form-control-label">Start Date:</label>
|
||||
<input class="form-control" type='date' class="form-control" [(ngModel)]= "project.startdate" id='start-date' name = "startdate"/>
|
||||
<input class="form-control" type='date' class="form-control" [(ngModel)]= "project.startdate" id='start-date' name = "startdate" required/>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="end-date" class="form-control-label">End Date:</label>
|
||||
<input class="form-control" type='date' class="form-control" [(ngModel)]= "project.enddate" id='end-date' name = "enddate"/>
|
||||
<input class="form-control" type='date' class="form-control" [(ngModel)]= "project.enddate" id='end-date' name = "enddate" required/>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="status-name" class="col-form-label">Status:</label>
|
||||
|
@ -119,7 +118,7 @@
|
|||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
|
||||
<button type="submit" class="btn btn-primary" (click)="SaveProject();">Save project</button>
|
||||
<button type="submit" class="btn btn-primary" [disabled]="!newProjectForm.form.valid" (click)="SaveProject();">Save project</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue