Init
This commit is contained in:
30
Server/Components/Pages/InvoiceListPage.razor
Normal file
30
Server/Components/Pages/InvoiceListPage.razor
Normal file
@@ -0,0 +1,30 @@
|
||||
@page "/"
|
||||
@page "/invoices"
|
||||
@using Server.Model
|
||||
@rendermode InteractiveServer
|
||||
|
||||
<h3>Rechnungen (@((Invoices ?? []).Count))</h3>
|
||||
|
||||
@foreach (var invoice in Invoices ?? [])
|
||||
{
|
||||
<div class="row">
|
||||
<div class="col-md-auto pt-3">
|
||||
<div class="card" style="width: 18rem;">
|
||||
<div class="card-body">
|
||||
<h5 class="card-title">#@invoice.InvoiceId</h5>
|
||||
<h6 class="card-subtitle mb-2 text-muted">@invoice.IssueDate.ToShortDateString()</h6>
|
||||
<p class="card-text">
|
||||
@invoice.Customer?.Name<br />
|
||||
@invoice.Items.Count Artikel<br />
|
||||
@($"{invoice.TotalNetto:N2} €") Netto<br />
|
||||
</p>
|
||||
<a href="@($"edit/{invoice.InvoiceId}")" class="btn btn-sm btn-primary">Bearbeiten</a>
|
||||
@if (invoice.DeletionAllowed)
|
||||
{
|
||||
<button class="btn btn-sm btn-danger" style="margin-left: .5rem;" @onclick="() => DeleteInvoiceAsync(invoice.InvoiceId)">Löschen</button>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
Reference in New Issue
Block a user