B_Apply
public List<Apply> RiskLink(Expression<Func<Apply, bool>> where)
{
using (var dbContext = new DBContext())
{
var query = dbContext.ApplyDs.Include(m => m.User).Where(where);
return query.ToList();
}
}
public ActionResult RiskLinkDetail01(string name,string idcard)
{
List<Apply> listApply = new B_Apply().RiskLink(m => m.User.Name == name && m.Account.IDCard == idcard);
var result = from item in listApply
select new
{
ApplyTime = item.ApplyTime.ToString("yyyy-MM-dd HH:mm:ss"),
Amounts = item.Amounts
};
return Json(new { total = listApply.Count, rows = result });
}C#: from in select ; m(linq where)
最新推荐文章于 2022-01-17 17:50:37 发布
本文详细介绍了如何使用B_Apply类的RiskLink方法进行风险链接筛选,并通过实例展示了如何获取特定条件下的风险链接详情,包括申请时间与金额的展示。
1141

被折叠的 条评论
为什么被折叠?



