Base solution for your next web application

Activities of "greatsamps"

Hi,

So thats what i tried last. I ran it under IIS using your web.config and i had the same issue. My config was in the nginx config file which was not present under IIS.

The whole thing feels like it is to do with relative paths settings. Surely there must be a way to tell Angular / ABP that the assets directory is always under root, never relative?

Hi,

Sorry for delay. So the issue is similar in that the problem is the same, where it differs however is that i am not serving it from a subfolder, its already in the root of the domain.

Thanks for that other link, but we are using using Nginx not IIS. Do you have an Nginx configuration file to use? We have already added the redirect to index.html to get the routing working, it's just the assets that are messed up.

Thanks,

UPDATE:

Just tried with IIS, using your config file and i have exactly the same problem.

I am building Angular using ng build --prod

is there anything else needed?

you can see an example of the problem here: https://cripto.compradivisas.com/account/login

Question

We are running ASP.NET Zero Angular on Nginx for an application we are about to launch. As angular is using its routing functionality, so by default, if one were to refresh the page, Nginx returns a 404 error as it can't find the routed path.

To correct this, we have added the following section to the Nginx configuration:

location / { try_files $uri $uri/ /index.html?$args; }

This is working, to the degree that if you perform a browser refresh, then the page now partially loads. The issue is that the paths for various assets are being distorted.

For example, we have a path on the site called Account/Login which is accessed like so:

http://site.name/Account/Login That page has a CSS file located within the assets folder. Normally when accessing the page completely through Angular routing (i.e. no refresh re-write), it would be located here:

http://site.name/Assets/CSS/Login.css What we are finding is that when the page is refreshed, and re-written, whilst it loads, the asset path distorts and becomes:

http://site.name/Account/Login/Assets/CSS/Login.css I suspect that this has nothing to do with Nginx and is, in fact, some configuration needed on the Angular side that will specify how the paths are referenced, but we are pretty new to Angular, so not sure where to start.

Any ideas?

Yeah i have already done that, but there seems to way to access the dashboard from angular. I have just disbaled authentication on handgire and am accessing it directly locally for now.

We are using the ASP.NET Core & Angular template. It seems that its not possible to access the Hangfire dashboard. Is this correct?

Question

Hi,

We are using the angular ASP.NET Core solution, and at least whilst in debug mode, any errors are recorded to a log file in the App_Data folder. Is there anyway to override this behaviour? It would be much more helpful to have it sent to the console, or even a logging framework such as Serilog...

Thanks,

I have taken an look at that, and whilst the symptoms are exactly the same, i do unfortunatally have that record in my settings database.

One other thing that i noticed that is a little odd. Under the host, i have all languages apart from english (en-GB) and spanish disabled, with english set to the default. When i log in under the tenant admin, i see all of the languages (including disabled ones) showing 'YES' under the default column, english is in bold with (default) written after it however.

Hi,

I am having some real issues with this combined with MultiTenancy. I have two languages enabled at host level, english and spanish, with english being the default. I have created a TenantLevel setting for the above name pointing it to spanish (es). This works well, you can browse to the tenant and its all in spanish.

The problem occurs when creating or logging in as a user. Looking at the database settings table, each time a page is loaded for a logged in user, an entry is created in the table for the above setting, with a value of "null". Due to this setting existing, but with a value of "null", it can't resolve the language and it reverts to the host default of english.

For the sake of clarity, when i say its set to "null" i mean a string comprising of 4 letters "null" not an actual NULL value.

I have tried looking at the source code, and i can't see where it is setting this value or why. I am currently working through the code trying to figure this out, but there is clearly something not right here.

Any ideas?

Kind Regards,

Done some more digging on this, and it appears that problem is related to this method:

public override Task DetermineProviderCultureResult(HttpContext httpContext)
{
if (httpContext == null)
{
throw new ArgumentNullException(nameof(httpContext));
}

    var localizationHeader = httpContext.Request.Headers[CookieRequestCultureProvider.DefaultCookieName];

    if (localizationHeader.Count == 0)
    {
        return Task.FromResult((ProviderCultureResult) null);
    }

    return Task.FromResult(ParseHeaderValue(localizationHeader));
}

var localizationHeader = httpContext.Request.Headers[CookieRequestCultureProvider.DefaultCookieName];

This cookie does not exist on the client, but it is still returning a result, with null as the culture id.

Hi,

Wondering if you can help here. Part of our project includes a library (written by us) that communicates with 3rd party systems via Akka.NET. What we are doing is starting the library and registering a static reference to a factory class during the startup routine in ASP.NET Boilerplate. Our ApplicationServices can talk to it, as its statically referenced, which is working fine.

The problem we are facing is that this library also needs to receive messages which need to be passed to an ApplicationService. Due to DI, this will not be as straightforward as sending the messages.

Does anyone have any pointers on how to go about doing this? My initial thoughts are to pass a reference to the DI framework when the library is initially started and using that, but as DI is pretty new to me, some pointers would be much appreciated1

So, i have done a little more digging. The problem seems to be localised to, if there are any rows that do not have any buttons showing (due to permissions etc), the entire column does not show.

If there is always at least 1 button showing on every row, then the permissions work as above.

Showing 1 to 10 of 18 entries