Migrate to python 3.
This commit is contained in:
parent
90729a0798
commit
cfdb082549
|
@ -4,8 +4,7 @@
|
|||
from trytond.pool import PoolMeta
|
||||
__all__ = ['Commission']
|
||||
|
||||
class Commission:
|
||||
__metaclass__ = PoolMeta
|
||||
class Commission(metaclass=PoolMeta):
|
||||
__name__ = 'commission'
|
||||
|
||||
@classmethod
|
||||
|
|
|
@ -11,8 +11,7 @@ __all__ = ['Invoice']
|
|||
ZERO = Decimal('0.0')
|
||||
|
||||
|
||||
class Invoice:
|
||||
__metaclass__ = PoolMeta
|
||||
class Invoice(metaclass=PoolMeta):
|
||||
__name__ = 'account.invoice'
|
||||
payment_type_kind = fields.Function(fields.Selection(KINDS,
|
||||
'Kind of payment type',
|
||||
|
|
6
move.py
6
move.py
|
@ -9,8 +9,7 @@ from trytond.transaction import Transaction
|
|||
__all__ = ['Move', 'Line']
|
||||
|
||||
|
||||
class Move:
|
||||
__metaclass__ = PoolMeta
|
||||
class Move(metaclass=PoolMeta):
|
||||
__name__ = 'account.move'
|
||||
|
||||
def cancel(self, default=None):
|
||||
|
@ -18,8 +17,7 @@ class Move:
|
|||
return super(Move, self).cancel(default=default)
|
||||
|
||||
|
||||
class Line:
|
||||
__metaclass__ = PoolMeta
|
||||
class Line(metaclass=PoolMeta):
|
||||
__name__ = 'account.move.line'
|
||||
|
||||
account_kind = fields.Function(fields.Selection([
|
||||
|
|
3
party.py
3
party.py
|
@ -27,8 +27,7 @@ class PartyAccountPaymentType(CompanyValueMixin, ModelSQL):
|
|||
supplier_payment_type = supplier_payment_type
|
||||
|
||||
|
||||
class Party:
|
||||
__metaclass__ = PoolMeta
|
||||
class Party(metaclass=PoolMeta):
|
||||
__name__ = 'party.party'
|
||||
|
||||
customer_payment_type = fields.MultiValue(customer_payment_type)
|
||||
|
|
5
setup.py
5
setup.py
|
@ -7,10 +7,7 @@ from setuptools import setup
|
|||
import re
|
||||
import os
|
||||
import io
|
||||
try:
|
||||
from configparser import ConfigParser
|
||||
except ImportError:
|
||||
from ConfigParser import ConfigParser
|
||||
from configparser import ConfigParser
|
||||
|
||||
MODULE = 'account_payment_type'
|
||||
PREFIX = 'trytonspain'
|
||||
|
|
Loading…
Reference in New Issue