private void BindItems(string cate) { ThreadPool.QueueUserWorkItem(delegate(object o) { Configclient.GetAppConfigByNameAsync("GetDicitionnaryFromCache"); //WaitHandle.WaitAll(EventArray); EventAttention.WaitOne(); }); }
private void InitParas() { PARENT.Children.Remove(loadbar); PARENT.Children.Add(loadbar); loadbar.Stop(); client = new PersonnelServiceClient(); client.EmployeeEntryAddCompleted += new EventHandler <System.ComponentModel.AsyncCompletedEventArgs>(client_EmployeeEntryAddCompleted); client.EmployeeAddCompleted += new EventHandler <EmployeeAddCompletedEventArgs>(client_EmployeeAddCompleted); client.EmployeeUpdateCompleted += new EventHandler <EmployeeUpdateCompletedEventArgs>(client_EmployeeUpdateCompleted); client.AddEmployeeEntryCompleted += new EventHandler <AddEmployeeEntryCompletedEventArgs>(client_AddEmployeeEntryCompleted); perclient = new PermissionServiceClient(); perclient.SysUserInfoAddORUpdateCompleted += new EventHandler <SysUserInfoAddORUpdateCompletedEventArgs>(perclient_SysUserInfoAddORUpdateCompleted); orclient = new SMT.Saas.Tools.OrganizationWS.OrganizationServiceClient(); orclient.GetPostNumberCompleted += new EventHandler <SMT.Saas.Tools.OrganizationWS.GetPostNumberCompletedEventArgs>(orclient_GetPostNumberCompleted); salaryCient = new Saas.Tools.SalaryWS.SalaryServiceClient(); salaryCient.AddSalaryPasswordCompleted += new EventHandler <System.ComponentModel.AsyncCompletedEventArgs>(salaryCient_AddSalaryPasswordCompleted); Configclient = new HrCommonServiceClient(); Configclient.GetAppConfigByNameCompleted += new EventHandler <GetAppConfigByNameCompletedEventArgs>(Configclient_GetAppConfigByNameCompleted); Configclient.GetAppConfigByNameAsync("isForHuNanHangXingSalary"); }
public void Save(string btnactionType) { if (IsExistFingerPrintID == false) { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("FINGERPRINTIDEXIST"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); return; } if (!SMT.SaaS.FrameworkUI.Common.Utility.CheckDataIsValid(Group1)) { //RefreshUI(RefreshedTypes.HideProgressBar); return; } if (cbxEmployeeSex.SelectedIndex < 0) { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("STRINGNOTNULL", "SEX")); // RefreshUI(RefreshedTypes.ProgressBar); return; } if (cbxIDType.SelectedIndex < 0) { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("STRINGNOTNULL", "IDTYPE")); // RefreshUI(RefreshedTypes.ProgressBar); return; } if (experience.ExperienceList == null || experience.ExperienceList.Count <= 0) { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("EXPERIENCEADD"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); return; } if (educateHistory.EducateHistory == null || educateHistory.EducateHistory.Count <= 0) { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("EDUCATEHISTORYADD"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); return; } else { if (chkHas.IsChecked.HasValue) { if (chkHas.IsChecked.Value == true) { Employee.HASCHILDREN = "1"; } else { Employee.HASCHILDREN = "0"; } } else { Employee.HASCHILDREN = "0"; } if (Employee.PHOTO != null) { if (Employee.PHOTO.Length > 51200) { string str = "员工头像图片不能大于50k,请压缩后再试"; Utility.ShowCustomMessage(MessageTypes.Caution, Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr(str)); return; } } //所属 if (dtpStartWorkTime.Text == string.Empty) { Utility.ShowCustomMessage(MessageTypes.Caution, Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("请输入员工社保缴纳起始时间")); return; } else { Employee.SOCIALSERVICEYEAR = dtpStartWorkTime.SelectedDate.Value.ToShortDateString(); } Employee.CREATECOMPANYID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.UserPosts[0].CompanyID; Employee.CREATEDEPARTMENTID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.UserPosts[0].DepartmentID; Employee.CREATEPOSTID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.UserPosts[0].PostID; Employee.CREATEUSERID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.EmployeeID; //Employee.OWNERCOMPANYID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.UserPosts[0].CompanyID; //Employee.OWNERDEPARTMENTID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.UserPosts[0].DepartmentID; //Employee.OWNERPOSTID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.UserPosts[0].PostID; //Employee.OWNERID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.EmployeeID; Employee.CREATEDATE = DateTime.Now; Employee.IDTYPE = (cbxIDType.SelectedItem as SMT.Saas.Tools.PermissionWS.T_SYS_DICTIONARY).DICTIONARYVALUE.ToString(); Employee.WORKINGAGE = 0; Employee.IDNUMBER = Employee.IDNUMBER.ToUpper(); btnActionType = btnactionType; Configclient.GetAppConfigByNameAsync("isForHuNanHangXingSalary"); //perclient.GetUserNameIsExistNameAddOneAsync(Employee.EMPLOYEEENAME, Employee.EMPLOYEEID); //client.EmployeeAddAsync(Employee); //if (!string.IsNullOrEmpty(Employee.FINGERPRINTID)) //{ // client.IsExistFingerPrintIDAsync(Employee.FINGERPRINTID, Employee.EMPLOYEEID, "Save"); //} //else //{ // OnUIRefreshed(); //} } }
private void InitParas() { PARENT.Children.Remove(loadbar); PARENT.Children.Add(loadbar); loadbar.Stop(); client = new PersonnelServiceClient(); client.EmployeeEntryAddCompleted += new EventHandler<System.ComponentModel.AsyncCompletedEventArgs>(client_EmployeeEntryAddCompleted); client.EmployeeAddCompleted += new EventHandler<EmployeeAddCompletedEventArgs>(client_EmployeeAddCompleted); client.EmployeeUpdateCompleted += new EventHandler<EmployeeUpdateCompletedEventArgs>(client_EmployeeUpdateCompleted); client.AddEmployeeEntryCompleted += new EventHandler<AddEmployeeEntryCompletedEventArgs>(client_AddEmployeeEntryCompleted); perclient = new PermissionServiceClient(); perclient.SysUserInfoAddORUpdateCompleted += new EventHandler<SysUserInfoAddORUpdateCompletedEventArgs>(perclient_SysUserInfoAddORUpdateCompleted); orclient = new SMT.Saas.Tools.OrganizationWS.OrganizationServiceClient(); orclient.GetPostNumberCompleted += new EventHandler<SMT.Saas.Tools.OrganizationWS.GetPostNumberCompletedEventArgs>(orclient_GetPostNumberCompleted); salaryCient = new Saas.Tools.SalaryWS.SalaryServiceClient(); salaryCient.AddSalaryPasswordCompleted += new EventHandler<System.ComponentModel.AsyncCompletedEventArgs>(salaryCient_AddSalaryPasswordCompleted); Configclient = new HrCommonServiceClient(); Configclient.GetAppConfigByNameCompleted += new EventHandler<GetAppConfigByNameCompletedEventArgs>(Configclient_GetAppConfigByNameCompleted); Configclient.GetAppConfigByNameAsync("isForHuNanHangXingSalary"); }
private void InitParas(string strID) { client.GetLeftOfficeConfirmByIDCompleted += new EventHandler<GetLeftOfficeConfirmByIDCompletedEventArgs>(client_GetLeftOfficeConfirmByIDCompleted); client.GetAllPostByEmployeeIDCompleted += new EventHandler<GetAllPostByEmployeeIDCompletedEventArgs>(client_GetAllPostByEmployeeIDCompleted); client.LeftOfficeConfirmUpdateCompleted += new EventHandler<System.ComponentModel.AsyncCompletedEventArgs>(client_LeftOfficeConfirmUpdateCompleted); client.LeftOfficeConfirmDeleteCompleted += new EventHandler<LeftOfficeConfirmDeleteCompletedEventArgs>(client_LeftOfficeConfirmDeleteCompleted); client.GetEmployeeToEngineCompleted += new EventHandler<GetEmployeeToEngineCompletedEventArgs>(client_GetEmployeeToEngineCompleted); client.LeftOfficeConfirmAddCompleted += new EventHandler<System.ComponentModel.AsyncCompletedEventArgs>(client_LeftOfficeConfirmAddCompleted); fbClient.GetLeavingUserCompleted += new EventHandler<SMT.Saas.Tools.FBServiceWS.GetLeavingUserCompletedEventArgs>(fbClient_GetLeavingUserCompleted); //oaClient.GetEmployeeNotReturnListByUserIdCompleted += new EventHandler<GetEmployeeNotReturnListByUserIdCompletedEventArgs>(oaClient_GetEmployeeNotReturnListByUserIdCompleted); flowClient.IsExistFlowDataByUserIDCompleted += new EventHandler<Saas.Tools.FlowWFService.IsExistFlowDataByUserIDCompletedEventArgs>(flowClient_IsExistFlowDataByUserIDCompleted); oClient.GetPostByIdCompleted += new EventHandler<Saas.Tools.OrganizationWS.GetPostByIdCompletedEventArgs>(oClient_GetPostByIdCompleted); DMClient.GetPersonAccountListByMultSearchCompleted += new EventHandler<GetPersonAccountListByMultSearchCompletedEventArgs>(DMClient_GetPersonAccountListByMultSearchCompleted); this.Loaded += new RoutedEventHandler(LeftOfficeConfirmForm_Loaded); client.IfDepartmentHaveEmployeeCompleted += new EventHandler<IfDepartmentHaveEmployeeCompletedEventArgs>(client_IfDepartmentHaveEmployeeCompleted); Configclient = new HrCommonServiceClient(); Configclient.GetAppConfigByNameCompleted += new EventHandler<GetAppConfigByNameCompletedEventArgs>(Configclient_GetAppConfigByNameCompleted); Configclient.GetAppConfigByNameAsync("isForHuNanHangXingSalary"); #region 原来的 /* if (FormType == FormTypes.Browse || FormType == FormTypes.Audit) { EnabledControl(); dpConfirmDate.IsEnabled = false; dpStopPaymentDate.IsEnabled = false; } */ #endregion }