/// <summary> /// PopupForm /// </summary> /// <param name="vo"></param> void PopupForm(EntityContagionDisplay vo) { if (vo == null) { vo = new EntityContagionDisplay(); vo.isNew = true; } vo.reportId = Viewer.ReportId; frmContagionEdit frm = new frmContagionEdit(vo); frm.Text = Viewer.Text; using (ProxyContagion proxy = new ProxyContagion()) { if (Function.Int(vo.rptId) > 0) { string Role = proxy.Service.GetContagionRole(GlobalLogin.objLogin.EmpNo); frm.blbiSave.Enabled = false; if (Role != string.Empty || vo.SHR == null) { frm.blbiSave.Enabled = true; } } } frm.ShowDialog(); if (frm.IsSave) { this.Query(); } }
/// <summary> /// SetUI /// </summary> /// <param name="child"></param> public override void SetUI(frmBase child) { base.SetUI(child); Viewer = (frmContagionEdit)child; }