44 lines
1.1 KiB
C#
44 lines
1.1 KiB
C#
using System.ComponentModel.DataAnnotations;
|
|
using System.ComponentModel.DataAnnotations.Schema;
|
|
|
|
namespace CampusErrand.Models;
|
|
|
|
/// <summary>
|
|
/// 门店表
|
|
/// </summary>
|
|
public class Shop
|
|
{
|
|
[Key]
|
|
public int Id { get; set; }
|
|
|
|
/// <summary>门店名称</summary>
|
|
[MaxLength(64)]
|
|
public string Name { get; set; } = string.Empty;
|
|
|
|
/// <summary>门店照片</summary>
|
|
[MaxLength(512)]
|
|
public string Photo { get; set; } = string.Empty;
|
|
|
|
/// <summary>门店位置</summary>
|
|
[MaxLength(256)]
|
|
public string Location { get; set; } = string.Empty;
|
|
|
|
/// <summary>注意事项</summary>
|
|
[MaxLength(1024)]
|
|
public string? Notice { get; set; }
|
|
|
|
/// <summary>打包费类型</summary>
|
|
public PackingFeeType PackingFeeType { get; set; }
|
|
|
|
/// <summary>打包费金额</summary>
|
|
[Column(TypeName = "decimal(10,2)")]
|
|
public decimal PackingFeeAmount { get; set; }
|
|
|
|
/// <summary>是否启用</summary>
|
|
public bool IsEnabled { get; set; } = true;
|
|
|
|
// 导航属性
|
|
public ICollection<ShopBanner> ShopBanners { get; set; } = [];
|
|
public ICollection<Dish> Dishes { get; set; } = [];
|
|
}
|