Beispiel #1
0
        public void Handle(GuestPackageSaved e)
        {
            //TODO: Chad: Overwrite existing
            var package = GuestPackages.SingleOrDefault(x => x.TournamentId == e.Id && x.Code == e.Code);

            if (package == null)
            {
                GuestPackages.Add(new GuestPackage
                {
                    TournamentId = e.Id,
                    Code         = e.Code,
                    Name         = e.Name,
                    Cost         = e.Cost,
                    Enabled      = e.Enabled
                });
            }
            else
            {
                package.Name    = e.Name;
                package.Cost    = e.Cost;
                package.Enabled = e.Enabled;
            }
        }
Beispiel #2
0
 public void Apply(GuestPackageSaved e)
 {
     //TODO: nothing at this time
 }