Files
tryton/configuration.py
T

22 lines
876 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.
from trytond.model import ModelView, ModelSQL, ModelSingleton, fields
2011-08-21 11:20:44 +02:00
from trytond.pyson import Eval
class Configuration(ModelSingleton, ModelSQL, ModelView):
2010-04-08 19:03:23 +02:00
'Party Configuration'
_name = 'party.configuration'
2010-04-08 19:03:23 +02:00
_description = __doc__
2010-03-11 16:48:37 +01:00
party_sequence = fields.Property(fields.Many2One('ir.sequence',
2011-08-04 16:57:31 +02:00
'Party Sequence', domain=[
('company', 'in',
2011-08-21 11:20:44 +02:00
[Eval('context', {}).get('company'), False]),
2011-08-04 16:57:31 +02:00
('code', '=', 'party.party'),
], required=True))
2011-03-29 15:17:39 +02:00
party_lang = fields.Property(fields.Many2One("ir.lang", 'Party Language',
help=('The value set on this field will preset the language on new '
'parties')))
Configuration()