I am getting the following error and i dont see the sweetalert2.all.min.js in the folder /libs/sweetalert2/dist/sweetalert2.all.min.js
do i have to copy it in there manually?
AbpException: Could not find the bundle file '/libs/sweetalert2/dist/sweetalert2.all.min.js' for the bundle 'Lepton.Global'!
can you please let me know how i can do this ??
In our use case the users are not allowed to change their username so i have override the UpdatAsync to be as follows
(await UserManager.SetUserNameAsync(user, input.UserName)).CheckErrors();
The above line is what changes the SecurityStamp which forces the user out because we are using AbpSecurityStampValidator
to ensure that the same user cant be signed in concurrently using the same username.
public override async Task<IdentityUserDto> UpdateAsync(Guid id, IdentityUserUpdateDto input)
{
//ADDED BY VB: To check if all Roles avalible as per license have been consumed.
if (CurrentUser.UserName != "dfo.admin")
{
await CheckCurrentTenantsLicenseConsumed(id, input);
}
await IdentityOptions.SetAsync();
var user = await UserManager.GetByIdAsync(id);
user.ConcurrencyStamp = input.ConcurrencyStamp;
if (!string.Equals(user.UserName, input.UserName, StringComparison.InvariantCultureIgnoreCase))
{
if (await SettingProvider.IsTrueAsync(IdentitySettingNames.User.IsUserNameUpdateEnabled))
{
(await UserManager.SetUserNameAsync(user, input.UserName)).CheckErrors();
}
}
await UpdateUserByInput(user, input);
input.MapExtraPropertiesTo(user);
(await UserManager.UpdateAsync(user)).CheckErrors();
await CurrentUnitOfWork.SaveChangesAsync();
var userDto = ObjectMapper.Map<Volo.Abp.Identity.IdentityUser, IdentityUserDto>(user);
//ADDED BY VB: To send an email to the user notifying their prifile has changed
var ppmUser = await GetUserByEmail(input.Email);
await _subscriptionEmailer.SendPpmUserUpdatedEmailAsync(ppmUser, "MVC");
return userDto;
}
Thanks for you help @liangshiwei
I have discoverd a side effect when implementing this in our application to deal with concurrent user.
It seems when we updated the user via his profile or in the users table under Identity the security stamp is updated and the user is logged out.
can you please suggest how we can over come this, if the user is updating his profile or via the user table the user shouldn't update its seucirty stamp.
i have tried that it does wirk unless the user is authenticated
i think thia line is cauaing the problem for a tenant becuase the emailsetting should only be avalabile to the hist right ?
modules/setting-management/src/Volo.Abp.SettingManagement.Web/AbpSettingManagementWebModule.cs
Configure<RazorPagesOptions>(options =>
{
options.Conventions.AuthorizePage("/SettingManagement/Index", SettingManagementPermissions.Emailing);
});
abp new Acme.BookStore
*.DbMigrator
and then run the solution with *.Web
project as startup projectTest
Test
I tried 4.3.2 and i can't even navigate to the setting page i am getting "access denied" error,
please see issue https://support.abp.io/QA/Questions/1424/Access-Denied-to-Settings-Management-for-Tenant-on-432
i think there is bug in the new 4.3.2 Commercial template it is trying to acess the Email Settings tab as a tenant and redirecting to "Access Denied"
I think it is a bug becuase it is trying to access the Email Settings tab for the tenant and since the tenant doesn't have access to the Email Settings it is giving "Access Denied"