public ViewLink Make(ViewDefinition definition, Section parentNode) { var viewLink = new ViewLink() { ViewLinkType = ViewLinkType.Default, ParentNode = parentNode }; viewLink.Props = new Dictionary <string, object>() { { "Name", definition.Name }, { "DisplayName", definition.DisplayName } }; viewLink.Events = new List <Event>() { new Event() { EventType = EventType.Click, Virtual = true, Actions = new List <UI.Action>() { new UI.Action() { ActionType = ActionType.OpenSection, Virtual = true, Parameters = new List <Parameter>() { new Parameter() { Virtual = true, ParameterType = ParameterType.FilterId, DefaultValue = definition .Filters .FirstOrDefault(f => f.ViewId == definition.Id)? .Id.ToString() } } } } } }; return(viewLink); }
/// <summary> /// select actions, then select view /// </summary> public void SelectView() { SelectActions(); ViewLink.Wait(3).Click(); DriverCommands.WaitAndMeasurePageLoadTime(90, 30); }
/// <summary> /// click the view link /// </summary> public void SelectView() { ViewLink.Wait(3).Click(); //returns /Assess/Items/ViewItemStatistics.aspx }
/// <summary> /// click the view link /// </summary> public void SelectView() { ViewLink.Click(); //on passage type, returns /Assess/Items/PassageDetail.aspx //on item type, returns /Assess/Items/ViewItemStatistics.aspx }
/// <summary> /// 表单提示信息构造函数 /// </summary> /// <param name="formMessageType">提示方式,失败或成功</param> /// <param name="message">提示信息</param> /// <param name="linkName">主链接文字</param> /// <param name="linkUrl">主链接Url</param> public FromMessage(FromMessageType formMessageType, string message, string linkName, string linkUrl) { Type = Type; Message = message; Link = new ViewLink(linkName, linkUrl); }
/// <summary> /// 表单提示信息构造函数 /// </summary> /// <param name="formMessageType">提示方式,失败或成功</param> /// <param name="message">提示信息</param> public FromMessage(FromMessageType formMessageType, string message) { Type = Type; Message = message; Link = new ViewLink("返回首页", "pages/index"); }
public LinkBinding(ViewLink vl, ModelLink ml, UnityEvent viewModelEvent) { this.vl = vl; this.ml = ml; this.environmentChanged = viewModelEvent; }
void LinkComponent(ViewLink link) { this.link = link; SignifyChange(); }