Activities of "maliming"

hi

We have released the new leptonX packages.

Please upgrade it to latest(3.2.1) to fix the user avatar problem

Answer

hi

Please send an email to liming.ma@volosoft.com

I will share you the project.

Answer

hi

Do you have a DNS map on your local machine?

eg:

extranetapp.cinca.porc to 127.0.0.1

We have to get the DNS for the domain from inside and outside the container.

Answer

hi

Can you share a test project?

I will test it in my local docker.

liming.ma@volosoft.com

hi

Join again : )

https://us05web.zoom.us/j/84339905664?pwd=RbkuzUzEgIzn0sZUT2ia7Ne6IObWLU.1

hi

https://us05web.zoom.us/j/82128719932?pwd=NSkf1WcgITWWyrGKvgMw8xqrZnFaeC.1

hi

url: greentherm.app.localhost
templateUrl: https://{0}.app.localhost:44399

Try the code below:

[Dependency(ReplaceServices = true)]
[ExposeServices(typeof(IMultiTenantUrlProvider), typeof(MultiTenantUrlProvider))]
public class WebAssemblyMultiTenantUrlProvider : MultiTenantUrlProvider
{
    private readonly static string[] ProtocolPrefixes = ["http://", "https://"];

    protected NavigationManager NavigationManager { get; }
    protected ILogger<WebAssemblyMultiTenantUrlProvider> Logger { get; }

    public WebAssemblyMultiTenantUrlProvider(
        ICurrentTenant currentTenant,
        ITenantStore tenantStore,
        NavigationManager navigationManager,
        ILogger<WebAssemblyMultiTenantUrlProvider> logger)
        : base(currentTenant, tenantStore)
    {
        NavigationManager = navigationManager;
        Logger = logger;
    }

    public async override Task<string> GetUrlAsync(string templateUrl)
    {
        Logger.LogError("templateUrl: " + templateUrl); // https://{0}.app.localhost:44399

        if (!CurrentTenant.IsAvailable)
        {
            var absoluteUri = NavigationManager.ToAbsoluteUri(NavigationManager.Uri);
            var url = absoluteUri.Authority.RemovePostFix("/");
            Logger.LogError("url: " + url); // greentherm.app.localhost:44399
            
            var myTemplateUrl = templateUrl.RemovePreFix(ProtocolPrefixes).RemovePostFix("/");
            Logger.LogError("myTemplateUrl: " + url); // {0}.app.localhost:44399
            
            var extractResult = FormattedStringValueExtracter.Extract(url, myTemplateUrl, ignoreCase: true);
            if (extractResult.IsMatch)
            {
                var tenant = extractResult.Matches[0].Value; // should be greentherm
                Logger.LogError("tenant: " + tenant);
                
                var apiUrl = templateUrl.Replace("{0}", tenant);
                Logger.LogError("apiUrl: " + apiUrl); // https://greentherm.app.localhost:44399
                return apiUrl;
            }
            
            Logger.LogError("No match tenant found");
        }

        return await GetUrlAsync(templateUrl);
    }
}

Thanks.

hi

Please change "BaseUrl": "https://{{tenantName}}.safetyplus-dev.com" to "BaseUrl": "https://{0}.safetyplus-dev.com"

And try adding WebAssemblyMultiTenantUrlProvider to your blazer.client project and check the error messages in the browser console.

Thanks. I have refunded your ticket.

[Dependency(ReplaceServices = true)]
[ExposeServices(typeof(IMultiTenantUrlProvider), typeof(MultiTenantUrlProvider))]
public class WebAssemblyMultiTenantUrlProvider : MultiTenantUrlProvider
{
    private readonly static string[] ProtocolPrefixes = ["http://", "https://"];

    protected NavigationManager NavigationManager { get; }
    protected ILogger<WebAssemblyMultiTenantUrlProvider> Logger { get; }

    public WebAssemblyMultiTenantUrlProvider(
        ICurrentTenant currentTenant,
        ITenantStore tenantStore,
        NavigationManager navigationManager,
        ILogger<WebAssemblyMultiTenantUrlProvider> logger)
        : base(currentTenant, tenantStore)
    {
        NavigationManager = navigationManager;
        Logger = logger;
    }

    public async override Task<string> GetUrlAsync(string templateUrl)
    {
        Logger.LogError("templateUrl: " + templateUrl); // https://{0}.safetyplus-dev.com

        if (!CurrentTenant.IsAvailable)
        {
            var absoluteUri = NavigationManager.ToAbsoluteUri(NavigationManager.Uri);
            var url = absoluteUri.Host;
            Logger.LogError("url: " + url); // greentherm.safetyplus-dev.com

            var extractResult = FormattedStringValueExtracter.Extract(url, templateUrl, ignoreCase: true);
            if (extractResult.IsMatch)
            {
                var tenant = extractResult.Matches[0].Value; // should be greentherm
                Logger.LogError("tenant: " + tenant);
                
                var apiUrl = templateUrl.Replace("{0}", tenant);
                Logger.LogError("apiUrl: " + apiUrl); // https://greentherm.safetyplus-dev.com
                return apiUrl;
            }

            Logger.LogError("No match tenant found");
        }

        return await GetUrlAsync(templateUrl);
    }
}

hi

I found the problem. I will provide the solution soon

hi

Can I check it by zoom?

https://us05web.zoom.us/j/87291194012?pwd=PmbAE6qr5bCKGGAnpRM3FKhfI7i24a.1

You can join and share your screen.

Thanks

Showing 541 to 550 of 7738 entries
Made with ❤️ on ABP v9.0.0-preview Updated on September 23, 2024, 13:33