0
hungvt created
Check the docs before asking a question: https://docs.abp.io/en/commercial/latest/ Check the samples, to see the basic tasks: https://docs.abp.io/en/commercial/latest/samples/index The exact solution to your question may have been answered before, please use the search on the homepage.
- ABP Framework version: v3.1.2
- UI type: Angular Hi team, I using IIdentityUserAppService to call function CreateAsync. How to AllowAnonymous Authorize for Authorize IIdentityUserAppService Thank
1 Answer(s)
-
0
Hi,
Try:
[Dependency(ReplaceServices = true)] [ExposeServices(typeof(IIdentityUserAppService))] public class MyIdentityUserAppService : IdentityUserAppService { public MyIdentityUserAppService(IdentityUserManager userManager, IIdentityUserRepository userRepository, IIdentityRoleRepository roleRepository) : base(userManager, userRepository, roleRepository) { } [AllowAnonymous] public override async Task<IdentityUserDto> CreateAsync(IdentityUserCreateDto input) { var result = await base.CreateAsync(input); return result; } }