mirror of
https://github.com/Kareadita/Kavita.git
synced 2026-03-01 23:02:35 -05:00
* Fixed a typo in a log * Invalid XML files now "validate" correctly by sending back a failure. * Cleaned up messaging on backend and frontend to provide some linking on series name when collision, handle corrupt xml files, etc. * When reading list conflict occurs, show the reading list name that's conflicting. Started refactoring the code to allow multiple files to be imported at once. * Started adding new CBL elements for some enhancements I have planned with maintainers. * Default to empty string for IpAddress to allow to fallback into existing experience * Tweaked the layout of reading list page (not complete), moved some not used much controls to page extras and reordered the buttons for reading list * Edit Reading Lists now allows selection of cover image from existing items * Fixed a bug where cover chooser base64 to image would fail to write webp files. * Refactored the validate step to now handle multiple files in one go. * Clean up code * Don't show CBL name if there were xml errors that prevented showing it * Don't allow user to go prev step after they perform the import. * Cleaned up the heading code for accordions * Fixed a bug with import keeping failed items * Sort the failures to the bottom of result windows * CBL import is pretty solid. Need one pass from Robbie on Reading List Page
65 lines
1.9 KiB
C#
65 lines
1.9 KiB
C#
using System.Collections.Generic;
|
|
using System.Xml.Serialization;
|
|
|
|
namespace API.DTOs.ReadingLists.CBL;
|
|
|
|
|
|
[XmlRoot(ElementName="Books")]
|
|
public class CblBooks
|
|
{
|
|
[XmlElement(ElementName="Book")]
|
|
public List<CblBook> Book { get; set; }
|
|
}
|
|
|
|
|
|
[XmlRoot(ElementName="ReadingList")]
|
|
public class CblReadingList
|
|
{
|
|
/// <summary>
|
|
/// Name of the Reading List
|
|
/// </summary>
|
|
[XmlElement(ElementName="Name")]
|
|
public string Name { get; set; }
|
|
|
|
/// <summary>
|
|
/// Summary of the Reading List
|
|
/// </summary>
|
|
/// <remarks>This is not a standard, adding based on discussion with CBL Maintainers</remarks>
|
|
[XmlElement(ElementName="Summary")]
|
|
public string Summary { get; set; }
|
|
|
|
/// <summary>
|
|
/// Start Year of the Reading List. Overrides calculation
|
|
/// </summary>
|
|
/// <remarks>This is not a standard, adding based on discussion with CBL Maintainers</remarks>
|
|
[XmlElement(ElementName="StartYear")]
|
|
public int StartYear { get; set; }
|
|
|
|
/// <summary>
|
|
/// Start Year of the Reading List. Overrides calculation
|
|
/// </summary>
|
|
/// <remarks>This is not a standard, adding based on discussion with CBL Maintainers</remarks>
|
|
[XmlElement(ElementName="StartMonth")]
|
|
public int StartMonth { get; set; }
|
|
|
|
/// <summary>
|
|
/// End Year of the Reading List. Overrides calculation
|
|
/// </summary>
|
|
/// <remarks>This is not a standard, adding based on discussion with CBL Maintainers</remarks>
|
|
[XmlElement(ElementName="EndYear")]
|
|
public int EndYear { get; set; }
|
|
|
|
/// <summary>
|
|
/// End Year of the Reading List. Overrides calculation
|
|
/// </summary>
|
|
/// <remarks>This is not a standard, adding based on discussion with CBL Maintainers</remarks>
|
|
[XmlElement(ElementName="EndMonth")]
|
|
public int EndMonth { get; set; }
|
|
|
|
/// <summary>
|
|
/// Issues of the Reading List
|
|
/// </summary>
|
|
[XmlElement(ElementName="Books")]
|
|
public CblBooks Books { get; set; }
|
|
}
|