20 lines
609 B
Python
20 lines
609 B
Python
# This file is part of Tryton. The COPYRIGHT file at the top level of
|
|
# this repository contains the full copyright notices and license terms.
|
|
|
|
from trytond.model import fields
|
|
from trytond.pool import PoolMeta
|
|
|
|
|
|
class SaleLine(metaclass=PoolMeta):
|
|
__name__ = 'sale.line'
|
|
produced = fields.Boolean('Produced', states={'readonly': True})
|
|
|
|
@classmethod
|
|
def copy(cls, lines, default=None):
|
|
if default is None:
|
|
default = {}
|
|
else:
|
|
default = default.copy()
|
|
default.setdefault('produced', None)
|
|
return super(SaleLine, cls).copy(lines, default)
|