feat: add role template and tenant role apis

This commit is contained in:
2025-12-05 20:55:56 +08:00
parent 373c97e965
commit 3a38ade302
12 changed files with 8799 additions and 2 deletions

View File

@@ -0,0 +1,40 @@
using MediatR;
using TakeoutSaaS.Application.Identity.Contracts;
namespace TakeoutSaaS.Application.Identity.Commands;
/// <summary>
/// 克隆角色模板。
/// </summary>
public sealed record CloneRoleTemplateCommand : IRequest<RoleTemplateDto>
{
/// <summary>
/// 源模板编码。
/// </summary>
public string SourceTemplateCode { get; init; } = string.Empty;
/// <summary>
/// 新模板编码。
/// </summary>
public string NewTemplateCode { get; init; } = string.Empty;
/// <summary>
/// 新模板名称(为空则沿用源模板)。
/// </summary>
public string? Name { get; init; }
/// <summary>
/// 新模板描述(为空则沿用源模板)。
/// </summary>
public string? Description { get; init; }
/// <summary>
/// 是否启用(为空则沿用源模板)。
/// </summary>
public bool? IsActive { get; init; }
/// <summary>
/// 权限编码集合(为空则沿用源模板权限)。
/// </summary>
public IReadOnlyCollection<string>? PermissionCodes { get; init; }
}