Ejemplo n.º 1
0
        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);
        }
Ejemplo n.º 2
0
 public void Insert(ng_ProductDTO newEntity)
 {
     Repo.Insert(ng_ProductEntity(newEntity));
     Repo.Save();
 }