Closes #3580: Render text and URL fields as textareas in the custom link form

This commit is contained in:
Jeremy Stretch 2019-10-09 09:40:24 -04:00
parent 4c677e7fe6
commit 6068b1a275
2 changed files with 5 additions and 0 deletions

View File

@ -12,6 +12,7 @@ v2.6.6 (FUTURE)
* [#1941](https://github.com/netbox-community/netbox/issues/1941) - Add InfiniBand interface types
* [#3259](https://github.com/netbox-community/netbox/issues/3259) - Add `rack` and `site` filters for cables
* [#3563](https://github.com/netbox-community/netbox/issues/3563) - Enable editing of individual DeviceType components
* [#3580](https://github.com/netbox-community/netbox/issues/3580) - Render text and URL fields as textareas in the custom link form
---

View File

@ -86,6 +86,10 @@ class CustomLinkForm(forms.ModelForm):
class Meta:
model = CustomLink
exclude = []
widgets = {
'text': forms.Textarea,
'url': forms.Textarea,
}
help_texts = {
'text': 'Jinja2 template code for the link text. Reference the object as <code>{{ obj }}</code>. Links '
'which render as empty text will not be displayed.',