Exemplo n.º 1
0
        public async Task <AttendeeInvite> GetInviteAsync(InviteInfo inviteInfo)
        {
            ParameterDictionary parameters = ParameterDictionary.Single("inviteId", inviteInfo.InviteId);

            return((await ExecuteStoredProc("[dbo].[spGetInviteById]", parameters)
                    .ConfigureAwait(continueOnCapturedContext: false)).FirstOrDefault());
        }
Exemplo n.º 2
0
        public async Task <IEnumerable <User> > GetReunionOrganizers(Guid reunionId)
        {
            ParameterDictionary parameters = ParameterDictionary.Single("reunionId", reunionId);

            return(await ExecuteStoredProc("[dbo].[spGetOrganizersByReunionId]", parameters)
                   .ConfigureAwait(continueOnCapturedContext: false));
        }
Exemplo n.º 3
0
        public async Task CancelReunionAsync(CancelRequest request)
        {
            ParameterDictionary parameters = ParameterDictionary.Single("reunionId", request.EntityId);

            _ = await ExecuteStoredProc("[dbo].[spDeleteReunionById]", parameters)
                .ConfigureAwait(continueOnCapturedContext: false);
        }
Exemplo n.º 4
0
        public async Task <Reunion> GetReunionAsync(Guid id)
        {
            ParameterDictionary parameters = ParameterDictionary.Single("id", id.ToString());

            return((await ExecuteStoredProc("[dbo].[spGetReunionById]", parameters)
                    .ConfigureAwait(continueOnCapturedContext: false)).SingleOrDefault());
        }
Exemplo n.º 5
0
        public async Task <IEnumerable <AttendeeInvite> > GetAttendeesByReunion(Guid reunionId)
        {
            ParameterDictionary parameters = ParameterDictionary.Single("reunionId", reunionId);

            return(await ExecuteStoredProc("[dbo].[spGetInvitesByReunionId]", parameters)
                   .ConfigureAwait(continueOnCapturedContext: false));
        }
Exemplo n.º 6
0
        public async Task <Address> GetEventAddressAsync(Guid eventId)
        {
            ParameterDictionary parameters = ParameterDictionary.Single("eventId", eventId.ToString());

            return((await ExecuteStoredProc("[dbo].[spGetAddressByEventId]", parameters)
                    .ConfigureAwait(continueOnCapturedContext: false)).SingleOrDefault());
        }
Exemplo n.º 7
0
        public async Task <IEnumerable <Event> > GetEventsByReunionIdAsync(Guid reunionId)
        {
            ParameterDictionary parameters = ParameterDictionary.Single("reunionId", reunionId.ToString());

            return(await ExecuteStoredProc("[dbo].[spGetEventsByReunionId]", parameters)
                   .ConfigureAwait(continueOnCapturedContext: false));
        }
Exemplo n.º 8
0
        public async Task <Address> GetReunionAddressAsync(Guid reunionId)
        {
            ParameterDictionary parameters = ParameterDictionary.Single("entityTypeId", (int)EntityType.Reunion);

            parameters.AddParameter("entityId", reunionId.ToString());
            return((await ExecuteStoredProc("[dbo].[spGetAddressByEntityTypeAndId]", parameters)
                    .ConfigureAwait(continueOnCapturedContext: false)).SingleOrDefault());
        }
Exemplo n.º 9
0
        public async Task AddAttendees(BulkAttendeeRequest request)
        {
            ParameterDictionary parameters = ParameterDictionary.Single("invites", TvpHelper.MapInvites(request.InviteRequests));

            parameters.AddParameter("userId", request.UserId);

            await ExecuteStoredProc("[dbo].[spCreateInvites]", parameters)
            .ConfigureAwait(continueOnCapturedContext: false);
        }
Exemplo n.º 10
0
 public async Task <User> GetUserByEmailAsync(string email)
 {
     return((await ExecuteStoredProc("[dbo].[spGetUserByEmail]", ParameterDictionary.Single("email", email))
             .ConfigureAwait(continueOnCapturedContext: false)).FirstOrDefault());
 }
Exemplo n.º 11
0
 public async Task <IEnumerable <Reunion> > GetManageReunionsAsync(string userId)
 {
     return(await ExecuteStoredProc("[dbo].[spGetManageReunions]", ParameterDictionary.Single("userId", userId))
            .ConfigureAwait(continueOnCapturedContext: false));
 }