app/Handlers/Duty/DutyGroups.php 1 location
|
@@ 97-103 (lines=7) @@
|
94 |
|
// Does list[i] already have date assigned? Is yes, skip assignment |
95 |
|
if (!empty($this->list[$i]['date'])) { |
96 |
|
continue; |
97 |
|
} else { |
98 |
|
$this->list[$i] = [ |
99 |
|
'group' => $this->list[$i]['group'], |
100 |
|
'id' => $this->list[$i]['id'], |
101 |
|
'date' => $newDatesList[$dateCounter++], |
102 |
|
]; |
103 |
|
} |
104 |
|
} |
105 |
|
$this->list = $this->list->sortBy('date'); |
106 |
|
return $this; |
app/Handlers/Duty/DutyUsers.php 1 location
|
@@ 156-163 (lines=8) @@
|
153 |
|
|
154 |
|
for ($i = 0; $i < $count; $i++) { |
155 |
|
// Does list[i] already have date assigned? Is yes, skip assignment |
156 |
|
if (!empty($this->list[$i]['date'])) { |
157 |
|
continue; |
158 |
|
} else { |
159 |
|
$this->list[$i] = [ |
160 |
|
'date' => $newDatesList[$dateCounter++], |
161 |
|
'user' => $this->list[$i]['user'] |
162 |
|
]; |
163 |
|
} |
164 |
|
} |
165 |
|
$this->list = $this->list->sortBy('date'); |
166 |
|
return $this; |