Skip to content

Commit

Permalink
Step 5.9: Add validators
Browse files Browse the repository at this point in the history
  • Loading branch information
kamilkisiela authored and dotansimha committed Nov 27, 2016
1 parent 1456a8d commit 68f7838
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions client/imports/app/parties/parties-form.component.ts
@@ -1,5 +1,5 @@
import { Component, OnInit } from '@angular/core';
import { FormGroup, FormBuilder } from '@angular/forms';
import { FormGroup, FormBuilder, Validators } from '@angular/forms';

import template from './parties-form.component.html';

Expand All @@ -16,9 +16,9 @@ export class PartiesFormComponent implements OnInit {

ngOnInit() {
this.addForm = this.formBuilder.group({
name: [],
name: ['', Validators.required],
description: [],
location: []
location: ['', Validators.required]
});
}
}

0 comments on commit 68f7838

Please sign in to comment.