(function(){"use strict";u8.Crm.Widgets.RelatedDataExtrasWidget=function(e,t){this.Widget(e,t);this._isCreated=false};$.extend(u8.Crm.Widgets.RelatedDataExtrasWidget.prototype,{create:function(){this._create($.extend(this._getViewOptions(),{onCreate:u8.tools.created.curry(this)}))},update:function(){var e=this._getViewOptions();if(this._view){var t=this._view.infoAreaId!=e.infoAreaId;var i=this._view.headerGroupName!=e.headerGroupName;if(!t&&!i){this._view.setValueImmediately(e.value);return}}this.children.clear();this.$(this.element).empty();this._create(e)},getWidget:function(e){switch(e){case"RelatedView":return this._view;default:break}},isModified:function(){return false},isEmpty:function(){return this._view.isEmpty()},_create:function(e){var t=this.$("<div />").appendTo(this.element);this._view=u8.widget("RelatedView",t[0],$.extend(e,{parent:this}))},_getViewOptions:function(){return $.extend({headerGroupName:this.expandView.model.properties.headerGroupName,value:[this.expandView.model.getUid()],infoAreaId:this.expandView.model.getInfoAreaId()},this.options)}});u8.Crm.Widgets.RelatedDataExtrasWidget.makeClass({name:"RelatedDataExtrasWidget",deriveFrom:u8.Base.Widgets.Widget,events:["Create"]})})();