예제 #1
0
        public override void Run()
        {
            AccountForm form = new AccountForm();

//			IAccountDao dao = new NHibernateAccountDao();
            form.AccountSaveAndClose += delegate(object sender, AccountEventArgs e) {
//				dao.SaveOrUpdate(e.Account);
                e.Account.SaveOrUpdate();
                form.Close();
            };
            form.AccountSaveAndClear += delegate(object sender, AccountEventArgs e) {
//				dao.SaveOrUpdate(e.Account);
                e.Account.SaveOrUpdate();
                form.Account = new Account();
            };
            WorkbenchSingleton.AddChild(form, "Edit Account");
        }