6_地址管理 B
BLL
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace LC.BLL
{
using Entity;
using DAL;
public class AddressesBLL
{
AddressesDAL dal = new AddressesDAL();
/// <summary>
/// 新增
/// </summary>
/// <param name="a"></param>
/// <returns></returns>
public int Add(Addresses a)
{
var result = dal.Add(a);
return result;
}
/// <summary>
/// 修改
/// </summary>
/// <param name="a"></param>
/// <returns></returns>
public int Update(Addresses a)
{
var result = dal.Update(a);
return result;
}
/// <summary>
/// 删除
/// </summary>
/// <param name="Id"></param>
/// <returns></returns>
public int Delete(int Id)
{
var result = dal.Delete(Id);
return result;
}
/// <summary>
/// 根据Id获取
/// </summary>
/// <param name="Id"></param>
/// <returns></returns>
public Addresses QueryById(int Id)
{
var result = dal.QueryById(Id);
return result;
}
/// <summary>
/// 获取数据
/// </summary>
/// <returns></returns>
public List<Addresses> Query()
{
var result = dal.Query();
return result;
}
/// <summary>
/// 获取数据
/// </summary>
/// <returns></returns>
public List<Region> GetRegion(int PId)
{
var result = dal.GetRegion(PId);
return result;
}
}
}