From 3d16a439612b64d484d793fb4aff266390e775e4 Mon Sep 17 00:00:00 2001 From: oysteini Date: Sun, 6 Mar 2011 19:36:38 +0000 Subject: [PATCH] =?UTF-8?q?Endret=20litt=20p=C3=A5=20utskrift=20av=20s?= =?UTF-8?q?=C3=B8keresultater.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Jeg synes det er fint å ha id-en først på linjen. --- python/worblehat.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/python/worblehat.py b/python/worblehat.py index c4f0797..b5ed2cc 100755 --- a/python/worblehat.py +++ b/python/worblehat.py @@ -57,12 +57,12 @@ def remove_duplicates(list): def search_person_cmd(search_strings, search_description=False): people = search_person(search_strings, search_description) - format = '%-20s %-10s %-70s' + format = '%-10s %-20s %-70s' for person in people: name = cut_str(person.first_name+' '+person.last_name, 20) p_id = cut_str(person.id, 10) books = cut_str(', '.join(map(lambda x: x.book.title, person.books.all())), 70) - print format % (name,p_id,books) + print format % (p_id, name, books) def search_person(search_strings, search_description=False): basic_query=Person.objects.select_related('books__book__alt_titles')