26 lines
946 B
Python
Executable File
26 lines
946 B
Python
Executable File
import django_tables2 as tables
|
|
from django_tables2.utils import A
|
|
|
|
from .models import Rapid
|
|
|
|
|
|
class RapidTable(tables.Table):
|
|
edit = tables.LinkColumn('rapids:rapid_update',
|
|
text='Edit',
|
|
args=[A('pk')],
|
|
orderable=False)
|
|
view = tables.LinkColumn('rapids:rapid_detail',
|
|
text='View',
|
|
args=[A('pk')],
|
|
orderable=False)
|
|
clone = tables.LinkColumn('rapids:rapid_clone',
|
|
text='Clone',
|
|
args=[A('pk')],
|
|
orderable=False)
|
|
|
|
class Meta:
|
|
model = Rapid
|
|
template_name = "django_tables2/bootstrap4.html"
|
|
fields = ("normal", "abnormality", "region", "examination",
|
|
"laterality", "site", "created_date", "author")
|
|
sequence = ("view", ) |