using Cksoft.Data; using DllEapEntity; using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace DllEapDal.OFILM { public class RecordDataHistoryDal { private IDatabase CurrDb; public RecordDataHistoryDal(IDatabase db) { CurrDb = db; } public IEnumerable Get(int start, int length, string order, string sort, string filter, string errorinfo, out int total) { var sql = $"select count(1) from RecordDataHistory a where 1=1 {filter}"; total = Convert.ToInt32(CurrDb.FindList(sql).FirstOrDefault() ?? "0"); var pros = CurrDb.FindListForCondition($" {filter} order by {sort} {order} limit {start - 1},{length}", ref errorinfo); return pros; } } }