done btn logic
This commit is contained in:
@@ -4,13 +4,13 @@ import styles from "./OrderDetails.module.css";
|
|||||||
import ProHeader from "components/ProHeader/ProHeader";
|
import ProHeader from "components/ProHeader/ProHeader";
|
||||||
import { useTranslation } from "react-i18next";
|
import { useTranslation } from "react-i18next";
|
||||||
|
|
||||||
import { useParams } from "react-router-dom";
|
import { useNavigate, useParams } from "react-router-dom";
|
||||||
import ProductChoicesCard from "components/productChoicesCard/ProductChoicesCard.tsx";
|
import ProductChoicesCard from "components/productChoicesCard/ProductChoicesCard.tsx";
|
||||||
|
|
||||||
export default function OrderDetails() {
|
export default function OrderDetails() {
|
||||||
const { orderId } = useParams();
|
const { orderId } = useParams();
|
||||||
const { t } = useTranslation();
|
const { t } = useTranslation();
|
||||||
|
const navigate = useNavigate();
|
||||||
const { data: orderDetails } = useGetOrderDetailsQuery(
|
const { data: orderDetails } = useGetOrderDetailsQuery(
|
||||||
{
|
{
|
||||||
orderID: orderId || "",
|
orderID: orderId || "",
|
||||||
@@ -42,7 +42,7 @@ export default function OrderDetails() {
|
|||||||
type="primary"
|
type="primary"
|
||||||
shape="round"
|
shape="round"
|
||||||
className={styles.button}
|
className={styles.button}
|
||||||
onClick={() => {}}
|
onClick={() => navigate(-1)}
|
||||||
>
|
>
|
||||||
{t("order.done")}
|
{t("order.done")}
|
||||||
</Button>
|
</Button>
|
||||||
|
|||||||
Reference in New Issue
Block a user