as I understand from your questions, you are trying to achieve a permission problem with settings. why don't you try to use Roles for this. add a permission to your admin role. or create a new TenantRole and add permissions to TenantRole. Setting system is more application related values (there's no scope for admins or users).
See the definition https://docs.abp.io/en/abp/latest/Settings#settingdefinition. There's no option for users
duplicate of #263. closing this one.
can you try to download this sample and check with the same configuration. I think it's not related with your angular code.
I'm closing this question.
You can also use PdfSharpCore library if you want to generate PDF in cross-platform. https://www.nuget.org/packages/PdfSharpCore/
First of all, the settings with the same key is being cached, so the second call will not go to database.
Also, you can inject ISettingProvider
and use GetAllAsync()
to retrieve all. it's better than getting 30 of them.
If you want to multiple features you can also injectIFeatureValueRepository
see
https://github.com/abpframework/abp/blob/dev/modules/feature-management/src/Volo.Abp.FeatureManagement.Domain/Volo/Abp/FeatureManagement/FeatureManagementStore.cs
in ABP v3.0 settings and permission usage will be refactored and will be made more performance
can you check this https://aspnetboilerplate.com/Pages/Documents/Zero/Organization-Units#common-use-cases it's very similar
you can hide the endpoints easily, see https://support.abp.io/QA/Questions/264/How-to-hide-an-endpoint-from-Swagger
To hide endpoints in Swagger, you can use IDocumentFilter
of the Swashbuckle.
class HideOrganizationUnitsFilter : IDocumentFilter
{
private const string pathToHide = "/identity/organization-units";
public void Apply(OpenApiDocument swaggerDoc, DocumentFilterContext context)
{
var organizationUnitPaths = swaggerDoc
.Paths
.Where(pathItem => pathItem.Key.Contains(pathToHide, StringComparison.OrdinalIgnoreCase))
.ToList();
foreach (var item in organizationUnitPaths)
{
swaggerDoc.Paths.Remove(item.Key);
}
}
}
in ConfigureSwaggerServices
, add this document filter
private void ConfigureSwaggerServices(IServiceCollection services)
{
services.AddSwaggerGen(
options =>
{
options.SwaggerDoc("v1", new OpenApiInfo {Title = "MyProjectName API", Version = "v1"});
options.DocInclusionPredicate((docName, description) => true);
options.CustomSchemaIds(type => type.FullName);
options.DocumentFilter<HideOrganizationUnitsFilter>(); //<-------- added this -----------
}
);
}
I want to hide the organization unit endpoints in Swagger
Forgotten User: The logic and emails for Forgotten User is together in this.accountService.sendPasswordResetCode. If I am using my own emailer I need to replace this with my own endpoint. What do I need to send. In .Net Core Identity I would do something like this but I don't know what to do is this case because I can't see the code.
to replace the existing email sender service; https://support.abp.io/QA/Questions/260/How-to-replace-the-existing-email-sender-with-my-own#answer-cc999500-981c-25df-e932-39f5f3e7f71b