public static function LingotekSync::getSourceCounts in Lingotek Translation 7.7
Same name and namespace in other branches
- 7.5 lib/Drupal/lingotek/LingotekSync.php \LingotekSync::getSourceCounts()
- 7.6 lib/Drupal/lingotek/LingotekSync.php \LingotekSync::getSourceCounts()
1 call to LingotekSync::getSourceCounts()
- lingotek_get_language_details in ./
lingotek.dashboard.inc - Get the details of each language
File
- lib/
Drupal/ lingotek/ LingotekSync.php, line 418 - LingotekSync
Class
- LingotekSync
- A utility class for Lingotek Syncing.
Code
public static function getSourceCounts($lingotek_locale) {
$total = 0;
$managed_entities = lingotek_managed_entity_types();
$response = array();
$response['types'] = array();
foreach (array_keys($managed_entities) as $entity_type) {
$entity_type_count = self::getEntitySourceCount($lingotek_locale, $entity_type);
$response['types'][$entity_type] = $entity_type_count;
$total += $entity_type_count;
}
$response['total'] = $total;
return $response;
}