import api from "src/api";

export const getFinancialByUnit = async (unitId) => {
  const { data } = await api.get("/unit-financial", { params: { unit_id: unitId } });
  return data.payload;
};

export const upsertFinancial = async (payload) => {
  const { data } = await api.post("/unit-financial", payload);
  return data.payload;
};
