Closed (works as designed)
Project:
Profile
Version:
8.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
13 Sep 2016 at 21:37 UTC
Updated:
21 Jun 2018 at 15:02 UTC
Jump to comment: Most recent
Comments
Comment #2
mglamanPerhaps we can include this in Profile. We currently limit profile types by role. The real problem is that the user register form does not allow you to say "I want this person to register for X role", which would be the end solution here.
We need to decide if that would live here, or something like "user_register_advanced".
Needless to say, lets research what porting profile2_regpath into the module would look like.
Comment #3
juliencarnot commentedThanks @mglaman for your quick answer and interesting perspective: I was thinking I'd use a single role with different profile types, as that seemed to fit my needs now, but it would make sense to have separate roles for more flexibility in permissions management...
In that case, maybe the Auto Assign Role module is the solution I've been looking for? Just asked for a status update of its port...
Or would you suggest opening an issue to explore a path feature for roles registration directly in core?
Comment #4
itamair commentedI subscribe. From a very brief overview of this D8 module, indeed it is seems this is lacking the user profile registration path, (that in D7 was guaranteed by the Profile2 Registration Path module) ...
Comment #5
kpv commentedTry using #2845570: Add profile form visibility settings per account (registration) form display mode together with one of the modules: form_mode_control or form_mode_manager. Both modules provide some options to switch form display mode (though I haven't tested them with registration form), which seems to be the only part needed to get the result. But anyway, with the issue mentioned above fixed the only task is to get registration (actually account) form to switch it's display mode which is not connected to the Profile module.
Comment #6
kpv commentedOr even better, instead of using contrib modules from #5 you can just add to your custom module
my_module.routing.ymlsomething like this:where
type1_modeandtype2_modeare machine names of your custom user form display modesalso you will need to implement the following hooks:
Comment #7
nedjoNo patch, so setting back to active.
Comment #8
kpv commentedSo, instead of making a custom solution (as described in #6) you can try using Registration types together with Field Permissions and avoid using Profile until #2864308: Expose profiles to all form modes is resolved.
Comment #9
dzy commentedI tried the patch and create custom module, the profile_form_user_register_form_alter() not working, profile field not show up.it worked.
Comment #10
mglamanThere's no patch.
Comment #11
geek-merlinSo we have at least 2 modules that provide this:
* Multiple Registration | Drupal.org
* Registration types | Drupal.org
so i'd say if something is needed, we need more specific integration issues.