Allow filtering by payment provider in order search

This commit is contained in:
Raphael Michel
2017-10-18 13:53:11 +02:00
parent 2f13fa79ba
commit e57ab7f030
4 changed files with 64 additions and 24 deletions

View File

@@ -50,6 +50,17 @@ class BasePaymentProvider:
def __str__(self):
return self.identifier
@property
def is_meta(self) -> bool:
"""
Returns whether or whether not this payment provider is a "meta" payment provider that only
works as a settings holder for other payment providers and should never be used directly. This
is a trick to implement payment gateways with multiple payment methods but unified payment settings.
Take a look at the built-in stripe provider to see how this might be used.
By default, this returns ``False``.
"""
return False
@property
def is_enabled(self) -> bool:
"""