Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
AE UTBM
Sith
Commits
1ebfcded
Commit
1ebfcded
authored
Jun 02, 2017
by
Krophil
Browse files
fix topic creation
parent
3521ad69
Pipeline
#1012
passed with stage
in 4 minutes and 12 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
forum/views.py
View file @
1ebfcded
...
...
@@ -155,7 +155,7 @@ class ForumTopicCreateView(CanCreateMixin, CreateView):
return
super
(
ForumTopicCreateView
,
self
).
dispatch
(
request
,
*
args
,
**
kwargs
)
def
form_valid
(
self
,
form
):
topic
=
ForumTopic
(
title
=
form
.
instance
.
title
,
author
=
self
.
request
.
user
,
forum
=
self
.
forum
)
topic
=
ForumTopic
(
_
title
=
form
.
instance
.
title
,
author
=
self
.
request
.
user
,
forum
=
self
.
forum
)
topic
.
save
()
form
.
instance
.
topic
=
topic
form
.
instance
.
author
=
self
.
request
.
user
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment