@@ -116,7 +116,7 @@ namespace IRaCIS.Api.Controllers
|
||||
[FromServices] IReadingImageTaskService readingImageTaskService,
|
||||
[FromServices] IOptionsMonitor<ServiceVerifyConfigOption> _verifyConfig,
|
||||
[FromServices] IOptionsMonitor<SystemEmailSendConfig> _emailConfig,
|
||||
[FromServices]IMapper _mapper,
|
||||
[FromServices] IMapper _mapper,
|
||||
[FromServices] IMailVerificationService _mailVerificationService)
|
||||
{
|
||||
var emailConfig = _emailConfig.CurrentValue;
|
||||
@@ -312,8 +312,8 @@ namespace IRaCIS.Api.Controllers
|
||||
{
|
||||
var token = _tokenService.GetToken(new UserTokenInfo()
|
||||
{
|
||||
UserRoleId = Guid.NewGuid(),
|
||||
UserName = "Share001",
|
||||
UserRoleId = Guid.NewGuid(),
|
||||
UserName = "Share001",
|
||||
UserTypeEnum = UserTypeEnum.ShareImage,
|
||||
|
||||
});
|
||||
@@ -375,7 +375,7 @@ namespace IRaCIS.Api.Controllers
|
||||
|
||||
[HttpGet("User/UserRedirect")]
|
||||
[AllowAnonymous]
|
||||
public async Task<IActionResult> UserRedirect([FromServices] IRepository<UserRole> _userRoleRepository, string url, [FromServices] ILogger<ExtraController> _logger)
|
||||
public async Task<IActionResult> UserRedirect([FromServices] IRepository<IdentityUser> _useRepository, string url, [FromServices] ILogger<ExtraController> _logger)
|
||||
{
|
||||
|
||||
var decodeUrl = System.Web.HttpUtility.UrlDecode(url);
|
||||
@@ -391,7 +391,7 @@ namespace IRaCIS.Api.Controllers
|
||||
var errorUrl = domainStrList[0] + "//" + domainStrList[2] + "/error";
|
||||
|
||||
|
||||
if (!await _userRoleRepository.AnyAsync(t => t.Id == Guid.Parse(userId) && t.EmailToken == token && t.IsFirstAdd))
|
||||
if (!await _useRepository.AnyAsync(t => t.Id == Guid.Parse(userId) && t.EmailToken == token && t.IsFirstAdd))
|
||||
{
|
||||
decodeUrl = errorUrl + $"?lang={lang}&ErrorMessage={System.Web.HttpUtility.UrlEncode(lang == "zh" ? "您的初始化链接已过期" : "Error!The initialization link has expired. Return")} ";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user