Hi @dejanj, thanks for your question!
This functionality will be included in our Pro version, which became available for pre-sale today! It’s coming in July.
Thread Starter
dejanj
(@dejanj)
Thank you very much!
We have Gravity Forms elite license. Does it include access to the Pro version of this plugin, or we have to purchase it separately?
@dejanj, Just for my curiosity, what type of field are you using? Is it the likert field? Because from my understanding of the radio option, this isn’t possible, or I’m just visualizing it wrong. In any case, what you are asking is (probably) not in the pro version, but possible with a few hooks. Could you share more about the type of field and the way you have set it up?
@dejanj I think I can even make it easier. I’m now quite convinced you use the likert field, as the behavior you explain is spot on with what I’m seeing 🙂
You only need to do one thing, (two if you want the score instead of the value):
First you need to split multi-field in to multiple columns:
1. Go to Forms > Settings (so the general settings, not the settings for a specific form)
2. Go to “Entries in Excel”
3. Select “Split multi-fields (name, address) into multiple columns” and Save.
Your export should now look like you want.
If you want the score of the selection, instead of the value, please use this hook in your functions.php
add_filter('gfexcel_export_field_value_likert', function ($value, $form_id, $input_id, $entry) {
$field = \GFAPI::get_field($form_id, $input_id);
if (!$field instanceof \GF_Field_Likert) {
return $value;
}
[$row, $column] = explode(':', $entry[$input_id] ?? ':');
foreach ($field->choices as $choice) {
if (($choice['value'] ?? '') === $column) {
return $choice['score'];
}
}
return 0; // choice not found, so value is 0
}, 10, 4);
Hope this helps. In any case, this plugin is part of GravityView, and not Gravity Forms. So your license does not apply to this particular plugin. However, the Pro version of Entries in excel is very cool, and I would highly recommend!
Thread Starter
dejanj
(@dejanj)
@doekenorg Yes, this is it! 🙂
Thanks a lot for the great support. I totally missed this configuration setting. it solved the issue.
Have a nice day, and I will recommend you to the client!