Summary Screen
After a transaction has been processed, a merchant might want to refund or capture it, or send another receipt to their shoppers. The Summary Screen makes these tasks easy to do.
To get started, make sure that you store the
transactionIdentifer
for each transaction in your system. You can access the
transactionIdentifer
in the
completed
callback of the payment method.
Showing the Summary Screen
To show the Summary Screen on the payment terminal, call the
createSummaryViewControllerWithTransactionIdentifier
with your previously stored
transactionIdentifier
:
ui.configuration.summaryFeatures = // Add this line, if you want to offer captures // MPUMposUiConfigurationSummaryFeatureCaptureTransaction | // Remove this line, if you do not want to offer refunds at all MPUMposUiConfigurationSummaryFeatureRefundTransaction | MPUMposUiConfigurationSummaryFeatureSendReceiptViaEmail; UIViewController *viewController = [ui createSummaryViewControllerWithTransactionIdentifier:@"transactionIdentifier" completed:^(UIViewController *controller) { [self dismissViewControllerAnimated:YES completion:NULL]; }]; UINavigationController *modalNav = [[UINavigationController alloc] initWithRootViewController:viewController]; if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone) { modalNav.modalPresentationStyle = UIModalPresentationFullScreen; } else { // on iPad modalNav.modalPresentationStyle = UIModalPresentationFormSheet; } [self presentViewController:modalNav animated:YES completion:NULL];
On the Summary Screen, your merchants can now refund or capture the transaction and email another receipt. If the transaction has already been refunded or captured, the Summary Screen will display this information.
Summary Screen
After a transaction is completed, a merchant might want to refund or capture it, or send another receipt to their shoppers. The Summary Screen makes this very easy to do.
To get started, make sure that you store the
transactionIdentifer
for each transaction in your system. You can access the
transactionIdentifer
in the
onActivityResult
callback of the payment method.
Showing the Summary Screen
To show the Summary Screen on the payment terminal, call the
createTransactionSummaryIntent
with your previously stored
transactionIdentifier
:
ui.getConfiguration().setSummaryFeatures(EnumSet.of( // Add this line, if you do want to offer captures // MposUiConfiguration.SummaryFeature.CAPTURE_TRANSACTION, // Remove this line, if you do not want to offer refunds at all MposUiConfiguration.SummaryFeature.REFUND_TRANSACTION, MposUiConfiguration.SummaryFeature.SEND_RECEIPT_VIA_EMAIL) ); Intent intent = ui.createTransactionSummaryIntent("transactionIdentifier"); startActivityForResult(intent, MposUi.REQUEST_CODE_SHOW_SUMMARY);
On the Summary Screen, your merchants can now refund or capture the transaction and email another receipt. If the transaction has already been refunded or captured, the Summary Screen will display this information.
Check if the Summary Screen was closed:
  1. In the
    onActivityResult
    callback, check for a result of
    RESULT_CODE_SUMMARY_CLOSED
    .
  2. Update your UI, if required.