You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Ideally, it would be nice to have a bi-directional related field type.
Current situation
There is a product entry type that has a related category field. As a user enters products individually over time they are using the related category field on each product. A few months go by, and the user wants to change the products that are related to one category. If they go into that category they are unable to bulk products. Instead the user has to go to each individual product to edit the related category field.
If dreams came true [Ideally]
If a related category field is created in the products entry type, and a related products field in a category group, when you edit one, the other would reflect the relationships.
As an example, the user is entering products individually over time while using the related category field. Months go by and the user wants to bulk edit the products that are related to a specific category. The user would be able to go to the edit page of that category and in the related products field they would see the products that have been connected from the related category field in the products.
This would be in similar fashion to when a twig relatedTo() function is executed.
Brainstorming for how this might work
Understandably, this request will involve a lot of magic connecting two fields or having a new bi-directional field so to try and help out as much as possible here are some (maybe not great) concepts on potentially getting this to work.
Create one bi-directional field where you would pick two types of entries/assets/categories
Create two different relationship fields, but while creating the field allow for a connection to another field
¯_(ツ)_/¯
Additional info
It's important to know that this would be a AX enhancement rather than a code enhancement. Also it is expected that if you add this bi-direction field to one entry type it would not automatically show up on the category edit page, but it would have to be added like any other field.
Also, I'm aware that there are plugins that currently show the relations, but if you have hundreds of products, having to go through each one is rather time consuming. And if the relationship is on the category side only, it is difficult for users to have to enter a product and edit an additional item every time.
The text was updated successfully, but these errors were encountered:
This is awesome, thank you Brandon! Really excited about this being part of Craft 4.
Sorry I wasn't able to find that other ticket. I had searched for bi-directional, two-way, _both directions and two sided – but I hadn't thought of both sides.
Description
Ideally, it would be nice to have a bi-directional related field type.
Current situation
There is a product entry type that has a related category field. As a user enters products individually over time they are using the related category field on each product. A few months go by, and the user wants to change the products that are related to one category. If they go into that category they are unable to bulk products. Instead the user has to go to each individual product to edit the related category field.
If dreams came true [Ideally]
If a related category field is created in the products entry type, and a related products field in a category group, when you edit one, the other would reflect the relationships.
As an example, the user is entering products individually over time while using the related category field. Months go by and the user wants to bulk edit the products that are related to a specific category. The user would be able to go to the edit page of that category and in the related products field they would see the products that have been connected from the related category field in the products.
This would be in similar fashion to when a twig relatedTo() function is executed.
Brainstorming for how this might work
Understandably, this request will involve a lot of magic connecting two fields or having a new bi-directional field so to try and help out as much as possible here are some (maybe not great) concepts on potentially getting this to work.
Additional info
It's important to know that this would be a AX enhancement rather than a code enhancement. Also it is expected that if you add this bi-direction field to one entry type it would not automatically show up on the category edit page, but it would have to be added like any other field.
Also, I'm aware that there are plugins that currently show the relations, but if you have hundreds of products, having to go through each one is rather time consuming. And if the relationship is on the category side only, it is difficult for users to have to enter a product and edit an additional item every time.
The text was updated successfully, but these errors were encountered: