Esempio n. 1
0
        protected EventTicketAttribute UpdateEventTicketAttribute(ExOzProductOptionResponse item, EventTicketAttribute FilEventTicketAttribute, long FilEventTicketDetailId, Guid ModifiedBy)
        {
            EventTicketAttribute FilEventTicketAttributeInserted = new EventTicketAttribute();

            if (FilEventTicketAttribute == null)
            {
                var newFilEventTicketAttribute = new EventTicketAttribute
                {
                    EventTicketDetailId       = FilEventTicketDetailId,
                    SalesStartDateTime        = DateTime.UtcNow,
                    SalesEndDatetime          = DateTime.UtcNow,
                    TicketTypeId              = Contracts.Enums.TicketType.Regular,
                    ChannelId                 = Contracts.Enums.Channels.Website,
                    CurrencyId                = 1,
                    SharedInventoryGroupId    = null,
                    AvailableTicketForSale    = 10,
                    RemainingTicketForSale    = 10,
                    TicketCategoryDescription = "Entry Only",
                    ViewFromStand             = "",
                    IsSeatSelection           = false,
                    Price = Convert.ToDecimal(item.Price),
                    IsInternationalCardAllowed = false,
                    IsEMIApplicable            = false,
                    ModifiedBy = ModifiedBy,
                    IsEnabled  = true,
                };
                FilEventTicketAttributeInserted = _eventTicketAttributeRepository.Save(newFilEventTicketAttribute);
            }
            else
            {
                FilEventTicketAttributeInserted = FilEventTicketAttribute;
            }
            return(FilEventTicketAttributeInserted);
        }
Esempio n. 2
0
        protected ExOzProductOption updateProductOption(ExOzProductOptionResponse item, ExOzProductOption exOzProductOption, long eventTicketDetailId, long sessionId, Guid ModifiedBy)
        {
            ExOzProductOption exOzProductOptionInserted = new ExOzProductOption();

            if (exOzProductOption == null)
            {
                var newExOzProductOption = new ExOzProductOption
                {
                    ProductOptionId     = item.Id,
                    Name                = item.Name,
                    Price               = Convert.ToDecimal(item.Price),
                    SessionId           = sessionId,
                    EventTicketDetailId = eventTicketDetailId,
                    RetailPrice         = Convert.ToDecimal(item.RetailPrice),
                    MaxQty              = item.MaxQty,
                    MinQty              = item.MinQty,
                    DefaultQty          = item.DefaultQty,
                    Multiple            = item.Multiple,
                    Weight              = item.Weight,
                    IsFromPrice         = item.IsFromPrice,
                    ModifiedBy          = ModifiedBy,
                    IsEnabled           = true,
                };
                exOzProductOptionInserted = _exOzProductOptionRepository.Save(newExOzProductOption);
            }
            else
            {
                exOzProductOption.IsEnabled  = true;
                exOzProductOption.ModifiedBy = ModifiedBy;
                exOzProductOptionInserted    = _exOzProductOptionRepository.Save(exOzProductOption);
            }
            return(exOzProductOptionInserted);
        }
Esempio n. 3
0
        protected string GetTicketCategoryName(ExOzProductOptionResponse item, int optionCount)
        {
            string TicketCategoryName = "";

            switch (optionCount)
            {
            case 0:
                break;

            case 1:
                TicketCategoryName = item.Name;
                break;

            default:

                TicketCategoryName = item.SessionName + " - " + item.Name;
                break;
            }
            return(TicketCategoryName);
        }