public async Task <ActionResult> Index([FromRoute] int albumId) { IEnumerable <PhotoEntity> photoEntities = photosService.GetPhotosByAlbumId(albumId); IEnumerable <PhotoModel> photos = mapper.Map <IEnumerable <PhotoModel> >(photoEntities); return(View(photos)); }
public async Task <IActionResult> Photos(int Id) { var photos = await _photosService.GetPhotosByAlbumId(Id); return(View(photos)); }