From 6ded560e267fbf59ec179246483c2b8aab8e6a61 Mon Sep 17 00:00:00 2001 From: Jimmy Liow <18777396951@163.com> Date: Tue, 16 May 2023 11:00:54 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A2=84=E8=A7=88=E5=AE=9E=E9=99=85=E8=AE=A1?= =?UTF-8?q?=E5=88=92=E5=92=8C=E6=8E=A5=E6=9C=BA=E7=89=8C=E6=96=87=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/reservation/Detail.jsx | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/src/views/reservation/Detail.jsx b/src/views/reservation/Detail.jsx index bc49ad5..be5f3c7 100644 --- a/src/views/reservation/Detail.jsx +++ b/src/views/reservation/Detail.jsx @@ -50,16 +50,18 @@ function Detail() { const [dataLoading, setDataLoading] = useState(false); const { notification } = App.useApp(); const { reservationId } = useParams(); - const { reservationStore } = useStore(); + const { authStore, reservationStore } = useStore(); const { reservationDetail, confirmationList } = reservationStore; - + const { login } = authStore; + const officeWebViewerUrl = + 'https://view.officeapps.live.com/op/embed.aspx?wdPrint=1&wdHideGridlines=0&wdHideComments=1&wdEmbedCode=0&src='; const reservationUrl = - 'https://view.officeapps.live.com/op/embed.aspx?wdPrint=1&wdHideGridlines=0&wdHideComments=1&wdEmbedCode=0&src=' + - encodeURIComponent('https://www.chinahighlights.com/public/reservationW220420009.doc'); - + `https://p9axztuwd7x8a7.mycht.cn/service-fileServer/DownloadPlanDoc?GRI_SN=${reservationId}&VEI_SN=${login.travelAgencyId}FileType=1`; const nameCardUrl = - 'https://view.officeapps.live.com/op/embed.aspx?wdPrint=false&wdHideGridlines=true&wdHideComments=true&src=' + - encodeURIComponent('https://www.chinahighlights.com/public/W220420009.doc'); + `https://p9axztuwd7x8a7.mycht.cn/service-fileServer/DownloadPlanDoc?GRI_SN=${reservationId}&VEI_SN=${login.travelAgencyId}FileType=2`; + + const reservationPreviewUrl = officeWebViewerUrl + encodeURIComponent(reservationUrl); + const nameCardPreviewUrl = officeWebViewerUrl + encodeURIComponent(nameCardUrl); const showConfirmModal = (confirm) => { setIsModalOpen(true); @@ -123,10 +125,10 @@ function Detail() { - + - +