<?php
namespace App\EventSubscriber\Import;
use App\Entity\User;
use App\Service\Import\CustomRowEvent;
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
class MovingCompany implements EventSubscriberInterface
{
public static function getSubscribedEvents(): array
{
return [
CustomRowEvent::NAME => ['customRow'],
];
}
/**
* @return void
*/
public function customRow(CustomRowEvent $event)
{
if ($event->getEntity() != User::class) {
return;
}
$row = $event->getData();
// dd($row);
$event->setData($row);
}
}