Permalink
Browse files

admin: Fix resetting events upon creation

When creating a new event based on another and the other event has no future
events defined, we need to reset base_fid of the new event to NULL or else the
user interface won't allow to choose what state to reset the new event to.
  • Loading branch information...
Andreas Gruenbacher
Andreas Gruenbacher committed Jan 8, 2019
1 parent 5d7cdbe commit a3ebbbfbce8bc292e85d03166957d93686f53884
Showing with 1 addition and 0 deletions.
  1. +1 −0 htdocs/admin/settings/controller.js
@@ -345,6 +345,7 @@ var settingsController = [
event.base = base;
let future_events = angular.copy(event.future_events);
$scope.future_events = future_events;
event.base_fid = null;
if (future_events.length)
event.base_fid = future_events[0].fid;
assign_event(event, true);

0 comments on commit a3ebbbf

Please sign in to comment.