| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465 |
- using Abp.AutoMapper;
- using System.ComponentModel.DataAnnotations;
- using VberZero.AppService.Base.Dto;
- using VberZero.BaseSystem.Roles;
- namespace VberZero.AppService.Roles.Dto;
- [AutoMapTo(typeof(Role))]
- public class CreateRoleDto
- {
- [StringLength(Role.MaxNameLength)]
- public string Name { get; set; }
- [Required]
- [StringLength(Role.MaxDisplayNameLength)]
- public string DisplayName { get; set; }
- public string NormalizedName { get; set; }
- [StringLength(Role.MaxDescriptionLength)]
- public string Description { get; set; }
- public List<string> PermissionNames { get; set; }
- public CreateRoleDto()
- {
- PermissionNames = new List<string>();
- }
- /// <summary>
- /// 用户级别
- /// </summary>
- public virtual VzDefinition.UserType UserType { get; set; }
- /// <summary>
- /// 账户类型
- /// </summary>
- public VzDefinition.AccountType AccountType { get; set; }
- }
- [AutoMapTo(typeof(Role))]
- public class UpdateRoleDto : VzEntityDto<int>
- {
- //[Required]
- //[StringLength(Role.MaxNameLength)]
- //public string Name { get; set; }
- [Required]
- [StringLength(Role.MaxDisplayNameLength)]
- public string DisplayName { get; set; }
- public string NormalizedName { get; set; }
- [StringLength(Role.MaxDescriptionLength)]
- public string Description { get; set; }
- /// <summary>
- /// 用户级别
- /// </summary>
- public virtual VzDefinition.UserType UserType { get; set; }
- public List<string> PermissionNames { get; set; }
- }
|