Index: univention-management-console-frontend/umc/widgets/Form.js =================================================================== --- univention-management-console-frontend/umc/widgets/Form.js (Revision 31953) +++ univention-management-console-frontend/umc/widgets/Form.js (Arbeitskopie) @@ -111,6 +111,8 @@ _initializingElements: 0, + _initializedDeferred: null, + postMixInProperties: function() { this.inherited(arguments); @@ -169,6 +171,8 @@ buildRendering: function() { this.inherited(arguments); + this._initializedDeferred = new dojo.Deferred(); + if (this.scrollable) { dojo.style(this.containerNode, { overflow: 'auto' @@ -210,6 +214,7 @@ } } + // send an event when all dynamic elements have been initialized this._initializingElements = 0; umc.tools.forIn(this._widgets, function(iname, iwidget) { @@ -228,7 +233,7 @@ // send event when the last element has been initialized if (0 === this._initializingElements) { - this.onValuesInitialized(); + this._initializedDeferred.resolve(); } })); } @@ -236,10 +241,18 @@ // maybe all elements are already initialized if (!this._initializingElements) { - this.onValuesInitialized(); + this._initializedDeferred.resolve(); } + }, + startup: function() { + this.inherited(arguments); + this._initializedDeferred.then(dojo.hitch(this, function(result) { + this.onValuesInitialized(); + })); + }, + postCreate: function() { this.inherited(arguments); Index: univention-management-console-frontend/umc/widgets/MultiObjectSelect.js =================================================================== --- univention-management-console-frontend/umc/widgets/MultiObjectSelect.js (Revision 32074) +++ univention-management-console-frontend/umc/widgets/MultiObjectSelect.js (Arbeitskopie) @@ -55,7 +55,14 @@ // 'javascript:functionName' // function(ids) { ... } // may return dojo.Deferred - formatter: function(ids) { return ids; }, + formatter: function(ids) { + dojo.forEach(ids, function(id, i) { + if (dojo.isString(id)) { + ids[i] = {label: id, id: id}; + } + }); + return ids; + }, autoSearch: true,