Drupal 8 - Triggering the automatic workflow for creating the role and team

Hello Team,

I have installed Drupal 8 with Apigee Kickstart distribution. I wanted to configure an automatic role and team creation as soon as the user logs in.

When an user logs in the Drupal Portal, it should directly trigger a workflow for creating the role and team.

Is this possible??Can anyone help me with this configuration?

Appreciate ideas!!

Thanks,

Shweta V Revankar

0 10 297
10 REPLIES 10

Hi @Shweta V Revankar,

Yes, you can do it, you should simply use rules module in Drupal 8 on the event user logs in first time. But I think there should be a button to confirm whether user wants to have team to be created or not. with this way individual developers won't need to have team created which won't be useful.

Thanks for the information @Ravindra Singh

But the concern here is how will the role get created? What action should I perform to create a role?

There are ways to you try -

- check rules module should have users and roles events/action.

- If not then you can create custom action for rules module which will be available for your configuration.

@Ravindra Singh Since, i am new to Drupal, i am not much aware about the rules and procedures.

Is it possible to configure multiple forms based on some conditions??

I have a very big workflow, which i found to be very complex having 2-3 decision flow. Is this possible? If Yes, how??

you should look for options to simplify the workflow which can load eaisly and the sequentially you can invoke the events. To run rules checkout rules documentation and videos on yourtube (configuration related thing), I hope you will get to know it eaisly.

@Ravindra Singh

Is it possible to create a new role automatically based on the LDAP Group, whenever a new user logins?

Its possible but not recommended beacuse any user will get admin access on creating new role. which might lead security issue in your application. I think you should predefined user roles and once user login,user should be able to get that role in Drupal.

@Ravindra Singh sorry i made a mistake, i meant creation of new team and not role.

Is it possible to create a new team based on LDAP group and whenever a new user logs-in he should have the role assigned to him in LDAP?

The team must be an entity on the Drupal which you will be maintaining either taxonomy or user groups or may be custom. so any entity can be created once you get access on the system programatically.

@Ravindra Singh

Will come up with proper flowchart or a plan for this.