Skip to Content Skip to Menu

[#4763] Hiding plan on registration based on field value

  • hac
  • hac
  • OFFLINE
  • Posts: 50
  • Thanks: 1
  • Karma: 0
10 years 3 weeks ago - 10 years 3 weeks ago #250194 by hac
Hi,

I have some plans that are for my country, National and others that are for other countries, International. I would like to show and hide the National and International plans based on the selection of the Country field.

The National plans that are for my country will show and hide based on the Country field value in the registration form. Under Workflows I have the following condition setup:
Dynamic Conditions on other plans and CB Fields to show this plan and to allow subscribing to it: These conditions must be met on the registration form to show this plan at registration:
Conditions on other plans to show this plan at registration: None is needed and None is not allowed
Conditions on CB Fields to show plan at registration:
All of following CB fields must be filled-in/selected at registration: Country
And all of following CB fields must be empty/unselected at registration: None must be empty
And following CB Field: Country
Condition: = (is equal to)
Value: CA

This works great. When CA is selected the plans show and if something other than CA is selected the plans disappear.

But if I use these conditions on my International plans:
Dynamic Conditions on other plans and CB Fields to show this plan and to allow subscribing to it: These conditions must be met on the registration form to show this plan at registration:
Conditions on other plans to show this plan at registration: None is needed and None is not allowed
Conditions on CB Fields to show plan at registration:
All of following CB fields must be filled-in/selected at registration: Country
And all of following CB fields must be empty/unselected at registration: None must be empty
And following CB Field: Country
Condition: <> (is different from)
Value: CA

The plan doesn't show no matter what the Country field is set to.

So, what conditions do I have to use, so the International plans will only display when the Country field is something other than CA?

Thank you.

Joomla 3.3.6
CB 1.9.1
CBSubs 3.0.0
Last edit: 10 years 3 weeks ago by krileon.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48479
  • Thanks: 8283
  • Karma: 1443
10 years 3 weeks ago #250273 by krileon
Try the following usages and see if either will work.

Field: Country
Condition: Does not contain
Value: CA

Field: Country
Condition: Does not match regexp below
Value: /^CA$/


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

  • hac
  • hac
  • OFFLINE
  • Posts: 50
  • Thanks: 1
  • Karma: 0
10 years 3 weeks ago #250298 by hac
Hi Kyle,

I had already tried the "Does not contain" condition. With it, when the country is Canada the International plan displays. When the Country is something other than Canada, the International plan displays.

With the "Does not match regexp below" condition the International plan does not display when Canada is selected, but when you change to some other Country the International plan still doesn't show. Works the same as the "Is different from" condition.

Other ideas?

Thank you.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48479
  • Thanks: 8283
  • Karma: 1443
10 years 3 weeks ago #250361 by krileon
If the "Does not contain" usage works I suggest using it. There could be a bug with the jQuery causing the other conditions to fail. I've created a bug ticket for CBSubs for further investigation.

#4763


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

  • hac
  • hac
  • OFFLINE
  • Posts: 50
  • Thanks: 1
  • Karma: 0
10 years 3 weeks ago #250391 by hac
Hi,

Does not contain doesn't work either. The plan shows whether the country is Canada or not Canada. It never gets hidden.

Is different from, Does not contain and the Does not match regexp below none of them work to hide the International plan for the country being Canada and show for all other countries.

Thanks.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48479
  • Thanks: 8283
  • Karma: 1443
10 years 3 weeks ago #250424 by krileon
It looks like it's bugged then. There's a bug ticket now for it to be investigated for next release.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum