2014-03-25 16:57:55 +01:00
|
|
|
# The COPYRIGHT file at the top level of this repository contains the full
|
2015-02-14 12:53:17 +01:00
|
|
|
# copyright notices and license terms.
|
2014-03-25 16:57:55 +01:00
|
|
|
|
|
|
|
from trytond.model import fields
|
|
|
|
from trytond.pool import PoolMeta
|
2015-08-31 10:34:14 +02:00
|
|
|
from trytond.pyson import Eval, Bool
|
2014-03-25 16:57:55 +01:00
|
|
|
|
|
|
|
__all__ = ['Party']
|
|
|
|
__metaclass__ = PoolMeta
|
|
|
|
|
|
|
|
GROUPING_PERIODS = [
|
|
|
|
(None, 'Standard'),
|
|
|
|
('biweekly', 'Biweekly'),
|
|
|
|
('monthly', 'Monthly'),
|
|
|
|
]
|
|
|
|
|
|
|
|
|
|
|
|
class Party:
|
|
|
|
__name__ = 'party.party'
|
|
|
|
|
|
|
|
sale_invoice_grouping_period = fields.Property(fields.Selection(
|
2015-08-31 10:31:26 +02:00
|
|
|
GROUPING_PERIODS, 'Sale Invoice Grouping Period', states={
|
2015-08-31 10:34:14 +02:00
|
|
|
'invisible': ~Bool(Eval('sale_invoice_grouping_method')),
|
2015-08-31 10:31:26 +02:00
|
|
|
}, depends=['sale_invoice_grouping_method']))
|