I have my client based on angular, as usual, I decide to create a desktop version of it using electron, it is working. The only problem that I am facing, is on auth-server, when loading https://localhost:44322/Account/Login jquery is not loagin properly, when i load from electron app, Network
I am assuming it is because jquery is loaded after LeptonX.global js is loaded
so, my question is,
is it possible to override a bundles, global bundles to make jquery be present first. is it possible to override the main layout.cshtml like vies/pages/_Layout.cshtml to load jquery manually here
any idea is welcome
I did, and it is not working
is it possible that you help me on a meeting?
Fetch error Failed to fetch https://localhost/swagger/v1/swagger.json Fetch error Possible cross-origin (CORS) issue? The URL origin (https://localhost) does not match the page (https://web-gateway.elevos.app). Check the server returns the correct 'Access-Control-Allow-*' headers.
I am facing an error on production environment, I would like to set a meeting to check and resolve this issue ASAP please
{ "ServiceKey": , "ServiceDns": , "DownstreamPathTemplate": "/api/product-service/{everything}", "DownstreamScheme": "https", "DownstreamHostAndPorts": [ { "Host": "localhost", "Port": 44361 } ], "UpstreamPathTemplate": "/api/product-service/{everything}", "UpstreamHttpMethod": [ "Put", "Delete", "Get", "Post" ] },
is there any documentation about "ServiceDns" on ocelot configuration?
I would like to know:
1: how to replace or override a function over EntityHelper or any other static helper. EntityHelper.TrySetId is causing a lot of problems on my system, the GUIDs do not match the standard for GUIDs [a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[afA-F0-9]{12}
2: if it is possible to stop the Id generation setting as default configuration on module setup
3: One example of how to use DisableIdGenerationAttribute
Let me know when you fix this problem please to delete my own implementation
Error on generating GUID, portion of code from repository to set Id
Class EfCoreRepository
`protected virtual void CheckAndSetId(TEntity entity) { if (entity is IEntity
protected virtual void TrySetGuidId(IEntity<Guid> entity)
{
if (entity.Id != default)
{
return;
}
EntityHelper.TrySetId(
entity,
() => GuidGenerator.Create(),
true
);
}`
the guid generated does not match the pattern for GUIDs [a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12} based on https://datatracker.ietf.org/doc/html/rfc4122
Partial solution
public class GuidValueGenerator : ValueGenerator<Guid> { private readonly IGuidGenerator _guidGenerator; private readonly string pattern = @"^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$";
public override bool GeneratesTemporaryValues => false;
public GuidValueGenerator()
{
var options = Options.Create(new AbpSequentialGuidGeneratorOptions());
options.Value.DefaultSequentialGuidType = SequentialGuidType.SequentialAtEnd;
_guidGenerator = new SequentialGuidGenerator(options);
}
public override Guid Next(EntityEntry entry)
{
var result = GenerateNextValue();
string json = JsonConvert.SerializeObject(entry.Entity);
WriteOnText(result.ToString());
WriteOnText(json);
return result;
}
public Guid GenerateNextValue()
{
var result = _guidGenerator.Create();
if (!Regex.IsMatch(result.ToString(), pattern))
{
return GenerateNextValue();
}
return result;
}
public void WriteOnText(string newGuid)
{
string filePath = @"D:\guid-lines.txt"; // Replace with your file path
// Open the file for writing
using (StreamWriter writer = new StreamWriter(filePath, true))
{
writer.WriteLine(newGuid);
}
}
}
Solved
Check list about errors
Thanks so much for your help
Hi,
Open the ServiceBHttpClientModule class and change AddHttpClientProxies to AddStaticHttpClientProxies
You can search for
AddHttpClientProxies
globally and replace it withAddStaticHttpClientProxies
in the MicroserviceB solution.
Hi,
I am still facing a problem, is it possible to set a meeting to show you so you could help me find the error?