client/src/actions/notesActions.js
changeset 62 b2514a9bcd49
parent 59 1eb52770eefa
child 66 f402435be429
equal deleted inserted replaced
61:7586b4a11c32 62:b2514a9bcd49
     2 
     2 
     3 import * as types from '../constants/actionTypes';
     3 import * as types from '../constants/actionTypes';
     4 
     4 
     5 export const addNote = (session, data) => {
     5 export const addNote = (session, data) => {
     6   return {
     6   return {
     7     type: types.ADD_NOTE_ASYNC,
     7     type: types.ADD_NOTE,
     8     note: {
     8     note: {
     9       _id: uuidV1(),
     9       _id: uuidV1(),
    10       session: session._id,
    10       session: session._id,
    11       raw: data.raw,
    11       raw: data.raw,
    12       plain: data.plain,
    12       plain: data.plain,
    18   };
    18   };
    19 }
    19 }
    20 
    20 
    21 export const loadNotesBySession = (session) => {
    21 export const loadNotesBySession = (session) => {
    22   return {
    22   return {
    23     type: types.LOAD_NOTES_BY_SESSION_ASYNC,
    23     type: types.LOAD_NOTES_BY_SESSION,
    24     session: session
    24     session: session
    25   }
    25   }
    26 }
    26 }