父窗体打开子窗体准备
BillShowParameter OtherInAdd = new BillShowParameter() { FormId = FormIdConst.STK_MISCELLANEOUS,//子窗体 ParentPageId = base.View.PageId,//父窗体 Status = OperationStatus.ADDNEW,//打开新增界面 AllowNavigation = false, };
设置携带参数
#region 携带参数 //售后类型 OtherInAdd.CustomParams.Add("FAfterType", afterType); //更换序列号 IsSerial OtherInAdd.CustomParams.Add("FIsSerial", IsSerial.ToString()); //售后单 FIDList OtherInAdd.CustomParams.Add("FIDList", string.Join(",", idList)); //明细 FEntity OtherInAdd.CustomParams.Add("FEntryList", entryList); #endregion
打开子窗体
OtherInAdd.OpenStyle.ShowType = ShowType.MainNewTabPage;//NewTabPage会导致在客户端无法打开新页签 OtherInAdd.OpenStyle.TagetKey = "FMainTab";//这个不能少 OtherInAdd.CreateWebParams(); this.View.ShowForm(OtherInAdd);
子窗体接收参数
public override void OnInitialize(InitializeEventArgs e) { base.OnInitialize(e); if (e.Paramter.GetCustomParameters().ContainsKey("FIDList"))//判断源单是否传递【售后单ID】 { this.idList = e.Paramter.GetCustomParameter("FIDList") + ""; } if (e.Paramter.GetCustomParameters().ContainsKey("FEntryList"))//判断源单是否传递【售后单行ID】 { this.entryList = e.Paramter.GetCustomParameter("FEntryList") + ""; } if (e.Paramter.GetCustomParameters().ContainsKey("FAfterType"))//判断源单是否传递某个动态参数【售后类型】 { this.afterType = e.Paramter.GetCustomParameter("FAfterType") + ""; } }
标签:插件,售后,到子,OtherInAdd,Add,Paramter,窗体,FIDList From: https://www.cnblogs.com/lanrenka/p/17824587.html