ProductVariationViewsData.php in Commerce Core 8.2
File
modules/product/src/ProductVariationViewsData.php
View source
<?php
namespace Drupal\commerce_product;
use Drupal\commerce\CommerceEntityViewsData;
class ProductVariationViewsData extends CommerceEntityViewsData {
protected function addEntityLinks(array &$data) {
parent::addEntityLinks($data);
$t_arguments = [
'@entity_type_label' => $this->entityType
->getLabel(),
];
$data['view_commerce_product_variation']['field'] = [
'title' => $this
->t('Link to @entity_type_label', $t_arguments),
'help' => $this
->t('Provide a view link to the @entity_type_label.', $t_arguments),
'id' => 'commerce_product_variation_view_link',
];
}
}