add Middleware + fixed all pages and fixed add propertise

This commit is contained in:
hamzaobed7
2026-08-06 22:26:35 +03:00
parent 7da4bf9f2b
commit 4d1b744516
30 changed files with 3618 additions and 4345 deletions

View File

@ -345,9 +345,10 @@ export async function editSaleProperty(id, data) {
}
export async function addSaleProperty(data) {
return apiFetch("/SaleProperties/AddSaleProperty", {
method: "POST",
body: data,
body: data ,
});
}
@ -446,7 +447,7 @@ async function multipartAuthFetch(endpoint, formData) {
};
}
export async function addOwner(data, frontImage = null, backImage = null) {
export async function addOwner(data, frontImage = null, backImage = null, licenseImage = null) {
const formData = new FormData();
formData.append("FirstName", data.firstName || data.FirstName || "");
@ -467,6 +468,7 @@ export async function addOwner(data, frontImage = null, backImage = null) {
if (frontImage) formData.append("FrontIdCarImagePath", frontImage);
if (backImage) formData.append("RearIdCarImagePath", backImage);
if (licenseImage) formData.append("RearIdCarImagePath", licenseImage);
return multipartAuthFetch("/Owner/Add", formData);
}