public ProjectPage2(UnicontaBaseEntity sourcedata, UnicontaBaseEntity master) : base(sourcedata, true) { InitializeComponent(); Debtor = master as Uniconta.DataModel.Debtor; InitPage(api); }
public override void SetParameter(IEnumerable <ValuePair> Parameters) { foreach (var rec in Parameters) { if (rec.Name == null || rec.Name == "Master") { DCAccount master; if (rec.Value == "Debtor") { master = new Uniconta.DataModel.Debtor(); } else if (rec.Value == "Creditor") { master = new Uniconta.DataModel.Creditor(); } else { continue; } master.SetMaster(api.CompanyEntity); dgContactGrid.UpdateMaster(master as UnicontaBaseEntity); var header = string.Concat(Uniconta.ClientTools.Localization.lookup("Contacts"), ": ", Uniconta.ClientTools.Localization.lookup(master.GetType().Name)); SetHeader(header); } } base.SetParameter(Parameters); }
public ProjectPage2(CrudAPI crudApi, UnicontaBaseEntity master) : base(crudApi, "") { InitializeComponent(); Debtor = master as Uniconta.DataModel.Debtor; InitPage(crudApi); #if !SILVERLIGHT FocusManager.SetFocusedElement(txtNumber, txtNumber); #endif }