@if (!string.IsNullOrWhiteSpace(_movie.Poster))
{

}
@_movie.Title
@_movie.Year
@if (!string.IsNullOrWhiteSpace(_movie.Plot))
{
@_movie.Plot
}
Add To Collection
@if (_movie.Studios.Any())
{
Studios
@foreach (string studio in _movie.Studios.OrderBy(s => s))
{
}
}
@if (_movie.Genres.Any())
{
Genres
@foreach (string genre in _movie.Genres.OrderBy(g => g))
{
}
}
@if (_movie.Tags.Any())
{
Tags
@foreach (string tag in _movie.Tags.OrderBy(t => t))
{
}
}
@code {
[Parameter]
public int MovieId { get; set; }
private MovieViewModel _movie;
protected override Task OnParametersSetAsync() => RefreshData();
private Task RefreshData() =>
Mediator.Send(new GetMovieById(MovieId)).IfSomeAsync(vm => _movie = vm);
private async Task AddToCollection()
{
var parameters = new DialogParameters { { "EntityType", "movie" }, { "EntityName", _movie.Title } };
var options = new DialogOptions { CloseButton = true, MaxWidth = MaxWidth.ExtraSmall };
IDialogReference dialog = Dialog.Show