ok
This commit is contained in:
@@ -193,12 +193,12 @@ export const getAllCafeOwner = async (formData) => {
|
||||
}
|
||||
};
|
||||
|
||||
export const createCafeOwner = async (shopId, email, username, password) => {
|
||||
export const createCafeOwner = async (email, username, password) => {
|
||||
const token = getLocalStorage("auth");
|
||||
if (token) {
|
||||
try {
|
||||
const response = await fetch(
|
||||
API_BASE_URL + "/user/create-clerk/" + shopId,
|
||||
API_BASE_URL + "/user/create-admin/" ,
|
||||
{
|
||||
method: "POST",
|
||||
headers: {
|
||||
@@ -276,6 +276,7 @@ export const createClerks = async (shopId, email, username, password) => {
|
||||
throw new Error(`HTTP error! status: ${response.status}`);
|
||||
}
|
||||
const data = await response.json();
|
||||
console.log(data)
|
||||
return data;
|
||||
} catch (error) {
|
||||
console.error("Error getting clerk:", error);
|
||||
|
||||
Reference in New Issue
Block a user