mirror of
https://github.com/ae-utbm/sith.git
synced 2026-10-13 06:06:06 +00:00
Compare commits
3
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
86730d4f7a | ||
|
|
6a6ed5462f | ||
|
|
d914fa0658 |
No files matched your search
+2
-5
@@ -346,16 +346,13 @@ class ForumTopicDetailView(CanViewMixin, DetailView):
|
||||
return kwargs
|
||||
|
||||
|
||||
class ForumMessageView(SingleObjectMixin, UserPassesTestMixin, RedirectView):
|
||||
class ForumMessageView(SingleObjectMixin, RedirectView):
|
||||
model = ForumMessage
|
||||
pk_url_kwarg = "message_id"
|
||||
permanent = False
|
||||
|
||||
def test_func(self) -> bool:
|
||||
self.object = self.get_object()
|
||||
return self.request.user.can_view(self.object)
|
||||
|
||||
def get_redirect_url(self, *args, **kwargs):
|
||||
self.object = self.get_object()
|
||||
return self.object.get_url()
|
||||
|
||||
|
||||
|
||||
+1
-1
@@ -40,7 +40,7 @@ dependencies = [
|
||||
"django-countries>=9.1.0,<10.0.0",
|
||||
"dict2xml>=1.7.8,<2.0.0",
|
||||
"Sphinx>=9.1.0,<10", # Used by xapian during installation
|
||||
"tomli>=2.5.0,<3.0.0",
|
||||
"tomli>=2.4.1,<3.0.0",
|
||||
"django-honeypot>=1.3.0,<2",
|
||||
"pydantic-extra-types>=2.11.1,<3.0.0",
|
||||
"ical>=14.2.0",
|
||||
|
||||
Reference in new issue
Block a user