添加对公转账提示
This commit is contained in:
parent
d412986b29
commit
359f6cb387
@ -11,7 +11,8 @@ import {
|
|||||||
Radio,
|
Radio,
|
||||||
Spin,
|
Spin,
|
||||||
Upload, UploadProps,
|
Upload, UploadProps,
|
||||||
Tag
|
Tag,
|
||||||
|
Modal
|
||||||
} from "antd";
|
} from "antd";
|
||||||
import {
|
import {
|
||||||
ReloadOutlined
|
ReloadOutlined
|
||||||
@ -65,6 +66,8 @@ interface IPaymentProps {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export default function Payment(props: IPaymentProps) {
|
export default function Payment(props: IPaymentProps) {
|
||||||
|
// 支付完成弹窗
|
||||||
|
const [paymentModal, setPaymentModal] = useState(false)
|
||||||
const [mask, setMask] = useState(false)
|
const [mask, setMask] = useState(false)
|
||||||
const [form] = Form.useForm<FormFieldType>();
|
const [form] = Form.useForm<FormFieldType>();
|
||||||
const [messageApi, messageApiContext] = useMessage();
|
const [messageApi, messageApiContext] = useMessage();
|
||||||
@ -230,7 +233,7 @@ export default function Payment(props: IPaymentProps) {
|
|||||||
setIsRechargeMoneyEdit(false)
|
setIsRechargeMoneyEdit(false)
|
||||||
getPay()
|
getPay()
|
||||||
}} color="volcano">400</Tag>
|
}} color="volcano">400</Tag>
|
||||||
<Tag style={{ cursor: 'pointer' }} onClick={() => {
|
<Tag style={{ cursor: 'pointer' }} onClick={() => {
|
||||||
form.setFieldValue('rechargeMoney', 500);
|
form.setFieldValue('rechargeMoney', 500);
|
||||||
setIsRechargeMoneyEdit(false)
|
setIsRechargeMoneyEdit(false)
|
||||||
getPay()
|
getPay()
|
||||||
@ -440,28 +443,29 @@ export default function Payment(props: IPaymentProps) {
|
|||||||
name="basic"
|
name="basic"
|
||||||
form={form}
|
form={form}
|
||||||
onFinish={() => {
|
onFinish={() => {
|
||||||
post<any>({
|
setPaymentModal(true)
|
||||||
messageApi,
|
// post<any>({
|
||||||
url: `/api/pay/pay-account-recharge/${accountRechargeId}`,
|
// messageApi,
|
||||||
body: {
|
// url: `/api/pay/pay-account-recharge/${accountRechargeId}`,
|
||||||
thirdParty: form.getFieldValue('thirdParty'),
|
// body: {
|
||||||
rechargeMoney: form.getFieldValue('rechargeMoney'),
|
// thirdParty: form.getFieldValue('thirdParty'),
|
||||||
orgName: thirdParty == ThirdPartyEnum.DGZZ ? form.getFieldValue('orgName') : '',
|
// rechargeMoney: form.getFieldValue('rechargeMoney'),
|
||||||
orgBank: thirdParty == ThirdPartyEnum.DGZZ ? form.getFieldValue('orgBank') : '',
|
// orgName: thirdParty == ThirdPartyEnum.DGZZ ? form.getFieldValue('orgName') : '',
|
||||||
orgNumber: thirdParty == ThirdPartyEnum.DGZZ ? form.getFieldValue('orgNumber') : '',
|
// orgBank: thirdParty == ThirdPartyEnum.DGZZ ? form.getFieldValue('orgBank') : '',
|
||||||
rechargeFinalTime: thirdParty == ThirdPartyEnum.DGZZ ? form.getFieldValue('rechargeFinalTime') : '',
|
// orgNumber: thirdParty == ThirdPartyEnum.DGZZ ? form.getFieldValue('orgNumber') : '',
|
||||||
rechargeVoucher: thirdParty == ThirdPartyEnum.DGZZ ? rechargeVoucherArray.join(',') : '',
|
// rechargeFinalTime: thirdParty == ThirdPartyEnum.DGZZ ? form.getFieldValue('rechargeFinalTime') : '',
|
||||||
},
|
// rechargeVoucher: thirdParty == ThirdPartyEnum.DGZZ ? rechargeVoucherArray.join(',') : '',
|
||||||
onBefore() {
|
// },
|
||||||
setIsLoading(true);
|
// onBefore() {
|
||||||
},
|
// setIsLoading(true);
|
||||||
onSuccess() {
|
// },
|
||||||
props.handleConfirm();
|
// onSuccess() {
|
||||||
},
|
// props.handleConfirm();
|
||||||
onFinally() {
|
// },
|
||||||
setIsLoading(false);
|
// onFinally() {
|
||||||
}
|
// setIsLoading(false);
|
||||||
});
|
// }
|
||||||
|
// });
|
||||||
}}
|
}}
|
||||||
autoComplete="off"
|
autoComplete="off"
|
||||||
>
|
>
|
||||||
@ -500,6 +504,46 @@ export default function Payment(props: IPaymentProps) {
|
|||||||
</Form>
|
</Form>
|
||||||
</Spin>
|
</Spin>
|
||||||
{messageApiContext}
|
{messageApiContext}
|
||||||
|
<Modal title="提示"
|
||||||
|
okText="确定"
|
||||||
|
cancelText="取消"
|
||||||
|
open={paymentModal}
|
||||||
|
okButtonProps={{
|
||||||
|
style: {
|
||||||
|
backgroundColor: 'var(--color-primary)', // 设置背景颜色
|
||||||
|
},
|
||||||
|
}}
|
||||||
|
onOk={() => {
|
||||||
|
post<any>({
|
||||||
|
messageApi,
|
||||||
|
url: `/api/pay/pay-account-recharge/${accountRechargeId}`,
|
||||||
|
body: {
|
||||||
|
thirdParty: form.getFieldValue('thirdParty'),
|
||||||
|
rechargeMoney: form.getFieldValue('rechargeMoney'),
|
||||||
|
orgName: thirdParty == ThirdPartyEnum.DGZZ ? form.getFieldValue('orgName') : '',
|
||||||
|
orgBank: thirdParty == ThirdPartyEnum.DGZZ ? form.getFieldValue('orgBank') : '',
|
||||||
|
orgNumber: thirdParty == ThirdPartyEnum.DGZZ ? form.getFieldValue('orgNumber') : '',
|
||||||
|
rechargeFinalTime: thirdParty == ThirdPartyEnum.DGZZ ? form.getFieldValue('rechargeFinalTime') : '',
|
||||||
|
rechargeVoucher: thirdParty == ThirdPartyEnum.DGZZ ? rechargeVoucherArray.join(',') : '',
|
||||||
|
},
|
||||||
|
onBefore() {
|
||||||
|
setIsLoading(true);
|
||||||
|
},
|
||||||
|
onSuccess() {
|
||||||
|
props.handleConfirm();
|
||||||
|
},
|
||||||
|
onFinally() {
|
||||||
|
setIsLoading(false);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}}
|
||||||
|
onCancel={() => {
|
||||||
|
setPaymentModal(false);
|
||||||
|
}}>
|
||||||
|
<div style={{display:'flex',alignItems:'center',justifyContent:'center',padding:10}}>
|
||||||
|
<div style={{ fontSize: 20, fontWeight: 700 }}>确定对公转账<span style={{color:'red'}}>¥<span style={{fontSize:30}}>{form.getFieldValue('rechargeMoney')}</span></span> 吗?不确定请修改金额。</div>
|
||||||
|
</div>
|
||||||
|
</Modal>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user