public ProductServices( IInventoryAAARepository <dbentities.Product> productServices, IInventoryAAARepository <dbentities.ProductLog> productLogServices, IInventoryAAARepository <dbentities.ProductPrice> productPriceServices, IInventoryAAARepository <dbentities.ProductPricesLog> productPricesLogServices) { this._productServices = productServices; this._productLogServices = productLogServices; this._productPriceServices = productPriceServices; this._productPricesLogServices = productPricesLogServices; this.products = new dbentities.Product(); this.productLogs = new dbentities.ProductLog(); this.productPrice = new dbentities.ProductPrice(); this.productPricesLog = new dbentities.ProductPricesLog(); }
public static dbentities.Product DtoToEntity(this ProductDetailRequest request) { dbentities.Product entity = null; if (request != null) { entity = new dbentities.Product { ProductID = request.ProductId, ProductCode = request.ProductCode, IsActive = request.IsActive, CreatedBy = request.CreatedBy, CreatedTime = request.CreatedTime, ModifiedBy = request.ModifiedBy, ModifiedTime = request.ModifiedTime, ProductDescription = request.ProductDescription, Quantity = request.Quantity, CategoryID = request.CategoryId }; } return(entity); }