Please answer the following questions before submitting an issue. YOU MAY DELETE THE PREREQUISITES SECTION.
I try to create user from backend with code automatically - and assign to default role.
Is this correkt like this?
Thanks for a hint - currently it seems not working. ( result = await _userManager.SetRolesAsync(user, role);)
//get Employee role value for existing & create new if not existing
IQueryable<Role> query = _roleManager.Roles;
Role roleExists = GetRole(query);
string roleName="";
if (roleExists != null)
{
try
{
roleName = query.ToList().FirstOrDefault(x => x.IsDefault == true).Name;
Logger.Info("roleName = query.ToList().FirstOrDefault(x => x.IsDefault == true).Name");
}
catch(Exception ex)
{
Logger.Error(ex.Message.ToString());
}
}
else
{
Role newRole = new Role(tenantId, "Employee") { IsDefault = false, Name = "Employee" };
CheckErrors(await _roleManager.CreateAsync(newRole));
await CurrentUnitOfWork.SaveChangesAsync();
roleExists = GetRole(query);
roleName = roleExists.Name;
Logger.Info("Role newRole = new Role(tenantId");
}
string[] role = new string[] { roleName };
result = await _userManager.SetRolesAsync(user, role);
Logger.Info("await _userManager.SetRolesAsync(user, role)");
if (!result.Succeeded)
{
throw new UserFriendlyException(L("UserRollNotAssigned"));
}
Please answer the following questions before submitting an issue. YOU MAY DELETE THE PREREQUISITES SECTION.
I try to publish the angular and wep api porject in two separate virtuell diretories instead own websites - is this possible - currently I don't get it up and running. The api .NET CORE throws http error 404 - not found
Any idea?
Page not found" error when I'm following the link on GitHub https://github.com/aspnetzero/aspnet-zero-core
I got here "Page not found" error when I'm following the link on GitHub https://github.com/aspnetzero/aspnet-zero-core
Please answer the following questions before submitting an issue. YOU MAY DELETE THE PREREQUISITES SECTION.
Please provide a tutorial for Elsa 2 Integration for Angluar and .NET CORE ASPZERO Solution (as you did for MVC) - it's urgent request - thanks!
Please answer the following questions before submitting an issue. YOU MAY DELETE THE PREREQUISITES SECTION.
We are working on the ESLA 2 Workflow integration - it works so far - but we have an issue with ESLA 2 Workflow Designer UI We have a Cross origins issue error. We tried "AllowedHosts": "*" - see below. Any idea?
{
"Logging": { "LogLevel": { "Default": "Information", "Microsoft": "Warning", "Microsoft.Hosting.Lifetime": "Information" } }, "Elsa": { "Server": { "BaseUrl": http://localhost:5001 } }, "Smtp": { "Host": "smtpserver.domainname", "Port": "25", "DefaultSender": [email protected] }, "AllowedHosts": "*" }