amenities update

This commit is contained in:
Samandar Turgunboyev
2025-11-06 11:34:47 +05:00
parent 22ded55cc1
commit 68b804c20d
2 changed files with 11 additions and 4 deletions

View File

@@ -75,7 +75,13 @@ export interface GetOneTours {
image: string;
},
];
ticket_amenities: number[];
ticket_amenities: {
icon_name: string;
id: number;
name: string;
name_ru: string;
name_uz: string;
}[];
ticket_included_services: [
{
image: string;

View File

@@ -156,10 +156,11 @@ const StepOne = ({
});
}
// 🔹 Qulayliklar (amenities)
form.setValue("amenities", tour.ticket_amenities);
form.setValue(
"amenities",
tour.ticket_amenities.map((e) => e.id),
);
// 🔹 Xizmatlar (hotel_services)
form.setValue(
"hotel_services",
tour.ticket_included_services?.map((s) => ({