Closed (fixed)
Project:
Entity Group Field
Version:
1.0.x-dev
Component:
Code
Priority:
Critical
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
16 Jun 2020 at 03:26 UTC
Updated:
2 Jul 2020 at 03:34 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
dwwHere's everything that didn't make it into the subtree split (as a patch against group, it's not going to apply here, so do-not-test).
Comment #3
dwwsrc/Element/GroupAutocomplete.php seems like another candidate to put into Group core itself, not this module. #NeedsFollowup?
Comment #4
dwwAnd maybe src/Plugin/EntityReferenceSelection/GroupContentSelection.php too?
Comment #5
dwwI split off #3152324: Add a getPluginIdsByEntityType() method to src/Plugin/GroupContentEnablerManager into an issue/patch against Group core. Let's see how that goes. ;)
The rest of #2 is to alter the site-wide group settings for the per-entity-type label for the pseudo field. That seems like a fairly weird thing to do via site-wide settings. A few options to move forward:
A) Provide reasonable defaults and let folks that want to alter them translate the terms. Basically, use 'Group memberships' for user entities, and 'Groups' for everything else.
B) Use hook_form_alter() to inject our settings into the global site-wide Group settings page (much like we used to do by modifying the GroupSettingsForm class) and continue manage these labels via config settings.
C) Maybe there's some way to say we want to be able to edit this stuff via Field UI. Trying to find out.
Comment #6
dwwHere's #5A in patch form. ;) Seems to work well in local testing. Also solves the problem that we had settings but no schema for them.
Comment #8
dwwRe: #5C: There's A Module For That(tm)! https://www.drupal.org/project/base_field_override_ui
I just tried it locally, and it all works to handle this case.
So I'm strongly in favor of committing #6 as-is, and adding some documentation to recommend base_field_override_ui if anyone wants to further customize/configure the label and description for the pseudo field.
Crediting @larowlan for the pointer to this module.
Yay,
-Derek
Comment #10
dww#3152324: Add a getPluginIdsByEntityType() method to src/Plugin/GroupContentEnablerManager is on its own path now. Either it'll land in Group core, or we'll solve it internally.
I added a pointer to https://www.drupal.org/project/base_field_override_ui in the README.md in #3152713: Add documentation for Entity Group Field
Everything else here is resolved.
Calling this fixed.
Yay,
-Derek