Permalink
Browse files

Step 17.3: Change party creation component

  • Loading branch information...
1 parent 88db718 commit 4f846ac29b61842bb40ad426573fe17e39c6a3ed @dotansimha dotansimha committed with DAB0mB Sep 27, 2016
Showing with 9 additions and 1 deletion.
  1. +9 −1 client/imports/app/parties/parties-form.component.ts
@@ -33,7 +33,15 @@ export class PartiesFormComponent implements OnInit {
}
if (this.addForm.valid) {
- Parties.insert(Object.assign({}, this.addForm.value, { owner: Meteor.userId() }));
+ Parties.insert({
+ name: this.addForm.value.name,
+ description: this.addForm.value.description,
+ location: {
+ name: this.addForm.value.location
+ },
+ public: this.addForm.value.public,
+ owner: Meteor.userId()
+ });
this.addForm.reset();
}

0 comments on commit 4f846ac

Please sign in to comment.