updated document upload according to fresh api

This commit is contained in:
Arseni
2026-03-04 18:07:08 +03:00
parent aff804ec58
commit c59538869b
12 changed files with 122 additions and 53 deletions

View File

@@ -65,7 +65,15 @@ class _PaymentDetailsView extends StatelessWidget {
payment: payment,
onBack: () => _handleBack(context),
onDownloadAct: controller.canDownload
? () => downloadPaymentAct(context, payment.paymentRef ?? '')
? () {
final request = controller.primaryOperationDocumentRequest;
if (request == null) return;
downloadPaymentAct(
context,
gatewayService: request.gatewayService,
operationRef: request.operationRef,
);
}
: null,
canDownloadOperationDocument:
controller.canDownloadOperationDocument,
@@ -74,7 +82,7 @@ class _PaymentDetailsView extends StatelessWidget {
if (request == null) return;
downloadPaymentAct(
context,
request.paymentRef,
gatewayService: request.gatewayService,
operationRef: request.operationRef,
);
},