Show the available variable in the help text

Signed-off-by: Roberto Rosario <roberto.rosario@mayan-edms.com>
This commit is contained in:
Roberto Rosario
2019-12-10 22:31:08 -04:00
parent 1ee449d894
commit 913e57a010
3 changed files with 9 additions and 3 deletions

View File

@@ -19,6 +19,7 @@ class DocumentTemplateSandboxForm(forms.Form):
self.model_variable = kwargs.pop('model_variable')
super(DocumentTemplateSandboxForm, self).__init__(*args, **kwargs)
self.fields['template'] = TemplateField(
initial_help_text=_('The template string to be evaluated.'),
label=_('Template'), model=self.model,
model_variable=self.model_variable, required=False
)