From 95ab87723f036a932ac43fd381fb7ad9b5451e99 Mon Sep 17 00:00:00 2001 From: Alex Cheung Date: Thu, 25 Sep 2025 02:06:19 +0800 Subject: [PATCH] update check public date --- src/pages/PublicNotice/ApplyForm/PublicNoticeApplyForm.js | 4 ++-- src/pages/PublicNotice/ApplyForm/index.js | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/pages/PublicNotice/ApplyForm/PublicNoticeApplyForm.js b/src/pages/PublicNotice/ApplyForm/PublicNoticeApplyForm.js index b3ed9de..ae90f5d 100644 --- a/src/pages/PublicNotice/ApplyForm/PublicNoticeApplyForm.js +++ b/src/pages/PublicNotice/ApplyForm/PublicNoticeApplyForm.js @@ -21,7 +21,7 @@ import { isDummyLoggedIn, // isCreditorLoggedIn, checkIsOnlyOnlinePaymentByIssueDate, - checkIsOnlyOnlinePaymentApply, + // checkIsOnlyOnlinePaymentApply, } from "utils/Utils"; import { useNavigate } from "react-router-dom"; @@ -583,7 +583,7 @@ const PublicNoticeApplyForm = ({ loadedData, _selections, gazetteIssueList }) => aria-label={intl.formatMessage({ id: 'applyPublicNotice' })} variant="contained" type="submit" - disabled={checkIsOnlyOnlinePaymentApply(tickAccept)} + disabled={!tickAccept} > diff --git a/src/pages/PublicNotice/ApplyForm/index.js b/src/pages/PublicNotice/ApplyForm/index.js index b5ed6a6..6bb3654 100644 --- a/src/pages/PublicNotice/ApplyForm/index.js +++ b/src/pages/PublicNotice/ApplyForm/index.js @@ -81,10 +81,10 @@ const ApplyForm = () => { setSelection(selection); } else { let selection = []; - if (checkIsOnlyOnlinePayment()){ - for (let i = 0; i < response.gazetteIssueList.length; i++) { - let data = response.gazetteIssueList[i]; - // only add if false + for (let i = 0; i < response.gazetteIssueList.length; i++) { + let data = response.gazetteIssueList[i]; + // only add if false + if (checkIsOnlyOnlinePayment()){ if (!checkIsOnlyOnlinePaymentByIssueDate(data.issueDate)) { selection.push(