I have a Laserfiche Forms business process where tasks are assigned to a Laserfiche Team. Template files are then copied to a repo folder through workflow so they can edit, but the individual team members can't view the files as they don't have access rights to the folder or files.
I can't find how to apply repo access rights to Forms Team members in Workflow.
You can apply rights to an individual user account through the Assign Rights action, so I started down the rabbit hole of trying to obtain every member of the team through SQL and then run a For Each to apply access rights to the individual. The only problem is my SQL query keeps returning users that are not part of the team and I'm not sure why.
DECLARE @teamName VARCHAR(100); SET @teamName = 'My Team Name'; SELECT t.name AS teamname ,t.id AS teamid ,u.username ,u.user_id AS username_id ,u.displayname ,u.email ,tm.leave_date FROM [LF_FORMS].[dbo].[cf_users] AS u --user table INNER JOIN [LF_FORMS].[dbo].[team_members] AS tm --team membership one-to-many table ON tm.[user_group_id] = u.[user_id] AND tm.leave_date IS NULL --check to see if user has left the team AND u.is_activated = '1' --check to see if user has active account INNER JOIN [LF_FORMS].[dbo].[teams] AS t --team table ON t.id = tm.team_id WHERE t.name = @teamName
Has anyone else already solved this with a better method? If not, is there a suggestion to retool my SQL query to properly obtain team members?
Thank you!