except ImportError, e:
import simplejson as json
+from htsworkflow.frontend.auth import require_api_key
from htsworkflow.frontend.experiments.models import FlowCell
from htsworkflow.frontend.samples.changelist import ChangeList
from htsworkflow.frontend.samples.models import Library
info['library_type'] = lib.library_type.name
return info
-@login_required
def library_json(request, library_id):
"""
Return a json formatted library dictionary
"""
+ require_api_key(request)
# what validation should we do on library_id?
lib = library_dict(library_id)
lib_json = json.dumps(lib)
return HttpResponse(lib_json, mimetype='application/json')
+
+def species_json(request, species_id):
+ """
+ Return information about a species.
+ """
+ raise Http404
@login_required
def user_profile(request):
context.update(SAMPLES_CONTEXT_DEFAULTS)
return render_to_response('registration/profile.html', context,
context_instance=RequestContext(request))
+