public GeneralData.Model.Entities.ng_Product ng_ProductEntity(ng_ProductDTO dto) { GeneralData.Model.Entities.ng_Product newEntity = new GeneralData.Model.Entities.ng_Product { description = dto.description, price = dto.price, imageUrl = dto.imageUrl, productCode = dto.productCode, productId = dto.productId, productName = dto.productName, releaseDate = dto.releaseDate, starRating = dto.starRating }; return(newEntity); }
public void Insert(ng_ProductDTO newEntity) { Repo.Insert(ng_ProductEntity(newEntity)); Repo.Save(); }