Saltar navegación

[Resuelto] form with 2 relationships

This support ticket is created hace 4 meses, 2 semanas. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Zona horaria del colaborador: Asia/Kolkata (GMT+05:30)

Este tema contiene 3 respuestas, tiene 1 mensaje.

Última actualización por Minesh hace 4 meses, 2 semanas.

Asistido por: Minesh.

Autor
Mensajes
#2801098

Hi
I have 3 CPT Movie, Client, Delivery.
Relationship 1-to-many: Movie-Delivery
Many-to Many: Delivery-Client

In the form to create a new Delivery I can add only 1 relationship link to my movie. However I need to add the relationship to the client. Which I do with a "Post-Reference". I need a solution to add 2 relationships instead 1 relationship and 1 post-reference.

Is there a way maybe to use the post-reference as a selection of a relationship that would be updated when saving the post "delivery" ? Meaning that when saving the post, the post-reference would be transformed in a relationship ?

#2801100

Minesh
Colaborador

Idiomas: Inglés (English )

Zona horaria: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

I'm afraid that its not possible.

As you already know you can manage one to many post relationship with your form and for many to many post relationship you will require another form that is post-relationship forms.

Please check the following Doc:
- https://toolset.com/course-lesson/front-end-relationship-forms-for-connecting-posts/

#2801103

How is the post-reference registered ? Isn't it an ID reference that could be used to update the 2nd relationship with cred-save script ?
What is the reason of this limitation ?

#2801109

Minesh
Colaborador

Idiomas: Inglés (English )

Zona horaria: Asia/Kolkata (GMT+05:30)

Here is the Doc that shows how you can use and register post reference field:
- https://toolset.com/course-lesson/using-post-reference-field-to-set-up-one-to-many-relationships/

One to many and many-to-many are different relationships where with many-to-many post relationship you can add intermediary post fields and it will have intermediary post type that seats between the post type A and B. Many to many post relationship will look like post type A {intermediary post type with custom fields if exists} post type B.

Please check the following Doc:
- https://toolset.com/course-lesson/many-to-many-post-relationships/#setting-up-many-to-many-post-relationships