setting and ui change password

This commit is contained in:
hamid zarghami
2025-02-03 14:37:40 +03:30
parent d7a004a41a
commit 1db7653cb2
10 changed files with 285 additions and 169 deletions
@@ -0,0 +1,15 @@
import axios from "../../../config/axios";
import { ChangePasswordType, UpdateSettingType } from "../types/SettingTypes";
export const getSettings = async () => {
const { data } = await axios.get(`/settings`);
return data;
};
export const updateSettings = async (params: UpdateSettingType) => {
await axios.patch(`/settings/${params.id}/update`, params);
};
export const changePassword = async (params: ChangePasswordType) => {
await axios.post(`/settings/password`, params);
};