Hi,
First, you can add the logoUrl
, faviconUrl
to the SaasTenant
entity via Module Entity Extensions
https://docs.abp.io/en/abp/latest/Module-Entity-Extensions#quick-example
Then, you can customize the brand-component
to get the logoUrl
and faviconUrl
from the tenant(you can add an API).
https://docs.abp.io/en/commercial/latest/themes/lepton-x/angular-customization#brand-component
Also, I want to change the content of this Home section. Can I get some reference URL on how to do that ?
The HTML source code is in your project; you can make any changes you want.
Could you please share the full logs? thanks
Hi,
That's weird. Could you please share a simple project with me? i will check it.
my email is shiwei.liang@volosoft.com
Hi,
this is only a portion of the call stack, I can post the rest if needed (character limit)
Yes, please share the full error logs
Hi,
On the Dashboard page - http://localhost:4200/ - we call the API to get a list post from Blogging. Now we can not see the uploaded image
Is there any error message?
Hi,
You can change the current user context. For example:
public class MyBackgroundJob : AsyncBackgroundJob<MyBackgroundJobArgs>
{
private readonly ICurrentPrincipalAccessor _principalAccessor;
private readonly IdentityUserManager _identityUserManager;
public MyBackgroundJob(ICurrentPrincipalAccessor principalAccessor, IdentityUserManager identityUserManager)
{
_principalAccessor = principalAccessor;
_identityUserManager = identityUserManager;
}
public override async Task ExecuteAsync(MyBackgroundJobArgs args)
{
// get messages....
var messages = ....;
using (_principalAccessor.Change(await CreateUserClaimsPrincipalFromMessagesAsync(messages)))
{
//send messages here...
}
}
private async Task<ClaimsPrincipal> CreateUserClaimsPrincipalFromMessagesAsync(messages...)
{
var user = await _identityUserManager.FindByNameAsync(messages.UserName);
var roles = await _identityUserManager.GetRolesAsync(user);
var claims = new List<Claim>
{
new Claim(AbpClaimTypes.UserId, user.Id.ToString()),
new Claim(AbpClaimTypes.UserName, user.UserName),
new Claim(AbpClaimTypes.Email,user.Email),
new Claim(AbpClaimTypes.TenantId,user.TenantId?.ToString()),
};
claims.AddRange(roles.Select(x => new Claim(AbpClaimTypes.Role, x)));
return new ClaimsPrincipal(new ClaimsIdentity(claims));
}
}
Hi,
I can confirm it's a bug, and we will fix it in the next patch version.
Your ticket was refunded.