You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// For non repeating events the previous event is the closest event prior to the current event
196
+
// For repeating events, (Repeat Entire Event & Repeat Instrument) the previous event is the current event
166
197
foreach ($eventsas$event) {
167
-
// Event instances share the same event id for every instance.
168
-
// To support event instances we only break on the first instance, and allow execution for all future instances i.e., $_GET['instance'] greater than 1.
169
-
// Event instances are enabled under: Project Setup > Enable optional modules and customizations > Repeatable instruments and events > 'Repeat instruments (repeat independently of each other)`
170
-
if ($event == $_GET['event_id'] && $_GET['instance'] == 1) {
198
+
// Only break for non repeating events.
199
+
// Non repeating events should not get data from current event, whereas, repeating events with instances depend on data from the current event i.e., $_GET['event_id']
200
+
if ($event == $_GET['event_id'] && !$this->isRepeatEvent()) {
171
201
break;
172
202
}
173
203
174
-
if (in_array($source_form, $Proj->eventsForms[$event])) {
204
+
if (in_array($source_form, $Proj->eventsForms[$event]) && !$this->isRepeatEvent()) {
0 commit comments