Appanvil karma designer | ||||
---|---|---|---|---|
|
Anchor | ||||
---|---|---|---|---|
|
Appanvil karma designer | ||||
---|---|---|---|---|
|
Hello there! In this video, section you will learn about entities in ACDI reports, what they mean, how to create reports with entities, as well as how to manage entity filters and display attributes of secondary entities in final reports.
If you need a report that will display values for different objects linked with each other by an attribute like groups and its members, roles and users, role requests, approvers, requester, request, target user, etc., you must add a secondary entity or entities to a report.
...
Anchor | ||||
---|---|---|---|---|
|
Appanvil karma designer | ||||
---|---|---|---|---|
|
Let's create a report that will show you data about all roles assigned to a user. This report will be created based on data from the snapshot. In ACDI there is a default Users Report which has only one entity, namely, a user from snapshot.
...
Your custom report will appear on the reports list.
...
Anchor | ||||
---|---|---|---|---|
|
Appanvil karma designer | ||||
---|---|---|---|---|
|
You may want to update some tags to use them later for placing the report in an appropriate submenu.
...
The entry in the “DateTime” field remains the same as for the copied entity, as do the entries in the “Entity Index” and “Entity primary key” fields.
...
Anchor | ||||
---|---|---|---|---|
|
Appanvil karma designer | ||||
---|---|---|---|---|
|
The next step is to create a link between the two entities.
...
Select here “many” to “one.” Let's save the settings.
...
Anchor | ||||
---|---|---|---|---|
|
Appanvil karma designer | ||||
---|---|---|---|---|
|
It’s time to add a few filters for a role. Let’s assume you will want to filter by “CN.”
...
Now you see all users and their information. You will probably want to display information about the roles themselves. Let's then add additional data to the “Role” entity.
...
Anchor | ||||
---|---|---|---|---|
|
Appanvil karma designer | ||||
---|---|---|---|---|
|
Go to the “Result Table attributes” where you can remove user attributes you don't want to be displayed and add a new field for entity “Role.”
...
The roles have long descriptions and names with all localizations available. This info can be handled with the help of postprocessing. Let’s create a postprocessing function to enable the postprocessing.
...
Anchor | ||||
---|---|---|---|---|
|
Appanvil karma designer | ||||
---|---|---|---|---|
|
Let's give it a name “getLocEng.” Here you have a ready-to-use function that will do the postprocessing for you. Now save the changes in your report and implement them to attributes you want to be processed by this function.
...
So you can see here that the table has a flat view - a row per role and columns for each secondary entity are displayed.
...
Anchor | ||||
---|---|---|---|---|
|
Appanvil karma designer | ||||
---|---|---|---|---|
|
But what can you do if entities are linked with some attributes that are located inside a CSV string or inside XML or JSON? Let`s see.
...
“nrfAssignedRoles” or the direct role assignment. You see here that the user object contains an attribute with value in CSV format and the DN of the role is the first part of this string and is separated with the “#” symbol. So, somehow you need to parse this DN from on one hand, and on another hand, you need to set it as a regular expression. What can be done in this case?
...
You can use “regex” functionality and postprocessing!
...
Let's go back to postprocessing. In this video functions prepared beforehand will be used to transform the strings.
...
The first one will be named “relation_role_fix_to” and with this function, you will get the first substring from this string separated by a hash.
...
The second function will be named “relation_role_fix_ from” and it will create a regular expression that will allow you to find the value you need. Let’s save everything and go back to entities.
...
From the snapshot side, you will need to use “term” because you will have DN in a user and it will relate to “relation_role_fix_to.”
...
Let's enable transformation and link the secondary entity by exact datetime.
...
From the role side, you’ll need to update this linkage to “regex” - regular expression - and switch to “relation_role_fix_ from.”
...
Make sure you don't forget to enable transformation.
...
You must also change the name of the attribute because previously you used “nrfMemberOf” and now you will be using “nrfassignedroles.”
...
The same values must be set in two entities.
...
Okay, let's save the changes and check the results. Refresh the page and run the report. Here are the results.
...
Here are the results.
...
You can learn more about the options and possibilities of ACDI Reporting in SKyPRO Academy. Thank you for your attention and take care.
Should you have any questions or require any assistance, please do not hesitate to contact us at any time swsupport.skypro@skypro.ch