Migrate to python 3
This commit is contained in:
parent
ce17185b79
commit
292ab6bd40
4
setup.py
4
setup.py
|
@ -4,7 +4,7 @@
|
||||||
from setuptools import setup
|
from setuptools import setup
|
||||||
import re
|
import re
|
||||||
import os
|
import os
|
||||||
import ConfigParser
|
import configparser
|
||||||
|
|
||||||
MODULE = 'sale_shop_trade_info'
|
MODULE = 'sale_shop_trade_info'
|
||||||
PREFIX = 'nantic'
|
PREFIX = 'nantic'
|
||||||
|
@ -14,7 +14,7 @@ MODULE2PREFIX = {}
|
||||||
def read(fname):
|
def read(fname):
|
||||||
return open(os.path.join(os.path.dirname(__file__), fname)).read()
|
return open(os.path.join(os.path.dirname(__file__), fname)).read()
|
||||||
|
|
||||||
config = ConfigParser.ConfigParser()
|
config = configparser.ConfigParser()
|
||||||
config.readfp(open('tryton.cfg'))
|
config.readfp(open('tryton.cfg'))
|
||||||
info = dict(config.items('tryton'))
|
info = dict(config.items('tryton'))
|
||||||
for key in ('depends', 'extras_depend', 'xml'):
|
for key in ('depends', 'extras_depend', 'xml'):
|
||||||
|
|
3
shop.py
3
shop.py
|
@ -5,10 +5,9 @@ from trytond.model import fields
|
||||||
from trytond.pool import PoolMeta
|
from trytond.pool import PoolMeta
|
||||||
|
|
||||||
__all__ = ['Shop']
|
__all__ = ['Shop']
|
||||||
__metaclass__ = PoolMeta
|
|
||||||
|
|
||||||
|
|
||||||
class Shop:
|
class Shop(metaclass=PoolMeta):
|
||||||
__name__ = 'sale.shop'
|
__name__ = 'sale.shop'
|
||||||
|
|
||||||
logo = fields.Binary('Logo')
|
logo = fields.Binary('Logo')
|
||||||
|
|
Loading…
Reference in New Issue