I am moving some form fields into the "Publishing Options" vertical tab group using hook_form_FORM_ID_alter(). This movement, however, means that the elements are not found by Conditional Fields after_build callback and as a result the dependency is not applied.

My code in hook_form_FORM_ID_alter looks something like this:

function example_form_node_form_alter(&$form, &$form_state){
  $form['options']['field_field_name'] = $form['field_field_name'];
  unset($form['field_field_name']);
}

Comments

dqd’s picture

Version: 7.x-3.0-alpha1 » 7.x-3.x-dev
Status: Active » Closed (outdated)

Thanks for the report and all the efforts in here. But due to inactivity in this issue for years and because of the upcoming EOL of Drupal 7, I will close this issue on th way cleaning up the issue queue.

Feel free to re-open as "Needs review" if you found a solution or have a patch to be reported to help others.