forked from expo/troggle
python3 fixes for djsngo admin pages
This commit is contained in:
@@ -3,6 +3,7 @@ import os.path
|
||||
import re
|
||||
|
||||
import django.db.models
|
||||
from django.db.models import Min, Max
|
||||
from django.core.urlresolvers import reverse
|
||||
from django.http import HttpResponse, HttpResponseRedirect
|
||||
from django.shortcuts import render, render_to_response
|
||||
@@ -49,7 +50,7 @@ def personindex(request):
|
||||
# From what I can tell, "persons" seems to be the table rows, while "personss" is the table columns. - AC 16 Feb 09
|
||||
personss = [ ]
|
||||
ncols = 4
|
||||
nc = (len(persons) + ncols - 1) / ncols
|
||||
nc = int((len(persons) + ncols - 1) / ncols)
|
||||
for i in range(ncols):
|
||||
personss.append(persons[i * nc: (i + 1) * nc])
|
||||
|
||||
|
||||
Reference in New Issue
Block a user