I need to modify the SysSecurity Report so it shows the tree flattened (don't worry - I'm making a copy) so it can be easily imported into Excel for use by our auditors.
For instance, the report now has lines like this:
Permissions Security Keys [this is the header]
View Accounts payable [this is the parent security key]
View Daily [this is the a first-level child security key]
View Backorder Purchase Lines [this is a 2nd-level child key]
View Blanket Purchase Orders [this is a 2nd-level child key]
View Delayed Purchase Orders [this is a 2nd-level child key]
What I need is an Excel-friendly version:
Permissions Security Keys [this is the header]
View Accounts payable [this is the parent security key]
View Accounts payable > Daily
View Accounts payable > Daily > Backorder Purchase Lines
View Accounts payable > Daily > Blanket Purchase Orders
View Accounts payable > Daily > Delayed Purchase Orders
I've looked through the relevant classes, and I see where the tree is being developed, but I do not see how to make it flat, as above.
This seems to be where the tree is being built (in classe "SysUserSecurityReport"):
container getData()
{
FormTreeControl treeControl = dialog.formRun().control(tree.id());
;
infolog.mayReloadMenu(false);
this.initSysSecurity();
sysSecurity2.parmTree(treeControl);
sysSecurity2.load();
sysSecurity2.initViewControl(false);
sysSecurity2.initSecurityTable();
sysSecurity2.buildTree();
sysSecurity2.expandForReport();
sysSecurity2.drawTree();
infolog.mayReloadMenu(true);
return SysUserSecurityReport2::extractData(treeControl, this.parmMenu() != '');
}
Is there a way to "draw the tree flat"?
Thanks! Happy long weekend!