change url param name to "subdomain"

This commit is contained in:
2025-10-31 13:56:20 +03:00
parent 42d0b2cacf
commit 3dddc78dda
24 changed files with 89 additions and 116 deletions

View File

@@ -39,7 +39,7 @@ export default function RestaurantServices({
}: RestaurantServicesProps) {
const { t } = useTranslation();
const { isRTL } = useAppSelector((state) => state.locale);
const { id } = useParams();
const { subdomain } = useParams();
const dispatch = useAppDispatch();
const services = [
@@ -54,7 +54,7 @@ export default function RestaurantServices({
/>
),
color: "bg-blue-50 text-blue-600",
href: `/${id}/menu?orderType=${OrderType.DineIn}`,
href: `/${subdomain}/menu?orderType=${OrderType.DineIn}`,
},
]) ||
[]),
@@ -69,7 +69,7 @@ export default function RestaurantServices({
/>
),
color: "bg-green-50 text-green-600",
href: `/${id}/menu?orderType=${OrderType.Pickup}`,
href: `/${subdomain}/menu?orderType=${OrderType.Pickup}`,
},
]) ||
[]),
@@ -84,7 +84,7 @@ export default function RestaurantServices({
/>
),
color: "bg-pink-50 text-pink-600",
href: `/${id}/menu?orderType=${OrderType.Gift}`,
href: `/${subdomain}/menu?orderType=${OrderType.Gift}`,
},
]) ||
[]),
@@ -97,7 +97,7 @@ export default function RestaurantServices({
<ToRoomIcon className={styles.serviceIcon + " " + styles.roomIcon} />
),
color: "bg-purple-50 text-purple-600",
href: `/${id}/menu?orderType=${OrderType.ToRoom}`,
href: `/${subdomain}/menu?orderType=${OrderType.ToRoom}`,
},
]) ||
[]),
@@ -112,7 +112,7 @@ export default function RestaurantServices({
/>
),
color: "bg-orange-50 text-orange-600",
href: `/${id}/menu?orderType=${OrderType.ToOffice}`,
href: `/${subdomain}/menu?orderType=${OrderType.ToOffice}`,
},
]) ||
[]),
@@ -127,7 +127,7 @@ export default function RestaurantServices({
/>
),
color: "bg-indigo-50 text-indigo-600",
href: `/${id}/menu?orderType=${OrderType.Booking}`,
href: `/${subdomain}/menu?orderType=${OrderType.Booking}`,
},
]) ||
[]),
@@ -142,7 +142,7 @@ export default function RestaurantServices({
/>
),
color: "bg-indigo-50 text-indigo-600",
href: `/${id}/address`,
href: `/${subdomain}/address`,
},
]) ||
[]),
@@ -157,7 +157,7 @@ export default function RestaurantServices({
/>
),
color: "bg-indigo-50 text-indigo-600",
href: `/${id}/menu?orderType=${OrderType.ScheduledOrder}`,
href: `/${subdomain}/menu?orderType=${OrderType.ScheduledOrder}`,
},
]) ||
[]),