Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve clarity and functionality of OG vertical tab in content type configuration #103

Closed
argiepiano opened this issue May 20, 2022 · 6 comments · Fixed by #104
Closed

Comments

@argiepiano
Copy link
Collaborator

As reported in #45 (comment), the target bundle is not being saved when selected in the Vertical Tab of the node "Configure" page. This problem also exists in D7.

@argiepiano
Copy link
Collaborator Author

argiepiano commented May 20, 2022

The problem is more complex than it seems at first, and it's the result a poor design that also affects the D7 version. In a nutshell, this is what's happening:

Assume you have two Content Types - the "Group type 1" bundle and "Group type 2" bundle - that are used to create group nodes.

Now assume you are creating two Content Types that will provide content for the groups of bundles "Group type 1" and "Group type 2" each (let's call them "Content for group type 1" and "Content for groups type 2").

Now let's say you are in the process of creating the content type "Content for group type 1". When you use the Organic Group vertical tab to assign a "Group content" field to it, OG creates the field info and field instance entries in the config folder of the site, and it assigns the select "Target type" (node) and "Target bundle" (Group type 1) correctly. The new field is called (by default) og_group_ref, and it's an entity reference field. All good 👍🏽

Now let's say you are in the process of creating the other content type, "Content for groups type 2." When you use the OG vertical tab to assign a "Group content" field to it, Backdrop has already created the field info for og_group_ref and has assigned the "Target type" and "Target bundle" to it (see above). So NO MATTER what you select in the UI for Target bundle, it will not change. 👎 To change it you have to change the field itself through "Manage fields" and then configure the "Global settings" of the og_group_ref field itself.

This is why, apparently, the OG vertical tab "Target bundle" select is not working. It works fine the first time you create the field, but then it just ignores whatever selection you make.

In a nutshell - messy, messy, messy. I feel like this OG vertical tab needs major overhaul.

@argiepiano
Copy link
Collaborator Author

PR #104. This PR significantly clarifies what can and can't be done with the OG vertical tab in the Content Type configure page. I still need to do some testing (e.g. with a clean install). I'll appreciate additional testing, questions, or concerns.

@stpaultim
Copy link
Member

Didn't have time to test bug. Looked at text changes and think they are helpful.

I would like to offer additional suggestions for improvement, but no energy tonight. Maybe later this weekend. We might be able to shorten the text a little and use the word "bundle" less often. ;-)

@argiepiano argiepiano changed the title Target bundle for group content fields not being saved Improve clarity and functionality of OG vertical tab in content type configuration May 21, 2022
@argiepiano
Copy link
Collaborator Author

Latest commit adds summary information to the vertical tab - as requested in #8. I will close that issue since this is addressed here.

@stpaultim
Copy link
Member

I think this one looks pretty good.

@argiepiano
Copy link
Collaborator Author

Thank you @stpaultim for checking this one. I'll merge in a moment.

argiepiano added a commit that referenced this issue May 25, 2022
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 a pull request may close this issue.

2 participants