Start on PDF report
This commit is contained in:
@@ -0,0 +1,9 @@
|
|||||||
|
using System.Text.Json.Serialization;
|
||||||
|
using ReceiptPDFBuilder.Models;
|
||||||
|
|
||||||
|
namespace ReceiptPDFBuilder.Helpers;
|
||||||
|
|
||||||
|
[JsonSerializable(typeof(Settings))]
|
||||||
|
[JsonSerializable(typeof(ReportFile))]
|
||||||
|
[JsonSerializable(typeof(PDFReport))]
|
||||||
|
internal partial class SourceGenerationContext : JsonSerializerContext { }
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.IO;
|
||||||
|
using System.Text;
|
||||||
|
using System.Text.Json;
|
||||||
|
using System.Text.Json.Serialization;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using ReceiptPDFBuilder.Helpers;
|
||||||
|
|
||||||
|
namespace ReceiptPDFBuilder.Models;
|
||||||
|
|
||||||
|
class PDFReport : ChangeNotifier
|
||||||
|
{
|
||||||
|
private string _baseFolder;
|
||||||
|
private string _name;
|
||||||
|
private List<ReportFile> _files;
|
||||||
|
|
||||||
|
public PDFReport()
|
||||||
|
{
|
||||||
|
_baseFolder = "";
|
||||||
|
_name = "";
|
||||||
|
_files = [];
|
||||||
|
}
|
||||||
|
|
||||||
|
public string BaseFolder
|
||||||
|
{
|
||||||
|
get => _baseFolder;
|
||||||
|
set { _baseFolder = value; NotifyPropertyChanged(); }
|
||||||
|
}
|
||||||
|
|
||||||
|
public string Name
|
||||||
|
{
|
||||||
|
get => _name;
|
||||||
|
set { _name = value; NotifyPropertyChanged(); }
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<ReportFile> Files
|
||||||
|
{
|
||||||
|
get => _files;
|
||||||
|
set { _files = value; NotifyPropertyChanged(); }
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user