diff --git a/Elwig/App.xaml.cs b/Elwig/App.xaml.cs index f20aebc..ef69575 100644 --- a/Elwig/App.xaml.cs +++ b/Elwig/App.xaml.cs @@ -12,6 +12,7 @@ using System.Globalization; using System.Threading; using System.Windows.Markup; using System.Reflection; +using Elwig.Helpers.Printing; namespace Elwig { public partial class App : Application { @@ -45,7 +46,7 @@ namespace Elwig { public static IList Scales { get; private set; } public static ClientParameters Client { get; private set; } - public static bool IsPrintingReady => Documents.Html.IsReady && Documents.Pdf.IsReady; + public static bool IsPrintingReady => Html.IsReady && Pdf.IsReady; public static Dispatcher MainDispatcher { get; private set; } public App() : base() { @@ -92,8 +93,8 @@ namespace Elwig { } } - Utils.RunBackground("HTML Initialization", () => Documents.Html.Init(PrintingReadyChanged)); - Utils.RunBackground("PDF Initialization", () => Documents.Pdf.Init(PrintingReadyChanged)); + Utils.RunBackground("HTML Initialization", () => Html.Init(PrintingReadyChanged)); + Utils.RunBackground("PDF Initialization", () => Pdf.Init(PrintingReadyChanged)); var list = new List(); foreach (var s in Config.Scales) { diff --git a/Elwig/Documents/BusinessDocument.cshtml.cs b/Elwig/Documents/BusinessDocument.cs similarity index 100% rename from Elwig/Documents/BusinessDocument.cshtml.cs rename to Elwig/Documents/BusinessDocument.cs diff --git a/Elwig/Documents/BusinessDocument.cshtml b/Elwig/Documents/BusinessDocument.cshtml index 7a985d9..1d843e4 100644 --- a/Elwig/Documents/BusinessDocument.cshtml +++ b/Elwig/Documents/BusinessDocument.cshtml @@ -2,7 +2,7 @@ @inherits TemplatePage @model Elwig.Documents.BusinessDocument @{ Layout = "Document"; } - +
diff --git a/Elwig/Documents/style-businessdocument.css b/Elwig/Documents/BusinessDocument.css similarity index 100% rename from Elwig/Documents/style-businessdocument.css rename to Elwig/Documents/BusinessDocument.css diff --git a/Elwig/Documents/BusinessLetter.cshtml.cs b/Elwig/Documents/BusinessLetter.cs similarity index 100% rename from Elwig/Documents/BusinessLetter.cshtml.cs rename to Elwig/Documents/BusinessLetter.cs diff --git a/Elwig/Documents/CreditNote.cshtml.cs b/Elwig/Documents/CreditNote.cs similarity index 100% rename from Elwig/Documents/CreditNote.cshtml.cs rename to Elwig/Documents/CreditNote.cs diff --git a/Elwig/Documents/CreditNote.cshtml b/Elwig/Documents/CreditNote.cshtml index d83fb1d..f6bf043 100644 --- a/Elwig/Documents/CreditNote.cshtml +++ b/Elwig/Documents/CreditNote.cshtml @@ -2,7 +2,7 @@ @inherits TemplatePage @model Elwig.Documents.CreditNote @{ Layout = "BusinessDocument"; } - + @{ var binNum = Model.BinNames.Length; } diff --git a/Elwig/Documents/style-creditnote.css b/Elwig/Documents/CreditNote.css similarity index 100% rename from Elwig/Documents/style-creditnote.css rename to Elwig/Documents/CreditNote.css diff --git a/Elwig/Documents/DeliveryConfirmation.cshtml.cs b/Elwig/Documents/DeliveryConfirmation.cs similarity index 100% rename from Elwig/Documents/DeliveryConfirmation.cshtml.cs rename to Elwig/Documents/DeliveryConfirmation.cs diff --git a/Elwig/Documents/DeliveryConfirmation.cshtml b/Elwig/Documents/DeliveryConfirmation.cshtml index f866463..fa3df41 100644 --- a/Elwig/Documents/DeliveryConfirmation.cshtml +++ b/Elwig/Documents/DeliveryConfirmation.cshtml @@ -2,7 +2,7 @@ @inherits TemplatePage @model Elwig.Documents.DeliveryConfirmation @{ Layout = "BusinessDocument"; } - +

@Model.Title

diff --git a/Elwig/Documents/style-deliveryconfirmation.css b/Elwig/Documents/DeliveryConfirmation.css similarity index 100% rename from Elwig/Documents/style-deliveryconfirmation.css rename to Elwig/Documents/DeliveryConfirmation.css diff --git a/Elwig/Documents/DeliveryJournal.cshtml.cs b/Elwig/Documents/DeliveryJournal.cs similarity index 100% rename from Elwig/Documents/DeliveryJournal.cshtml.cs rename to Elwig/Documents/DeliveryJournal.cs diff --git a/Elwig/Documents/DeliveryJournal.cshtml b/Elwig/Documents/DeliveryJournal.cshtml index 678aab4..e48a158 100644 --- a/Elwig/Documents/DeliveryJournal.cshtml +++ b/Elwig/Documents/DeliveryJournal.cshtml @@ -2,7 +2,7 @@ @inherits TemplatePage @model Elwig.Documents.DeliveryJournal @{ Layout = "Document"; } - +

Lieferjournal

@Model.Filter

diff --git a/Elwig/Documents/style-deliveryjournal.css b/Elwig/Documents/DeliveryJournal.css similarity index 100% rename from Elwig/Documents/style-deliveryjournal.css rename to Elwig/Documents/DeliveryJournal.css diff --git a/Elwig/Documents/DeliveryNote.cshtml.cs b/Elwig/Documents/DeliveryNote.cs similarity index 100% rename from Elwig/Documents/DeliveryNote.cshtml.cs rename to Elwig/Documents/DeliveryNote.cs diff --git a/Elwig/Documents/DeliveryNote.cshtml b/Elwig/Documents/DeliveryNote.cshtml index 7855909..1c10201 100644 --- a/Elwig/Documents/DeliveryNote.cshtml +++ b/Elwig/Documents/DeliveryNote.cshtml @@ -2,7 +2,7 @@ @inherits TemplatePage @model Elwig.Documents.DeliveryNote @{ Layout = "BusinessDocument"; } - +

@Model.Title

diff --git a/Elwig/Documents/style-deliverynote.css b/Elwig/Documents/DeliveryNote.css similarity index 100% rename from Elwig/Documents/style-deliverynote.css rename to Elwig/Documents/DeliveryNote.css diff --git a/Elwig/Documents/style-page.css b/Elwig/Documents/Document.Page.css similarity index 100% rename from Elwig/Documents/style-page.css rename to Elwig/Documents/Document.Page.css diff --git a/Elwig/Documents/Document.cshtml.cs b/Elwig/Documents/Document.cs similarity index 99% rename from Elwig/Documents/Document.cshtml.cs rename to Elwig/Documents/Document.cs index e826769..fee9ba2 100644 --- a/Elwig/Documents/Document.cshtml.cs +++ b/Elwig/Documents/Document.cs @@ -4,6 +4,7 @@ using System.IO; using Elwig.Helpers; using System.Collections.Generic; using System.Linq; +using Elwig.Helpers.Printing; namespace Elwig.Documents { public abstract partial class Document : IDisposable { diff --git a/Elwig/Documents/Document.cshtml b/Elwig/Documents/Document.cshtml index bfac449..74e33af 100644 --- a/Elwig/Documents/Document.cshtml +++ b/Elwig/Documents/Document.cshtml @@ -7,8 +7,8 @@ @Model.Title - - + + @if (Model.DoubleSided) {