fix single analysis result page button

This commit is contained in:
Danel Kungla
2025-10-06 15:16:13 +03:00
parent 98dcb881ac
commit 8958972d78
5 changed files with 39 additions and 20 deletions

View File

@@ -13,7 +13,7 @@ import { GlobalLoader } from '@kit/ui/makerkit/global-loader';
import { PageBody, PageHeader } from '@kit/ui/page';
import { Trans } from '@kit/ui/trans';
import { AnalysisOrder } from '~/lib/types/analysis-order';
import { AnalysisOrder } from '~/lib/types/order';
function OrderConfirmedLoadingWrapper({
medusaOrder: initialMedusaOrder,
@@ -71,7 +71,14 @@ function OrderConfirmedLoadingWrapper({
<PageHeader title={<Trans i18nKey="cart:orderConfirmed.title" />} />
<Divider />
<div className="small:grid-cols-[1fr_360px] grid grid-cols-1 gap-x-40 gap-y-6 lg:px-4">
<OrderDetails order={order} />
<OrderDetails
order={{
id: order.medusa_order_id,
created_at: order.created_at,
location: null,
serviceProvider: null,
}}
/>
<Divider />
<OrderItems medusaOrder={medusaOrder} />
<CartTotals medusaOrder={medusaOrder} />

View File

@@ -60,24 +60,22 @@ export async function HomeMenuNavigation(props: {
</span>
</Card>
{hasCartItems && (
<Button
className="relative mr-0 h-10 cursor-pointer border-1 px-4 py-2"
variant="ghost"
>
<span className="flex items-center text-nowrap">{totalValue}</span>
</Button>
)}
<Link href={pathsConfig.app.cart}>
<Button
variant="ghost"
className="relative mr-0 h-10 cursor-pointer border-1 px-4 py-2"
>
<ShoppingCart className="stroke-[1.5px]" />
<Trans
i18nKey="common:shoppingCartCount"
values={{ count: cartQuantityTotal }}
/>
<Trans i18nKey="common:shoppingCart" />{' '}
{hasCartItems && (
<>
(
<span className="text-success font-bold">
{cartQuantityTotal}
</span>
)
</>
)}
</Button>
</Link>
<UserNotifications userId={user.id} />

View File

@@ -81,6 +81,8 @@ export default function OrderBlock({
items={itemsOther}
title="orders:table.otherOrders"
order={{
medusaOrderId: analysisOrder?.medusa_order_id,
id: analysisOrder?.id,
status: analysisOrder?.status,
}}
/>