@@ -13,7 +13,7 @@ import * as UrlUtils from "utils/ApiPathConst"; | |||||
// import { useNavigate } from "react-router-dom"; | // import { useNavigate } from "react-router-dom"; | ||||
// import FpsIcon from "assets/images/icons/fps.svg"; | // import FpsIcon from "assets/images/icons/fps.svg"; | ||||
// import { useLocation } from 'react-router-dom'; | // import { useLocation } from 'react-router-dom'; | ||||
import {paymentPath} from "auth/utils"; | |||||
// import {paymentPath} from "auth/utils"; | |||||
// import {poll} from "utils/Utils"; | // import {poll} from "utils/Utils"; | ||||
import * as DateUtils from "utils/DateUtils" | import * as DateUtils from "utils/DateUtils" | ||||
@@ -50,7 +50,7 @@ const AckPage = () => { | |||||
// const [transactionDate, setTransactionDate] = React.useState(""); | // const [transactionDate, setTransactionDate] = React.useState(""); | ||||
// const [transactionTime, setTransactionTime] = React.useState(""); | // const [transactionTime, setTransactionTime] = React.useState(""); | ||||
const [onReady, setOnReady] = React.useState(false); | const [onReady, setOnReady] = React.useState(false); | ||||
const paymentStatusApi = "/api/payment/status/"; | |||||
// const paymentStatusApi = "/api/payment/status/"; | |||||
const [onDownload, setOnDownload] = React.useState(false); | const [onDownload, setOnDownload] = React.useState(false); | ||||
const intl = useIntl(); | const intl = useIntl(); | ||||
const { locale } = intl; | const { locale } = intl; | ||||
@@ -85,7 +85,7 @@ const AckPage = () => { | |||||
let webtoken = localStorage.getItem("webtoken") | let webtoken = localStorage.getItem("webtoken") | ||||
HttpUtils.post({ | HttpUtils.post({ | ||||
url: paymentPath+paymentStatusApi+transactionid, | |||||
url: UrlUtils.PAYMENT_STATUS_API+transactionid, | |||||
params:{ | params:{ | ||||
"apprefid": transactionid, | "apprefid": transactionid, | ||||
"webtoken": webtoken, | "webtoken": webtoken, | ||||
@@ -7,6 +7,7 @@ import { | |||||
} from '@mui/material'; | } from '@mui/material'; | ||||
import * as React from "react"; | import * as React from "react"; | ||||
import * as HttpUtils from "utils/HttpUtils"; | import * as HttpUtils from "utils/HttpUtils"; | ||||
import * as UrlUtils from "utils/ApiPathConst"; | |||||
import { useNavigate } from "react-router-dom"; | import { useNavigate } from "react-router-dom"; | ||||
import FpsIcon from "assets/images/icons/fps.svg"; | import FpsIcon from "assets/images/icons/fps.svg"; | ||||
import { useLocation } from 'react-router-dom'; | import { useLocation } from 'react-router-dom'; | ||||
@@ -55,7 +56,7 @@ const Index = () => { | |||||
const pasgPath = 'https://sim.fps.payapps.hkicl.com.hk'; //Testing | const pasgPath = 'https://sim.fps.payapps.hkicl.com.hk'; //Testing | ||||
const loadPaymentUrl = "/api/payment/wallet/fps"; | const loadPaymentUrl = "/api/payment/wallet/fps"; | ||||
const cancelPaymentUrl = "/api/payment/cancelpayment"; | const cancelPaymentUrl = "/api/payment/cancelpayment"; | ||||
const paymentStatusApi = "/api/payment/status/"; | |||||
// const paymentStatusApi = "/api/payment/status/"; | |||||
// const payloadUrl = "/api/payment/wallet/fps/enquiryfpspayload/"; | // const payloadUrl = "/api/payment/wallet/fps/enquiryfpspayload/"; | ||||
// const receiverUrl = "/noti-api/payment/payment-notification"; | // const receiverUrl = "/noti-api/payment/payment-notification"; | ||||
@@ -198,7 +199,7 @@ const Index = () => { | |||||
const getPaymentStatus = () => { | const getPaymentStatus = () => { | ||||
if(Object.keys(paymentData).length > 0){ | if(Object.keys(paymentData).length > 0){ | ||||
HttpUtils.post({ | HttpUtils.post({ | ||||
url: paymentPath+paymentStatusApi+paymentData.transactionid, | |||||
url: UrlUtils.PAYMENT_STATUS_API+paymentData.transactionid, | |||||
params:{ | params:{ | ||||
"apprefid": paymentData.transactionid, | "apprefid": paymentData.transactionid, | ||||
"webtoken": paymentData.webtoken, | "webtoken": paymentData.webtoken, | ||||
@@ -47,7 +47,7 @@ const Index = () => { | |||||
// const [transactionTime, setTransactionTime] = React.useState(""); | // const [transactionTime, setTransactionTime] = React.useState(""); | ||||
const [onReady, setOnReady] = React.useState(false); | const [onReady, setOnReady] = React.useState(false); | ||||
const updatePaymentApi = "/api/payment/updatepayment"; | const updatePaymentApi = "/api/payment/updatepayment"; | ||||
const paymentStatusApi = "/api/payment/status/"; | |||||
// const paymentStatusApi = "/api/payment/status/"; | |||||
const intl = useIntl(); | const intl = useIntl(); | ||||
const { locale } = intl; | const { locale } = intl; | ||||
@@ -109,7 +109,7 @@ const Index = () => { | |||||
// ) | // ) | ||||
HttpUtils.post({ | HttpUtils.post({ | ||||
url: paymentPath + paymentStatusApi + transactionid, | |||||
url: UrlUtils.PAYMENT_STATUS_API+transactionid, | |||||
params: { | params: { | ||||
"apprefid": transactionid, | "apprefid": transactionid, | ||||
"webtoken": localStorage.getItem("webtoken"), | "webtoken": localStorage.getItem("webtoken"), | ||||
@@ -158,6 +158,9 @@ export const PAYMENT_TRANSACTION_ID = apiPath+'/payment/api/transaction';//GET | |||||
// export const PAYMENT_STATUS_API = paymentPath+'/api/payment/status/';//POST | // export const PAYMENT_STATUS_API = paymentPath+'/api/payment/status/';//POST | ||||
export const PAYMENT_STATUS_API = apiPath+'/payment/api/status/';//POST | export const PAYMENT_STATUS_API = apiPath+'/payment/api/status/';//POST | ||||
export const LOAD_PAYMENT_URL = apiPath+ "/api/payment/wallet/fps";//POST | |||||
export const CANCEL_PAYMENT_URL = apiPath+ "/api/payment/cancelpayment";//POST | |||||
export const DEMAND_NOTE_PREVIEW = apiPath+'/demandNote/preview';//GET | export const DEMAND_NOTE_PREVIEW = apiPath+'/demandNote/preview';//GET | ||||
export const DEMAND_NOTE_CREATE = apiPath+'/demandNote/create';//POST | export const DEMAND_NOTE_CREATE = apiPath+'/demandNote/create';//POST | ||||
export const DEMAND_NOTE_LIST = apiPath+'/demandNote/list';//GET pub | export const DEMAND_NOTE_LIST = apiPath+'/demandNote/list';//GET pub | ||||