|
|
@@ -363,14 +363,24 @@ class CustomLinkForm(ChangelogMessageMixin, OwnerMixin, forms.ModelForm):
|
|
|
'link_text': forms.Textarea(attrs={'class': 'font-monospace'}),
|
|
|
'link_url': forms.Textarea(attrs={'class': 'font-monospace'}),
|
|
|
}
|
|
|
+ # TODO: Remove in NetBox v5.0
|
|
|
help_texts = {
|
|
|
'link_text': _(
|
|
|
"Jinja2 template code for the link text. Reference the object as {example}. Links "
|
|
|
- "which render as empty text will not be displayed."
|
|
|
- ).format(example="<code>{{ object }}</code>"),
|
|
|
+ "which render as empty text will not be displayed. Direct access to the in-memory "
|
|
|
+ "objects ({names}) is deprecated and will be removed in NetBox v5.0."
|
|
|
+ ).format(
|
|
|
+ example="<code>{{ object }}</code>",
|
|
|
+ names="<code>object</code>, <code>user</code>, <code>perms</code>",
|
|
|
+ ),
|
|
|
'link_url': _(
|
|
|
- "Jinja2 template code for the link URL. Reference the object as {example}."
|
|
|
- ).format(example="<code>{{ object }}</code>"),
|
|
|
+ "Jinja2 template code for the link URL. Reference the object as {example}. Direct "
|
|
|
+ "access to the in-memory objects ({names}) is deprecated and will be removed in "
|
|
|
+ "NetBox v5.0."
|
|
|
+ ).format(
|
|
|
+ example="<code>{{ object }}</code>",
|
|
|
+ names="<code>object</code>, <code>user</code>, <code>perms</code>",
|
|
|
+ ),
|
|
|
}
|
|
|
|
|
|
|