We previously had a requirement to setup a List field that gave a specific user the ability to select a different user from the List based on specific Department listings. Prior to the availability we used static List field types on the LF Template but this was always a problem to keep updated.
Once Dynamic Fields were introduced, we then managed to create a 'View' in a separated SQL DB that pointed to the data listed in the dbo.trustee table. This allowed us to then setup a Dynamic Field that would filter on Group, and make available the users from that group for selection on the Template. This works well as maintenance is so much more simple. By removing the User from the Group when they leave, the User is no longer available for selection on the Template.
This has been running for more than I year now using the Laserfiche Accounts.
We are however in the process to switch over to Windows Accounts and just noticed that the Windows Account is not recorded in the dbo.trustee table. So even though the Windows Account has been added to the respective Group the User details is not available in the trustee table.
Here is a snippet of the code used to create the view:
CREATE VIEW [dbo].[Trustees_ViewDept1] AS SELECT a.trustee_name AS [User], c.trustee_name AS [Group], AFSLaserficheQA.dbo.trustee_attr.attr_name, CAST(AFSLaserficheQA.dbo.trustee_attr.attr_val AS varchar(10)) AS attr_val FROM AFSLaserficheQA.dbo.trustee AS a INNER JOIN AFSLaserficheQA.dbo.grouplist AS b ON b.member_id = a.trustee_id INNER JOIN AFSLaserficheQA.dbo.trustee AS c ON b.group_id = c.trustee_id INNER JOIN AFSLaserficheQA.dbo.trustee_attr ON a.sid = AFSLaserficheQA.dbo.trustee_attr.sid WHERE (c.trustee_name <> 'Administrators') AND (c.trustee_name IN ('Customer Admin', 'Procurement', 'Manual Transactions')) AND (AFSLaserficheQA.dbo.trustee_attr.attr_name = '[Workflow]CompanyID') GO
Below is screenshots indicating how the Dynamic Field is used for user selection. Initially only the normal Laserfiche Account and then After that once a Windows Account has been added to the Group.
Now after the Windows Account is Added:
We checked the Trustee table and found no trace of the Windows Account which is why we assume out view does not work as expected.
We would therefor Like to know which table contains the Windows Account Info as we would need to amend our View to include the details from there.
the Basis of the view is to give a listing of the Users in respective groups and filtered on a Custom Attribute that is captured on each of the Users. The Sale Attribute is also captured on the Windows accounts, and through Tests in Workflow, we have noticed that the Attribute value resolve correctly.