/// <summary> /// 新增 /// </summary> public void ExecutEvent(object source, EventArgs e) { _ItsView.ResultMessage = string.Empty; if (!new EmployeeValidater(_ItsView).Validation()) { return; } Account account = new EmployeeDataCollector(_ItsView).AccountDataCollect(); try { using (TransactionScope ts = new TransactionScope(TransactionScopeOption.Required)) { BllInstance.AccountBllInstance.CreateAccount(account, LoginUser); if (CompanyConfig.HasHrmisSystem && account.IsHRAccount) { IEmployeeFacade hrmisEmployeeFacade = new EmployeeFacade(); hrmisEmployeeFacade.InitEmployeeProxy(account.Id, LoginUser); } ts.Complete(); } GoToListPage(); } catch (Exception ex) { _ItsView.ResultMessage = //" <img src='../../image/icon03.jpg' align='absmiddle'' /> <span class='fontred'>" + ex.Message;// +"</span>"; } }