Skip to content

Instantly share code, notes, and snippets.

@kevinold
Created November 25, 2015 17:35

Revisions

  1. kevinold created this gist Nov 25, 2015.
    14 changes: 14 additions & 0 deletions ExpensesApp.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,14 @@
    /*global ExpenseReports Currencies ExpenseCategories ExpenseReportCustomFields ExpenseLineCustomFields ExpenseCategoryCustomFields*/
    // imports...
    class ExpensesApp extends Component {
    componentDidMount() {
    let dispatch = this.props.dispatch;
    dispatch(CustomFieldActionCreators.receiveReportCustomFields(ExpenseReportCustomFields));
    dispatch(CustomFieldActionCreators.receiveLineCustomFields(ExpenseLineCustomFields));
    dispatch(CustomFieldActionCreators.receiveCategoryCustomFields(ExpenseCategoryCustomFields));

    dispatch(ExpenseReportActionCreators.receiveAll(ExpenseReports, ExpenseReportCustomFields));
    dispatch(CurrencyActionCreators.receiveAll(Currencies));
    dispatch(ExpenseCategoryActionCreators.receiveAll(ExpenseCategories));
    dispatch(WalletActionCreators.receiveWalletLines(WalletLines));
    }