CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviEvent (Moderator: Yashodha Chaku) »
  • How to set up optional fields for event activity choices
Pages: [1]

Author Topic: How to set up optional fields for event activity choices  (Read 332 times)

P a u l

  • Guest
How to set up optional fields for event activity choices
February 11, 2015, 04:27:15 pm
I have found 2 different ways to have field trip choices (an example activity) on an event registration form. Either use price set items with $0 cost, or a profile custom data set with a multi-select box. Both ways allow you to get a list of participants by field trip. The profile method results in a search filter for field trips on the List Participants form. For the price set method you have to use the custom search on price sets for events, not as useful. I initially preferred to have check boxes for each field trip in the custom data designer, but CiviCRM has a strange custom data set design where option check boxes are not treated as true/false, plus they are displayed like radio buttons: all on one line. Of course if an activity has a non-zero price then you would use price sets. (I am using 'activity' in the non-CiviCRM sense).

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: How to set up optional fields for event activity choices
February 12, 2015, 03:11:19 pm
Quote
CiviCRM has a strange custom data set design where option check boxes are not treated as true/false, plus they are displayed like radio buttons: all on one line.

That's not quite right: each checkbox is treated as true/false, but when the data is stored all the values are serialized and stored together. As far as the data is concerned it works exactly the same way as multiselect, only the representation on the form is different.

If you don't like all the checkboxes being on the same line you should modify the "options per line" setting for that field. You could set it to 1 to have 1 per line.
Try asking your question on the new CiviCRM help site.

P a u l

  • Guest
Re: How to set up optional fields for event activity choices
February 12, 2015, 09:46:40 pm
Quote from: Coleman Watts on February 12, 2015, 03:11:19 pm
Quote
CiviCRM has a strange custom data set design where option check boxes are not treated as true/false, plus they are displayed like radio buttons: all on one line.

That's not quite right: each checkbox is treated as true/false, but when the data is stored all the values are serialized and stored together. As far as the data is concerned it works exactly the same way as multiselect, only the representation on the form is different.

If you don't like all the checkboxes being on the same line you should modify the "options per line" setting for that field. You could set it to 1 to have 1 per line.

That's why I posted this, I need to get this cleared up thanks. I didn't know about options per line. I dropped the checkbox idea a while ago and went with multi-select. If my karma keeps dropping I will have to get a new username :+> I don't get paid for any of this, and it's wearing me out. I told the organization I would set this up for them.
« Last Edit: February 12, 2015, 09:52:48 pm by P a u l »

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviEvent (Moderator: Yashodha Chaku) »
  • How to set up optional fields for event activity choices

This forum was archived on 2017-11-26.