feat(PaymentReceivePdf): payment pdf preview.

This commit is contained in:
elforjani13
2022-01-11 14:34:41 +02:00
parent dd7d11ffb7
commit 1656691940
7 changed files with 128 additions and 5 deletions

View File

@@ -62,6 +62,11 @@ function PaymentReceiveActionsBar({
openDialog('notify-payment-via-sms', { paymentReceiveId });
};
// Handle print payment receive.
const handlePrintPaymentReceive = () => {
openDialog('payment-pdf-preview', { paymentReceiveId });
};
return (
<DrawerActionsBar>
<NavbarGroup>
@@ -74,6 +79,14 @@ function PaymentReceiveActionsBar({
/>
<NavbarDivider />
</Can>
<Can I={PaymentReceiveAction.View} a={AbilitySubject.PaymentReceive}>
<Button
className={Classes.MINIMAL}
icon={<Icon icon="print-16" />}
text={<T id={'print'} />}
onClick={handlePrintPaymentReceive}
/>
</Can>
<Can I={PaymentReceiveAction.Delete} a={AbilitySubject.PaymentReceive}>
<Button
className={Classes.MINIMAL}