WordPress.org

Making WordPress.org


Ignore:
Timestamp:
02/23/2017 11:42:12 PM (3 years ago)
Author:
ocean90
Message:

Translate: Show link to locale glossary on project overviews.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/wporg-gp-routes/inc/routes/class-locale.php

    r4928 r4996  
    134134        }
    135135
     136        $can_create_locale_glossary = GP::$permission->current_user_can( 'admin' );
     137        $locale_glossary_translation_set = GP::$translation_set->by_project_id_slug_and_locale( 0, $set_slug, $locale_slug );
     138        $locale_glossary = GP::$glossary->by_set_id( $locale_glossary_translation_set->id );
     139
    136140        $this->tmpl( 'locale-projects', get_defined_vars() );
    137141    }
     
    188192
    189193        $locale_contributors = $this->get_locale_contributors( $sub_project, $locale_slug, $set_slug );
     194
     195        $can_create_locale_glossary = GP::$permission->current_user_can( 'admin' );
     196        $locale_glossary_translation_set = GP::$translation_set->by_project_id_slug_and_locale( 0, $set_slug, $locale_slug );
     197        $locale_glossary = GP::$glossary->by_set_id( $locale_glossary_translation_set->id );
    190198
    191199        $this->tmpl( 'locale-project', get_defined_vars() );
Note: See TracChangeset for help on using the changeset viewer.