aboutsummaryrefslogtreecommitdiff
path: root/wqflask/wqflask/collect.py
diff options
context:
space:
mode:
Diffstat (limited to 'wqflask/wqflask/collect.py')
-rw-r--r--wqflask/wqflask/collect.py14
1 files changed, 13 insertions, 1 deletions
diff --git a/wqflask/wqflask/collect.py b/wqflask/wqflask/collect.py
index e5c24873..2a94e63d 100644
--- a/wqflask/wqflask/collect.py
+++ b/wqflask/wqflask/collect.py
@@ -225,4 +225,16 @@ def view_collection():
else:
return render_template("collections/view.html",
**collection_info
- ) \ No newline at end of file
+ )
+
+@app.route("/collections/change_name", methods=('POST',))
+def change_collection_name():
+ params = request.form
+
+ collection_id = params['collection_id']
+ new_name = params['new_name']
+
+ g.user_session.change_collection_name(collection_id, new_name)
+
+ return new_name
+