fix: idk
This commit is contained in:
parent
0199e9d0dc
commit
6ae50f9cf7
@ -84,9 +84,10 @@
|
|||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, defineProps, onMounted } from "vue";
|
import { ref, defineProps, onMounted } from "vue";
|
||||||
import { getSectionCellsByDate } from "@/api_tmp.ts";
|
import { getSectionCellsByDate } from "@/services/Apis/Shared.ts";
|
||||||
import SectionCell from "@/ApiClasses/SectionCell.ts";
|
import { addSectionCell } from "@/services/Apis/Entrepreneurs.ts";
|
||||||
import { addSectionCell } from "@/api_tmp.ts";
|
import SectionCell from "@/ApiClasses/SectionCell";
|
||||||
|
|
||||||
import type { AxiosResponse, AxiosError } from "axios";
|
import type { AxiosResponse, AxiosError } from "axios";
|
||||||
|
|
||||||
const props = defineProps<{
|
const props = defineProps<{
|
||||||
|
@ -57,12 +57,12 @@ function requestProjectCreation(
|
|||||||
}
|
}
|
||||||
|
|
||||||
function addSectionCell(
|
function addSectionCell(
|
||||||
sectionCellDetails: SectionCell, // Replace 'any' with a proper type for section cell details if available
|
sectionCellDetails: SectionCell,
|
||||||
onSuccessHandler?: (response: AxiosResponse) => void,
|
onSuccessHandler?: (response: AxiosResponse) => void,
|
||||||
onErrorHandler?: (error: AxiosError) => void
|
onErrorHandler?: (error: AxiosError) => void
|
||||||
): void {
|
): void {
|
||||||
axiosInstance
|
axiosInstance
|
||||||
.post("/entrepreneur/sectionCells", sectionCellDetails)
|
.post("/entrepreneur/sectionCells", sectionCellDetails.toPlainObject()) // <-- Ici
|
||||||
.then((response) => {
|
.then((response) => {
|
||||||
if (onSuccessHandler) {
|
if (onSuccessHandler) {
|
||||||
onSuccessHandler(response);
|
onSuccessHandler(response);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user