20 Commits

Author SHA1 Message Date
cfdv
78c0744077 Merge remote-tracking branch 'origin/master' into is315 2011-06-20 12:50:44 -05:00
cfdv
0bf340727e enables entering user details including website url and bio
fixes usage of objects. still need to display the data on user page
2011-06-18 21:30:56 -05:00
cfdv
630b57a366 baby step towards enabling profile edits
adds
* url and bio fields to database
* form for editing the user profile
* route to the edit profile controller
* view for the profile editing page
* template for the profile editing page
* link to edit profile in the welcome page

still needs
* thorough inspection to see if it makes sense
* tests
* ?
2011-06-18 16:42:22 -05:00
Joar Wandborg
44e51d3464 Made changes according to http://bugs.foocorp.net/issues/363#note-5 2011-06-15 23:07:54 +02:00
Joar Wandborg
44e2da2fe6 Added Markdown rendering for media_entry 2011-06-12 03:24:31 +02:00
Christopher Allan Webber
9038c9f9ac I have a strong preference for aligning all parameters in a function call. 2011-06-05 15:41:08 -05:00
Elrond
9150244afa Create redirect shortcut and use it around
This is just replacing exc.HTTPFound(location=request.urlgen(...))
by redirect(request, ...). No magic.
2011-06-05 16:16:03 +02:00
Elrond
c9c2493435 Reformat render_to_response calls
Just a simple indentation and ordering change, no
functional change.
2011-06-05 16:16:03 +02:00
Elrond
1c63ad5d35 Create render_to_reponse and use it everywhere.
Just a shortcut for Response(render_template(...))
2011-06-05 16:16:03 +02:00
Christopher Allan Webber
b5d3aec615 Moving all views over to using util.render_template()! 2011-06-04 17:36:36 -05:00
Christopher Allan Webber
a1556d3f49 Mount media editing under /u/{username}/m/{media}/edit/ 2011-06-04 08:50:25 -05:00
Christopher Allan Webber
8ee83b4333 Let's redirect back to the media homepage using the slug instead of the id 2011-06-04 08:48:17 -05:00
Christopher Allan Webber
747623cc04 I shouldn't have removed the .save() entirely :) 2011-06-04 07:41:31 -05:00
Christopher Allan Webber
d5e90fe4b4 Find out if such a slug exists via a query instead of via a .save() call 2011-06-03 18:43:08 -05:00
Elrond
9bfe1d8e12 Add GNU headers to new *.py 2011-06-02 18:28:26 +02:00
Elrond
0732236e9c Handle Exceptions from save(); Move may_edit_media
Turn .save() excpetions into a HTTPConflict. Not nice, but
at least the user gets the error.  Until there is a proper
way to validate things and get nice errors.

Move may_edit_media() to lib.py, as it's not a view.
2011-06-02 17:43:54 +02:00
Elrond
8cd5d4f8c3 Prepare for moving /edit/ under /u/.../edit/
To make moving the whole thing under /u/ easier, prepare to
pass in the {user} needed for that.
2011-06-02 16:48:15 +02:00
Elrond
c849e69092 Check for edit permission.
You need to own the media, or be an admin to use the edit form.
As simple as that, for now.
2011-06-02 14:26:53 +02:00
Elrond
98857207cc "edit": Finally implement saving.
Currently no checks. Probably not so good.
And especially, every logged in user currently can edit the
data for any other user's media.
2011-05-27 00:17:30 +02:00
Elrond
aba81c9f20 Starting "edit" functionality.
This adds a link to the "edit" form, the form, the view for
displaying the form and that's about it.
2011-05-26 23:09:33 +02:00