2021-11-14 04:27:59 +00:00
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.ComponentModel.DataAnnotations;
|
2021-11-21 06:47:10 +00:00
|
|
|
|
using System.Text.Json.Serialization;
|
2021-11-14 04:27:59 +00:00
|
|
|
|
|
|
|
|
|
namespace Start.Shared {
|
|
|
|
|
public class BookmarkContainerDto {
|
|
|
|
|
public int BookmarkContainerId { get; set; }
|
2021-11-29 00:21:15 +00:00
|
|
|
|
[Required]
|
2021-11-14 04:27:59 +00:00
|
|
|
|
[StringLength(300)]
|
|
|
|
|
public string Title { get; set; }
|
|
|
|
|
|
|
|
|
|
public IList<BookmarkGroupDto>? BookmarkGroups { get; set; }
|
|
|
|
|
|
|
|
|
|
public BookmarkContainerDto(string title) {
|
|
|
|
|
this.Title = title;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public BookmarkContainerDto(int bookmarkContainerId, string title) : this(title) {
|
|
|
|
|
this.BookmarkContainerId = bookmarkContainerId;
|
|
|
|
|
}
|
|
|
|
|
|
2021-11-21 06:47:10 +00:00
|
|
|
|
[JsonConstructor]
|
2021-11-14 04:27:59 +00:00
|
|
|
|
public BookmarkContainerDto(int bookmarkContainerId, string title,
|
2021-11-16 05:44:16 +00:00
|
|
|
|
IList<BookmarkGroupDto>? bookmarkGroups) : this(bookmarkContainerId, title) {
|
2021-11-14 04:27:59 +00:00
|
|
|
|
this.BookmarkGroups = bookmarkGroups;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|