void SoaChannel_GetAgentSetBysIdCompleted(object sender, GetAgentSetBysIdCompletedEventArgs e) { try { if (e.Error == null) { if (e.Result != null) { AgentSetInfo = e.Result; this.DataContext = AgentSetInfo; if (!string.IsNullOrEmpty(AgentSetInfo.SYSCODE.ToString()))//系统代码 { foreach (T_SYS_DICTIONARY Region in cbSYSTEMTYPE.Items) { if (Region.DICTIONARYVALUE == int.Parse(AgentSetInfo.SYSCODE)) { cbSYSTEMTYPE.SelectedItem = Region; break; } } } //if (!string.IsNullOrEmpty(AgentSetInfo.MODELCODE.ToString()))//模块代码 //{ // foreach (SMT.Saas.Tools.FlowDesignerWS.FLOW_MODELDEFINE_T Region in cbModelCode.Items) // { // if (Region.MODELCODE == AgentSetInfo.MODELCODE) // { // ModelDefineList.Add(Region); // cbModelCode.SelectedItem = Region; // break; // } // } //} FlowDesigner.GetModelNameInfosComboxAsync(); //T_OA_AGENTSET PARENTMODELCODE = cbModelCode.ItemsSource.Cast<T_OA_AGENTSET>().Where(a => a.MODELCODE == MODELDEFINE.MODELCODE).ToList().First(); //cbModelCode.SelectedItem = PARENTMODELCODE; txtPostId.Text = Utility.GetPostName(AgentSetInfo.AGENTPOSTID);//岗位ID txtCompanyId.Text = Utility.GetCompanyName(AgentSetInfo.OWNERCOMPANYID); txtDepartmentId.Text = Utility.GetDepartmentName(AgentSetInfo.OWNERDEPARTMENTID); Party.Add(AgentSetInfo.USERID); client.GetEmployeeByIDsAsync(Party); } } else { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), e.Error.Message); } } catch (Exception ex) { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), ex.ToString()); } }
void SoaChannel_GetAgentSetBysIdCompleted(object sender, GetAgentSetBysIdCompletedEventArgs e) { try { if (e.Error == null) { if (e.Result != null) { AgentSetInfo = e.Result; this.DataContext = AgentSetInfo; if (!string.IsNullOrEmpty(AgentSetInfo.SYSCODE.ToString()))//系统代码 { foreach (T_SYS_DICTIONARY Region in cbSYSTEMTYPE.Items) { if (Region.DICTIONARYVALUE == int.Parse(AgentSetInfo.SYSCODE)) { cbSYSTEMTYPE.SelectedItem = Region; break; } } } //if (!string.IsNullOrEmpty(AgentSetInfo.MODELCODE.ToString()))//模块代码 //{ // foreach (SMT.Saas.Tools.FlowDesignerWS.FLOW_MODELDEFINE_T Region in cbModelCode.Items) // { // if (Region.MODELCODE == AgentSetInfo.MODELCODE) // { // ModelDefineList.Add(Region); // cbModelCode.SelectedItem = Region; // break; // } // } //} FlowDesigner.GetModelNameInfosComboxAsync(); //T_OA_AGENTSET PARENTMODELCODE = cbModelCode.ItemsSource.Cast<T_OA_AGENTSET>().Where(a => a.MODELCODE == MODELDEFINE.MODELCODE).ToList().First(); //cbModelCode.SelectedItem = PARENTMODELCODE; txtPostId.Text = Utility.GetPostName(AgentSetInfo.AGENTPOSTID);//岗位ID txtCompanyId.Text = Utility.GetCompanyName(AgentSetInfo.OWNERCOMPANYID); txtDepartmentId.Text = Utility.GetDepartmentName(AgentSetInfo.OWNERDEPARTMENTID); Party.Add(AgentSetInfo.USERID); client.GetEmployeeByIDsAsync(Party); } } else { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), e.Error.Message); } } catch (Exception ex) { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), ex.ToString()); } }