front_foundation #9

Closed
mohamed_maoulainine wants to merge 181 commits from front_foundation into main
4 changed files with 10 additions and 8 deletions
Showing only changes of commit 351727f3d5 - Show all commits

View File

@ -7,7 +7,7 @@ import {
defaultApiSuccessHandler,
} from "@/services/api";
// Admin API
// Admin API
function getPendingAccounts(
onSuccessHandler?: (response: AxiosResponse) => void,
onErrorHandler?: (error: AxiosError) => void

View File

@ -1,11 +1,13 @@
import { type AxiosError, type AxiosResponse } from "axios";
import Project from "@/ApiClasses/Project";
import SectionCell from "@/ApiClasses/SectionCell";
import { axiosInstance, defaultApiErrorHandler, defaultApiSuccessHandler } from "@/services/api"
import {
axiosInstance,
defaultApiErrorHandler,
defaultApiSuccessHandler,
} from "@/services/api";
// Entrepreneurs API
// Entrepreneurs API
function requestProjectCreation(
projectDetails: Project, // Replace 'any' with a proper type for project details if available
onSuccessHandler?: (response: AxiosResponse) => void,
@ -35,7 +37,7 @@ function addSectionCell(
onErrorHandler?: (error: AxiosError) => void
): void {
axiosInstance
.post("/entrepreneur/sectionCells", sectionCellDetails.toPlainObject())
.post("/entrepreneur/sectionCells", sectionCellDetails.toPlainObject())
.then((response) => {
if (onSuccessHandler) {
onSuccessHandler(response);

View File

@ -6,7 +6,7 @@ import {
defaultApiSuccessHandler,
} from "@/services/api";
// Shared API
// Shared API
function getSectionCellsByDate(
projectId: number,
sectionId: number,

View File

@ -6,7 +6,7 @@ import {
defaultApiSuccessHandler,
} from "@/services/api";
// Unauth API
// Unauth API
function finalizeAccount(
onSuccessHandler?: (response: AxiosResponse) => void,
onErrorHandler?: (error: AxiosError) => void