Syrve POS API SDK

Printing a fiscal receipt before order payment

[ v9preview4  v9  ]

Starting from V9Preview4, it is now possible to print a fiscal receipt before order payment: PrintFiscalChequeBeforePaymentOrder.

To print a fiscal receipt before payment, the following conditions must be met:

Also, printing a fiscal receipt before payment is not available for deliveries, except for self-pickup mode.

Before paying for the order PayOrder or before printing a fiscal receipt before payment PrintFiscalChequeBeforePaymentOrder, the notification BeforeProceedOrderPayment will be triggered. If one of the subscribed plugins throws an OperationCanceledException, the addition of the payment will be cancelled.

When printing a fiscal receipt before payment, the order will switch to a non-editable state (status Bill), but the payments will not be processed.

In case of success, the order is marked as fiscalized: IsFiscalizedBeforePayment. All order payments are marked as fiscalized: IsFiscalizedLocally.

In case of an error, the front-end will issue an exception with an error description: PrintFiscalChequeBeforePaymentOrderFailed.

Closing a fiscalized order

A fiscal receipt can be printed only once before payment for an order. Subsequently, the fiscalized order can be closed: PayOrder. At this stage, all unprocessed payments will be completed. If the fiscalized order has been modified, then when executing IOperationService.PayOrder, the following will be printed:

Correction receipt

A fiscalized order is considered modified if at least one of the following conditions is met:

To track the “correction receipt” fiscal operation (for FFD 1.1 and higher), which occurs when paying for a modified fiscalized order, use:

Deleting a fiscalized order

When deleting a fiscalized order, a fiscal return receipt will be printed.

Examples of PrintFiscalChequeBeforePaymentOrder calls can be found in the SDK SamplePaymentPlugin project.