US06: Add a button for the owner create form to the owners list, fix bug where all whitespaces were considered valid input

This commit is contained in:
2020-04-05 18:14:03 +02:00
parent be37d5ce86
commit a01405e3cc
4 changed files with 4 additions and 3 deletions

View File

@@ -17,7 +17,7 @@
<form (ngSubmit)="addOwner()" #ownerForm="ngForm">
<div class="form-group">
<label for="name">Name</label>
<input type="text" class="form-control" name="name" [(ngModel)]="owner.name" required>
<input type="text" class="form-control" name="name" [(ngModel)]="owner.name" pattern="\s*\S+.*" required>
</div>
<button type="submit" class="btn btn-success" [disabled]="!ownerForm.form.valid" (submit)="addOwner()">Submit</button>

View File

@@ -14,6 +14,7 @@
</div>
<button type="submit" class="btn btn-primary"><i class="fas fa-search"></i></button>
<button type="button" onclick="document.getElementById('searchForm').reset();" class="btn btn-danger"><i class="fas fa-times"></i></button>
<a href="owner/add" class="btn btn-success"><i class="fas fa-plus"></i></a>
</div>
</form>
<table class="table">