Merge branch 'MDL-59670-master' of git://github.com/andrewnicols/moodle
authorEloy Lafuente (stronk7) <stronk7@moodle.org>
Mon, 28 Aug 2017 22:41:57 +0000 (00:41 +0200)
committerEloy Lafuente (stronk7) <stronk7@moodle.org>
Mon, 28 Aug 2017 22:41:57 +0000 (00:41 +0200)
calendar/amd/build/event_form.min.js
calendar/amd/src/event_form.js

index 49c3a88..d90e7c8 100644 (file)
Binary files a/calendar/amd/build/event_form.min.js and b/calendar/amd/build/event_form.min.js differ
index 0a4e33e..e6abfd8 100644 (file)
@@ -232,7 +232,7 @@ define(['jquery', 'core/templates'], function($, Templates) {
                     element.removeClass('hidden');
                     element.prop('disabled', false);
 
-                    if (selectedIndex === null) {
+                    if (selectedIndex === null || element.attr('selected')) {
                         selectedIndex = index;
                     }
                 } else {