Revision d0d23caa
Added by Andreas Kohlbecker almost 8 years ago
modules/cdm_dataportal/cdm_dataportal.module | ||
---|---|---|
262 | 262 |
dropShadow: false, |
263 | 263 |
cluetipClass: 'rounded' |
264 | 264 |
}); |
265 |
});", array('type' => 'inline')); |
|
265 |
});", |
|
266 |
array( |
|
267 |
'type' => 'inline', |
|
268 |
'scope' => 'footer' |
|
269 |
) |
|
270 |
); |
|
266 | 271 |
} |
267 | 272 |
|
268 | 273 |
/** |
... | ... | |
275 | 280 |
drupal_add_js(drupal_get_path('module', 'cdm_dataportal') . '/js/ahah-content.js'); |
276 | 281 |
} |
277 | 282 |
|
283 |
/** |
|
284 |
* @todo Please document this function. |
|
285 |
* @see http://drupal.org/node/1354 |
|
286 |
*/ |
|
287 |
function _add_js_taxonomic_children($jquery_selector) { |
|
288 |
drupal_add_js(drupal_get_path('module', 'cdm_dataportal') . '/js/taxonomic_children.js'); |
|
289 |
|
|
290 |
drupal_add_js('jQuery(document).ready(function() { |
|
291 |
jQuery(\'' . $jquery_selector . '\').taxonomic_children(); |
|
292 |
}); |
|
293 |
', array('type' => 'inline')); |
|
294 |
} |
|
295 |
|
|
278 | 296 |
/** |
279 | 297 |
* Adds the external javascript file for domEvent.js. |
280 | 298 |
* |
modules/cdm_dataportal/includes/pages.inc | ||
---|---|---|
956 | 956 |
*/ |
957 | 957 |
function compose_classification_breadcrumbs($taxon_uuid) { |
958 | 958 |
|
959 |
_add_js_taxonomic_children('#classification-breadcrumbs .taxonomic-children'); |
|
960 |
|
|
959 | 961 |
$render_array = array(); |
960 | 962 |
if(!is_uuid($taxon_uuid)){ |
961 | 963 |
return $render_array; |
... | ... | |
980 | 982 |
$node_name = cdm_dataportal_shortname_of($node); |
981 | 983 |
$path = path_to_taxon($node->taxonUuid); |
982 | 984 |
|
983 |
$items[] = ($is_first_item ? '': ' > ') . l($node_name, $path); |
|
985 |
$items[] = ($is_first_item ? '': ' ' . '<span class="taxonomic-children" data-cdm-taxon-uuid="'. $node->taxonUuid. '" > > </span>' . ' ') |
|
986 |
. l($node_name, $path); |
|
984 | 987 |
} |
985 | 988 |
$render_array['#items'] = $items; |
986 | 989 |
|
Also available in: Unified diff
initial commit for breadcrumb-children feature