Merge pull request #8 from SamandarTurgunboyev/samandar

amenities update
This commit is contained in:
Samandar Turg'unboev
2025-11-06 11:35:34 +05:00
committed by GitHub
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) => ({