|
|
@ -11,7 +11,6 @@ from django.conf import settings |
|
|
|
|
|
|
|
from seminar.models.tvorba import Cislo, Deadline, Problem, Uloha, aux_generate_filename |
|
|
|
from seminar.models.personalni import Resitel |
|
|
|
from seminar.models.treenode import TreeNode |
|
|
|
from seminar.models.base import SeminarModelBase |
|
|
|
|
|
|
|
|
|
|
@ -242,19 +241,3 @@ class Reseni_Resitele(models.Model): |
|
|
|
def __str__(self): |
|
|
|
return '{} od {}'.format(self.reseni, self.resitel) |
|
|
|
# NOTE: Poteciální DB HOG bez select_related |
|
|
|
|
|
|
|
class ReseniNode(TreeNode): |
|
|
|
class Meta: |
|
|
|
db_table = 'seminar_nodes_otistene_reseni' |
|
|
|
verbose_name = 'Otištěné řešení (Node)' |
|
|
|
verbose_name_plural = 'Otištěná řešení (Node)' |
|
|
|
reseni = models.ForeignKey(Reseni, |
|
|
|
on_delete=models.PROTECT, |
|
|
|
verbose_name = 'reseni') |
|
|
|
|
|
|
|
def aktualizuj_nazev(self): |
|
|
|
self.nazev = "ReseniNode: "+str(self.reseni) |
|
|
|
|
|
|
|
def getOdkazStr(self): |
|
|
|
return str(self.reseni) |
|
|
|
|
|
|
|