narsil/Tanshu.Accounts.BI/FiltersBI.cs

31 lines
903 B
C#
Raw Normal View History

using System;
using System.Collections.Generic;
using Tanshu.Accounts.Contracts;
namespace Tanshu.Accounts.BI
{
public class FiltersBI
{
public List<CustomerBO> GetFilteredCustomers(Dictionary<string, string> filter)
{
using (var connection = new SqlDAO.SqlConnectionDAO())
{
using (var dao = new SqlDAO.CustomerDAO(connection))
{
return dao.GetFilteredCustomers(filter);
}
}
}
public List<ProductDisplaySmallBO> GetFilteredProducts(Dictionary<string, string> filter)
{
using (var connection = new SqlDAO.SqlConnectionDAO())
{
using (var dao = new SqlDAO.ProductDAO(connection))
{
return dao.GetFilteredProducts(filter);
}
}
}
}
}