Guite / MostGenerator

Transformation cartridges for generating Symfony bundles from ModuleStudio models.
https://modulestudio.de
23 stars 2 forks source link

Undefined method 'get'. The method name must start with either findBy or findOneBy! #773

Closed robbrandt closed 8 years ago

robbrandt commented 8 years ago

Stack trace shows this is in archiveObjects(). Here's the whole stack trace

`[1] BadMethodCallException: Undefined method 'get'. The method name must start with either findBy or findOneBy! at n/a in /Users/robbrandt/Documents/htdocs/Conference/vendor/doctrine/orm/lib/Doctrine/ORM/EntityRepository.php line 226

at Doctrine\ORM\EntityRepository->__call('get', array('botanyorg_conference_module.hook_helper'))
    in /Users/robbrandt/Documents/htdocs/Conference/modules/Botanyorg/ConferenceModule/Entity/Repository/Base/Eventitem.php line 1142

at Botanyorg\ConferenceModule\Entity\Repository\Eventitem->get('botanyorg_conference_module.hook_helper')
    in /Users/robbrandt/Documents/htdocs/Conference/modules/Botanyorg/ConferenceModule/Entity/Repository/Base/Eventitem.php line 1142

at Botanyorg\ConferenceModule\Entity\Repository\Base\Eventitem->archiveObjects()
    in /Users/robbrandt/Documents/htdocs/Conference/modules/Botanyorg/ConferenceModule/Base/bootstrap.php line 50

at conferPerformRegularAmendments()
    in /Users/robbrandt/Documents/htdocs/Conference/modules/Botanyorg/ConferenceModule/Base/bootstrap.php line 24

at include_once('/Users/robbrandt/Documents/htdocs/Conference/modules/Botanyorg/ConferenceModule/Base/bootstrap.php')
    in /Users/robbrandt/Documents/htdocs/Conference/modules/Botanyorg/ConferenceModule/bootstrap.php line 20

at include_once('/Users/robbrandt/Documents/htdocs/Conference/modules/Botanyorg/ConferenceModule/bootstrap.php')
    in /Users/robbrandt/Documents/htdocs/Conference/lib/Zikula/Core/Controller/AbstractController.php line 61

at Zikula\Core\Controller\AbstractController->boot(object(BotanyorgConferenceModule))
    in /Users/robbrandt/Documents/htdocs/Conference/lib/Zikula/Core/Controller/AbstractController.php line 48

at Zikula\Core\Controller\AbstractController->__construct(object(BotanyorgConferenceModule))
    in /Users/robbrandt/Documents/htdocs/Conference/lib/Zikula/Bundle/CoreBundle/Controller/ControllerResolver.php line 66

at Zikula\Bundle\CoreBundle\Controller\ControllerResolver->createController('Botanyorg\ConferenceModule\Controller\AdminController::indexAction')
    in /Users/robbrandt/Documents/htdocs/Conference/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Controller/ControllerResolver.php line 76

at Symfony\Component\HttpKernel\Controller\ControllerResolver->getController(object(Zikula_Request_Http))
    in /Users/robbrandt/Documents/htdocs/Conference/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Controller/TraceableControllerResolver.php line 46

at Symfony\Component\HttpKernel\Controller\TraceableControllerResolver->getController(object(Zikula_Request_Http))
    in /Users/robbrandt/Documents/htdocs/Conference/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpKernel.php line 132

at Symfony\Component\HttpKernel\HttpKernel->handleRaw(object(Zikula_Request_Http), '1')
    in /Users/robbrandt/Documents/htdocs/Conference/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpKernel.php line 64

at Symfony\Component\HttpKernel\HttpKernel->handle(object(Zikula_Request_Http), '1', true)
    in /Users/robbrandt/Documents/htdocs/Conference/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/DependencyInjection/ContainerAwareHttpKernel.php line 69

at Symfony\Component\HttpKernel\DependencyInjection\ContainerAwareHttpKernel->handle(object(Zikula_Request_Http), '1', true)
    in /Users/robbrandt/Documents/htdocs/Conference/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php line 193

at Symfony\Component\HttpKernel\Kernel->handle(object(Zikula_Request_Http))
    in /Users/robbrandt/Documents/htdocs/Conference/index.php line 23`

and the referenced code itself:

` $action = 'archive'; $workflowHelper = $serviceManager->get('botanyorg_conference_module.workflow_helper'); $hookHelper = $this->get('botanyorg_conference_module.hook_helper');

    foreach ($affectedEntities as $entity) {`
Guite commented 8 years ago

Fixed in 9be14c97d27a9ce1a99dca4b2e942ed5a9a54356