if i have two entities, and i need some metadata on their relatuonship, is best pactice to create an entity with FKs and properties, and use the rad tool to generate with no UI, etc?
I figured it out, the documentation has a bug in it.
In Main Definition section, it says to inert:
var helloWorld = new WidgetDefinition(
id:AbpZeroTemplateDashboardCustomizationConsts.Widgets.Tenant.HelloWorld,
name:"WidgetRecentTenants",//localized string key
side: MultiTenancySides.Tenant,
usedWidgetFilters: new List<string>() { helloWorldFilter.Id },// you can use any filter you need
permissions: tenantWidgetsDefaultPermission);
What is Should say is:
var helloWorld = new WidgetDefinition(
id:AbpZeroTemplateDashboardCustomizationConsts.Widgets.Tenant.HelloWorld,
name:"WidgetHelloWorld",//localized string key
side: MultiTenancySides.Tenant,
usedWidgetFilters: new List<string>() { helloWorldFilter.Id },// you can use any filter you need
permissions: tenantWidgetsDefaultPermission);
I think I found a way other than making the permission host only in the auth provider, adding a property to every permission "HostOnlyAssignable", true | false.
Then, I add a permission to host only, for HostOnlyAssign.
Then, in the common controller, when it builds the tree, I remove any permissions from the list that where that property is set so they don't show up in the tree.
In this way, the tenant admin can have permissions to DynamicProperties, but cannot assign that permission to another role - or even remove that permission from themselves.
If I could do this based on edition - that might be the way to go.
What I'm trying to do is hide certain permissions from being assignable by a tenant.
For example, I have several entities the Tenant manages.
Be default, I have static roles that have permissions assigned for the entities.
What I'm trying to do is allow the Tenant admin create a new role, and assign permissions for the entities.
However, when they're assigning roles, I do not want some of the permissions to be visible when the admin is assigning roles. Such as WebHooks.
I don't want the tenant admin to be able to assign them to any other role, so I do not want them visible when editing / creating roles.
I do, however, want the tenant admin to be able to see web hooks permission.
In summary, what I'm trying to do is limit the assignable permissions for the tenant.
I want the tenant admin to only allow to create roles and apply permissions for entities, but be unable to grant all the permisisons under administration, except for things like audit logs, organization units, Subscription.
In effect, what I'm thinking is the answer is to use Properties on permissions.
In the Properties for the permissions, I could assign a custom string that defines a permission I'd create in the AppPermissions (similar to Pages permission structure).
For reference - fix is here ->
https://github.com/aspnetzero/aspnet-zero-core/commit/3f46dddff97d31bf03650acc6836e4b0de4e0a34
Publish works. npm run create-bundles works. npm run build craps out here:
let btnEdit = `#${_args.name}-list .alert-close .editBtn`;
$(document).on('click', btnEdit, function () {
let parent = $(this).closest(".alert");
let index = parent.attr("data-index");
let item = _keyValueItems[index];
manageEditMode(item?.key);
});
in the file
_keyValueListManager.js
For diagnostic purposes only, I removed the ? from both item?key calls and it passed without issue - then failed on datatables when it used ??
@andyfuw - Did you find a workaround for this?
Is there a temprorary work around for this?
I'm also getting this error - breaking deployments to production.
I don't get the error when running create-bundles gulp
I think I see a bug fix in 8.9.2 for this, I think.
These are non-modal CreateOrEdit forms.