public function OrderRenderer::getFilename in Commerce Core 8.2
File
- modules/
order/ src/ EntityPrint/ OrderRenderer.php, line 93
Class
- OrderRenderer
- Provides a custom entity_print renderer for orders.
Namespace
Drupal\commerce_order\EntityPrintCode
public function getFilename(array $entities) {
$entities_label = $this->filenameGenerator
->generateFilename($entities, static function (OrderInterface $order) {
return $order
->id();
});
return $this
->t('Order @id @receipt', [
'@id' => $entities_label,
'@receipt' => $this
->formatPlural(count($entities), 'receipt', 'receipts'),
]);
}