Bladeren bron

Merge branch 'Paging_Enhancement' of https://git.2fi-solutions.com/alex/PNSPS-frontend-MaterialUI into Paging_Enhancement

master
Jason Chuang 1 jaar geleden
bovenliggende
commit
4f6d5630e1
5 gewijzigde bestanden met toevoegingen van 17 en 15 verwijderingen
  1. +11
    -9
      src/auth/index.js
  2. +1
    -1
      src/pages/Payment/FPS/AckPage.js
  3. +2
    -2
      src/pages/Payment/PaymentCallback.js
  4. +1
    -1
      src/pages/PublicNotice/Search_GLD/DataGrid.js
  5. +2
    -2
      src/pages/PublicNotice/Search_Mark_As_Paid_GLD/DataGrid.js

+ 11
- 9
src/auth/index.js Bestand weergeven

@@ -92,11 +92,12 @@ export const handleLogoutFunction = () => {
localStorage.removeItem('webtoken')
localStorage.removeItem('transactionid')
//localStorage.removeItem(config.storageUserRoleKeyName)
localStorage.removeItem('expiredAlertShown')
localStorage.removeItem(refreshIntervalName)
localStorage.removeItem(windowCount)
localStorage.removeItem(predictProductionQty)
localStorage.removeItem(predictUsageCount)
setTimeout(()=> localStorage.removeItem("expiredAlertShown"), 5000)
// setTimeout(()=> localStorage.removeItem("expiredAlertShown"), 5000)
}
}

@@ -161,9 +162,10 @@ export const SetupAxiosInterceptors = () => {
});
} else {
if (error.response.status === 401) {
await dispatch(handleLogoutFunction());
await navigate('/login');
await window.location.reload();
if (localStorage.getItem("expiredAlertShown") === null) {
localStorage.setItem("expiredAlertShown", true)
alert("登入驗證已過期,請重新登入。")
}
}
// ** if (status === 401) {
@@ -181,11 +183,11 @@ export const SetupAxiosInterceptors = () => {
// }
// }
// if (localStorage.getItem("expiredAlertShown")) {
// await dispatch(handleLogoutFunction());
// await navigate('/login');
// await window.location.reload();
// }
if (localStorage.getItem("expiredAlertShown")) {
await dispatch(handleLogoutFunction());
await navigate('/login');
await window.location.reload();
}

if (error.response.status === 500){
//setIsUploading(false);


+ 1
- 1
src/pages/Payment/FPS/AckPage.js Bestand weergeven

@@ -165,7 +165,7 @@ const AckPage = () => {
const local = locale
HttpUtils.fileDownload({
// url: UrlUtils.GEN_PAYMENT_RECEIPT+"/"+localStorage.getItem("paymentId")+"/"+local,
url: UrlUtils.GEN_PAYMENT_RECEIPT+"/"+paymentData.data.id+"/"+local,
url: UrlUtils.GEN_PAYMENT_RECEIPT+"/"+paymentData.id+"/"+local,
onResponse:()=>{
setOnDownload(false)
},


+ 2
- 2
src/pages/Payment/PaymentCallback.js Bestand weergeven

@@ -160,10 +160,10 @@ const Index = () => {
// window.print();
setOnDownload(true)
const local = locale
// console.log(local)
console.log(local)
HttpUtils.fileDownload({
// url: UrlUtils.GEN_PAYMENT_RECEIPT+"/"+localStorage.getItem("paymentId")+"/"+local,
url: UrlUtils.GEN_PAYMENT_RECEIPT+"/"+paymentData.data.id+"/"+local,
url: UrlUtils.GEN_PAYMENT_RECEIPT+"/"+paymentData.id+"/"+local,
onResponse:()=>{
setOnDownload(false)
},


+ 1
- 1
src/pages/PublicNotice/Search_GLD/DataGrid.js Bestand weergeven

@@ -95,7 +95,7 @@ export default function SearchPublicNoticeTable({ searchCriteria }) {
{
id: 'contactPerson',
field: 'contactPerson',
headerName: 'Client / Payment Method',
headerName: 'Client / Payment Means',
sortable: false,
minWidth: 250,
flex: 2,


+ 2
- 2
src/pages/PublicNotice/Search_Mark_As_Paid_GLD/DataGrid.js Bestand weergeven

@@ -77,7 +77,7 @@ export default function SearchPublicNoticeTable({ searchCriteria }) {
company = params.row.contactPerson
}
return <div>
{company}
{params?.value}<br />{company}
</div>;
}
},
@@ -99,7 +99,7 @@ export default function SearchPublicNoticeTable({ searchCriteria }) {
{
id: 'paymentMethod',
field: 'paymentMethod',
headerName: 'Payment Method',
headerName: 'Payment Means',
sortable: false,
minWidth: 250,
flex: 2,


Laden…
Annuleren
Opslaan