Drag 'n Drop Inline Images Backend - View
Review Request #6616 — Created Nov. 21, 2014 and submitted
Information | |
---|---|
dkus | |
Review Board | |
master | |
Reviewers | |
reviewboard, students | |
Part of a set of changes to add support for dragging and dropping images into the markdown editor.
Adding a view that redirects to a FileAttachment's file. Adding a uuid field to the FileAttachment model, to be used by the view as non-guessable identifier for the FileAttachment.
This view can be accessed at the following url: /users/<username>/file-attachments/<uuid>/
All unit tests pass after making the changes.
Did some manual testing to make sure the view properly redirects to the file, and the file can be viewed.
Description | From | Last Updated |
---|---|---|
Since this is a "view", the view_ prefix seems superfluous - maybe just call this user_file_attachment. |
|
|
Isn't the user already available at request.user? |
|
|
We're using single quotes throughout the rest of this file - might as well stick with the convention. Same applies … |
|
|
Why the double $? |
|
|
Might as well just be "user-file-attachment" |
|
|
"URL", "UUID", and "a its" -> "its". |
|
Change Summary:
Updating description.
Description: |
|
---|
-
-
reviewboard/attachments/views.py (Diff revision 1) Since this is a "view", the view_ prefix seems superfluous - maybe just call this user_file_attachment.
-
reviewboard/attachments/views.py (Diff revision 1) Isn't the user already available at request.user?
-
reviewboard/urls.py (Diff revision 1) We're using single quotes throughout the rest of this file - might as well stick with the convention. Same applies with the rest of your changes in here.
-
-

-
Tool: Pyflakes Processed Files: reviewboard/attachments/evolutions/file_attachment_uuid.py reviewboard/attachments/evolutions/__init__.py reviewboard/attachments/views.py reviewboard/attachments/models.py reviewboard/urls.py Tool: PEP8 Style Checker Processed Files: reviewboard/attachments/evolutions/file_attachment_uuid.py reviewboard/attachments/evolutions/__init__.py reviewboard/attachments/views.py reviewboard/attachments/models.py reviewboard/urls.py

-
Tool: Pyflakes Processed Files: reviewboard/attachments/evolutions/file_attachment_uuid.py reviewboard/attachments/evolutions/__init__.py reviewboard/attachments/views.py reviewboard/attachments/models.py reviewboard/urls.py Tool: PEP8 Style Checker Processed Files: reviewboard/attachments/evolutions/file_attachment_uuid.py reviewboard/attachments/evolutions/__init__.py reviewboard/attachments/views.py reviewboard/attachments/models.py reviewboard/urls.py