removed CORS setting per api, due to middleware fix from mdoglio

This commit is contained in:
Cameron Dawson 2013-08-06 10:10:58 -07:00
Родитель 62739a22e5
Коммит 1f76bb1914
1 изменённых файлов: 3 добавлений и 3 удалений

Просмотреть файл

@ -91,7 +91,7 @@ class JobsViewSet(viewsets.ViewSet):
page = request.QUERY_PARAMS.get('page', 0)
jm = JobsModel(project)
objs = jm.get_job_list(page, 10)
return Response(objs, headers={"Access-Control-Allow-Origin": "*"})
return Response(objs)
except DatasetNotFoundError as e:
return Response({"message": unicode(e)}, status=404)
except Exception as e: # pragma nocover
@ -149,7 +149,7 @@ class ResultSetViewSet(viewsets.ViewSet):
jm = JobsModel(project)
objs = jm.get_result_set_list(page, 1000)
return Response(objs, headers={"Access-Control-Allow-Origin": "*"})
return Response(objs)
except DatasetNotFoundError as e:
return Response({"message": unicode(e)}, status=404)
except Exception as e: # pragma nocover
@ -195,7 +195,7 @@ class ResultSetViewSet(viewsets.ViewSet):
"warning_level": self.get_warning_level(jobs),
"jobs": jobs
})
return Response(rs, headers={"Access-Control-Allow-Origin": "*"})
return Response(rs)
except DatasetNotFoundError as e:
return Response(
{"message": "No project with name {0}".format(project)},