using System;
|
using System.Collections.Generic;
|
using System.Linq;
|
using System.Text;
|
using CY.IDAL;
|
using CY.Model;
|
using AbstractFactory;
|
using CY.IBaseDAL;
|
using CY.Infrastructure.DESEncrypt;
|
using CY.Infrastructure.Query;
|
using System.Data;
|
|
namespace CY.BLL.OA
|
{
|
public class OA_SuppliersBLL
|
{
|
IOA_SuppliersDAL suppliersDAL = null;
|
public OA_SuppliersBLL()
|
{
|
suppliersDAL = Factory.GetDALByInterfaceName(DALInterface.IOA_SuppliersDAL) as IOA_SuppliersDAL;
|
|
}
|
/// <summary>
|
/// 添加一个供应商
|
/// </summary>
|
/// <param name="model"></param>
|
/// <returns></returns>
|
public bool InsertModel(OA_Suppliers model)
|
{
|
return suppliersDAL.InserModel(model);
|
|
}
|
/// <summary>
|
/// 更新供应商
|
/// </summary>
|
/// <param name="model"></param>
|
/// <returns></returns>
|
public bool UpdateModel(OA_Suppliers model)
|
{
|
return suppliersDAL.UpdateModel(model);
|
}
|
/// <summary>
|
/// 删除一个供应商
|
/// </summary>
|
/// <param name="model"></param>
|
/// <returns></returns>
|
public bool DeleteModel(OA_Suppliers model)
|
{
|
return suppliersDAL.DeleteModel(model);
|
}
|
|
/// <summary>
|
/// 根据条件获取全部供应商
|
/// </summary>
|
/// <param name="pa"></param>
|
/// <param name="FirmId"></param>
|
/// <param name="CooperativeStateId"></param>
|
/// <param name="SuppliersLevelId"></param>
|
/// <param name="SuppliersTypeId"></param>
|
/// <returns></returns>
|
public IEnumerable<Model.OA_Suppliers> getAllSuppliers(Pagination pa, Guid FirmId, string CooperativeStateId, string SuppliersLevelId, string SuppliersTypeId, string SuppliersName, string BusinessScope)
|
{
|
|
return suppliersDAL.getAllSuppliers(pa, FirmId, CooperativeStateId, SuppliersLevelId, SuppliersTypeId, SuppliersName, BusinessScope);
|
}
|
/// <summary>
|
/// 得到单个供应商
|
/// </summary>
|
/// <param name="Keyid"></param>
|
/// <returns></returns>
|
public OA_Suppliers getSingleSupplier(string Keyid)
|
{
|
|
return suppliersDAL.getSingleSupplier(Keyid);
|
}
|
|
/// <summary>
|
/// 获取table类型的所有供应商
|
/// </summary>
|
/// <param name="FirmId"></param>
|
/// <returns></returns>
|
public DataTable getSupplierTable(Guid FirmId)
|
{
|
return suppliersDAL.getSupplierTable(FirmId);
|
}
|
}
|
}
|