Commit 43b6ac5dab6d19a8090bb7e6423173675f8963ec
1 parent
f7687e65
Update
Showing
1 changed file
with
8 additions
and
0 deletions
src/main/resources/rules/shiftloop_fb.drl
| ... | ... | @@ -248,6 +248,10 @@ rule "Calcu_loop_guideboard_result" |
| 248 | 248 | new ArrayList<ScheduleResult_output>(); |
| 249 | 249 | |
| 250 | 250 | int i = $indexData.getCalcu_index(); |
| 251 | + if (((Boolean) $weekdays.get(initDate.getDayOfWeek() - 1)).booleanValue() == false) { | |
| 252 | + i = (i + 1) % $rangesize; | |
| 253 | + } | |
| 254 | + | |
| 251 | 255 | while (!initDate.isAfter(endDate)) { |
| 252 | 256 | if (((Boolean) $weekdays.get(initDate.getDayOfWeek() - 1)).booleanValue()) { |
| 253 | 257 | ScheduleResult_output ro = new ScheduleResult_output(); |
| ... | ... | @@ -302,6 +306,10 @@ rule "Calcu_loop_employee_result" |
| 302 | 306 | new ArrayList<ScheduleResult_output>(); |
| 303 | 307 | |
| 304 | 308 | int i = $indexData.getCalcu_index(); |
| 309 | + if (((Boolean) $weekdays.get(initDate.getDayOfWeek() - 1)).booleanValue() == false) { | |
| 310 | + i = (i + 1) % $rangesize; | |
| 311 | + } | |
| 312 | + | |
| 305 | 313 | while (!initDate.isAfter(endDate)) { |
| 306 | 314 | if (((Boolean) $weekdays.get(initDate.getDayOfWeek() - 1)).booleanValue()) { |
| 307 | 315 | ScheduleResult_output ro = new ScheduleResult_output(); | ... | ... |