protected function LingotekManagementRelatedEntitiesForm::getRow in Lingotek Translation 3.4.x
Same name and namespace in other branches
- 8.2 src/Form/LingotekManagementRelatedEntitiesForm.php \Drupal\lingotek\Form\LingotekManagementRelatedEntitiesForm::getRow()
- 4.0.x src/Form/LingotekManagementRelatedEntitiesForm.php \Drupal\lingotek\Form\LingotekManagementRelatedEntitiesForm::getRow()
- 3.0.x src/Form/LingotekManagementRelatedEntitiesForm.php \Drupal\lingotek\Form\LingotekManagementRelatedEntitiesForm::getRow()
- 3.1.x src/Form/LingotekManagementRelatedEntitiesForm.php \Drupal\lingotek\Form\LingotekManagementRelatedEntitiesForm::getRow()
- 3.2.x src/Form/LingotekManagementRelatedEntitiesForm.php \Drupal\lingotek\Form\LingotekManagementRelatedEntitiesForm::getRow()
- 3.3.x src/Form/LingotekManagementRelatedEntitiesForm.php \Drupal\lingotek\Form\LingotekManagementRelatedEntitiesForm::getRow()
- 3.5.x src/Form/LingotekManagementRelatedEntitiesForm.php \Drupal\lingotek\Form\LingotekManagementRelatedEntitiesForm::getRow()
- 3.6.x src/Form/LingotekManagementRelatedEntitiesForm.php \Drupal\lingotek\Form\LingotekManagementRelatedEntitiesForm::getRow()
- 3.7.x src/Form/LingotekManagementRelatedEntitiesForm.php \Drupal\lingotek\Form\LingotekManagementRelatedEntitiesForm::getRow()
- 3.8.x src/Form/LingotekManagementRelatedEntitiesForm.php \Drupal\lingotek\Form\LingotekManagementRelatedEntitiesForm::getRow()
Gets a rows fo rendering based on the passed entity.
Parameters
\Drupal\Core\Entity\EntityInterface $entity:
Return value
array A render array.
Overrides LingotekManagementFormBase::getRow
1 call to LingotekManagementRelatedEntitiesForm::getRow()
- LingotekManagementRelatedEntitiesForm::getRows in src/
Form/ LingotekManagementRelatedEntitiesForm.php - Gets the rows for rendering based on the passed entity list.
File
- src/
Form/ LingotekManagementRelatedEntitiesForm.php, line 230
Class
- LingotekManagementRelatedEntitiesForm
- Form for bulk management of related content.
Namespace
Drupal\lingotek\FormCode
protected function getRow($entity) {
// For this method to be able to be reused for the table component, order
// matters, so we rebuild the order of the row. For tableselect the headers
// defines the order, for the table, the order we add to the array matters.
$parentRow = parent::getRow($entity);
$bundleInfo = $this->entityTypeBundleInfo
->getBundleInfo($entity
->getEntityTypeId());
$row['title'] = $parentRow['title'];
$row['entity_type_id'] = $entity
->getEntityType()
->getLabel();
$row['bundle'] = $bundleInfo[$entity
->bundle()]['label'];
$row['title'] = $parentRow['title'];
$row['source'] = $parentRow['source'];
$row['translations'] = $parentRow['translations'];
$row['profile'] = $parentRow['profile'];
$row['job_id'] = $parentRow['job_id'];
return $row;
}