Skip to content

Conversation

@cory-colt
Copy link

This is to customize the implementation I'm using to help manage a lot of user accounts and who has access to what forms. Functionality was added when a folder is created and deleted. When a folder is created it will:

  1. Look up all of the users within Umbraco
  2. Get all of the users' Content Start Nodes
  3. Compare the users' Content Start Node (names) with the Perplex Folder name, if they match then it will auto-assign the user to include the folder as a Form Start Node.

When a folder is deleted, Perplex seems to leave abandoned records within the perplexUmbracoUser table, which would ordinarily be fine, but not for my specific requirements, so I've added code to remove these abandoned records once the form is deleted.

Cory Colt added 2 commits May 2, 2020 13:32
…able which belong to a folder that is being deleted.
…7.4.0. Added new class and functionality to associate users with a newly created Perplex folders and to remove this association when the folder is deleted.
@PerplexDaniel
Copy link
Member

Hey @cory-colt,

Thanks for the PR. Cool people are sharing back to this project.
I'll have a look at this in more detail sometime next week, I only got notified about this today.
One quick note; I saw you updated the UmbracoCms.Core version from 7.6.0 to 7.15.4 and Forms to 7.4.0.
In general we try to target the lowest possible Umbraco + Forms version so more people can use this in their (older) projects. And of course that version would also work in newer versions most of the time, unless Umbraco / Forms introduced some breaking changes.
So if not necessary please target the older versions again.

@cory-colt
Copy link
Author

@PerplexDaniel I totally get it and definitely agree regarding the versioning. This work was created in response to a client need who was using those specific versions. You are correct though, it wouldn't make sense for your project as it's so public, so some refactoring is definitely in order. This was a fairly specific implementation (not good for the masses I realize), but I figured it was worth sharing in case you wanted to adopt the option of this type of functionality at some future date to allow it to auto-assign permissions to users based on their starting content nodes if they match a perplex folder. This was the directive I was given and just figured I would share. :-) Keep up the great work!

@PerplexDaniel
Copy link
Member

@cory-colt Alright, thanks for the explanation! I can see this functionality being useful indeed. For now I'll just keep it here on the "backlog" as we are not actively developing this package right now and unfortunately I cannot really allocate time to work on this anytime soon. Thanks again for contributing back though, really appreciated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants