Base solution for your next web application

Activities of "moretl"

Yes I try,

I add a new entry in my xml file for localization with this key "Identity.DuplicateName" and french translation for value...

but it doesn't work... I always see english default message :/

I think the better place is in domain service !

domain services return entity

application services ask to domain service, get entity and return a dto with automapper...

here, <a class="postlink" href="http://aspnetboilerplate.com/Pages/Documents/Domain-Services">http://aspnetboilerplate.com/Pages/Docu ... n-Services</a> you can read this : "Unlike Application Services which gets/returns Data Transfer Objects, a Domain Service gets/returns domain objects (like entities or value types)."

Thank you for your reply, but after searching , I come to the conclusion that the message is generated by the method AbpUserManager.CheckDuplicateUsernameOrEmailAddressAsync ... Here are its contents (<a class="postlink" href="https://www.symbolsource.org/Public/Metadata/NuGet/Project/Abp.Zero/0.7.1.0/Release/.NETFramework,Version=v4.5.1/Abp.Zero/Abp.Zero/Authorization/Users/AbpUserManager.cs">https://www.symbolsource.org/Public/Met ... Manager.cs</a>) :

public virtual async Task<IdentityResult> CheckDuplicateUsernameOrEmailAddressAsync(long? expectedUserId, string userName, string emailAddress) { var user = (await FindByNameAsync(userName)); if (user != null && user.Id != expectedUserId) { return AbpIdentityResult.Failed(string.Format(L("Identity.DuplicateName"), userName)); }

        user = (await FindByEmailAsync(emailAddress));
        if (user != null && user.Id != expectedUserId)
        {
            return AbpIdentityResult.Failed(string.Format(L("Identity.DuplicateEmail"), emailAddress));
        }

        return IdentityResult.Success;
    }

Hello,

I would change default error message on UserManager base class. I see that this class use LocalizationManager but even if I add "Identity.DuplicateName" key with french traduction in my xml file, it doesn't work... I don't understand why Thanks

Showing 1 to 4 of 4 entries