Change assignment text widget to be rich text
Resolves MS-518
This commit is contained in:
parent
dddce52150
commit
34afbbe1be
|
|
@ -0,0 +1,19 @@
|
||||||
|
# Generated by Django 3.2.13 on 2022-06-15 15:40
|
||||||
|
|
||||||
|
from django.db import migrations
|
||||||
|
import wagtail.core.fields
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('assignments', '0013_auto_20210315_2143'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AlterField(
|
||||||
|
model_name='assignment',
|
||||||
|
name='assignment',
|
||||||
|
field=wagtail.core.fields.RichTextField(),
|
||||||
|
),
|
||||||
|
]
|
||||||
|
|
@ -13,7 +13,7 @@ from core.constants import DEFAULT_RICH_TEXT_FEATURES
|
||||||
@register_snippet
|
@register_snippet
|
||||||
class Assignment(index.Indexed, TimeStampedModel):
|
class Assignment(index.Indexed, TimeStampedModel):
|
||||||
title = models.CharField(max_length=255)
|
title = models.CharField(max_length=255)
|
||||||
assignment = models.TextField()
|
assignment = RichTextField(features=DEFAULT_RICH_TEXT_FEATURES)
|
||||||
solution = RichTextField(null=True, blank=True, features=DEFAULT_RICH_TEXT_FEATURES)
|
solution = RichTextField(null=True, blank=True, features=DEFAULT_RICH_TEXT_FEATURES)
|
||||||
deleted = models.BooleanField(default=False)
|
deleted = models.BooleanField(default=False)
|
||||||
owner = models.ForeignKey(get_user_model(),
|
owner = models.ForeignKey(get_user_model(),
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue