Hi, i am using webform 6.x-3.11 (the last version of this great drupal module).
And i am working in projects and it´s necessary that a grid can be created dinamically from the options of other grid.
I explain I have a grid with 10 files for example with car brands (renault, opel, fiat, peugeot...) and in the columns i have two values (yes, no).
I want to create a new grid dinamically with the options that have been choosen in the first grid like "yes". I mean if i choose "renault" and "peugeot" like "yes" in the first grid, in the second i would have two files (renault, peugeot) with 5 columns (with vlues from 1 to 5)
It's not a solution to have hidden grids and show them, because the posible grids number would be 10! and for that is necessary to do it dinamically.
¿is it possible to do it? I am very confused and lost.
I dont know if its possible to do it in the same page, or that the first grid is in the first page, and the second grid in other page.
I am trying to create a new module, and i am trying to recover from database the values from the first grid, but i dont know why it doesnt work, i would need the files in which i have to do changes, how, and which hooks i need to alter to do it.
Thank you very much!!!
Comments
Comment #1
quicksketchNo I do not think this possible. Certainly not through the interface and doing it through custom coding would be a tricky feat. In any case, per the submission guidelines I don't provide support on custom coding in the issue queue.
Comment #2
pebels commentedThank you quicksketch, what I am trying is to do it by coding.
I only wanted to know if it would be possible to do it.
I am not asking a change, instead some help if someone has could do it, and what is the way, or some ideas.
I have seen that it is possible that select fields can be filled with a database query.
But I am interested in create a grid field dinamically, nothing more.
A more specific question:
it is possible create a field through webform administration, and by coding change their values?
Thank you all.
Comment #3
quicksketchI don't think the Webform architecture is capable of doing what you're trying to do. You'd have to write a custom component using hook_webform_component_info() to expose it, but the "render" hook for the component does not have access to $form_state or the previous values in the form thus far, so I don't know how you would be able to generate the custom items in the grid component.
Comment #4
quicksketchClosing after lack of activity.