import { adminGetCharts } from "../../../features/admin/services/admin-get-charts";
import { adminGetHatchingByPeriod } from "../../../features/admin/services/admin-get-hatching-by-period";

export const adminExtraReducers = {
  [adminGetCharts.fulfilled]: (state, { payload }) => {
    state.statics = payload.data;
    state.pending = false;
  },
  [adminGetCharts.pending]: (state) => {
    state.pending = true;
  },
  [adminGetHatchingByPeriod.fulfilled]: (state, { payload }) => {
    state.hatchingByPeriod = payload.data;
    state.pending = false;
  },
  [adminGetHatchingByPeriod.pending]: (state) => {
    state.pending = true;
  },
};
