Revision 4c380cc0
Added by Andreas Kohlbecker almost 3 years ago
modules/cdm_dataportal/includes/common.inc | ||
---|---|---|
54 | 54 |
$attributes = "cdm:" . $cdm_entity->class . " uuid:" . $cdm_entity->uuid; |
55 | 55 |
switch ($cdm_entity->class){ |
56 | 56 |
case 'Taxon': |
57 |
if(isset($cdm_entity->sec->uuid)){ |
|
58 |
$attributes .= " sec_uuid:" . $cdm_entity->sec->uuid; |
|
57 |
if(isset($cdm_entity->secSource->uuid)){
|
|
58 |
$attributes .= " sec_uuid:" . $cdm_entity->secSource->citation->uuid;
|
|
59 | 59 |
} |
60 | 60 |
break; |
61 | 61 |
} |
modules/cdm_dataportal/includes/footnotes.inc | ||
---|---|---|
373 | 373 |
|
374 | 374 |
/* ============ annotations_and_sources handling =================== */ |
375 | 375 |
|
376 |
const ANNOTATIONS_AND_SOURCE_CONFIG_DEFAULT = [ |
|
376 |
// since PHP 5.6 constant expressions are allowed in const --> change to const AMNOTATIONS_... ? |
|
377 |
define("ANNOTATIONS_AND_SOURCE_CONFIG_DEFAULT", [ |
|
377 | 378 |
'sources_as_content' => FALSE, |
378 | 379 |
'annotations_as_content' => FALSE, |
379 | 380 |
'link_to_name_used_in_source' => TRUE, |
380 | 381 |
'link_to_reference' => TRUE, |
381 | 382 |
'add_footnote_keys' => TRUE, |
382 | 383 |
'bibliography_aware' => FALSE |
383 |
]; |
|
384 |
]);
|
|
384 | 385 |
|
385 |
/**
|
|
386 |
/** |
|
386 | 387 |
* Provides the default configuration for handle_annotations_and_sources() in the |
387 | 388 |
* synonymy. |
388 | 389 |
* |
modules/cdm_dataportal/includes/pages.inc | ||
---|---|---|
703 | 703 |
$accepted_name = ''; |
704 | 704 |
if (variable_get(CDM_SYNONYMY_ACCEPTED_TAXON_SEC_SEPARATE, 0)) { |
705 | 705 |
$label = variable_get(CDM_SYNONYMY_ACCEPTED_TAXON_SEC_SEPARATE_LABEL, CDM_SYNONYMY_ACCEPTED_TAXON_SEC_SEPARATE_LABEL_DEFAULT); |
706 |
$accepted_name .= '<div class="secReference"><span class="label">' . t($label) . ':</span> ' . $taxon->sec->titleCache . '</div>'; |
|
706 |
$accepted_name .= '<div class="secReference"><span class="label">' . t($label) . ':</span> ' . $taxon->secSource->citation->titleCache . '</div>';
|
|
707 | 707 |
} |
708 | 708 |
if (isset($taxon->name->nomenclaturalSource->citation)) { |
709 | 709 |
$referenceUri = url(path_to_reference($taxon->name->nomenclaturalSource->citation->uuid)); |
modules/cdm_dataportal/includes/taxon.inc | ||
---|---|---|
533 | 533 |
// $taxon_or_name this is a trick to suppress the sec reference for synonyms |
534 | 534 |
// supplying the name will cause render_taxon_or_name() to not show the sec reference |
535 | 535 |
$out .= "<div class=\"item " . $taxon_type . "\">" . render_taxon_or_name($taxon, $taxonUri, $referenceUri, true, false, $skip_render_template_parts); |
536 |
if($taxon_type == TAXON_TYPE_MISAPPLIEDNAME && isset_not_empty($taxon->sec)){ |
|
537 |
if(isset($taxon->sec->authorship)){ |
|
538 |
$authorship = $taxon->sec->authorship->titleCache; |
|
536 |
if($taxon_type == TAXON_TYPE_MISAPPLIEDNAME && isset_not_empty($taxon->secSource->citation)){
|
|
537 |
if(isset($taxon->secSource->citation->authorship)){
|
|
538 |
$authorship = $taxon->secSource->citation->authorship->titleCache;
|
|
539 | 539 |
} else { |
540 |
$authorship = $taxon->sec->titleCache; |
|
540 |
$authorship = $taxon->secSource->citation->titleCache;
|
|
541 | 541 |
} |
542 | 542 |
$out .= ' sensu ' . $authorship; |
543 | 543 |
} |
Also available in: Unified diff
ref #9329 adapting data portal to ->sec reference being now ->secSource->citation