-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
🚀 Adding Create Post Form #91
Conversation
c0749d0
to
e21954e
Compare
Please add an Issue here
|
e21954e
to
9a02232
Compare
Created the issues and edited this PR description to include them. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
9a02232
to
c127152
Compare
f39dbc9
to
8c747bb
Compare
8c747bb
to
246e327
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@paOmer Nice work, I just do not see any client tests in the PR.
When we test View/Form it is not guaranteed the the hole path is not broken
from http request to http response
Setting up the post creation view using django CreateView build-in class. Setting the post author to be the logged in user. Requiring a logged in user in order to create new post. Setting a login url to redirect logged out users.
246e327
to
96a9730
Compare
When using the CreateView class, a get_absolute_url function needs to be created in order for Django to know where to redirect after creation.
96a9730
to
b51b7f6
Compare
b51b7f6
to
be4cce5
Compare
Thanks, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Added a post creation form to let users have the ability to publish posts.
Used django CreateView class.
I tried to not include the post creation html template in this PR in order to not include UI but I had to set a html page for testing purposes.
Future tasks:
Close #92