changed create campus dunc to send mails

This commit is contained in:
Aran Zaiger 2015-06-15 19:10:38 +03:00
parent 4d49e93d8c
commit 59663af67d

View file

@ -20,6 +20,7 @@ from models.Campus import Campus
#Validation Utils Libs #Validation Utils Libs
from SE_API.Validation_Utils import * from SE_API.Validation_Utils import *
from SE_API.Respones_Utils import * from SE_API.Respones_Utils import *
from SE_API.Email_Utils import *
@ -78,11 +79,10 @@ def create_campus(token):
except Exception: except Exception:
return bad_request() return bad_request()
db.put(campus)
db.save send_create_campus_request(user.email, user.name, campus.title)
return Response(response=campus.to_JSON(), notify_se_hub_campus_request(campus, campus.title)
status=201, return ok()
mimetype="application/json")