[FIX] Super call on static methods

This commit is contained in:
mreficent
2018-07-25 12:58:12 +02:00
committed by Don Kendall
parent 56381c70a9
commit 0eeba05a5d
2 changed files with 4 additions and 12 deletions

View File

@@ -7,13 +7,8 @@ from odoo import models
class MassReconcileAdvanced(models.AbstractModel): class MassReconcileAdvanced(models.AbstractModel):
_inherit = 'mass.reconcile.advanced' _inherit = 'mass.reconcile.advanced'
@staticmethod def _selection_columns(self):
def _base_columns(): aml_cols = super(MassReconcileAdvanced, self)._selection_columns()
""" Mandatory columns for move lines queries
An extra column aliased as ``key`` should be defined
in each query."""
aml_cols = super(MassReconcileAdvanced, MassReconcileAdvanced).\
_base_columns()
aml_cols.append('account_move_line.purchase_line_id') aml_cols.append('account_move_line.purchase_line_id')
aml_cols.append('account_move_line.product_id') aml_cols.append('account_move_line.product_id')
return aml_cols return aml_cols

View File

@@ -7,11 +7,8 @@ from odoo import models
class AccountMassReconcileMethod(models.Model): class AccountMassReconcileMethod(models.Model):
_inherit = 'account.mass.reconcile.method' _inherit = 'account.mass.reconcile.method'
@staticmethod def _selection_name(self):
def _get_reconcilation_methods(): methods = super(AccountMassReconcileMethod, self)._selection_name()
methods = super(
AccountMassReconcileMethod, AccountMassReconcileMethod).\
_get_reconcilation_methods()
methods += [ methods += [
('mass.reconcile.advanced.by.purchase.line', ('mass.reconcile.advanced.by.purchase.line',
'Advanced. Product, purchase order line.'), 'Advanced. Product, purchase order line.'),