From 85d43d460be8fd90f0e0468fc631b4e5699bc983 Mon Sep 17 00:00:00 2001 From: Jimmy Liow Date: Mon, 5 Feb 2024 15:43:58 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BD=BF=E7=94=A8=20Link=E3=80=81Location=20?= =?UTF-8?q?=E4=BC=A0=E9=80=92=E5=AF=B9=E8=B1=A1=E5=8F=82=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/Conversations/Components/CustomerProfile.jsx | 3 +++ src/views/OrderFollow.jsx | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/views/Conversations/Components/CustomerProfile.jsx b/src/views/Conversations/Components/CustomerProfile.jsx index 568e053..eb1a11d 100644 --- a/src/views/Conversations/Components/CustomerProfile.jsx +++ b/src/views/Conversations/Components/CustomerProfile.jsx @@ -1,6 +1,7 @@ import { Card, Flex, Avatar, Typography, Radio, Button, Table } from 'antd'; import { useAuthContext } from '@/stores/AuthContext.js'; import { useConversationState } from '@/stores/ConversationContext'; +import { useLocation } from 'react-router-dom' import { HomeOutlined, LoadingOutlined, SettingFilled, SmileOutlined, SyncOutlined, PhoneOutlined, MailOutlined, WhatsAppOutlined, SmileTwoTone } from '@ant-design/icons'; import CreatePayment from './CreatePayment'; @@ -22,6 +23,8 @@ const orderStatus = [ const { Meta } = Card; const CustomerProfile = (({ colisn }) => { + let { state } = useLocation() + console.info(state) console.log('invoke customer profile+++++++++++++++++++++++++++++++++++++++++++++', colisn); const { customerOrderProfile: orderInfo } = useConversationState(); const { loginUser: currentUser } = useAuthContext(); diff --git a/src/views/OrderFollow.jsx b/src/views/OrderFollow.jsx index 237b96a..afd8f2d 100644 --- a/src/views/OrderFollow.jsx +++ b/src/views/OrderFollow.jsx @@ -3,7 +3,7 @@ import { Radio, Row, Col, Select, Space, Switch, Table, Tag } from 'antd' import { memo, useCallback, useEffect, useState } from 'react' -import { NavLink } from 'react-router-dom' +import { Link } from 'react-router-dom' import dayjs from 'dayjs' import { Conditional } from '@/components/Conditional' import { useAuthContext } from '@/stores/AuthContext' @@ -164,7 +164,7 @@ function OrderList({ formValues }) { if (record.buytime > 0) regularText = '(R' + record.buytime + ')' return ( - {text + regularText} + {text + regularText}