Fully functional widgets for adding shifts

- todo: wait for React Datepicker PR 1380
- batch api call and saga handlers
- view/edit
This commit is contained in:
Alexander Wong
2018-04-19 10:30:33 -06:00
parent 0c8defd469
commit 530593b721
5 changed files with 117 additions and 22 deletions

View File

@@ -6,9 +6,11 @@ import {
CLEAR_CSHIFT_REQUEST_SUCCESS,
SET_FORM_EMPLOYEE_UUID,
SET_FORM_PRICE_UUID,
SET_CLEAR_CSHIFT_STATE,
SET_FORM_SHIFT_START_TIME,
SET_FORM_SHIFT_DURATION
SET_FORM_SHIFT_DURATION,
SET_FORM_SHIFT_NOTE,
SET_FORM_SHIFT_DATES,
SET_CLEAR_CSHIFT_STATE
} from "../../constants/cShift.constants";
import { parseError } from "../common.actions";
@@ -74,6 +76,20 @@ export function setFormShiftDuration(duration) {
};
}
export function setFormShiftNote(note) {
return {
type: SET_FORM_SHIFT_NOTE,
data: note
};
}
export function setFormShiftDates(dates) {
return {
type: SET_FORM_SHIFT_DATES,
data: dates
};
}
export function setClearCshiftState() {
return {
type: SET_CLEAR_CSHIFT_STATE