public string strApplyManName(Guid ACRecordID, int MaterialID) { string str = ""; object obj2 = str + " select ApplyMan from OA_OfficeRes_PersonalApplication a " + " right join OA_OfficeRes_PersonalApplicationDetail b "; DataTable table = publicDbOpClass.DataTableQuary(string.Concat(new object[] { obj2, " on a.PARecordID = b.PARecordID where ACRecordID = '", ACRecordID, "' " }) + " and MaterialID = " + MaterialID); if (table.Rows.Count > 0) { userManageDb db = new userManageDb(); return(db.GetUserName(table.Rows[0]["ApplyMan"].ToString())); } return(""); }
public string GetAduitUserName(int tempid, Guid InstanceCode) { object obj2 = ("" + " select * from WF_Instance n left join WF_Instance_Main m on n.ID =m.ID ") + " where TheOrder in ( " + " select isnull(Max(TheOrder),0) from WF_Instance a left join WF_Instance_Main b on a.ID =b.ID "; object obj3 = string.Concat(new object[] { obj2, " where b.TemplateID = ", tempid, " " }); DataTable table = publicDbOpClass.DataTableQuary(string.Concat(new object[] { obj3, " ) and m.TemplateID = ", tempid, " and m.InstanceCode = '", InstanceCode, "'" })); if (table.Rows.Count <= 0) { return(""); } userManageDb db = new userManageDb(); string str2 = ""; for (int i = 0; i < table.Rows.Count; i++) { string userName = db.GetUserName(table.Rows[i]["Operator"].ToString()); if (userName != "") { str2 = str2 + userName + ","; } } return(str2); }