Update smart_linking dynamic title handling using ModelAttribute class
This commit is contained in:
@@ -10,6 +10,10 @@ from .models import SmartLink, SmartLinkCondition
|
||||
|
||||
|
||||
class SmartLinkForm(forms.ModelForm):
|
||||
def __init__(self, *args, **kwargs):
|
||||
super(SmartLinkForm, self).__init__(*args, **kwargs)
|
||||
self.fields['dynamic_title'].help_text = ' '.join([self.fields['dynamic_title'].help_text, ModelAttribute.help_text_for(Document, type_names=['field', 'related', 'property'])])
|
||||
|
||||
class Meta:
|
||||
fields = ('title', 'dynamic_title', 'enabled')
|
||||
model = SmartLink
|
||||
|
||||
Reference in New Issue
Block a user