Project

General

Profile

« Previous | Next » 

Revision 2316d086

Added by Andreas Kohlbecker about 3 years ago

ref #7599 ref #6866 fixing bug in determinations display#

View differences:

modules/cdm_dataportal/includes/occurrences_new.inc
296 296
  }
297 297

  
298 298
  /* TODO
299

  
300
            @_description_list_group_add($sub_dl_groups, cdm_occurrence_field_name_label('medium'), $value->medium, NULL, 1);
301
            @_description_list_group_add($sub_dl_groups, cdm_occurrence_field_name_label('temperature'), $value->temperature, NULL, 2);
302
            @_description_list_group_add($sub_dl_groups, cdm_occurrence_field_name_label('definedMaterialOrMethod'), $value->definedMaterialOrMethod, NULL, 3);
303

  
299
  @_description_list_group_add($sub_dl_groups, cdm_occurrence_field_name_label('medium'), $value->medium, NULL, 1);
300
  @_description_list_group_add($sub_dl_groups, cdm_occurrence_field_name_label('temperature'), $value->temperature, NULL, 2);
301
  @_description_list_group_add($sub_dl_groups, cdm_occurrence_field_name_label('definedMaterialOrMethod'), $value->definedMaterialOrMethod, NULL, 3);
304 302
  */
305 303
  if (isset_not_empty($du_dto->characterData)) {
306 304
    $table_row_data[] = cdm_sob_dto_table_row(
......
419 417
      $link_path = path_to_taxon($det_event->determination->uuid);
420 418
      $taxon_or_name = cdm_ws_get(CDM_WS_PORTAL_TAXON, [$det_event->determination->uuid]);
421 419
    }
422
    $timeperiod_string = NULL;
423
    if (isset($det_eventEvent->timeperiod)) {
424
      $timeperiod_string = timePeriodToString($det_event->timeperiod);
420
    $time_period_string = NULL;
421
    if (isset($det_eventEvent->timePeriod)) {
422
      $time_period_string = timePeriodToString($det_event->timePeriod);
425 423
    }
426
    $markup = $det_event->determination->taggedText;
424
    $markup = render_taxon_or_name($taxon_or_name, $link_path);
427 425
    if (isset($determinationEvent->modifier)) {
428 426
      $markup .= cdm_term_representation($determinationEvent->modifier);
429 427
    }
430
    if ($timeperiod_string) {
431
      $markup .= ' ' . $timeperiod_string;
428
    if ($time_period_string) {
429
      $markup .= ', ' . $time_period_string;
432 430
    }
433 431
    if (isset($determinationEvent->actor->titleCache)) {
434
      $markup .= ' ' . $determinationEvent->actor->titleCache;
432
      $markup .= ', ' . $determinationEvent->actor->titleCache;
435 433
    }
436 434
    // FXIME not yet supported by the DTO!
437 435
    if (isset($determinationEvent->description)) {
438
      $markup .= ' ' . $determinationEvent->description;
436
      $markup .= ', ' . $determinationEvent->description;
439 437
    }
440
    $row = cdm_sob_dto_table_row(NULL, render_taxon_or_name($taxon_or_name, $link_path));
441
    $row['#weight'] = isset_numerical($det_event->isPreferred) ? '0' : ($timeperiod_string ? $timeperiod_string : '1');
438
    $row = cdm_sob_dto_table_row(NULL, $markup);
439
    $row['#weight'] = isset_numerical($det_event->isPreferred) ? '0' : ($time_period_string ? $time_period_string : '1');
442 440
    $table_row_data[] = $row;
443 441
  }
444 442

  

Also available in: Unified diff