feat: 添加sample示例

This commit is contained in:
陈淳
2024-01-10 17:26:40 +08:00
parent a3f7c1e867
commit 2c8d579668
43 changed files with 907 additions and 1 deletions

View File

@@ -0,0 +1,24 @@
using System.ComponentModel.DataAnnotations;
using Acme.BookStore.Domain.Shared.Enums;
namespace Acme.BookStore.Application.Contracts.Dtos.Book
{
public class BookCreateUpdateDto
{
[Required]
[StringLength(128)]
public string Name { get; set; }
[Required]
public BookTypeEnum Type { get; set; } = BookTypeEnum.Undefined;
[Required]
[DataType(DataType.Date)]
public DateTime PublishDate { get; set; } = DateTime.Now;
[Required]
public float Price { get; set; }
}
}