Activities of "alper"

Hello Albert,

So I went digging for my whole day yesterday into ABP and ABP commercial source code and I have found the issue :

The script that is responsible for setting the cookie is missing something :

function setLanguageToCookie(injector) { return () => { const sessionState = injector.get(SessionStateService); const document = injector.get(DOCUMENT); const cookieLanguageKey = injector.get(COOKIE_LANGUAGE_KEY); sessionState.getLanguage$().subscribe(language => { const cookieValue = encodeURIComponent(c=${language}|uic=${language}); document.cookie = ${cookieLanguageKey}=${cookieValue}; }); };

If the path of the cookie is not specified then it is assigned to the path of the current page, which causes the problem in my case ; thus the fix (tested) is to change the line :

document.cookie = ${cookieLanguageKey}=${cookieValue};

to

document.cookie = ${cookieLanguageKey}=${cookieValue};path=/;

I did change manually the generated script (main.js) on the server to test but I do not know where I should do this change for a clean fix.

Could you tell me in which file I should do the change before compiling ?

Thanks

Thomas

is this from the Angular project?

you can temporarily disable it for a while. this will filter down the probable problems

thanks for your feedback. the generated code looks complex for the standard inputs. but this format is designed to support navigation properties (1-n, n-n). that's why it looks ugly. I created an internal issue (10906) to make an enhancement on this code.

@maliming will be your point of contact for this issue

then I'm closing the issue. you can always reopen

ok. you can inform us about the recent status.

I know there was an issue like this before v5.3.0 but it should be fixed in application templates. is this a module template?

First, no need to run RUN abp login ******** -p ********

Copy your local ABP token file which is at %UserProfile%\.abp\cli\access-token.bin into your Docker container's target directory:

  • Windows => %UserProfile%\.abp\cli\
  • Linux => /home/user/.abp/cli/

approximately 7 days.

this doesn't seem to be a framework or ABP commercial template issue. it's related to IIS that's why better to ask on the IIS support website. On the other hand, you can try to change the cookie path in your module class.

services.ConfigureApplicationCookie(options =>
  {
    options.Cookie.Path = "/";
  });
Showing 351 to 360 of 1975 entries
Made with ❤️ on ABP v9.1.0-preview. Updated on November 11, 2024, 11:11