Line 300 of bootstrap_fieldgroup.module, the first thing that bootstrap_fieldgroup_field_group_pre_render() does is:
$element['#group'] = $group;
(Source: http://cgit.drupalcode.org/bootstrap_fieldgroup/tree/bootstrap_fieldgrou...
This causes collapsible fieldsets generated by the Field Group module to no longer be collapsible. This is because the Bootstrap theme itself looks for the #group attribute, and if it is not empty then it forces the fieldset to be non-collapsible:
// Force grouped fieldsets to not be collapsible (for vertical tabs).
if (!empty($element['#group'])) {
$variables['collapsible'] = FALSE;
$variables['collapsed'] = FALSE;
}
(Source: http://cgit.drupalcode.org/bootstrap/tree/templates/bootstrap/bootstrap-...)
The #group is used in Drupal core (and in the field_group module itself) as a simple string, to denote what group the field belongs to. That is the assumption that the Bootstrap theme's code is working with.
So it seems that this module should not be using #group to store the group object. This bug can probably be easily fixed by using a name other than #group for storing the object (maybe something more specific to this module, so that other namespace conflicts are avoided).
Further, maybe the $group object should only be added to the element if the element belongs to this module? Otherwise, it is adding it to any field_group element type, regardless of whether or not it is managed by this module.
Comments
Comment #2
m.stentaComment #3
m.stentaClosing this - I think it needs to be fixed in the Bootstrap module, not in this module.
I created a separate bug report: #2910624: Collapsible fieldsets are disabled when group is set