You are here

protected function LingotekContentTranslationService::getUploadProcessId in Lingotek Translation 3.8.x

Same name and namespace in other branches
  1. 4.0.x src/LingotekContentTranslationService.php \Drupal\lingotek\LingotekContentTranslationService::getUploadProcessId()
  2. 3.7.x src/LingotekContentTranslationService.php \Drupal\lingotek\LingotekContentTranslationService::getUploadProcessId()

Gets the upload process id.

Parameters

\Drupal\Core\Entity\ContentEntityInterface $entity: The entity being imported.

1 call to LingotekContentTranslationService::getUploadProcessId()
LingotekContentTranslationService::checkUploadProcessId in src/LingotekContentTranslationService.php
Checks the upload process id.

File

src/LingotekContentTranslationService.php, line 2509

Class

LingotekContentTranslationService
Service for managing Lingotek content translations.

Namespace

Drupal\lingotek

Code

protected function getUploadProcessId(ContentEntityInterface $entity) {
  $state = \Drupal::state();
  $stored_process_ids = $state
    ->get('lingotek_import_process_ids', []);
  $parents = [
    $entity
      ->getEntityTypeId(),
    $entity
      ->id(),
  ];
  return NestedArray::getValue($stored_process_ids, $parents);
}