Exemplo n.º 1
0
        protected ExOzProduct UpdateProduct(ExOzProductResponse item, ExOzProduct exOzProduct, long FilEventDetailId, int FilVenueId, Guid ModifiedBy)
        {
            ExOzProduct exOzProductInserted = new ExOzProduct();

            if (exOzProduct == null)
            {
                var newExOzProduct = new ExOzProduct
                {
                    ProductId                 = item.Id,
                    Name                      = item.Name,
                    UrlSegment                = item.UrlSegment,
                    Summary                   = item.Summary,
                    OperatorId                = item.OperatorId,
                    EventDetailId             = FilEventDetailId,
                    VenueId                   = FilVenueId,
                    CanonicalRegionUrlSegment = item.CanonicalRegionUrlSegment,
                    BookingRequired           = item.BookingRequired,
                    HandlerKey                = item.HandlerKey,
                    Title                     = item.Title,
                    Timestamp                 = item.Timestamp,
                    OperatorName              = item.OperatorName,
                    Description               = item.Description,
                    MoreInfo                  = item.MoreInfo,
                    Tips                      = item.Tips,
                    ModifiedBy                = ModifiedBy,
                    IsEnabled                 = true,
                    HelpCode                  = item.HelpCode,
                    Timezone                  = item.Timezone,
                };
                exOzProductInserted = _exOzProductRepository.Save(newExOzProduct);
            }
            else
            {
                exOzProduct.IsEnabled  = true;
                exOzProduct.ModifiedBy = ModifiedBy;
                exOzProductInserted    = _exOzProductRepository.Save(exOzProduct);
            }
            return(exOzProductInserted);
        }
Exemplo n.º 2
0
 public ExOzProduct Save(ExOzProduct exOzProduct)
 {
     return(_exOzProductRepository.Save(exOzProduct));
 }