Compare commits

..

No commits in common. "51cb82a9ea0ab71a9cb1b6a2190dc6d2a46baf21" and "25672ca40335677e3baa2c9fb8caa118508f1392" have entirely different histories.

View file

@ -144,12 +144,6 @@ class ProblemAdmin(PolymorphicParentModelAdmin):
] ]
# Pokud chceme orezavat na aktualni rocnik, musime do modelu pridat odkaz na rocnik. Zatim bere vse. # Pokud chceme orezavat na aktualni rocnik, musime do modelu pridat odkaz na rocnik. Zatim bere vse.
search_fields = ['nazev'] search_fields = ['nazev']
list_filter = ['stav']
actions = ['vyres_problemy']
@admin.action(description= 'Označit problémy jako vyřešené')
def vyres_problemy(self, req, qs):
qs.update(stav=Problem.STAV_VYRESENY)
# V ProblemAdmin to nejde, protoze se to nepropise do deti # V ProblemAdmin to nejde, protoze se to nepropise do deti