Advertisement
Guest User

Untitled

a guest
Nov 24th, 2014
176
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.35 KB | None | 0 0
  1. FatalErrorException: Error: Call to undefined method PathToMyEntityClass::setAction()
  2. in /path/to/vendor/gedmo/doctrine-extensions/lib/Gedmo/Loggable/LoggableListener.php line 225
  3.  
  4. at ErrorHandler->handleFatal() in /path/to/vendor/symfony/symfony/src/Symfony/Component/Debug/ErrorHandler.php line 0
  5. at LoggableListener->createLogEntry() in /path/to/vendor/gedmo/doctrine-extensions/lib/Gedmo/Loggable/LoggableListener.php line 188
  6. at LoggableListener->onFlush() in /path/to/vendor/symfony/symfony/src/Symfony/Bridge/Doctrine/ContainerAwareEventManager.php line 61
  7. at ContainerAwareEventManager->dispatchEvent() in /path/to/vendor/doctrine/orm/lib/Doctrine/ORM/UnitOfWork.php line 306
  8. at UnitOfWork->commit() in /path/to/vendor/doctrine/orm/lib/Doctrine/ORM/EntityManager.php line 355
  9. at EntityManager->flush() in /Path/To/My/Bundle/Controller.php line 364
  10. at Controller->addEntityAction() in /Path/To/app/bootstrap.php.cache line 2891
  11. at ??call_user_func_array() in /Path/To/app/bootstrap.php.cache line 2891
  12. at HttpKernel->handleRaw() in /Path/To/app/bootstrap.php.cache line 2865
  13. at HttpKernel->handle() in /Path/To/app/bootstrap.php.cache line 2994
  14. at ContainerAwareHttpKernel->handle() in /Path/To/app/bootstrap.php.cache line 2274
  15. at Kernel->handle() in /Path/To/web/app_dev.php line 28
  16. at ??{main}() in /Path/To/web/app_dev.php line 0
  17.  
  18. foreach ($ea->getScheduledObjectInsertions($uow) as $object) {
  19. $this->createLogEntry(self::ACTION_CREATE, $object, $ea);
  20. }
  21.  
  22. public function onFlush(EventArgs $eventArgs)
  23. {
  24. $ea = $this->getEventAdapter($eventArgs);
  25. $om = $ea->getObjectManager();
  26. $uow = $om->getUnitOfWork();
  27.  
  28. foreach ($ea->getScheduledObjectInsertions($uow) as $object) {
  29. $this->createLogEntry(self::ACTION_CREATE, $object, $ea);
  30. }
  31. foreach ($ea->getScheduledObjectUpdates($uow) as $object) {
  32. $this->createLogEntry(self::ACTION_UPDATE, $object, $ea);
  33. }
  34. foreach ($ea->getScheduledObjectDeletions($uow) as $object) {
  35. $this->createLogEntry(self::ACTION_REMOVE, $object, $ea);
  36. }
  37. }
  38.  
  39. /** @var GedmoLoggableEntityLogEntry $logEntry */
  40. $logEntry = $logEntryMeta->newInstance();
  41.  
  42. use GedmoMappingAnnotation as Gedmo;
  43.  
  44. /**
  45. * @GedmoLoggable(logEntryClass="MyBundlesThisBundleThisEntity")
  46. */
  47.  
  48. /**
  49. * @ORMColumn(type="string", length=30, nullable=false)
  50. * @AssertLength(max=30)
  51. * @GedmoVersioned
  52. */
  53. protected $name;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement