function ds_build_load in Display Suite 7
Same name and namespace in other branches
- 7.2 modules/ds_forms/ds_forms.module \ds_build_load()
Helper function to determine if this form can be loaded.
2 calls to ds_build_load()
- ds_forms_form_alter in modules/
ds_forms/ ds_forms.module - Implements hook_form_alter().
- ds_forms_preprocess_ds_forms_custom_form in modules/
ds_forms/ ds_forms.module - Implements hook_preprocess_ds_forms_custom_form().
File
- modules/
ds_forms/ ds_forms.module, line 152 - Display Suite forms integration.
Code
function ds_build_load($form, $form_id) {
$ds_form = FALSE;
if (module_exists('rel')) {
$ds_form = rel_build_load($form_id);
}
if (!$ds_form && isset($form['#entity_type']) && isset($form['#bundle']) && $form_id != 'field_ui_field_overview_form') {
$ds_form = new stdClass();
$ds_form->entity_type = $form['#entity_type'];
$ds_form->bundle = $form['#bundle'];
$ds_form->rel_type = 'form';
}
return $ds_form;
}