from django.shortcuts import render
from .forms import ChapterLookup


def home(request):
    search_result = {}
    print(request)
    if 'category' in request.GET:
        form = ChapterLookup(request.GET)
        if form.is_valid():
            search_result = form.search()
    else:
        form = ChapterLookup()
    return render(request, 'core/home.html', {'form': form, 'search_result':
        search_result})

09373d9e4f7a0020da37928b57ad1deea12d1a35
<mask token>

<mask token>


def home(request):
    search_result = {}
    print(request)
    if 'category' in request.GET:
        form = ChapterLookup(request.GET)
        if form.is_valid():
            search_result = form.search()
    else:
        form = ChapterLookup()
    return render(request, 'core/home.html', {'form': form, 'search_result':
        search_result})

from django.shortcuts import render
from .forms import ChapterLookup


def home(request):
    search_result = {}
    print(request)
    if 'category' in request.GET:
        form = ChapterLookup(request.GET)
        if form.is_valid():
            search_result = form.search()
    else:
        form = ChapterLookup()
    return render(request, 'core/home.html', {'form': form, 'search_result':
        search_result})
