Updated the proostekrant to work properly again.
This commit is contained in:
@@ -0,0 +1,49 @@
|
||||
@page "/indienen/bevestiging"
|
||||
@inject ArticleService Artikelen
|
||||
|
||||
<PageTitle>Bevestiging — ProostenKrant</PageTitle>
|
||||
|
||||
<section class="card">
|
||||
<span class="kicker">Bedankt!</span>
|
||||
<h1 class="headline">@( _artikel is not null ? "Artikel ingediend" : "Bevestiging")</h1>
|
||||
|
||||
@if (_artikel is null)
|
||||
{
|
||||
<p>Er is geen recent ingediend artikel gevonden.</p>
|
||||
}
|
||||
else
|
||||
{
|
||||
<p>Het artikel <strong>@_artikel.Title</strong> is veilig in de brievenbus van de redactie gevallen.</p>
|
||||
<dl class="bevestiging-lijst">
|
||||
<dt>Schrijver</dt>
|
||||
<dd>@_artikel.AuthorName</dd>
|
||||
<dt>Gebeurtenis</dt>
|
||||
<dd>@Krant.DutchShortDate(_artikel.EventDate)</dd>
|
||||
@if (_artikel.SeasonName is not null)
|
||||
{
|
||||
<dt>Editie</dt>
|
||||
<dd>@_artikel.SeasonName</dd>
|
||||
}
|
||||
</dl>
|
||||
<p class="muted">De redactie bekijkt alle inzendingen en publiceert ze in de komende editie.</p>
|
||||
<div class="form-actions">
|
||||
<a class="btn btn-primary" href="/indienen">Nog een artikel indienen</a>
|
||||
<a class="btn" href="/">Naar de voorpagina</a>
|
||||
</div>
|
||||
}
|
||||
</section>
|
||||
|
||||
@code {
|
||||
[SupplyParameterFromQuery(Name = "artikel")]
|
||||
public int? ArtikelId { get; set; }
|
||||
|
||||
private Article? _artikel;
|
||||
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
if (ArtikelId is int id)
|
||||
{
|
||||
_artikel = await Artikelen.FindAsync(id);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user