Migrate to py3

This commit is contained in:
Raimon Esteve 2018-09-15 18:08:37 +02:00
parent 714d39b235
commit cbed57695f
4 changed files with 5 additions and 12 deletions

View File

@ -17,8 +17,7 @@ __all__ = ['Carrier', 'FormulaPriceList']
DIGITS = config_.getint('product', 'price_decimal', default=4)
class Carrier:
__metaclass__ = PoolMeta
class Carrier(metaclass=PoolMeta):
__name__ = 'carrier'
formula_currency = fields.Many2One('currency.currency', 'Currency',
states={

View File

@ -6,8 +6,7 @@ from trytond.pool import PoolMeta
__all__ = ['Sale']
class Sale:
__metaclass__ = PoolMeta
class Sale(metaclass=PoolMeta):
__name__ = 'sale.sale'
def _get_carrier_context(self):

View File

@ -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 = 'carrier_formula'
PREFIX = 'trytonzz'

View File

@ -28,8 +28,7 @@ def _formula_amount(lines, company):
return amount
class ShipmentIn:
__metaclass__ = PoolMeta
class ShipmentIn(metaclass=PoolMeta):
__name__ = 'stock.shipment.in'
def _get_carrier_context(self):
@ -47,8 +46,7 @@ class ShipmentIn:
return context
class ShipmentOut:
__metaclass__ = PoolMeta
class ShipmentOut(metaclass=PoolMeta):
__name__ = 'stock.shipment.out'
def _get_carrier_context(self):