[Zope] problems sorting list

Sebastian Kügler sebas@ick-kupplungen.de
Fri, 28 Sep 2001 10:33:29 +0200


Hi group,

I am busy with a part of a cms in which several DTML documents are being
displayed on the frontpage.

I have the following problem with it, i could not yet figure out how to sort
the items by bobobas modification time, i tried different things, none of
them helped. To me it seems not a difficult problem, but anyway, i could not
figure out how to do that.

Can anyone help me?

This peace of code is contains it:

list = context.items.objectItems('DTML Document')
#list.sort(list(bobobase_modification-time))
#list.sort(cmp)
#list.sort(lambda a, b:
cmp(a.bobobase_modification_time,b.bobobase_modification_time))
#list.sort(objectValues(),('bobobase_modification_time'))


All the commented lines contains different approaches, all of them return
errors.

Maybe someone has a link to where i can read about these things, to figure
out what goes wrong?


Sebastian Kügler
________________________
Webmaster NSM