Skip Navigation

[Resolved] Woocommerce and custom post types to accomplish what I need?

This support ticket is created 7 years, 5 months ago. 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
- - 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00
- - - - - - -

Supporter timezone: Asia/Ho_Chi_Minh (GMT+07:00)

Tagged: 

This topic contains 1 reply, has 2 voices.

Last updated by Beda 7 years, 5 months ago.

Assisted by: Beda.

Author
Posts
#481662

OK so reading the woocommerce cred integration I can see there is a way to create a custom post type that will charge someone through the woocommerce store. I wanted to throw my scenario out there first to make sure what I was looking to accomplish was even possible. This is for a sports club and I need to build a form for parents to register their kids.

Most parents will already have an account in wordpress/woocommerce. New families to the club may need to create an account still.

I have a custom post type for the parents to fill out the information on their kids. Info like: My kid is 5 years old, they play center, this is their insurance number, etc. I associate that custom post type to the wordpress account by the author field.

I want to create a form that I can send a link to the parents/family so they can click on it and register their kids. When they click the link I want them to see the custom post with the registration detail and price for the team they are signing up for. Since some families have more kids it would be great to allow them to select which of their kids they were signing up for. Is it possible in a form like this to pull all custom posts of that type and then have a pull down or a radial button allowing them to select? If that makes this a lot more difficult then I would need an admin to be able to select which kid the form was for before the link was sent. After the parent/family completes the form and sends it can the sale be recorded in some way to the custom post type I am using to collect their kids information? The goal is to track which kid paid for which program and generate a view showing that information.

I am hopeful I am on the right track here and this would work. If that's the case any examples I can be pointed to would be helpful. If something here will not work or I am doing this the hard way I need ideas then please to try and accomplish this.

Thanks for any help provided!

Ted

#481874

1. I can see there is a way to create a custom post type that will charge someone through the WooCommerce store

The idea is that a User either sets up a new user or a Post, and while doing so, he is charged with a previously defined WooCommerce Product.
https://toolset.com/documentation/user-guides/using-cred-commerce-to-add-payments-to-forms/
https://toolset.com/documentation/user-guides/charging-payments-with-cred-to-register-users/

2. Most parents will already have an account in wordpress/woocommerce. New families to the club may need to create an account still.

CRED - if used with User Forms and WooCommerce, will require you to disable the WooCommerce Registration process, as otherwise, you'll have 2 users set up for each subscription.
https://toolset.com/documentation/user-guides/charging-payments-with-cred-to-register-users/ > Setting correct WooCommerce account-creation options

3. For your goal, you probably need a Parent / Child relation of Post types, where your User creates a Parent Post (for the actual Parents) and then starts to add Child Posts (for the kids) and those have payment applied.
https://toolset.com/documentation/user-guides/many-to-many-post-relationship/

You can set always the same Product to be charged, or let the User choose it via a Custom Field.

This means, you would charge with a Custom Post Type form not with a User Register Form

Each new kid has it's own Post, and the Parent is charged when submitting the new Kid.

This ticket is now closed. If you're a Toolset client and need related help, please open a new support ticket.