Ejemplo n.º 1
0
        protected override async Task MapBeforeCacheAsync(IList <T> cached)
        {
            foreach (var activity in cached)
            {
                var entity = activity;
                entity.GroupId = await _groupActivityService.GetGroupIdAsync(activity.Id);

                await _commentsService.FillCommentsAsync(entity);

                await _likesService.FillLikesAsync(entity);
                await FillLinkPreviewAsync(entity);
            }
        }
Ejemplo n.º 2
0
        protected override async Task MapBeforeCacheAsync(IList <Entities.News> cached)
        {
            foreach (var activity in cached)
            {
                var entity = activity;
                entity.Location = await _activityLocationService.GetAsync(entity.Id);

                entity.GroupId = await _groupActivityService.GetGroupIdAsync(activity.Id);

                await _commentsService.FillCommentsAsync(entity);

                await _likesService.FillLikesAsync(entity);
            }
        }
Ejemplo n.º 3
0
        protected override async Task MapBeforeCacheAsync(IList <Event> cached)
        {
            foreach (var activity in cached)
            {
                var entity = activity;
                entity.GroupId = await _groupActivityService.GetGroupIdAsync(activity.Id);

                _subscribeService.FillSubscribers(entity);
                await _commentsService.FillCommentsAsync(entity);

                await _likesService.FillLikesAsync(entity);

                _activitySubscribeSettingService.FillSubscribeSettings(entity);
            }
        }