def METHOD_NAME(self, vals):
    if not self._context.get("copy_pos_config") and "name" not in vals:
        for pos in self:
            sequence = pos.l10n_es_simplified_invoice_sequence_id
            sequence.check_simplified_invoice_unique_prefix()
    if "name" in vals:
        prefix = self.l10n_es_simplified_invoice_prefix.replace(
            self.name, vals["name"]
        )
        if prefix != self.l10n_es_simplified_invoice_prefix:
            self.l10n_es_simplified_invoice_sequence_id.update(
                {
                    "prefix": prefix,
                    "name": (
                        self.l10n_es_simplified_invoice_sequence_id.name.replace(
                            self.name, vals["name"]
                        )
                    ),
                }
            )
    return super().METHOD_NAME(vals)