removed confusing and useless code
This commit is contained in:
@@ -4,7 +4,7 @@ from collections import OrderedDict
|
|||||||
|
|
||||||
import datetime
|
import datetime
|
||||||
|
|
||||||
def split_by_12h_blocks(iterable, field="heure_debut"):
|
def split_by_12h_blocks(iterable):
|
||||||
""" Move object with given 'field' time under 12:00 to the end of stream.
|
""" Move object with given 'field' time under 12:00 to the end of stream.
|
||||||
Apart from this, order is untouched.
|
Apart from this, order is untouched.
|
||||||
"""
|
"""
|
||||||
@@ -37,7 +37,7 @@ class CompteRendu(Maraude):
|
|||||||
observations = []
|
observations = []
|
||||||
for r in self._iter(order=order, reverse=reverse):
|
for r in self._iter(order=order, reverse=reverse):
|
||||||
observations += r.observations.get_queryset()
|
observations += r.observations.get_queryset()
|
||||||
return list(split_by_12h_blocks(observations, field=order))
|
return list(split_by_12h_blocks(observations))
|
||||||
|
|
||||||
def __iter__(self):
|
def __iter__(self):
|
||||||
""" Iterates on related 'rencontres' objects using default ordering """
|
""" Iterates on related 'rencontres' objects using default ordering """
|
||||||
|
|||||||
Reference in New Issue
Block a user