@@ -29,7 +29,11 @@ class PaymentMethodService: elif gateway == 'yoo_money': metadata = {'account_number': yookassa_payment_method.account_number} elif gateway == 'sbp': - metadata = {'sbp_operation_id': yookassa_payment_method.sbp_operation_id} + metadata = { + 'sbp_operation_id': yookassa_payment_method.sbp_operation_id, + 'bic': yookassa_payment_method.payer_bank_details.bic, + 'bank_id': yookassa_payment_method.payer_bank_details.bank_id, + } else: metadata = {} payment_method, created = PaymentMethod.objects.update_or_create( @@ -64,7 +68,7 @@ class PaymentMethodService: self.user.email, method.uid, cancel_reason, - method.total_attempts+1, + method.total_attempts + 1, ) return payment_attempt