mirror of
https://github.com/guohuadeng/app-odoo.git
synced 2025-02-23 04:11:36 +02:00
fix chinese
This commit is contained in:
@@ -7,7 +7,7 @@ from odoo.exceptions import UserError, ValidationError
|
|||||||
class ResPartner(models.Model):
|
class ResPartner(models.Model):
|
||||||
_inherit = 'res.partner'
|
_inherit = 'res.partner'
|
||||||
|
|
||||||
name = fields.Char(translate=True)
|
name = fields.Char(translate=False)
|
||||||
short_name = fields.Char('Short Name') # 简称
|
short_name = fields.Char('Short Name') # 简称
|
||||||
fax = fields.Char('Fax') # 简称
|
fax = fields.Char('Fax') # 简称
|
||||||
|
|
||||||
|
|||||||
@@ -20,6 +20,7 @@
|
|||||||
</xpath>
|
</xpath>
|
||||||
<xpath expr="//page//field[@name='child_ids']//form[1]//field[@name='name']" position="attributes">
|
<xpath expr="//page//field[@name='child_ids']//form[1]//field[@name='name']" position="attributes">
|
||||||
<attribute name="required">1</attribute>
|
<attribute name="required">1</attribute>
|
||||||
|
<attribute name="force_save">1</attribute>
|
||||||
</xpath>
|
</xpath>
|
||||||
<xpath expr="//field[@name='child_ids']//form[1]//field[@name='email']" position="before">
|
<xpath expr="//field[@name='child_ids']//form[1]//field[@name='email']" position="before">
|
||||||
<field name="category_id" widget="many2many_tags"/>
|
<field name="category_id" widget="many2many_tags"/>
|
||||||
@@ -46,24 +47,23 @@
|
|||||||
<field name="model">res.partner</field>
|
<field name="model">res.partner</field>
|
||||||
<field name="priority" eval="900"/>
|
<field name="priority" eval="900"/>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<div class="o_address_format o_address_chinese">
|
<form>
|
||||||
<field name="country_enforce_cities" invisible="1"/>
|
<div class="o_address_format o_address_chinese">
|
||||||
<field name="parent_id" invisible="1"/>
|
<div name="partner_address_country" class="d-flex">
|
||||||
<field name="type" invisible="1"/>
|
<field name="country_id" placeholder="Country" class="o_address_country"
|
||||||
<div name="partner_address_country" class="d-flex">
|
options='{"no_open": True, "no_create": True}'/>
|
||||||
<field name="country_id" placeholder="Country" class="o_address_country"
|
<field name="zip" placeholder="ZIP" class="o_address_zip"/>
|
||||||
options="{"no_open": True, "no_create": True}"/>
|
</div>
|
||||||
<field name="zip" placeholder="ZIP" class="o_address_zip"/>
|
<field name="state_id" class="o_address_state" placeholder="State" options='{"no_open": True, "no_create": True}'
|
||||||
|
context="{'country_id': country_id, 'default_country_id': country_id, 'zip': zip}"/>
|
||||||
|
<field name="city_id" placeholder="City" class="o_address_city"
|
||||||
|
options='{"no_open": True, "no_create": True}'
|
||||||
|
context="{'default_country_id': country_id, 'default_state_id': state_id,}"/>
|
||||||
|
<field name="city" placeholder="City" invisible="1"/>
|
||||||
|
<field name="street" placeholder="Street..." class="o_address_street"/>
|
||||||
|
<field name="street2" placeholder="Street 2..." class="o_address_street"/>
|
||||||
</div>
|
</div>
|
||||||
<field name="state_id" class="o_address_state" placeholder="State" options='{"no_open": True, "no_create": True}'
|
</form>
|
||||||
context="{'country_id': country_id, 'default_country_id': country_id, 'zip': zip}"/>
|
|
||||||
<field name="city_id" placeholder="City" class="o_address_city"
|
|
||||||
options='{"no_open": True, "no_create": True}'
|
|
||||||
context="{'default_country_id': country_id, 'default_state_id': state_id,}"/>
|
|
||||||
<field name="city" placeholder="City" invisible="1"/>
|
|
||||||
<field name="street" placeholder="Street..." class="o_address_street"/>
|
|
||||||
<field name="street2" placeholder="Street 2..." class="o_address_street"/>
|
|
||||||
</div>
|
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user