Migrate to py3
This commit is contained in:
parent
0f52298115
commit
69ade72909
14
api.py
14
api.py
|
@ -1,23 +1,15 @@
|
|||
# This file is part of the carrier_send_shipments_seurvalencia module for Tryton.
|
||||
# The COPYRIGHT file at the top level of this repository contains the full
|
||||
# copyright notices and license terms.
|
||||
import logging
|
||||
from trytond.pool import PoolMeta
|
||||
from trytond.pyson import Eval, Not, Equal
|
||||
import logging
|
||||
|
||||
try:
|
||||
from seurvalencia.picking import *
|
||||
except ImportError:
|
||||
logger = logging.getLogger(__name__)
|
||||
message = 'Install Seur: pip install seurvalencia'
|
||||
logger.error(message)
|
||||
raise Exception(message)
|
||||
from seurvalencia.picking import *
|
||||
|
||||
__all__ = ['CarrierApi']
|
||||
|
||||
|
||||
class CarrierApi:
|
||||
__metaclass__ = PoolMeta
|
||||
class CarrierApi(metaclass=PoolMeta):
|
||||
__name__ = 'carrier.api'
|
||||
|
||||
@classmethod
|
||||
|
|
|
@ -9,8 +9,7 @@ from base64 import decodestring
|
|||
__all__ = ['CarrierManifest']
|
||||
|
||||
|
||||
class CarrierManifest:
|
||||
__metaclass__ = PoolMeta
|
||||
class CarrierManifest(metaclass=PoolMeta):
|
||||
__name__ = 'carrier.manifest'
|
||||
|
||||
def get_manifest_seurvalencia(self, api, from_date, to_date):
|
||||
|
|
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
|
||||
|
||||
MODULE2PREFIX = {}
|
||||
|
||||
|
|
|
@ -13,8 +13,7 @@ __all__ = ['ShipmentOut']
|
|||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
class ShipmentOut:
|
||||
__metaclass__ = PoolMeta
|
||||
class ShipmentOut(metaclass=PoolMeta):
|
||||
__name__ = 'stock.shipment.out'
|
||||
|
||||
@classmethod
|
||||
|
|
Loading…
Reference in New Issue