Hello,
There is issue with Feature Toggle switch permissions when specifying team to a feature toggle.
When specifying Team to a Feature Toggle only one environment toggle switch is active, rest environments switches are inactive for a team member.
I tried to analyze the LifetimeTeams_Sync_ServiceAccount action logic and found following:
1. The only one record is inserted in LifetimeTeamUser user with first environment appeared in the list, remaining environments are missing because once GetUsersByUsername aggregate returns a result no more records will be inserted for user. The logic should check both, for the user and environment. So, the GetUsersByUsername must filter by user and environment.
2. HasChangePermissions is not updated for the existing users. If the team member role changed, so HasChangePermissions has new value, the change will not be updated in LifetimeTeamUser. There must be update part in the logic to fix this.
3. If by some reason user is not found at all (e.g. there might be inactive users), new record will be inserted to LifetimeTeamUser with UserId equal to 0. The logic must check if the user is found in the User table.
We have 'EnableLifetimeServiceAccount' set to 'True' so I have looked only to the Sync logic with 'ServiceAccount'.
Hope this helps.
Will be waiting for the new version with fixes.
Thanks.
Mikheil Osipov