Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
The Checkbox element has this:
'#process' => array(
...
array($class, 'processGroup'),
),
'#pre_render' => array(
...
array($class, 'preRenderGroup'),
),
so does the Textfield and the Datetime element.
But Select does not. Is there any good reason? Adding the calls in the form definition makes things work instantly, so there is a workaround, but why not add this to the element itself?
Comment | File | Size | Author |
---|---|---|---|
#9 | Screen Shot 2019-06-13 at 1.27.33 PM.png | 90.6 KB | sean_e_dietrich |
#9 | Screen Shot 2019-06-13 at 11.39.49 AM.png | 70.09 KB | sean_e_dietrich |
#9 | Screen Shot 2019-06-13 at 11.39.31 AM.png | 269.97 KB | sean_e_dietrich |
#5 | 2854166.patch | 626 bytes | grathbone |
Comments
Comment #2
ChristianAdamski CreditAttribution: ChristianAdamski as a volunteer and at Wolters Kluwer commentedComment #5
grathbone CreditAttribution: grathbone at VMLY&R commentedRan into this issue trying to figure out why the "select" Form Elements weren't going into their correct groups on Views arguments.
Wrote a patch to add the default methods.
Also, looks like this could be solved globally, so may want to watch this ticket.
https://www.drupal.org/project/drupal/issues/2190333
Comment #6
grathbone CreditAttribution: grathbone at VMLY&R commentedComment #9
sean_e_dietrichTested patch as I was having a similar issue with a module.
Applied patch successfully.
Codebase currently
Before patching there were some issues
After applying the patch this was successful.
Comment #10
Pancho@grathbone wrote:
#2190333-11: Make #group FAPI / render feature work on all form/render #types out of the box has a working patch now and solves the issue generically. Please test with your usecases.
Comment #11
larowlanWe need some tests here.
But I think it might be best to close as a duplicate of #2190333: Make #group FAPI / render feature work on all form/render #types out of the box
Comment #13
paper boyThanks a lot for your patch which seems to work on 8.7.8.
Tho I applied the one at https://www.drupal.org/project/drupal/issues/2190333 which fixed the problem.
Comment #16
Pasqualle#2190333: Make #group FAPI / render feature work on all form/render #types out of the box should fix this issue