client/src/components/NoteInput.js
changeset 78 49c5ea36d0a4
parent 77 cd27d9fc1c73
child 79 772b73e31069
--- a/client/src/components/NoteInput.js	Thu Jun 22 12:53:00 2017 +0200
+++ b/client/src/components/NoteInput.js	Thu Jun 22 12:37:53 2017 +0200
@@ -32,15 +32,16 @@
     const raw = this.refs.editor.asRaw();
     const html = this.refs.editor.asHtml();
     const categories = this.refs.editor.asCategories();
+    const marginComment = this.marginComment.value;
 
     this.props.notesActions.addNote(this.props.session, {
       plain: plain,
       raw: raw,
       html: html,
-
       startedAt: this.state.startedAt,
       finishedAt: now(),
       categories: categories,
+      marginComment: marginComment,
     });
 
     this.refs.editor.clear();
@@ -74,7 +75,7 @@
               name="margin"
               componentClass="textarea"
               placeholder="Enter a margin comment for your note"
-              inputRef={ ref => { this.description = ref; } }
+              inputRef={ ref => { this.marginComment = ref; } }
             />
           </div>
         </div>