fix: always use totalPrice to display roomCharge
This commit is contained in:
@@ -16,8 +16,7 @@ import IconChip from "@/components/TempDesignSystem/IconChip"
|
||||
import useLang from "@/hooks/useLang"
|
||||
|
||||
import { IconForFeatureCode } from "../../utils"
|
||||
import Points from "../Points"
|
||||
import Price from "../Price"
|
||||
import PriceType from "../PriceType"
|
||||
import { hasModifiableRate } from "../utils"
|
||||
import { hasBreakfastPackageFromBookingFlow } from "../utils/hasBreakfastPackage"
|
||||
import { mapRoomDetails } from "../utils/mapRoomDetails"
|
||||
@@ -119,17 +118,18 @@ export default function MultiRoom({
|
||||
const {
|
||||
adults,
|
||||
checkInDate,
|
||||
cheques,
|
||||
childrenAges,
|
||||
confirmationNumber,
|
||||
cancellationNumber,
|
||||
hotelId,
|
||||
roomPoints,
|
||||
roomPrice,
|
||||
packages,
|
||||
rateDefinition,
|
||||
isCancelled,
|
||||
priceType,
|
||||
vouchers,
|
||||
totalPrice,
|
||||
} = multiRoom
|
||||
|
||||
const fromDate = dt(checkInDate).locale(lang)
|
||||
@@ -349,26 +349,15 @@ export default function MultiRoom({
|
||||
})}
|
||||
</p>
|
||||
</Typography>
|
||||
{priceType === "points" ? (
|
||||
<Points points={roomPoints} variant="Body/Paragraph/mdBold" />
|
||||
) : priceType === "voucher" ? (
|
||||
<Typography variant="Body/Paragraph/mdBold">
|
||||
<p>
|
||||
{intl.formatMessage(
|
||||
{
|
||||
defaultMessage: "{count} voucher",
|
||||
},
|
||||
{ count: vouchers }
|
||||
)}
|
||||
</p>
|
||||
</Typography>
|
||||
) : (
|
||||
<Price
|
||||
price={isCancelled ? 0 : roomPrice.perStay.local.price}
|
||||
variant="Body/Paragraph/mdBold"
|
||||
isMember={rateDefinition.isMemberRate}
|
||||
/>
|
||||
)}
|
||||
<PriceType
|
||||
cheques={cheques}
|
||||
isCancelled={isCancelled}
|
||||
priceType={priceType}
|
||||
rateDefinition={rateDefinition}
|
||||
roomPoints={roomPoints}
|
||||
totalPrice={totalPrice}
|
||||
vouchers={vouchers}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user