You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
1.0 KiB
38 lines
1.0 KiB
|
|
using System.ComponentModel.DataAnnotations;
|
|
using Admin.NET.Core;
|
|
using Nest;
|
|
using SqlSugar;
|
|
using Yitter.IdGenerator;
|
|
|
|
namespace Admin.Bodk.Customer.Entities;
|
|
/// <summary>
|
|
/// 客户表
|
|
/// </summary>
|
|
[SugarTable(null, "客户表")]
|
|
[SysTable]
|
|
public class Customer: EntityTenant, IRepositorySettings
|
|
{
|
|
[SugarColumn(ColumnDescription = "主键", IsPrimaryKey = true, IsIdentity = false)]
|
|
public long Id { get; set; } = YitIdHelper.NextId();
|
|
|
|
[SugarColumn(ColumnDescription = "客户名称", Length = 32)]
|
|
[Required, MaxLength(32)]
|
|
public virtual string? Name { get; set; }
|
|
|
|
[SugarColumn(ColumnDescription = "性别")]
|
|
[Required]
|
|
public virtual Sex Sex { get; set; }
|
|
|
|
[SugarColumn(ColumnDescription = "身份证号码", Length = 32,IsNullable = true)]
|
|
public virtual string IdNo { get; set; }
|
|
|
|
[SugarColumn(ColumnDescription = "手机号码", Length = 32,IsNullable = true)]
|
|
public virtual string PhoneNo { get; set; }
|
|
}
|
|
|
|
public enum Sex
|
|
{
|
|
Man = 1,
|
|
Woman = 0
|
|
}
|