Skip to Content Skip to Menu

🎃 Happy Halloween! Treat yourself with an awesome discount on memberships! Get 20% off now with code SPOOKY-2024!

[SOLVED] Custom field that only shows up for certain group(s)

  • jkj86
  • jkj86
  • OFFLINE
  • Posts: 9
  • Thanks: 1
  • Karma: 0
11 years 1 month ago - 11 years 1 month ago #233741 by jkj86
Hello,

I am new to CB. I just set it up and have a few groups. One group is tutors and the other is students. I want the students group to have an "assessment" field, which the tutor group will not have. However, under fields it looks like it cannot be done. Is there a simple/easy way of setting this up for a specific group?

Thanks,
Jordan
Last edit: 11 years 1 month ago by krileon.

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

  • nant
  • nant
  • OFFLINE
  • Posts: 12339
  • Thanks: 1467
  • Karma: 877
11 years 1 month ago #233780 by nant

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48466
  • Thanks: 8280
  • Karma: 1443
11 years 1 month ago #233785 by krileon
CB Conditional can be used to conditionally show/hide fields/tabs based off other fields values. If you're using a field to determine what type of profile the user has this will be quite easy to condition. Aside from that fields can't have access controls. Only the tabs they are on can, but that would limit edit and view access to only that usergroup. Please see the below tutorial to get started with CB Conditional.

www.joomlapolis.com/support/tutorials/107-use-cases/18336-using-cb-conditionals-to-hide-or-show-fields-or-tabs


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.

  • jkj86
  • jkj86
  • OFFLINE
  • Posts: 9
  • Thanks: 1
  • Karma: 0
11 years 1 month ago #233800 by jkj86
Krileon,

Thanks for the quick response. I setup CB conditionals, and have a checkbox field called ifStudent that when value=0, should cause a text field called Student Assessment to hide, and when value=1, should allow Student Assessment to show. However, when I input these conditions to the Student Assessment text field, the field still shows regardless of whether the value is 0 or 1.

I've attached a screenshot of the conditionals settings on the text field. Is there something that I missed?

Thanks,
Jordan
Attachments:

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48466
  • Thanks: 8280
  • Karma: 1443
11 years 1 month ago #233802 by krileon
Don't condition against 0, it won't work for checkbox fields. Checkbox fields can be NULL as well. So use the Is Empty or Not Empty operators or conditioning against the value 1 (checked).


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.

  • jkj86
  • jkj86
  • OFFLINE
  • Posts: 9
  • Thanks: 1
  • Karma: 0
11 years 1 month ago #233806 by jkj86
Krileon,

I have attempted both conditioning it against the value 1 and checking if it is empty, then hiding. However, for some reason the student assessment field still shows regardless of what I choose.

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

Moderators: beatnantkrileon
Powered by Kunena Forum