public bool CheckProductExist(CheckProductExistRequest checkProductExist) { using (DataAccess dataAccess = new DataAccess()) { return(((from product in dataAccess.Products join unit in dataAccess.Unit on product.UnitID equals unit.UnitID where (product.ProductCode == checkProductExist.ProductCode && product.ProductName == checkProductExist.ProductName && product.Volume == checkProductExist.Volume && unit.UnitName == checkProductExist.UnitName && product.SellerID == checkProductExist.SellerID)select(product)).Count()) == 1); } }
public bool CheckProductExist(CheckProductExistRequest checkProductExist) { return(productService.CheckProductExist(checkProductExist)); }