This fixes issues during the first load of the calendar chunk:
Proper enabling/disabling the form based on perms
Properly initializing the pretty autocompleter
RedBox.loading();
this.doAction('chunkContent', { chunk: 'calendar' }, function(r) {
if (r.response.chunk) {
+ RedBox.onDisplay = function() { this.editCalendarCallback(calendar); RedBox.onDisplay = null; }.bind(this);
RedBox.showHtml(r.response.chunk);
- this.editCalendarCallback(calendar);
} else {
this.closeRedBox();
}