def METHOD_NAME(self):
    """Write the l10n_br specific functional fields."""
    for company in self:
        state_tax_number_ids = self.env["state.tax.numbers"]
        for ies in company.state_tax_number_ids:
            state_tax_number_ids |= ies
        company.partner_id.state_tax_number_ids = state_tax_number_ids