public IEnumerable <MeetingViewModel> GetHierarchicalResources()
        {
            var firstRoomAttendees = new List <int>()
            {
                1, 2
            };
            var secondRoomAttendees = new List <int>()
            {
                1, 3
            };

            var result = MeetingsRepository.All()
                         .Where(s => (s.RoomID == 1 && s.Attendees.All(p => firstRoomAttendees.Contains(p))) ||
                                (s.RoomID == 2 && s.Attendees.All(p => secondRoomAttendees.Contains(p))));

            return(result);
        }
Ejemplo n.º 2
0
 public ActionResult Index()
 {
     return(this.Jsonp(MeetingsRepository.All()));
 }