Odoo Mindscape. Understand Odoo faster. Explore modules, fields, dependencies and version differences in one place instead of digging through the source code.

Module: Companyweb

Entity: res.partner

Compute Method: _compute_cweb_show_button_address

Inputs Method Outputs
"""for the button to be show
        the partner has have cweb_address enabled and data for the address field"""
for rec in self:
            if (
                rec.cweb_address_enable
                and rec.cweb_street
                and rec.cweb_zip
                and rec.cweb_city
                and rec.cweb_country
            ):
                rec.cweb_show_button_address = True
            else:
                rec.cweb_show_button_address = False

Back to entity