Remove Party Language configuration
The Party language is now a property for which the default value is no more managed by default method. Also it is probably better to leave the field empty if user doesn't know than having a default value set like that a choice can be done at run time. issue5198 review20111002
This commit is contained in:
1 parent
4ae1f36378
commit
c8fd86722d
3 files changed
-12
No files matched your search
@@ -13,6 +13,3 @@ class Configuration(ModelSingleton, ModelSQL, ModelView):
|
||||
'Party Sequence', domain=[
|
||||
('code', '=', 'party.party'),
|
||||
]))
|
||||
party_lang = fields.Property(fields.Many2One("ir.lang", 'Party Language',
|
||||
help=('The value set on this field will preset the language on new '
|
||||
'parties')))
|
||||
@@ -115,13 +115,6 @@ class Party(ModelSQL, ModelView):
|
||||
'write_uid', 'write_date'))
|
||||
return [Address.default_get(fields_names)]
|
||||
|
||||
@staticmethod
|
||||
def default_lang():
|
||||
Configuration = Pool().get('party.configuration')
|
||||
config = Configuration(1)
|
||||
if config.party_lang:
|
||||
return config.party_lang.id
|
||||
|
||||
@staticmethod
|
||||
def default_code_readonly():
|
||||
Configuration = Pool().get('party.configuration')
|
||||
|
||||
@@ -4,6 +4,4 @@ this repository contains the full copyright notices and license terms. -->
|
||||
<form string="Party Configuration">
|
||||
<label name="party_sequence"/>
|
||||
<field name="party_sequence"/>
|
||||
<label name="party_lang" />
|
||||
<field name="party_lang" widget="selection" />
|
||||
</form>
|
||||
Reference in new issue
Block a user