Example #1
0
 public VenueMetadata GetMetadata(VenueName venueName)
 {
     return session.Advanced.LuceneQuery<VenueMetadata>("Venues/Metadata")
         .WhereEquals("VenueName", venueName.Value)
         .FirstOrDefault() ?? new VenueMetadata
                                  {
                                      VenueName = venueName.Value
                                  };
 }
Example #2
0
 public VenueDiary Get(VenueName venueName)
 {
     var gigs = gigSummary.AllGigs()
         .Where(x => x.Venue == venueName.Value)
         .OrderBy(x => x.Date)
         .ToList();
     return new VenueDiary
     {
         Gigs = gigs,
         Venue = venueName.Value
     };
 }
Example #3
0
 public VenueMetadata GetMetadata(VenueName venueName)
 {
     var dir = files.GetDirectory(HostingEnvironment.MapPath("~/Content/Export/Venues/Metadata"));
     var result = new SmartMatch<VenueMetadata>().Do(dir, venueName);
     return result.ExactMatchFound ? result.Results.First() : new VenueMetadata { VenueName = venueName.Value };
 }
Example #4
0
 public VenueDiary Get(VenueName venueName)
 {
     var dir = files.GetDirectory(HostingEnvironment.MapPath("~/Content/Export/Venues/"));
     var result = new SmartMatch<VenueDiary>().Do(dir, venueName);
     return result.ExactMatchFound ? result.Results.First() : new EmptyVenueDiary { Venue = venueName.Value };
 }