mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-06-18 20:08:15 +08:00
- 增加 MaxLength 特性的解析,实体字符串长度设置;
This commit is contained in:
@ -1,6 +1,7 @@
|
||||
using FreeSql;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
public class UserGroup : BaseEntity<UserGroup, int>
|
||||
{
|
||||
@ -35,20 +36,24 @@ public class User1 : BaseEntity<User1, Guid>
|
||||
/// <summary>
|
||||
/// 登陆名
|
||||
/// </summary>
|
||||
[MaxLength(32)]
|
||||
public string Username { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 昵称
|
||||
/// </summary>
|
||||
[MaxLength(64)]
|
||||
public string Nickname { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 头像
|
||||
/// </summary>
|
||||
[MaxLength(1024)]
|
||||
public string Avatar { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 描述
|
||||
/// </summary>
|
||||
[MaxLength(4000)]
|
||||
public string Description { get; set; }
|
||||
}
|
||||
|
Reference in New Issue
Block a user