def index(request):
    """The main page."""
    form = forms.MapSearchForm(request.GET)

    job_list = (models.MapRenderingJob.objects.all()
                .order_by('-submission_time'))
    job_list = (job_list.filter(status=0) |
                job_list.filter(status=1))

    return render(request,
                  'maposmatic/index.html',
                  { 'form': form,
                    'queued': job_list.count()
                  }
                 )