[19.0][ADD] partner_display_ref - #2384
Open
JasminSForgeFlow wants to merge 1 commit into
Open
Conversation
1 task
JasminSForgeFlow
force-pushed
the
19.0-add-partner_display_ref
branch
from
June 8, 2026 07:33
eae6529 to
7dea9cc
Compare
1 task
ChristianSantamaria
approved these changes
Jun 8, 2026
ChristianSantamaria
left a comment
Contributor
There was a problem hiding this comment.
Only review code LGTM 👍
JasminSForgeFlow
force-pushed
the
19.0-add-partner_display_ref
branch
from
June 10, 2026 04:57
7dea9cc to
be56841
Compare
| def _compute_display_name(self): | ||
| super()._compute_display_name() | ||
| ctx = self.env.context | ||
| field_name = ctx.get("partner_display_ref_field") |
Contributor
There was a problem hiding this comment.
Maybe a little explanation on why computing the value on context value in this case ?
Author
There was a problem hiding this comment.
For now, this case OCA/purchase-workflow#3094
and for the same kind of case where the field name is different, to handle it with any particular app
luisDIXMIT
approved these changes
Jul 8, 2026
luisDIXMIT
left a comment
There was a problem hiding this comment.
Code review and tested locally, LGTM!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This module prefixes the customer reference (
res.partner.ref) to a partner'sdisplay_namewhenever it is rendered inside an opted-in view — typically as[C00123] Acme Corpin an autocomplete dropdown.The decoration is a generic mechanism: it activates only when a view injects
the
partner_display_ref_fieldcontext key naming the field to prefix on ares.partnerfield. Contacts, CRM,Invoicing and any other view that does not opt in continue to see the plain
partner name. Companion modules (e.g.
sale_partner_display_ref) wire thismechanism into specific apps.
@ForgeFlow