136 lines
3.8 KiB
C#
136 lines
3.8 KiB
C#
/*
|
||
*代码由框架生成,任何更改都可能导致被代码生成器覆盖
|
||
*如果数据库字段发生变化,请在代码生器重新生成此Model
|
||
*/
|
||
using System;
|
||
using System.Collections.Generic;
|
||
using System.ComponentModel.DataAnnotations;
|
||
using System.ComponentModel.DataAnnotations.Schema;
|
||
using System.Linq;
|
||
using System.Text;
|
||
using System.Threading.Tasks;
|
||
using SqlSugar;
|
||
using VolPro.Entity.SystemModels;
|
||
|
||
namespace VolPro.Entity.DomainModels
|
||
{
|
||
[Entity(TableCnName = "产品管理",TableName = "Demo_Product",DetailTable = new Type[] { typeof(Demo_ProductColor),typeof(Demo_ProductSize)},DetailTableCnName = "颜色,尺寸",DBServer = "SysDbContext")]
|
||
public partial class Demo_Product:SysEntity
|
||
{
|
||
/// <summary>
|
||
///
|
||
/// </summary>
|
||
[SugarColumn(IsPrimaryKey = true)]
|
||
[Key]
|
||
[Display(Name ="ProductId")]
|
||
[Column(TypeName="uniqueidentifier")]
|
||
[Required(AllowEmptyStrings=false)]
|
||
public Guid ProductId { get; set; }
|
||
|
||
/// <summary>
|
||
///商品名称
|
||
/// </summary>
|
||
[Display(Name ="商品名称")]
|
||
[MaxLength(100)]
|
||
[Column(TypeName="nvarchar(100)")]
|
||
[Editable(true)]
|
||
[Required(AllowEmptyStrings=false)]
|
||
public string ProductName { get; set; }
|
||
|
||
/// <summary>
|
||
///商品编号
|
||
/// </summary>
|
||
[Display(Name ="商品编号")]
|
||
[MaxLength(100)]
|
||
[Column(TypeName="varchar(100)")]
|
||
[Editable(true)]
|
||
[Required(AllowEmptyStrings=false)]
|
||
public string ProductCode { get; set; }
|
||
|
||
/// <summary>
|
||
///价格
|
||
/// </summary>
|
||
[Display(Name ="价格")]
|
||
[DisplayFormat(DataFormatString="18,2")]
|
||
[Column(TypeName="decimal")]
|
||
[Editable(true)]
|
||
[Required(AllowEmptyStrings=false)]
|
||
public decimal Price { get; set; }
|
||
|
||
/// <summary>
|
||
///审核状态
|
||
/// </summary>
|
||
[Display(Name ="审核状态")]
|
||
[Column(TypeName="int")]
|
||
public int? AuditStatus { get; set; }
|
||
|
||
/// <summary>
|
||
///备注
|
||
/// </summary>
|
||
[Display(Name ="备注")]
|
||
[MaxLength(500)]
|
||
[Column(TypeName="nvarchar(500)")]
|
||
[Editable(true)]
|
||
public string Remark { get; set; }
|
||
|
||
/// <summary>
|
||
///
|
||
/// </summary>
|
||
[Display(Name ="CreateID")]
|
||
[Column(TypeName="int")]
|
||
public int? CreateID { get; set; }
|
||
|
||
/// <summary>
|
||
///创建人
|
||
/// </summary>
|
||
[Display(Name ="创建人")]
|
||
[MaxLength(30)]
|
||
[Column(TypeName="nvarchar(30)")]
|
||
[Editable(true)]
|
||
public string Creator { get; set; }
|
||
|
||
/// <summary>
|
||
///创建时间
|
||
/// </summary>
|
||
[Display(Name ="创建时间")]
|
||
[Column(TypeName="datetime")]
|
||
[Editable(true)]
|
||
public DateTime? CreateDate { get; set; }
|
||
|
||
/// <summary>
|
||
///
|
||
/// </summary>
|
||
[Display(Name ="ModifyID")]
|
||
[Column(TypeName="int")]
|
||
public int? ModifyID { get; set; }
|
||
|
||
/// <summary>
|
||
///修改人
|
||
/// </summary>
|
||
[Display(Name ="修改人")]
|
||
[MaxLength(30)]
|
||
[Column(TypeName="nvarchar(30)")]
|
||
[Editable(true)]
|
||
public string Modifier { get; set; }
|
||
|
||
/// <summary>
|
||
///修改时间
|
||
/// </summary>
|
||
[Display(Name ="修改时间")]
|
||
[Column(TypeName="datetime")]
|
||
[Editable(true)]
|
||
public DateTime? ModifyDate { get; set; }
|
||
|
||
[Display(Name ="颜色")]
|
||
[ForeignKey("ProductId")][Navigate(NavigateType.OneToMany,nameof(ProductId),nameof(ProductId))]
|
||
public List<Demo_ProductColor> Demo_ProductColor { get; set; }
|
||
|
||
|
||
[Display(Name ="尺寸")]
|
||
[ForeignKey("ProductId")][Navigate(NavigateType.OneToMany,nameof(ProductId),nameof(ProductId))]
|
||
public List<Demo_ProductSize> Demo_ProductSize { get; set; }
|
||
|
||
|
||
|
||
}
|
||
} |