Esempio n. 1
0
        public async Task <IActionResult> Index(UserProfileCommentIndexViewModel viewModel)
        {
            IEnumerable <UserProfileComment> userProfileComments = await userProfileCommentService.GetAllAsync();

            viewModel.UserProfileComments = userProfileComments;

            return(View(viewModel));
        }
Esempio n. 2
0
        public async Task <ApiResponse> GetAll()
        {
            IEnumerable <UserProfileComment> result = await userProfileCommentService.GetAllAsync();

            if (result != null)
            {
                return(new ApiResponse(result, ResponseStatusCode.Success, "Successfully returned User Profile Comment list."));
            }

            return(new ApiResponse(result, ResponseStatusCode.Error, "Could not return User Profile Comment list."));
        }