Attention une mise à jour du serveur va être effectuée le vendredi 16 avril entre 12h et 12h30. Cette mise à jour va générer une interruption du service de quelques minutes.

Commit cb9d6dd6 authored by HERBERT Ryan's avatar HERBERT Ryan Committed by Vidjil Team

controllers/ Added route to update info

 This route is designed to be used asynchronously by the browser to
 update a timepoint's info
parent f07e5c53
......@@ -277,3 +277,22 @@ def producer_list():
res = {"producer": producer_list}
return gluon.contrib.simplejson.dumps(res, separators=(',',':'))
def save_info():
sequence_file_id = request.vars["id"]
row = db.sequence_file[sequence_file_id]
if row is not None:
if auth.can_modify_patient(row.patient_id):
row = dict(info = request.vars["info"])
res = {"success": True,
"message": "The changes have been saved"}
res = {"success": False,
"message": "You do not have permission to do that"}
res = {"success": False,
"message": "An error occured"}
return gluon.contrib.simplejson.dumps(res, separators=(',', ':'))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment