I have an on-premises SharePoint 2013 site, and the site has a custom list, and this list has an event receiver linked to it, where the event receiver do the following steps, when a list item is approved:
- Create a new sub-site using a custom site template. the sub-site's url will be equal to the list item ID. also the sub-site's description will be equal to the list item description field.
- Define that the new sub-site will have unique permissions.
- Create 2 SharePoint groups, add users to them and associate them with the new sub-site.
- modify the left side navigation to have links to the new security groups.
- also when the list item description is updates, the related sub-site's description will be updated.
Now i want to migrate my site collection to SharePoint online, and i am going to convert the above event receiver to be a remove event receiver, which will do the exact steps as above, but instead of creating a sub-site the remove event receiver will do these steps:-
- create a new modern team site collection.
- link the new modern team site collection with a modern hub site.
- since we can not create a new modern team site collection from a site template (as we do in the sub-site case).. then i will have to create some custom lists and custom documents libraries. for example i will need to create a custom content type >> add a managed metadata site column to it (which will be linked to a term set) >> create a new docuemnt library inside the new site collection which will use the custom content type.
- do all the other operation as define inside the above server-side event receiver.
- also i need to modify the defualt permission level for the modern team site member group from Edit to Contribute.
so generally speaking should i be able to develop a remove event recevier which can do all the above steps?