Changed form modal to use ckeditor
This commit is contained in:
parent
efc1ae42a6
commit
c8360c293d
@ -1,6 +1,8 @@
|
||||
from django.db import models
|
||||
from django.contrib.auth.models import User
|
||||
|
||||
from ckeditor_uploader.fields import RichTextUploadingField
|
||||
|
||||
|
||||
class Thread(models.Model):
|
||||
topic = models.CharField(max_length=255)
|
||||
@ -12,7 +14,7 @@ class Thread(models.Model):
|
||||
class Post(models.Model):
|
||||
topic = models.ForeignKey(Thread)
|
||||
title = models.CharField(max_length=255)
|
||||
question = models.TextField()
|
||||
question = RichTextUploadingField()
|
||||
creator = models.ForeignKey(User)
|
||||
created = models.DateTimeField(auto_now_add=True)
|
||||
|
||||
@ -22,7 +24,7 @@ class Post(models.Model):
|
||||
|
||||
class Comment(models.Model):
|
||||
post = models.ForeignKey(Post)
|
||||
reply = models.TextField()
|
||||
reply = RichTextUploadingField()
|
||||
creator = models.ForeignKey(User)
|
||||
created = models.DateTimeField(auto_now_add=True)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user