Migarte to python 3
This commit is contained in:
parent
852a77eccd
commit
ad769b4ad8
4
setup.py
4
setup.py
|
@ -4,7 +4,7 @@
|
|||
from setuptools import setup
|
||||
import re
|
||||
import os
|
||||
import ConfigParser
|
||||
import configparser
|
||||
|
||||
MODULE = 'stock_shipment_prevent_cancel'
|
||||
PREFIX = 'nantic'
|
||||
|
@ -24,7 +24,7 @@ def get_require_version(name):
|
|||
major_version, minor_version + 1)
|
||||
return require
|
||||
|
||||
config = ConfigParser.ConfigParser()
|
||||
config = configparser.ConfigParser()
|
||||
config.readfp(open('tryton.cfg'))
|
||||
info = dict(config.items('tryton'))
|
||||
for key in ('depends', 'extras_depend', 'xml'):
|
||||
|
|
|
@ -6,8 +6,7 @@ from trytond.pyson import Eval
|
|||
__all__ = ['ShipmentIn', 'ShipmentOut']
|
||||
|
||||
|
||||
class ShipmentIn:
|
||||
__metaclass__ = PoolMeta
|
||||
class ShipmentIn(metaclass=PoolMeta):
|
||||
__name__ = 'stock.shipment.in'
|
||||
|
||||
@classmethod
|
||||
|
@ -17,8 +16,7 @@ class ShipmentIn:
|
|||
cancel['invisible'] |= Eval('state') == 'received'
|
||||
|
||||
|
||||
class ShipmentOut:
|
||||
__metaclass__ = PoolMeta
|
||||
class ShipmentOut(metaclass=PoolMeta):
|
||||
__name__ = 'stock.shipment.out'
|
||||
|
||||
@classmethod
|
||||
|
|
Loading…
Reference in New Issue