Closed polo195pl closed 3 years ago
Problem solved in many to one relation we must use 'field' option for example:
$table = $dataTableFactory->create()
->add('firstName', TextColumn::class, ['label' => 'Firstname', 'field' => 'user.firstname'])
->add('logStart', DateTimeColumn::class, ['label' => 'Log start'])
->createAdapter(ORMAdapter::class, [
'entity' => Log::class,
])
->handleRequest($request);
Hi everyone :) I use omines/datables-bundle with Symfony 4.4 and Doctrine 2.4 and PHP 7.3.12
I have two entietes: User with fields: id, firstname, lastname and logs and entity Log with fields: id, user, time
So i try builid table:
But when i run this code i have only data from Log entity without User I would be very grateful for your help :) Thx all 👍