Files
tryton/product.py
T

16 lines
525 B
Python
Raw Normal View History

#This file is part of Tryton. The COPYRIGHT file at the top level of
#this repository contains the full copyright notices and license terms.
2012-09-24 22:18:22 +02:00
from trytond.model import fields
2012-05-29 18:12:23 +02:00
from trytond.pyson import Eval
2012-09-24 22:18:22 +02:00
from trytond.pool import PoolMeta
__all__ = ['Product']
__metaclass__ = PoolMeta
2012-09-24 22:18:22 +02:00
class Product:
__name__ = 'product.product'
locations = fields.One2Many('stock.product.location', 'product',
2012-05-29 18:12:23 +02:00
'Default Locations', states={
'invisible': ~Eval('type').in_(['goods', 'assets']),
})