Components/create-modal: update form
This commit is contained in:
parent
4f505507be
commit
ac9d6a4566
2 changed files with 8 additions and 3 deletions
|
|
@ -9,13 +9,17 @@
|
||||||
<input formControlName="title" type="text" class="form-control"/>
|
<input formControlName="title" type="text" class="form-control"/>
|
||||||
</div>
|
</div>
|
||||||
<div class="mb-3">
|
<div class="mb-3">
|
||||||
<label class="form-label">Year</label>
|
<label class="form-label">Date</label>
|
||||||
<input formControlName="year" type="number" class="form-control"/>
|
<input formControlName="date" type="date" class="form-control"/>
|
||||||
</div>
|
</div>
|
||||||
<div class="mb-3">
|
<div class="mb-3">
|
||||||
<label class="form-label">Seasons</label>
|
<label class="form-label">Seasons</label>
|
||||||
<input formControlName="seasons" type="number" class="form-control"/>
|
<input formControlName="seasons" type="number" class="form-control"/>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="mb-3">
|
||||||
|
<label class="form-label">Episodes</label>
|
||||||
|
<input formControlName="episodes" type="number" class="form-control"/>
|
||||||
|
</div>
|
||||||
<div class="mb-3">
|
<div class="mb-3">
|
||||||
<label class="form-label">Description</label>
|
<label class="form-label">Description</label>
|
||||||
<input formControlName="description" type="text" class="form-control"/>
|
<input formControlName="description" type="text" class="form-control"/>
|
||||||
|
|
|
||||||
|
|
@ -17,8 +17,9 @@ export class CreateModalComponent {
|
||||||
constructor() {
|
constructor() {
|
||||||
this.newShowForm = new FormGroup({
|
this.newShowForm = new FormGroup({
|
||||||
title: new FormControl("", Validators.required),
|
title: new FormControl("", Validators.required),
|
||||||
year: new FormControl("", [Validators.required, Validators.min(1900)]),
|
date: new FormControl("", Validators.required),
|
||||||
seasons: new FormControl("", [Validators.required, Validators.min(1)]),
|
seasons: new FormControl("", [Validators.required, Validators.min(1)]),
|
||||||
|
episodes: new FormControl("", [Validators.required, Validators.min(1)]),
|
||||||
description: new FormControl("", Validators.required)
|
description: new FormControl("", Validators.required)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue