old_contents: from django.http import HttpResponse
  
  def index(request):
      return HttpResponse('index')
  
  def channel(request, name):
      return HttpResponse('channel: %s' % name)
  
  def show(request, name, year, month, day):
      return HttpResponse('show: %s - %s/%s/%s' % (name, year, month, day))
  
  
new_contents: from datetime import datetime
  
  from django.http import HttpResponse
  from django.shortcuts import get_object_or_404
  
  from annoying.decorators import render_to
  
  from .models import Channel, Log
  
  def index(request):
      return HttpResponse('index')
  
  def channel_index(request, name):
      channel = get_object_or_404(Channel, name=name)
      return HttpResponse('channel: %s' % name)
  
  @render_to('irclogview/show_log.html')
  def show_log(request, name, year, month, day):
      channel = get_object_or_404(Channel, name=name)
      date = datetime(int(year), int(month), int(day)).date()
  
      log = get_object_or_404(Log, channel=channel, date=date)
  
      return {'log': log}
  
  
subject: Add view to show log of a channel on a day