.
This commit is contained in:
+18
-1
@@ -1,7 +1,7 @@
|
||||
import django_tables2 as tables
|
||||
from django_tables2.utils import A
|
||||
|
||||
from .models import AnatomyQuestion
|
||||
from .models import AnatomyQuestion, CidUserAnswer
|
||||
|
||||
from django.utils.html import format_html
|
||||
|
||||
@@ -9,6 +9,23 @@ from easy_thumbnails.files import get_thumbnailer
|
||||
|
||||
from easy_thumbnails.exceptions import InvalidImageFormatError
|
||||
|
||||
#from generic.tables import UserAnswerTable
|
||||
|
||||
|
||||
class AnatomyUserAnswerTable(tables.Table):
|
||||
class Meta:
|
||||
model = CidUserAnswer
|
||||
template_name = "django_tables2/bootstrap4.html"
|
||||
fields = (
|
||||
"cid",
|
||||
"question",
|
||||
"answer",
|
||||
#"answer_compare",
|
||||
"exam",
|
||||
"created",
|
||||
"updated",
|
||||
)
|
||||
|
||||
|
||||
class ImageColumn(tables.Column):
|
||||
def render(self, value):
|
||||
|
||||
Reference in New Issue
Block a user