Add Gesamtlieferung to DeliveryNote

This commit is contained in:
2023-08-30 14:18:43 +02:00
parent 75e6c1bd5d
commit 9b84452b86
7 changed files with 130 additions and 13 deletions

View File

@ -41,7 +41,7 @@ namespace Elwig.Windows {
private void PdfButton_Click(object sender, RoutedEventArgs evt) {
Utils.RunBackground("PDF Generation", async () => {
using var ctx = new AppDbContext();
using var doc = new DeliveryNote(ctx.Deliveries.OrderBy(d => d.Parts.Count).ThenBy(d => d.Year).ThenBy(d => d.DId).Last());
using var doc = new DeliveryNote(ctx.Deliveries.OrderBy(d => d.Parts.Count).ThenBy(d => d.Year).ThenBy(d => d.DId).Last(), ctx);
await doc.Generate();
doc.Show();
});