From c86281b476010907aed769fe57d7176a41fa243b Mon Sep 17 00:00:00 2001 From: Alex Cheung Date: Wed, 3 Jan 2024 16:10:35 +0800 Subject: [PATCH] add receipt --- src/pages/Payment/Details_GLD/index.js | 5 ++++- src/pages/Payment/Details_Public/index.js | 5 ++++- src/utils/ApiPathConst.js | 1 + 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/pages/Payment/Details_GLD/index.js b/src/pages/Payment/Details_GLD/index.js index a0cd8e3..3db673c 100644 --- a/src/pages/Payment/Details_GLD/index.js +++ b/src/pages/Payment/Details_GLD/index.js @@ -53,7 +53,10 @@ const Index = () => { } const doPrint = () => { - window.print(); + // window.print(); + HttpUtils.fileDownload({ + url: UrlUtils.GEN_PAYMENT_RECEIPT+"/"+params.id, + }); }; const loadForm = () => { diff --git a/src/pages/Payment/Details_Public/index.js b/src/pages/Payment/Details_Public/index.js index e5be45b..4beeb56 100644 --- a/src/pages/Payment/Details_Public/index.js +++ b/src/pages/Payment/Details_Public/index.js @@ -54,7 +54,10 @@ const Index = () => { } const doPrint = () => { - window.print(); + // window.print(); + HttpUtils.fileDownload({ + url: UrlUtils.GEN_PAYMENT_RECEIPT+"/"+params.id, + }); }; diff --git a/src/utils/ApiPathConst.js b/src/utils/ApiPathConst.js index a87cd0c..d64407b 100644 --- a/src/utils/ApiPathConst.js +++ b/src/utils/ApiPathConst.js @@ -125,6 +125,7 @@ export const GET_SMART_LOGIN = apiPath+'/smart/login'; //POST //gen report export const GEN_GAZETTE_PROOF = apiPath+'/proof/gazetteProof'; //POST +export const GEN_PAYMENT_RECEIPT = apiPath+'/payment/receipt'; //POST //gen report export const GEN_GFMIS_XML = apiPath+'/gfmis'; //GET \ No newline at end of file