protected virtual void OnParamValueChanged(DataContextParamEventArgs e) { if (this.ParamValueChanged != null) { this.ParamValueChanged(this, e); } if (this.Parent != null) { this.Parent.OnParamValueChanged(e); } }
protected virtual void OnInitParam(DataContextParamEventArgs e) { if (this.Session != null && e.Param.PropertyPath != null) { var paramDataType = e.Param.PropertyPath.Last.PropertyType; if (typeof(Row).IsAssignableFrom(paramDataType) && e.Control is IDataContexable) { var table = this.Session.Tables[paramDataType]; if (table != null) { ((IDataContexable)e.Control).DataContext = table.CreateView(); } } } if (this.InitParam != null) { this.InitParam(this, e); } if (this.Parent != null) { this.Parent.OnInitParam(e); } }