HTNResp/Controllers/ProjectDictionaryController.cs
(开头部分) 3KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Text;
using System.Web.Mvc;
using System.Data.SqlClient;
using HTNResp.Models;
using HTNResp.Codes;
namespace HTNResp.Controllers
{
public class ProjectDictionaryController : BaseController
{
HTNResp.BLL.ProjectDictionary bll = new HTNResp.BLL.ProjectDictionary();
public override ActionResult Index()
{
return View();
}
public override ActionResult AjaxList()
{
int start = 0; // 分页起始条目数
int length = 0; // 分页每页分页数
start = Convert.ToInt32(Request.Params["start"]);
length = Convert.ToInt32(Request.Params["length"]);
string strSql = " 1=1 ";
System.Text.StringBuilder sb = new System.Text.StringBuilder();
if (!string.IsNullOrEmpty(Request.Params["ProjectName"]))
{
sb.Append(" and ProjectName like '%" + Request.Params["ProjectName"] + "%' ");
}
if (!string.IsNullOrEmpty(Request.Params["ProjectCode"]))
{
sb.Append(" and ProjectCode like '%" + Request.Params["ProjectCode"] + "%' ");
}
if (!string.IsNullOrEmpty(Request.Params["ProjectType"]))
{
sb.Append(" and ProjectType like '%" + Request.Params["ProjectType"] + "%' ");
}
strSql += sb.ToString();
List<HTNResp.Model.ProjectDictionary> list = bll.DataTableToList(bll.GetListByPage(strSql, " ", start + 1, start + length).Tables[0]);
int total = bll.GetRecordCount(""); //总页数
int totalFilter = bll.GetRecordCount(strSql); //查到的页数
BLL.EvalGuid bllEvalGrid = new BLL.EvalGuid();
// 返回JSON结果,JSON统一格式为 { result = 1, data = new { } } 或 { result = 0, msg = "" }
return this.Json(new
{
result = 1,
data = new
后面还有 61 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。