Documentation things.
This commit is contained in:
parent
3717c2b844
commit
0d0f5e2373
@ -51,6 +51,7 @@ MIDDLEWARE = [
|
||||
'django.middleware.csrf.CsrfViewMiddleware',
|
||||
'django.contrib.auth.middleware.AuthenticationMiddleware',
|
||||
'django.contrib.messages.middleware.MessageMiddleware',
|
||||
'django.contrib.admindocs.middleware.XViewMiddleware',
|
||||
# 'django.contrib.auth.middleware.SessionAuthenticationMiddleware',
|
||||
# "django.contrib.flatpages.middleware.FlatpageFallbackMiddleware",
|
||||
# 'django.contrib.messages.middleware.MessageMiddleware',
|
||||
|
@ -28,11 +28,26 @@ def home(request):
|
||||
return render(request, 'yeast/home.html',{})
|
||||
|
||||
def batch(request, batch_id):
|
||||
"""
|
||||
Display a batch of yeast samples.
|
||||
|
||||
``Batch``
|
||||
An instance of :model:`yeast.Batch`.
|
||||
|
||||
``Template``
|
||||
:template:`yeast/batch.html`
|
||||
"""
|
||||
batch = get_object_or_404(Batch, pk=batch_id)
|
||||
return render(request, 'yeast/batch.html', {'batch': batch})
|
||||
|
||||
def batch_labels(request, batch_id):
|
||||
""" Create label PDF for samples in a batch
|
||||
"""
|
||||
Create label PDF for samples in a batch.
|
||||
|
||||
**Context**
|
||||
|
||||
``Batch``
|
||||
An instance of :model:`yeast.Batch`.
|
||||
"""
|
||||
skip_count = request.POST.get("skip_count", "")
|
||||
samples = request.POST.getlist("samples", "")
|
||||
|
Loading…
Reference in New Issue
Block a user