actionCategoriesSearchPage.js 375 B

123456789
  1. import { actionFeedCatsFind, actionFeedClear, actionPromiseClear } from "../reducers";
  2. export const actionCategoriesSearchPage =
  3. ({ orderBy = "_id", text = "" } = {}) =>
  4. async (dispatch, getState) => {
  5. dispatch(actionFeedClear());
  6. dispatch(actionPromiseClear("feedCatsFind"));
  7. dispatch(actionFeedCatsFind({ text, orderBy, skip: 0 }));
  8. };