front_foundation #9

Closed
mohamed_maoulainine wants to merge 181 commits from front_foundation into main
2 changed files with 6 additions and 5 deletions
Showing only changes of commit 6ae50f9cf7 - Show all commits

View File

@ -84,9 +84,10 @@
<script setup lang="ts">
import { ref, defineProps, onMounted } from "vue";
import { getSectionCellsByDate } from "@/api_tmp.ts";
import SectionCell from "@/ApiClasses/SectionCell.ts";
import { addSectionCell } from "@/api_tmp.ts";
import { getSectionCellsByDate } from "@/services/Apis/Shared.ts";
import { addSectionCell } from "@/services/Apis/Entrepreneurs.ts";
import SectionCell from "@/ApiClasses/SectionCell";
import type { AxiosResponse, AxiosError } from "axios";
const props = defineProps<{

View File

@ -57,12 +57,12 @@ function requestProjectCreation(
}
function addSectionCell(
sectionCellDetails: SectionCell, // Replace 'any' with a proper type for section cell details if available
sectionCellDetails: SectionCell,
onSuccessHandler?: (response: AxiosResponse) => void,
onErrorHandler?: (error: AxiosError) => void
): void {
axiosInstance
.post("/entrepreneur/sectionCells", sectionCellDetails)
.post("/entrepreneur/sectionCells", sectionCellDetails.toPlainObject()) // <-- Ici
.then((response) => {
if (onSuccessHandler) {
onSuccessHandler(response);