18 lines
548 B
TypeScript
18 lines
548 B
TypeScript
import axios from "../../../config/axios";
|
|
import type { AboutUsResponse, CreateAboutUs } from "../types/Types";
|
|
|
|
export const getAboutUs = async (): Promise<AboutUsResponse> => {
|
|
const { data } = await axios.get("/about-us");
|
|
return data;
|
|
};
|
|
|
|
export const createAboutUs = async (params: CreateAboutUs) => {
|
|
const { data } = await axios.post("/admin/settings/about-us", params);
|
|
return data;
|
|
};
|
|
|
|
export const deleteAboutUs = async (id: string) => {
|
|
const { data } = await axios.delete(`/admin/settings/about-us/${id}`);
|
|
return data;
|
|
};
|