|
@@ -81,9 +81,9 @@ const FormPanel = ({ formData }) => { |
|
|
} |
|
|
} |
|
|
let pm = paymentMethod; |
|
|
let pm = paymentMethod; |
|
|
if (!isDummyLoggedIn()) { |
|
|
if (!isDummyLoggedIn()) { |
|
|
if (actionValue==true && pm == "demandNote") { |
|
|
|
|
|
|
|
|
if (actionValue == true && pm == "demandNote") { |
|
|
pm = isOverDnReviseDeadline() ? "" : pm; |
|
|
pm = isOverDnReviseDeadline() ? "" : pm; |
|
|
} else if (actionValue==true && pm == "office") { |
|
|
|
|
|
|
|
|
} else if (actionValue == true && pm == "office") { |
|
|
pm = isOverNpgoReviseDeadline() ? "" : pm; |
|
|
pm = isOverNpgoReviseDeadline() ? "" : pm; |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
@@ -121,16 +121,16 @@ const FormPanel = ({ formData }) => { |
|
|
files: attachments ? attachments : [], |
|
|
files: attachments ? attachments : [], |
|
|
onSuccess: function (responseData) { |
|
|
onSuccess: function (responseData) { |
|
|
console.log(responseData) |
|
|
console.log(responseData) |
|
|
if (responseData.success === false){ |
|
|
|
|
|
navigate("/publicNotice/"+responseData.id); |
|
|
|
|
|
}else{ |
|
|
|
|
|
|
|
|
if (responseData.success === false) { |
|
|
|
|
|
navigate("/publicNotice/" + responseData.id); |
|
|
|
|
|
} else { |
|
|
if (responseData.msg) { |
|
|
if (responseData.msg) { |
|
|
setWarningTitle(intl.formatMessage({ id: "attention" })) |
|
|
setWarningTitle(intl.formatMessage({ id: "attention" })) |
|
|
setWarningText(intl.formatMessage({ id: responseData.msg })); |
|
|
setWarningText(intl.formatMessage({ id: responseData.msg })); |
|
|
setIsWarningPopUp(true); |
|
|
setIsWarningPopUp(true); |
|
|
return; |
|
|
return; |
|
|
} |
|
|
} |
|
|
if (actionValue== true && responseData.id == params.id) { |
|
|
|
|
|
|
|
|
if (actionValue == true && responseData.id == params.id) { |
|
|
notifyActionSuccess(intl.formatMessage({ id: "submitted" })) |
|
|
notifyActionSuccess(intl.formatMessage({ id: "submitted" })) |
|
|
navigate("/proof/pay/" + params.id); |
|
|
navigate("/proof/pay/" + params.id); |
|
|
} else { |
|
|
} else { |
|
@@ -396,125 +396,137 @@ const FormPanel = ({ formData }) => { |
|
|
</tr> |
|
|
</tr> |
|
|
</table> |
|
|
</table> |
|
|
</Grid> : |
|
|
</Grid> : |
|
|
<Grid item xs={12} sx={{ mb: 1, }}> |
|
|
|
|
|
<table style={tabelStyle}> |
|
|
|
|
|
<tr style={tabelStyle}> |
|
|
|
|
|
<th style={tabelStyle} width="50" align="left"></th> |
|
|
|
|
|
<th style={tabelStyle} width="300" align="left"><FormattedMessage id="paymentMeans" /></th> |
|
|
|
|
|
<th style={tabelStyle} width="300" align="left"><FormattedMessage id="confirmingDealine" /></th> |
|
|
|
|
|
<th style={tabelStyle} width="400" align="left"><FormattedMessage id="PaymentCoonpletDealine" /></th> |
|
|
|
|
|
</tr> |
|
|
|
|
|
<tr> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
<Checkbox |
|
|
|
|
|
checked={paymentMethod == "online"} |
|
|
|
|
|
onChange={() => { |
|
|
|
|
|
set_paymentMethod("online") |
|
|
|
|
|
}} |
|
|
|
|
|
/> |
|
|
|
|
|
</td> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
<FormattedMessage id="payOnline" /> |
|
|
|
|
|
<br /><a href="#payOnlineDetails" color='#fff' onClick={() => { |
|
|
|
|
|
setWarningTitle(intl.formatMessage({ id: "payOnline" })) |
|
|
|
|
|
setWarningText( |
|
|
|
|
|
<><FormattedMessage id="paymentMethodMeans" /> |
|
|
|
|
|
<ul> |
|
|
|
|
|
<li><FormattedMessage id="fps" /></li> |
|
|
|
|
|
<li><FormattedMessage id="card" /></li> |
|
|
|
|
|
<li><FormattedMessage id="pps" /></li> |
|
|
|
|
|
</ul> |
|
|
|
|
|
</> |
|
|
|
|
|
); |
|
|
|
|
|
setIsWarningPopUp(true); |
|
|
|
|
|
}}><FormattedMessage id="viewDetail" /></a> |
|
|
|
|
|
</td> |
|
|
|
|
|
<td style={tabelStyle}>{DateUtils.dateFormat(formData.proofPaymentDeadline, intl.formatMessage({ id: "paymentMethodDatetimeStrFormat" }))?.replace("am", "a.m.")?.replace("pm", "p.m.")}</td> |
|
|
|
|
|
<td style={tabelStyle}>{DateUtils.dateFormat(formData.expiryDate, intl.formatMessage({ id: "paymentMethodDatetimeStrFormat" }))?.replace("am", "a.m.")?.replace("pm", "p.m.")}</td> |
|
|
|
|
|
</tr> |
|
|
|
|
|
<tr> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
{isOverDnReviseDeadline() ? |
|
|
|
|
|
<></> : |
|
|
|
|
|
|
|
|
<> |
|
|
|
|
|
<Grid item xs={12} sx={{ mb: 1, }}> |
|
|
|
|
|
<table style={tabelStyle}> |
|
|
|
|
|
<tr style={tabelStyle}> |
|
|
|
|
|
<th style={tabelStyle} width="50" align="left"></th> |
|
|
|
|
|
<th style={tabelStyle} width="300" align="left"><FormattedMessage id="paymentMeans" /></th> |
|
|
|
|
|
<th style={tabelStyle} width="300" align="left"><FormattedMessage id="confirmingDealine" /></th> |
|
|
|
|
|
<th style={tabelStyle} width="400" align="left"><FormattedMessage id="PaymentCoonpletDealine" /></th> |
|
|
|
|
|
</tr> |
|
|
|
|
|
<tr> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
<Checkbox |
|
|
<Checkbox |
|
|
checked={paymentMethod == "demandNote"} |
|
|
|
|
|
|
|
|
checked={paymentMethod == "online"} |
|
|
onChange={() => { |
|
|
onChange={() => { |
|
|
set_paymentMethod("demandNote") |
|
|
|
|
|
|
|
|
set_paymentMethod("online") |
|
|
}} |
|
|
}} |
|
|
/> |
|
|
/> |
|
|
} |
|
|
|
|
|
</td> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
<FormattedMessage id="payDn" /> |
|
|
|
|
|
<br /><a href="#payOnlineDetails" color='#fff' onClick={() => { |
|
|
|
|
|
setWarningTitle(intl.formatMessage({ id: "payDn" })) |
|
|
|
|
|
setWarningText( |
|
|
|
|
|
<><FormattedMessage id="paymentMethodMeans" /> |
|
|
|
|
|
<ul> |
|
|
|
|
|
<li><FormattedMessage id="atm" /></li> |
|
|
|
|
|
<li><FormattedMessage id="pps" /></li> |
|
|
|
|
|
<li><FormattedMessage id="eBank" /></li> |
|
|
|
|
|
<li><FormattedMessage id="phoneBank" /></li> |
|
|
|
|
|
<li><FormattedMessage id="eCheque" /></li> |
|
|
|
|
|
<li><FormattedMessage id="fps" /></li> |
|
|
|
|
|
<li><FormattedMessage id="hkpo" /></li> |
|
|
|
|
|
<li><FormattedMessage id="store" /></li> |
|
|
|
|
|
<li><FormattedMessage id="post" /></li> |
|
|
|
|
|
</ul> |
|
|
|
|
|
</> |
|
|
|
|
|
); |
|
|
|
|
|
setIsWarningPopUp(true); |
|
|
|
|
|
}}><FormattedMessage id="viewDetail" /></a> |
|
|
|
|
|
</td> |
|
|
|
|
|
|
|
|
|
|
|
<td style={tabelStyle}>{DateUtils.dateFormat(formData.closingDateOff, intl.formatMessage({ id: "dateStrFormat" }))} 5:00 p.m.</td> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
<FormattedMessage id="payDnRemark" values={{ |
|
|
|
|
|
date: DateUtils.dateFormat(formData.closingDate, intl.formatMessage({ id: "dateStrFormat" })) + " 12:00 p.m." |
|
|
|
|
|
}} /> |
|
|
|
|
|
</td> |
|
|
|
|
|
</tr> |
|
|
|
|
|
|
|
|
|
|
|
<tr> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
{ |
|
|
|
|
|
isOverNpgoReviseDeadline() ? |
|
|
|
|
|
|
|
|
</td> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
<FormattedMessage id="payOnline" /> |
|
|
|
|
|
<br /><a href="#payOnlineDetails" color='#fff' onClick={() => { |
|
|
|
|
|
setWarningTitle(intl.formatMessage({ id: "payOnline" })) |
|
|
|
|
|
setWarningText( |
|
|
|
|
|
<><FormattedMessage id="paymentMethodMeans" /> |
|
|
|
|
|
<ul> |
|
|
|
|
|
<li><FormattedMessage id="fps" /></li> |
|
|
|
|
|
<li><FormattedMessage id="card" /></li> |
|
|
|
|
|
<li><FormattedMessage id="pps" /></li> |
|
|
|
|
|
</ul> |
|
|
|
|
|
</> |
|
|
|
|
|
); |
|
|
|
|
|
setIsWarningPopUp(true); |
|
|
|
|
|
}}><FormattedMessage id="viewDetail" /></a> |
|
|
|
|
|
</td> |
|
|
|
|
|
<td style={tabelStyle}>{DateUtils.dateFormat(formData.proofPaymentDeadline, intl.formatMessage({ id: "paymentMethodDatetimeStrFormat" }))?.replace("am", "a.m.")?.replace("pm", "p.m.")}</td> |
|
|
|
|
|
<td style={tabelStyle}>{DateUtils.dateFormat(formData.expiryDate, intl.formatMessage({ id: "paymentMethodDatetimeStrFormat" }))?.replace("am", "a.m.")?.replace("pm", "p.m.")}</td> |
|
|
|
|
|
</tr> |
|
|
|
|
|
<tr> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
{isOverDnReviseDeadline() ? |
|
|
<></> : |
|
|
<></> : |
|
|
<Checkbox |
|
|
<Checkbox |
|
|
checked={paymentMethod == "office"} |
|
|
|
|
|
|
|
|
checked={paymentMethod == "demandNote"} |
|
|
onChange={() => { |
|
|
onChange={() => { |
|
|
set_paymentMethod("office") |
|
|
|
|
|
|
|
|
set_paymentMethod("demandNote") |
|
|
}} |
|
|
}} |
|
|
/> |
|
|
/> |
|
|
} |
|
|
|
|
|
</td> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
<FormattedMessage id="payNPGO" /> |
|
|
|
|
|
<br /><a href="#payOnlineDetails" color='#fff' onClick={() => { |
|
|
|
|
|
setWarningTitle(intl.formatMessage({ id: "payNPGO" })) |
|
|
|
|
|
setWarningText( |
|
|
|
|
|
<><FormattedMessage id="paymentMethodMeans" /> |
|
|
|
|
|
<ul> |
|
|
|
|
|
<li><FormattedMessage id="cheque" /></li> |
|
|
|
|
|
<li><FormattedMessage id="cash" /></li> |
|
|
|
|
|
</ul> |
|
|
|
|
|
</> |
|
|
|
|
|
); |
|
|
|
|
|
setIsWarningPopUp(true); |
|
|
|
|
|
}}><FormattedMessage id="viewDetail" /></a> |
|
|
|
|
|
</td> |
|
|
|
|
|
<td style={tabelStyle}>{DateUtils.dateFormat(formData.closingDate, intl.formatMessage({ id: "dateStrFormat" }))} 12:00 p.m.</td> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
<FormattedMessage id="payNPGORemark" values={{ |
|
|
|
|
|
date: DateUtils.dateFormat(formData.closingDate, intl.formatMessage({ id: "dateStrFormat" })) + " 12:30 p.m." |
|
|
|
|
|
}} /> |
|
|
|
|
|
</td> |
|
|
|
|
|
</tr> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</table> |
|
|
|
|
|
</Grid> |
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
</td> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
<FormattedMessage id="payDn" /> |
|
|
|
|
|
<br /><a href="#payOnlineDetails" color='#fff' onClick={() => { |
|
|
|
|
|
setWarningTitle(intl.formatMessage({ id: "payDn" })) |
|
|
|
|
|
setWarningText( |
|
|
|
|
|
<><FormattedMessage id="paymentMethodMeans" /> |
|
|
|
|
|
<ul> |
|
|
|
|
|
<li><FormattedMessage id="atm" /></li> |
|
|
|
|
|
<li><FormattedMessage id="pps" /></li> |
|
|
|
|
|
<li><FormattedMessage id="eBank" /></li> |
|
|
|
|
|
<li><FormattedMessage id="phoneBank" /></li> |
|
|
|
|
|
<li><FormattedMessage id="eCheque" /></li> |
|
|
|
|
|
<li><FormattedMessage id="fps" /></li> |
|
|
|
|
|
<li><FormattedMessage id="hkpo" /></li> |
|
|
|
|
|
<li><FormattedMessage id="store" /></li> |
|
|
|
|
|
<li><FormattedMessage id="post" /></li> |
|
|
|
|
|
</ul> |
|
|
|
|
|
</> |
|
|
|
|
|
); |
|
|
|
|
|
setIsWarningPopUp(true); |
|
|
|
|
|
}}><FormattedMessage id="viewDetail" /></a> |
|
|
|
|
|
</td> |
|
|
|
|
|
|
|
|
|
|
|
<td style={tabelStyle}>{DateUtils.dateFormat(formData.closingDateOff, intl.formatMessage({ id: "dateStrFormat" }))} 5:00 p.m.</td> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
<FormattedMessage id="payDnRemark" values={{ |
|
|
|
|
|
date: DateUtils.dateFormat(formData.closingDate, intl.formatMessage({ id: "dateStrFormat" })) + " 12:00 p.m." |
|
|
|
|
|
}} /> |
|
|
|
|
|
</td> |
|
|
|
|
|
</tr> |
|
|
|
|
|
|
|
|
|
|
|
<tr> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
{ |
|
|
|
|
|
isOverNpgoReviseDeadline() ? |
|
|
|
|
|
<></> : |
|
|
|
|
|
<Checkbox |
|
|
|
|
|
checked={paymentMethod == "office"} |
|
|
|
|
|
onChange={() => { |
|
|
|
|
|
set_paymentMethod("office") |
|
|
|
|
|
}} |
|
|
|
|
|
/> |
|
|
|
|
|
} |
|
|
|
|
|
</td> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
<FormattedMessage id="payNPGO" /> |
|
|
|
|
|
<br /><a href="#payOnlineDetails" color='#fff' onClick={() => { |
|
|
|
|
|
setWarningTitle(intl.formatMessage({ id: "payNPGO" })) |
|
|
|
|
|
setWarningText( |
|
|
|
|
|
<><FormattedMessage id="paymentMethodMeans" /> |
|
|
|
|
|
<ul> |
|
|
|
|
|
<li><FormattedMessage id="cheque" /></li> |
|
|
|
|
|
<li><FormattedMessage id="cash" /></li> |
|
|
|
|
|
</ul> |
|
|
|
|
|
</> |
|
|
|
|
|
); |
|
|
|
|
|
setIsWarningPopUp(true); |
|
|
|
|
|
}}><FormattedMessage id="viewDetail" /></a> |
|
|
|
|
|
</td> |
|
|
|
|
|
<td style={tabelStyle}>{DateUtils.dateFormat(formData.closingDate, intl.formatMessage({ id: "dateStrFormat" }))} 12:00 p.m.</td> |
|
|
|
|
|
<td style={tabelStyle}> |
|
|
|
|
|
<FormattedMessage id="payNPGORemark" values={{ |
|
|
|
|
|
date: DateUtils.dateFormat(formData.closingDate, intl.formatMessage({ id: "dateStrFormat" })) + " 12:30 p.m." |
|
|
|
|
|
}} /> |
|
|
|
|
|
</td> |
|
|
|
|
|
</tr> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</table> |
|
|
|
|
|
</Grid> |
|
|
|
|
|
<Grid item xs={12}> |
|
|
|
|
|
<Typography variant="h6" height="100%" > |
|
|
|
|
|
<div style={{ padding: 12 }} dangerouslySetInnerHTML={{ __html: intl.formatMessage({ id: "proofNote" }) }} /> |
|
|
|
|
|
</Typography> |
|
|
|
|
|
</Grid> |
|
|
|
|
|
|
|
|
|
|
|
<Grid item xs={12}> |
|
|
|
|
|
<Typography variant="h6" height="100%" > |
|
|
|
|
|
<div style={{ padding: 12 }} dangerouslySetInnerHTML={{ __html: intl.formatMessage({ id: "proofImportant" }) }} /> |
|
|
|
|
|
</Typography> |
|
|
|
|
|
</Grid> |
|
|
|
|
|
</> |
|
|
: |
|
|
: |
|
|
actionValue ? |
|
|
actionValue ? |
|
|
<></> |
|
|
<></> |
|
|