Commit 1a71a360 authored by Yusei Tahara's avatar Yusei Tahara

The first start date may be the same to periodicity effective date.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@36086 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 4b623208
...@@ -91,13 +91,12 @@ class PeriodicityLine(Path, PeriodicityLineMixin): ...@@ -91,13 +91,12 @@ class PeriodicityLine(Path, PeriodicityLineMixin):
expiration_date = self.getExpirationDate() expiration_date = self.getExpirationDate()
result = [] result = []
if effective_date is not None and from_date < effective_date:
from_date = effective_date
if expiration_date is not None and to_date > expiration_date: if expiration_date is not None and to_date > expiration_date:
to_date = expiration_date to_date = expiration_date
next_start_date = self.getNextPeriodicalDate(from_date) next_start_date = self.getNextPeriodicalDate(from_date)
while next_start_date <= to_date: while next_start_date <= to_date:
if next_start_date >= effective_date:
result.append((next_start_date, result.append((next_start_date,
self.getPeriodicityTermStopDate(next_start_date))) self.getPeriodicityTermStopDate(next_start_date)))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment