修改BUG:系统日志排序没有起作用,防止数据过大,选取Top 1000数据
This commit is contained in:
parent
f966aa2b9d
commit
4c454e6ffa
|
@ -63,7 +63,6 @@ namespace Bootstrap.Admin.Models
|
|||
default:
|
||||
break;
|
||||
}
|
||||
data = Order == "asc" ? data.OrderBy(t => t.CRUD) : data.OrderByDescending(t => t.CRUD);
|
||||
ret.rows = data.Skip(Offset).Take(Limit);
|
||||
return ret;
|
||||
}
|
||||
|
|
|
@ -23,7 +23,7 @@ namespace Bootstrap.DataAccess
|
|||
{
|
||||
var ret = CacheManager.GetOrAdd(RetrieveLogsDataKey, CacheSection.RetrieveIntervalByKey(RetrieveLogsDataKey), key =>
|
||||
{
|
||||
string sql = "select * from Logs";
|
||||
string sql = "select top 1000 * from Logs";
|
||||
List<Log> Logs = new List<Log>();
|
||||
DbCommand cmd = DBAccessManager.SqlDBAccess.CreateCommand(CommandType.Text, sql);
|
||||
try
|
||||
|
|
Loading…
Reference in New Issue