summaryrefslogtreecommitdiff
path: root/addons/payment_authorize/models/payment.py
diff options
context:
space:
mode:
Diffstat (limited to 'addons/payment_authorize/models/payment.py')
-rw-r--r--addons/payment_authorize/models/payment.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/addons/payment_authorize/models/payment.py b/addons/payment_authorize/models/payment.py
index d6e08fda0e5..3c89c36b5da 100644
--- a/addons/payment_authorize/models/payment.py
+++ b/addons/payment_authorize/models/payment.py
@@ -19,7 +19,9 @@ _logger = logging.getLogger(__name__)
class PaymentAcquirerAuthorize(models.Model):
_inherit = 'payment.acquirer'
- provider = fields.Selection(selection_add=[('authorize', 'Authorize.Net')])
+ provider = fields.Selection(selection_add=[
+ ('authorize', 'Authorize.Net')
+ ], ondelete={'authorize': 'set default'})
authorize_login = fields.Char(string='API Login Id', required_if_provider='authorize', groups='base.group_user')
authorize_transaction_key = fields.Char(string='API Transaction Key', required_if_provider='authorize', groups='base.group_user')
authorize_signature_key = fields.Char(string='API Signature Key', required_if_provider='authorize', groups='base.group_user')