From b9c9d10dad7473f1a2cd6525860f1f91a1a4a883 Mon Sep 17 00:00:00 2001 From: Alexis de Lattre Date: Mon, 23 May 2016 10:42:28 +0200 Subject: [PATCH] Take into accounts the remarks of Eric Caudal --- account_banking_mandate/README.rst | 7 ++----- account_banking_mandate/__openerp__.py | 3 +-- .../models/account_banking_mandate.py | 10 +++++----- .../models/account_payment_method.py | 2 +- account_banking_mandate/models/res_partner_bank.py | 4 ++-- 5 files changed, 11 insertions(+), 15 deletions(-) diff --git a/account_banking_mandate/README.rst b/account_banking_mandate/README.rst index 2366bc8c8..0fb4974ec 100644 --- a/account_banking_mandate/README.rst +++ b/account_banking_mandate/README.rst @@ -1,6 +1,7 @@ .. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg :alt: License: AGPL-3 +======================= Account Banking Mandate ======================= @@ -46,11 +47,7 @@ Bug Tracker Bugs are tracked on `GitHub Issues `_. In case of trouble, please check there if your issue has already been reported. If you spotted it first, -help us smashing it by providing a detailed and welcomed `feedback -`_. +help us smashing it by providing a detailed and welcomed feedback. Credits ======= diff --git a/account_banking_mandate/__openerp__.py b/account_banking_mandate/__openerp__.py index 76936cef4..864781e95 100644 --- a/account_banking_mandate/__openerp__.py +++ b/account_banking_mandate/__openerp__.py @@ -7,7 +7,7 @@ { 'name': 'Account Banking Mandate', 'summary': 'Banking mandates', - 'version': '9.0.0.2.0', + 'version': '9.0.1.0.0', 'license': 'AGPL-3', 'author': "Compassion CH, " "Serv. Tecnol. Avanzados - Pedro M. Baeza, " @@ -31,7 +31,6 @@ 'security/mandate_security.xml', 'security/ir.model.access.csv', ], - 'demo': [], 'test': ['test/banking_mandate.yml'], 'installable': True, } diff --git a/account_banking_mandate/models/account_banking_mandate.py b/account_banking_mandate/models/account_banking_mandate.py index fbecc4ca8..cd5958d7c 100644 --- a/account_banking_mandate/models/account_banking_mandate.py +++ b/account_banking_mandate/models/account_banking_mandate.py @@ -54,7 +54,7 @@ class AccountBankingMandate(models.Model): _sql_constraints = [( 'mandate_ref_company_uniq', 'unique(unique_mandate_reference, company_id)', - 'A Mandate with the same reference already exists for this company !')] + 'A Mandate with the same reference already exists for this company!')] @api.multi @api.constrains('signature_date', 'last_debit_date') @@ -65,7 +65,7 @@ class AccountBankingMandate(models.Model): mandate)): raise ValidationError( _("The date of signature of mandate '%s' " - "is in the future !") + "is in the future!") % mandate.unique_mandate_reference) if (mandate.signature_date and mandate.last_debit_date and mandate.signature_date > mandate.last_debit_date): @@ -108,7 +108,7 @@ class AccountBankingMandate(models.Model): for mandate in self: if mandate.state != 'draft': raise UserError( - _('Mandate should be in draft state')) + _('Mandate should be in draft state.')) self.write({'state': 'valid'}) return True @@ -117,7 +117,7 @@ class AccountBankingMandate(models.Model): for mandate in self: if mandate.state not in ('draft', 'valid'): raise UserError( - _('Mandate should be in draft or valid state')) + _('Mandate should be in draft or valid state.')) self.write({'state': 'cancel'}) return True @@ -129,6 +129,6 @@ class AccountBankingMandate(models.Model): for mandate in self: if mandate.state != 'cancel': raise UserError( - _('Mandate should be in cancel state')) + _('Mandate should be in cancel state.')) self.write({'state': 'draft'}) return True diff --git a/account_banking_mandate/models/account_payment_method.py b/account_banking_mandate/models/account_payment_method.py index 589506a9c..884365210 100644 --- a/account_banking_mandate/models/account_payment_method.py +++ b/account_banking_mandate/models/account_payment_method.py @@ -10,5 +10,5 @@ class AccountPaymentMethod(models.Model): mandate_required = fields.Boolean( string='Mandate Required', - help="Activate this option is this payment method requires your " + help="Activate this option if this payment method requires your " "customer to sign a direct debit mandate with your company.") diff --git a/account_banking_mandate/models/res_partner_bank.py b/account_banking_mandate/models/res_partner_bank.py index 119d3b4ff..028a1ddb8 100644 --- a/account_banking_mandate/models/res_partner_bank.py +++ b/account_banking_mandate/models/res_partner_bank.py @@ -12,5 +12,5 @@ class ResPartnerBank(models.Model): mandate_ids = fields.One2many( comodel_name='account.banking.mandate', inverse_name='partner_bank_id', string='Direct Debit Mandates', - help='Banking mandates represents an authorization that the bank ' - 'account owner gives to a company for a specific operation') + help='Banking mandates represent an authorization that the bank ' + 'account owner gives to a company for a specific operation.')