public bool InGrid(IHPatternComponent component) { return (component.ComponentType == ComponentType.Grid && Parent.IsInGrid(this)); }
private static bool CanRedirectTo(IHPatternComponent component) { // Does it have acceptable (or no) parameters? bool temParm = false; // Verifica se os parametros da selection existem na transação, se existir, permite redirectionar, if (component is SelectionElement) { foreach (ParameterElement pare in component.Parameters) { ParameterElement pare2 = component.TrnElement.Parameters.FindParameter(pare.Name); if (pare2 == null) { temParm = false; break; } else { temParm = true; } } } if (component.Parameters.IsOnlyAttributes || temParm) { // Is it an existing webpanel? WebPanel currentObject = WebPanel.Get(component.Instance.Model, component.ObjectName); if (currentObject != null) { // Can it be called? string objectType = currentObject.GetPropertyValue<string>(Properties.WBP.Type); string urlAccess = currentObject.GetPropertyValue<string>(Properties.WBP.UrlAccess); if (objectType == Properties.WBP.Type_Values.WebPage || objectType == Properties.WBP.Type_Values.Component && urlAccess == Properties.WBP.UrlAccess_Values.Yes) { return true; } } } return false; }