When use SELECT with

<Basic Prague Walks>
0|The Best of Prague Tour
1|Right River Bank Tour
<Non-traditional Prague>
2|Prague Underground
3|Prague Legends
<Trips outside Prague>
4|Kutna Hora
5|Karlovy Vary

in E-mail shows only safe_key

You are booking the tour: 3

+ when I select first option, it shows nothing in e-mail.
Like

You are booking the tour: 

When use no in select

0|The Best of Prague Tour
1|Right River Bank Tour
2|Prague Underground
3|Prague Legends
4|Kutna Hora
5|Karlovy Vary

in E-mail it shows "readable value" correctly

You are booking the tour: Prague Legends

+ when select first option works fine too:

You are booking the tour: The Best of Prague Tour

There in some problem with GROUPS isnt it?

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

quicksketch’s picture

Priority: Major » Normal

Thanks for the report! I'll look into this next time I'm working on Webform.

timb’s picture

I am also experiencing troubles with groups in select lists. For me when using groups in a multi-select no values are sent in email or recorded to submissions.

<Wills>
1|Creating a Will
2|Creating a Will to Name Guardian for Children 
3|Probating a Will
<Trusts>
4|Creating a Trust
5|Administering During the Life of Grantor

When taking the groups out the form works fine.

tobyontour’s picture

The problem seems to be that when converting the safe_key back to the readable value the code doesn't take into account that the options array is an extra level deep (and so ends up looking for the safe_key in the array level where the keys are group names).

Here is a patch that fixes it (apologies for it being slightly old-skool, but I don't have ssh/git access at work).

quicksketch’s picture

Apparently all of #762574: Select and grid components show key (or nothing) instead of values in emails, CSV, table, etc. somehow did not make it into the 7.x branch, so this problem (and several others) are fixed in D6 but not D7. Forward-porting all the changes fixes this issue with e-mail keys breaking when nested and it also fixes the display of "Table" view under the Analysis tab.

quicksketch’s picture

Status: Active » Needs review
FileSize
9.37 KB

#762574: Select and grid components show key (or nothing) instead of values in emails, CSV, table, etc. also included a small change to grid.inc to fix its table display. Including that here also.

quicksketch’s picture

Status: Needs review » Fixed

I've committed this patch to the 7.x-3.x branch.

quicksketch’s picture

FileSize
969 bytes

My patch caused a test failure because Drupal 7 returns an integer 0 for checkboxes that are not checked, instead of FALSE like Drupal 6. This patch fixes the mistake.

Automatically closed -- issue fixed for 2 weeks with no activity.