You add a MyProfileManagementPageContributorservice and remove two auth and pictures from the context.
public class MyAccountProfileManagementPageContributor : IProfileManagementPageContributor { public async Task ConfigureAsync(ProfileManagementPageCreationContext context) { var l = context.ServiceProvider.GetRequiredService<IStringLocalizer<AccountResource>>();
if (await IsPasswordChangeEnabled(context))
{
context.Groups.Add(
new ProfileManagementPageGroup(
"Volo-Abp-Account-Password",
l["ProfileTab:Password"],
typeof(AccountProfilePasswordManagementGroupViewComponent)
)
);
}
context.Groups.Add(
new ProfileManagementPageGroup(
"Volo-Abp-Account-PersonalInfo",
l["ProfileTab:PersonalInfo"],
typeof(AccountProfilePersonalInfoManagementGroupViewComponent)
)
);
}
protected virtual async Task<bool> IsPasswordChangeEnabled(ProfileManagementPageCreationContext context)
{
var userManager = context.ServiceProvider.GetRequiredService<IdentityUserManager>();
var currentUser = context.ServiceProvider.GetRequiredService<ICurrentUser>();
var user = await userManager.GetByIdAsync(currentUser.GetId());
return !user.IsExternal;
}
}
do I need to call this anywhere?
IProfileManagementPageContributor
do I need to use this code?
Hi
I want to remove two auth and picture tabs from the manage profile page so how can I delete or hide please let me know.
Thanks,
Sure, you can send your project to engin.veske@volosoft.com.
are u checking?
I've checked and write you an email back, can you check and apply it?
yes it's working now thanks much :)
Sure, you can send your project to engin.veske@volosoft.com.
are u checking?
Sure, you can send your project to engin.veske@volosoft.com.
Hi
I can't share project but I shared code and error in mail so can you pls check.
Does your .HttpApi.Host and .IdentityServer projects are running? It seems it couldn't get a response from localhost:44358 and localhost:63079
can u share mail id or can we connect on zoom?