Exemple #1
0
def spend_hours(request):

    hour = Hour()
    hour.category = "game"
    hour.save()

    output = "Gaming hour claimed!"
    return HttpResponse(output)
Exemple #2
0
def redeem_hour(request):
    category = request.POST["type"]
    hour = Hour()
    hour.category = category
    hour.save()

    output = "Earned " + category + " Hour"
    return HttpResponse(output)