using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using CY.IDAL.Inquiry;
using AbstractFactory;
using CY.Model;
using CY.Infrastructure.Query;
using CY.IDAL;
using CY.IBaseDAL;
using CY.Infrastructure;
namespace CY.BLL.Inquiry
{
///
/// 纸张类别相关业务逻辑类
///
public class PaperTypeBLL
{
IPaperTypeDAL _iPaperTypeDAL = null;
public PaperTypeBLL()
{
_iPaperTypeDAL = Factory.GetDALByInterfaceName(DALInterface.IPaperTypeDAL) as IPaperTypeDAL;
}
///
/// 分页返回纸张类别列表
///
/// 品牌名称
/// 分页参数
///
public IEnumerable SelectModelPage(string typeName,int status,Infrastructure.Query.Pagination pagination)
{
return _iPaperTypeDAL.SelectModelPage(typeName,status,pagination);
}
///
/// 根据主键返回纸张类别实体
///
/// 主键ID
/// 纸张类别实体
public Model.SysInquiry_PaperType SelectModelByKey(int keyid)
{
return _iPaperTypeDAL.SelectModelByKey(keyid);
}
///
/// 判断是否有相同的纸张类别名称
///
///
///
public bool IsExistsPaperTypeName(string typeName)
{
return _iPaperTypeDAL.IsExistsPaperTypeName(typeName);
}
///
/// 返回所有有效的纸张列表
///
///
public IEnumerable GetPaperTypeList()
{
return _iPaperTypeDAL.GetPaperTypeList();
}
///
/// 新增纸张类型
///
///
///
public bool InsertPaperType(SysInquiry_PaperType model)
{
return _iPaperTypeDAL.InserModel(model);
}
///
/// 修改纸张类别
///
///
///
public bool UpdatePaperType(SysInquiry_PaperType model)
{
return _iPaperTypeDAL.UpdateModel(model);
}
///
/// 获取最新排序顺序
///
///
public int GetOrderNumByMax()
{
return _iPaperTypeDAL.GetOrderNumByMax();
}
}
}