New statuses added to export files: json, csv, excel

This commit is contained in:
Robert McRackan 2021-07-29 15:11:42 -04:00
parent a72c3f069b
commit c45e6d526c
2 changed files with 21 additions and 3 deletions

View File

@ -88,6 +88,15 @@ namespace ApplicationServices
[Name("My Libation Tags")] [Name("My Libation Tags")]
public string MyLibationTags { get; set; } public string MyLibationTags { get; set; }
[Name("Book Liberation Status")]
public string BookStatus { get; set; }
[Name("Book File Location")]
public string BookLocation { get; set; }
[Name("PDF Liberation Status")]
public string PdfStatus { get; set; }
} }
public static class LibToDtos public static class LibToDtos
{ {
@ -116,7 +125,10 @@ namespace ApplicationServices
MyRatingOverall = a.Book.UserDefinedItem.Rating.OverallRating, MyRatingOverall = a.Book.UserDefinedItem.Rating.OverallRating,
MyRatingPerformance = a.Book.UserDefinedItem.Rating.PerformanceRating, MyRatingPerformance = a.Book.UserDefinedItem.Rating.PerformanceRating,
MyRatingStory = a.Book.UserDefinedItem.Rating.StoryRating, MyRatingStory = a.Book.UserDefinedItem.Rating.StoryRating,
MyLibationTags = a.Book.UserDefinedItem.Tags MyLibationTags = a.Book.UserDefinedItem.Tags,
BookStatus = a.Book.UserDefinedItem.BookStatus.ToString(),
BookLocation = a.Book.UserDefinedItem.BookLocation,
PdfStatus = a.Book.UserDefinedItem.PdfStatus.ToString()
}).ToList(); }).ToList();
} }
public static class LibraryExporter public static class LibraryExporter
@ -187,7 +199,10 @@ namespace ApplicationServices
nameof (ExportDto.MyRatingOverall), nameof (ExportDto.MyRatingOverall),
nameof (ExportDto.MyRatingPerformance), nameof (ExportDto.MyRatingPerformance),
nameof (ExportDto.MyRatingStory), nameof (ExportDto.MyRatingStory),
nameof (ExportDto.MyLibationTags) nameof (ExportDto.MyLibationTags),
nameof (ExportDto.BookStatus),
nameof (ExportDto.BookLocation),
nameof (ExportDto.PdfStatus)
}; };
var col = 0; var col = 0;
foreach (var c in columns) foreach (var c in columns)
@ -249,6 +264,9 @@ namespace ApplicationServices
col = createCell(row, col, dto.MyRatingStory); col = createCell(row, col, dto.MyRatingStory);
row.CreateCell(col++).SetCellValue(dto.MyLibationTags); row.CreateCell(col++).SetCellValue(dto.MyLibationTags);
row.CreateCell(col++).SetCellValue(dto.BookStatus);
row.CreateCell(col++).SetCellValue(dto.BookLocation);
row.CreateCell(col++).SetCellValue(dto.PdfStatus);
rowIndex++; rowIndex++;
} }

View File

@ -13,7 +13,7 @@
<!-- <PublishSingleFile>true</PublishSingleFile> --> <!-- <PublishSingleFile>true</PublishSingleFile> -->
<RuntimeIdentifier>win-x64</RuntimeIdentifier> <RuntimeIdentifier>win-x64</RuntimeIdentifier>
<Version>5.4.8.1</Version> <Version>5.4.8.3</Version>
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>