Skip Navigation

[Resolved] Unable to “Select a custom field” in Toolset Forms Commerce for Featured Ad

This thread is resolved. Here is a description of the problem and solution.

Problem: I would like to allow Users to make a selection on a Commerce Form that will determine which Product is added to their cart.

Solution: You can create a custom field with option values that correspond to the Product IDs.

Relevant Documentation:
https://toolset.com/documentation/user-guides/using-cred-commerce-to-add-payments-to-forms/#2-1-product-to-buy

This support ticket is created 6 years, 4 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.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

This topic contains 12 replies, has 3 voices.

Last updated by Christian Cox 6 years, 2 months ago.

Assisted by: Christian Cox.

Author
Posts
#924397
Toolset Bug.jpg

I am trying to: "Select a custom field" in Toolset Forms Commerce for Featured Ad

Link to a page where the issue can be seen: hidden link

I expected to see: A list of custom fields

Instead, I got:"Select a custom field"

I saw that this issue came up earlier and was resolved by deleting the form and creating it again. I tried following those instructions but it is still not working. I wonder if it is an incompatibility with Elementor, I was having an issue editing with Elementor when Toolset Forms Commerce is enabled....

#924618

I cannot load this site.
It times out.

But reading your post, did you add Custom Fields which do hold an ID pf products as explained here?
https://toolset.com/documentation/user-guides/using-cred-commerce-to-add-payments-to-forms/#2-1-product-to-buy

You need fields that field on the post or user you are submitting with this form, not in a product.

Is this setup correctly?

#948513
Custom Fields.jpg

Hi Beda, yes I did add custom fields to the content, I'll include a screenshot of them.

#948675
Custom Fields 2.jpg

Update: I started adding some more options to the field group, and I noticed 2 of them are now showing up on the "Select Custom Field" dropdown in the form builder. I highlighted the two that are showing up, though I'm not sure what is different about them. There are others that are radio buttons and drop downs, but those two are showing up under the "Select custom fields" for some reason, while the rest of them are not...

#948680

Hi, I just logged in and created a test Form here:
hidden link
I was able to select the "Featured" custom field and save it successfully. I wasn't able to find the exact form you mentioned before, the ID doesn't seem to exist anymore. Can you take a quick look and let me know if it's working as expected?

#948693

Strange, yes, it does seem to be working now....

What is it that determines which slugs are viewed in that "Select custom field" dropdown?

I had deleted the previous form, which is why you couldn't see it, and recreated another one with a different ID. I was hoping if I created a different form it would register the new fields.

Last question, I thought there would be a dropdown of some sort to allow me to link the custom field to a specific product, is that not the case? How do I tell the form which product they are purchasing?

#948726

What is it that determines which slugs are viewed in that "Select custom field" dropdown?
Typically any custom field, or any generic custom field set with "persist" = 1. There is usually a link just beside the dropdown field that allows you to refresh the options, but it seems to be displayed incorrectly. All I can see is the underline representing the link...I'll report this as a bug. The link is useful if you have edited the Form and you're trying to find the custom field without refreshing the page.

Last question, I thought there would be a dropdown of some sort to allow me to link the custom field to a specific product, is that not the case? How do I tell the form which product they are purchasing?
The selected field option values should correspond to Product IDs. This can be a standard custom field or a generic custom field. Then the User selects one of the options, which tells the Form which Product should be added to the User's cart.

#948746

Good to know, thanks.

In reference to the form assigning a product, you said: "The selected field option values should correspond to Product IDs. "

Will that not work until the bug is fixed? Also, do you know how long it typically takes those kinds of bugs to be fixed?

#949149

The missing button icon bug should not cause any problems with Product assignment in the Form, except that it might be difficult to refresh the list while you are building the Form. You can see some more information about specifying a product in a custom field here: https://toolset.com/documentation/user-guides/using-cred-commerce-to-add-payments-to-forms/#2-1-product-to-buy

Bugs are prioritized against new features and other bugfixes, and our developers release them on irregular schedules. I don't have a standard timeline available for you, but I can keep you posted here as I receive more information from the developers. Again, this issue should not prevent you from creating or using the Commerce Forms features.

#949291
Screenshot_1.jpg

I saw that, I'm still a little unclear with the instructions on connecting a field option to a product, I think some more detailed instructions on that article would be helpful.

I'll include a screenshot, first time I tried it I put the product ID in the box I labeled #1, and that seems to have broken the form. I no longer see the "featured-ad" under the "Select a custom field" options for some reason, even when I switch the product ID out and put "featured-ad" back in it's place.

I also tried putting the product ID in the field I labeled #2, but that didn't seem to work either. Can you better clarify the instructions of the article? And also explain why "featured-ad" is no longer coming up as an option under the "Product to buy when submitting the form" custom field?

Thanks for your continued support!

#949354

Can you better clarify the instructions of the article?
The Custom field content (number 1 in your picture) for each option in the custom field should be a number. That number should be the same as the numeric ID of the Product you want to place in the User's cart when they submit this Form.

And also explain why "featured-ad" is no longer coming up as an option under the "Product to buy when submitting the form" custom field?
The "featured-ad" field is no longer present in the Form. Perhaps it was deleted mistakenly or renamed?

#949363

Got it, looks like this is working as expected, thanks!

I do still recommend someone updating the article with a screenshot showing exactly how to accomplish that, I really did not understand the instructions, so I really appreciate the help!

#1093872

Our developers have let me know that the missing refresh button icon issue will be fixed in Forms 2.1, which is currently in QA and planned for release soon.