You are here

function references_dialog_js_settings in References dialog 7

Javascript settings for the dialog.

Parameters

$id: Identifier.

array $settings: Settings to add.

Return value

array Prepared settings array.

2 calls to references_dialog_js_settings()
references_dialog_build_element in ./references_dialog.module
references_dialog_process_widget in ./references_dialog.module
Add our references dialog fields to the existing element

File

./references_dialog.module, line 494
This the main module file.

Code

function references_dialog_js_settings($id, array $settings) {
  if (isset($settings['callback_path'])) {
    $settings['callback_path'] = url($settings['callback_path']);
  }
  return array(
    'data' => array(
      'ReferencesDialog' => array(
        'fields' => array(
          $id => $settings,
        ),
      ),
    ),
    'type' => 'setting',
  );
}