Esempio n. 1
0
        public List <RoomReservationInfo> FindByAssignMember(string room, AssignMember member)
        {
            var query =
                this.client.CreateDocumentQuery <RoomReservationInfo>(
                    UriFactory.CreateDocumentCollectionUri(DocumentDbManager.DatabaseId, DocumentDbManager.CollectionId))
                .Where(r => r.Room == room && r.AssignMembers.Contains(member));
            var result = query.ToList();

            return(result);
        }
Esempio n. 2
0
        public List <RoomReservationInfo> FindByAssignMember(AssignMember member)
        {
            FeedOptions feedOptions = new FeedOptions()
            {
                EnableCrossPartitionQuery = true
            };

            var query =
                this.client.CreateDocumentQuery <RoomReservationInfo>(
                    UriFactory.CreateDocumentCollectionUri(DocumentDbManager.DatabaseId, DocumentDbManager.CollectionId),
                    feedOptions).
                Where(r => r.AssignMembers.Contains(member));
            var result = query.ToList();

            return(result);
        }