diff --git a/tasks/forms.py b/tasks/forms.py index eef1f93..14e7c93 100644 --- a/tasks/forms.py +++ b/tasks/forms.py @@ -1,6 +1,7 @@ from datetime import datetime from django import forms +from markdownx.widgets import MarkdownxWidget from .models import Event @@ -8,6 +9,9 @@ class EventForm(forms.ModelForm): class Meta: model = Event fields = ['date', 'user', 'notes'] + widgets = { + 'notes': MarkdownxWidget(attrs={'rows': 2}), + } def __init__(self, *args, **kwargs): user = kwargs.pop('user') diff --git a/tasks/templates/tasks/taskDetail.djhtml b/tasks/templates/tasks/taskDetail.djhtml index 7203700..d98e121 100644 --- a/tasks/templates/tasks/taskDetail.djhtml +++ b/tasks/templates/tasks/taskDetail.djhtml @@ -82,7 +82,7 @@ {% csrf_token %}