[IMP] partner_gogocarto_export_api: refactor partner form view
This commit is contained in:
@@ -8,7 +8,7 @@
|
|||||||
),
|
),
|
||||||
'website': 'https://lokavaluto.fr',
|
'website': 'https://lokavaluto.fr',
|
||||||
'category': 'Localization',
|
'category': 'Localization',
|
||||||
'version': '12.0.1.0.0',
|
'version': '12.0.1.1.0',
|
||||||
'depends': [
|
'depends': [
|
||||||
'base',
|
'base',
|
||||||
'contacts',
|
'contacts',
|
||||||
|
@@ -7,7 +7,7 @@ class ResPartner(models.Model):
|
|||||||
""" Inherits partner, adds Gogocarto fields in the partner form, and functions"""
|
""" Inherits partner, adds Gogocarto fields in the partner form, and functions"""
|
||||||
_inherit = 'res.partner'
|
_inherit = 'res.partner'
|
||||||
|
|
||||||
in_gogocarto = fields.Boolean('In gogocarto')
|
in_gogocarto = fields.Boolean('Export to Gogocarto')
|
||||||
|
|
||||||
def _get_gogocarto_domain(self, company_id):
|
def _get_gogocarto_domain(self, company_id):
|
||||||
# To OVERRIDE in sub_modules to customize the partner selection
|
# To OVERRIDE in sub_modules to customize the partner selection
|
||||||
|
@@ -6,8 +6,21 @@
|
|||||||
<field name="inherit_id" ref="base.view_partner_form" />
|
<field name="inherit_id" ref="base.view_partner_form" />
|
||||||
<field name='priority'>99</field>
|
<field name='priority'>99</field>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<xpath expr="//field[@name='function']" position="after">
|
<xpath expr="//page[@name='geo_location']" position="replace">
|
||||||
|
<page name="gogocarto" string="Gogocarto">
|
||||||
|
<group colspan="2" col="2">
|
||||||
|
<separator string="Geolocation" colspan="2" />
|
||||||
|
<button
|
||||||
|
string="Geolocate"
|
||||||
|
name="geo_localize"
|
||||||
|
colspan="2"
|
||||||
|
icon="fa-check"
|
||||||
|
type="object" />
|
||||||
|
<field name="partner_latitude" />
|
||||||
|
<field name="partner_longitude" />
|
||||||
<field name="in_gogocarto" />
|
<field name="in_gogocarto" />
|
||||||
|
</group>
|
||||||
|
</page>
|
||||||
</xpath>
|
</xpath>
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
Reference in New Issue
Block a user