removed eland_config
[htsworkflow.git] / gaworkflow / frontend / exp_track / views.py
1 # Create your views here.
2 #from django.template import Context, loader
3 #shortcut to the above modules
4 from django.shortcuts import render_to_response, get_object_or_404
5 from gaworkflow.frontend.exp_track.models import DataRun
6 from django.http import HttpResponse
7
8 def index(request):
9     all_runs = DataRun.objects.all().order_by('-run_start_time')
10     #t = loader.get_template('exptrack/index.html')
11     #c = Context({
12     #    'data_run_list': all_runs,
13     #})
14     #return HttpResponse(t.render(c)) 
15     # shortcut to the above module usage
16     return render_to_response('exptrack/index.html',{'data_run_list': all_runs}) 
17     
18 def detail(request, run_folder):
19     html_str = '<h2>Exp Track Details Page</h2>'
20     html_str += 'Run Folder: '+run_folder
21     r = get_object_or_404(DataRun,run_folder=run_folder)
22     return render_to_response('exptrack/detail.html',{'run_f': r})