Project

General

Profile

Revision 4feeabc7

ID4feeabc7eb75a09ab5a445413a4b6a3505c49e37
Parent 4b3be949
Child ed0183ea

Added by Andreas Kohlbecker almost 4 years ago

fix #4490 taxon page tab labels configurable and fixing translation issue with menu items

View differences:

modules/cdm_dataportal/cdm_dataportal.module
529 529
  // --- tabbed taxon page
530 530
  if (variable_get('cdm_dataportal_taxonpage_tabs', 1)) {
531 531
    $items['cdm_dataportal/taxon/%'] = array(
532
      'title' => '@tabname',
533
      'title arguments' => array('@tabname' => theme('cdm_taxonpage_tab', array('tabname' => 'General'))),
532
      'title' => cdm_taxonpage_tab_label('General'),
534 533
      'page callback' => 'cdm_dataportal_taxon_page_view',
535 534
      'access arguments' => array('access cdm content'),
536 535
      'type' => MENU_CALLBACK,
......
540 539
    );
541 540

  
542 541
    $items['cdm_dataportal/taxon/%/all'] = array(
543
      'title' => '@tabname',
544
      'title arguments' => array('@tabname' => theme('cdm_taxonpage_tab', array('tabname' => 'General'))),
542
      'title' => cdm_taxonpage_tab_label('General'),
545 543
      'page callback' => 'cdm_dataportal_taxon_page_view',
546 544
      'access arguments' => array('access cdm content'),
547 545
      'type' => MENU_CALLBACK,
......
551 549
    );
552 550

  
553 551
    $items['cdm_dataportal/taxon/%/description'] = array(
554
      'title' => '@tabname',
555
      'title arguments' => array('@tabname' => theme('cdm_taxonpage_tab', array('tabname' => 'General'))),
552
      'title' => cdm_taxonpage_tab_label('General'),
556 553
      'page callback' => 'cdm_dataportal_taxon_page_view',
557 554
      'access arguments' => array('access cdm content'),
558 555
      'type' => MENU_DEFAULT_LOCAL_TASK,
......
562 559
    );
563 560

  
564 561
    $items['cdm_dataportal/taxon/%/synonymy'] = array(
565
      'title' => '@tabname',
566
      'title arguments' => array('@tabname' => theme('cdm_taxonpage_tab', array('tabname' => 'Synonymy'))),
562
      'title' => cdm_taxonpage_tab_label('Synonymy'),
567 563
      'page callback' => 'cdm_dataportal_taxon_page_view',
568 564
      'access arguments' => array('access cdm content'),
569 565
      'type' => MENU_LOCAL_TASK,
......
572 568
      , // Expected callback arguments: taxon_uuid and ...
573 569
    );
574 570
    $items['cdm_dataportal/taxon/%/images'] = array( // Images
575
      'title' => '@tabname',
576
      'title arguments' => array('@tabname' => theme('cdm_taxonpage_tab', array('tabname' => 'Images'))),
571
      'title' => cdm_taxonpage_tab_label('Images'),
577 572
      'page callback' => 'cdm_dataportal_taxon_page_view',
578 573
      'access arguments' => array('access cdm content'),
579 574
      'type' => MENU_LOCAL_TASK,
......
583 578
    );
584 579

  
585 580
    $items['cdm_dataportal/taxon/%/specimens'] = array( // Specimens
586
      'title' => '@tabname',
587
      'title arguments' => array('@tabname' => theme('cdm_taxonpage_tab', array('tabname' => 'Specimens'))),
581
      'title' => cdm_taxonpage_tab_label('Specimens'),
588 582
      'page callback' => 'cdm_dataportal_taxon_page_view',
589 583
      'access arguments' => array('access cdm content'),
590 584
      'type' => MENU_LOCAL_TASK,
......
594 588
    );
595 589

  
596 590
    $items['cdm_dataportal/taxon/%/keys'] = array( // Keys
597
      'title' => '@tabname',
598
      'title arguments' => array('@tabname' => theme('cdm_taxonpage_tab', array('tabname' => 'Keys'))),
591
      'title' => cdm_taxonpage_tab_label('Keys'),
599 592
      'page callback' => 'cdm_dataportal_taxon_page_view',
600 593
      'access arguments' => array('access cdm content'),
601 594
      'type' => MENU_LOCAL_TASK,
......
605 598
    );
606 599

  
607 600
    $items['cdm_dataportal/taxon/%/experts'] = array( // Experts
608
      'title' => '@tabname',
609
      'title arguments' => array('@tabname' => theme('cdm_taxonpage_tab', array('tabname' => 'Experts'))),
601
      'title' => cdm_taxonpage_tab_label('Experts'),
610 602
        'page callback' => 'cdm_dataportal_taxon_page_view',
611 603
        'access arguments' => array('access cdm content'),
612 604
        'type' => MENU_LOCAL_TASK,

Also available in: Unified diff

Add picture from clipboard (Maximum size: 40 MB)