public string GetFullName(string userId) { BusiUserService user = new BusiUserService(); StringBuilder sbJsr = new StringBuilder(); if (userId.Equals("0")) { sbJsr.Append("系统管理员"); } else { sbJsr.Append(user.CompanyName(userId) + " - " + user.DeptName(userId) + " - " + user.RealName(userId)); } return(sbJsr.ToString()); }
private void AddUserNode(TreeViewNode departmentNode, string departmentCode) { TreeViewOperation treeViewOperation = new TreeViewOperation(); BusiUserService user = new BusiUserService(); DataTable dtUser = user.GetUserByDeptCode(departmentCode); for (int j = 0; j < dtUser.Rows.Count; j++) { string provinceUserCompanyCode = dtUser.Rows[j]["CCODE"].ToString(); string provinceUserId = dtUser.Rows[j]["USERID"].ToString(); string provinceUserName = dtUser.Rows[j]["REALNAME"].ToString(); TreeViewNode userNode = treeViewOperation.BuildNode(Guid.NewGuid().ToString(), provinceUserId, provinceUserName, false, false); userNode.ServerXzdm = CommonHelper.GetSHICode(provinceUserCompanyCode); treeViewOperation.AddNode(departmentNode, userNode); } }