Skip to content
Snippets Groups Projects
Commit 1b55edaa authored by Todd Dembrey's avatar Todd Dembrey
Browse files

Update the edit form to also save the note as it is edited

parent fceebb59
No related branches found
No related tags found
No related merge requests found
......@@ -41,6 +41,7 @@ class EditNoteForm extends React.Component {
disabled={isCreating}
onSubmit={this.onSubmit}
onCancel={() => clearNote(submissionID)}
onChange={this.onChange}
instance="add-note-form"
initialValue={draftNote.message}
/>
......@@ -48,6 +49,10 @@ class EditNoteForm extends React.Component {
);
}
onChange = (message) => {
this.props.storeNote(this.props.submissionID, message)
}
onSubmit = (message, resetEditor) => {
this.props.submitNote({
...this.props.draftNote,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment