mvc+dwz第五天

封装XiaowuBLL类库

 

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Xiaowu.DAL;
using Xiaowu.Model;
using System.Linq.Expressions;
namespace Xiaowu.BLL
{
public class wu_userBLL
{
wu_userDAL wu_userDAL = new wu_userDAL();


public IQueryable<w_user> GetEntitysByStrwhere(Expression<Func<w_user, bool>> wherelambad)
{
return wu_userDAL.GetEntitys(wherelambad);
}
public int AddUser(w_user userinfo )
{
return wu_userDAL.Add(userinfo);
}
public int DeleteUser(int id)
{
return wu_userDAL.Delete(id);
}
public int UpdateUser(w_user userinfo)
{
return wu_userDAL.Update(userinfo);
}

public IQueryable<w_user> GetPageEntities<T_key>(int pageIndex, int pageSize, out int total, Expression<Func<w_user, bool>> wherelambad, Expression<Func<w_user, T_key>> OrderbyLambad, bool IsSort)
{
return wu_userDAL.GetPageEntities<T_key>(pageIndex, pageSize, out total, wherelambad, OrderbyLambad, IsSort);
}
}
}

posted @ 2020-11-18 22:19  .net&new  阅读(121)  评论(0编辑  收藏  举报