|
@@ 259-268 (lines=10) @@
|
| 256 |
|
$day = substr($this->iterator->from, 0, 10); |
| 257 |
|
$planned = $entry->getDayPlannedPeriods($day); |
| 258 |
|
|
| 259 |
|
if (0 === count($planned)) { |
| 260 |
|
$workingPeriods = $entry->getDayWorkingPeriods($day); |
| 261 |
|
|
| 262 |
|
if (0 === count($workingPeriods)) { |
| 263 |
|
return bab_mktime($this->iterator->from); |
| 264 |
|
} |
| 265 |
|
|
| 266 |
|
$firstPeriod = reset($workingPeriods); |
| 267 |
|
return $firstPeriod->ts_begin; |
| 268 |
|
} |
| 269 |
|
|
| 270 |
|
$firstperiod = reset($planned); |
| 271 |
|
|
|
@@ 298-307 (lines=10) @@
|
| 295 |
|
$day = $end->getIsoDate(); |
| 296 |
|
$planned = $entry->getDayPlannedPeriods($day); |
| 297 |
|
|
| 298 |
|
if (0 === count($planned)) { |
| 299 |
|
$workingPeriods = $entry->getDayWorkingPeriods($day); |
| 300 |
|
|
| 301 |
|
if (0 === count($workingPeriods)) { |
| 302 |
|
return bab_mktime($this->iterator->to); |
| 303 |
|
} |
| 304 |
|
|
| 305 |
|
$lastPeriod = end($workingPeriods); |
| 306 |
|
return $lastPeriod->ts_end; |
| 307 |
|
} |
| 308 |
|
|
| 309 |
|
$lastperiod = end($planned); |
| 310 |
|
|