/// <summary> /// 提取意见列表 /// </summary> /// <param name="context"></param> private void GetSuggestions(HttpContext context) { var ds = new DataSet(); var courBll = new BLL.Course(); ds = courBll.GetAllList(); var courseId = context.Request["coId"]; if (!string.IsNullOrEmpty(courseId)) { var page = Convert.ToInt32(context.Request["page"]); var rows = Convert.ToInt32(context.Request["rows"]); var startIndex = (page - 1) * rows + 1; var endIndex = startIndex + rows - 1; var questionbll = new BLL.Questionnaire(); var num = questionbll.GetSuggestion(courseId) == null ? 0 : questionbll.GetSuggestion(courseId).Tables[0].Rows.Count; ds = questionbll.GetSuggestionByPage(courseId, "", startIndex, endIndex); var str = JsonConvert.SerializeObject(new { total = num, rows = ds.Tables[0] }); context.Response.Write(str); } }