1000 search results

When you run doctrine:fixtures:load, the default path that fixture-loading classes are looked for is AppBundle/DataFixtures/ORM - that's how it knows to load the LoadFixtures class and run the load method. This was the first time during this course that I…
Had trouble loading doctrine-fixtures-bundle and nelmio/alice... when trying to do the require --dev for them I got all kinds of errors about symfony/symfony 3.1.4 satisfiable by v3.1.4 and so forth....on a bunch of bundles. Luckily, I…
When trying to install doctrine-fixtures-bundle I get an error. I'm with Symfony version 3.1.10 and I need to install it adding "^2.0.0" like this: composer require --dev "doctrine/doctrine-fixtures-bundle:^2.0.0" Hope that helps someone…
Lluís Puig Ferrer
Lluís Puig Ferrer
Read Full Comment
Hey $ ./bin/console doctrine:migrations:migrate Application Migrations WARNING! You are about to execute a database migration that could result in schema changes and data lost. Are you sure you wish to continue? (y/n)n Migration cancelled! Databases only migration_versions create done…
Д. Энхбаяр
Д. Энхбаяр
Read Full Comment
When running `doctrine:migrations:diff` I ran into an issue where the doctrine_migrations defaults were not defined, resulting in the following error: ``` [Symfony\Component\DependencyInjection\Exception\InvalidArgumentException] The parameter "doctrine_migrations.dir_name" must be defined. ``` Fixing it only requires a small config.yml…
> composer require doctrine/doctrine-migrations-bundle This completly blow up my php memory limit. So on MAC you'll need to : - find out where is your php.ini for the php CLI > php --ini - Then edit the file ( in my case : /Applications/MAMP…
One Q : why is Doctrine so "obvious" at the newAction level ($this->getDoctrin()->...) ? Do we discover later how to abstract it yet further where our entire controller could just change from Doctrine to something different?
Richie Hamburg
Richie Hamburg
Read Full Comment
…return $this->render('product/new.html.twig', array( 'product' => $product, 'category' => $category, 'form' => $form->createView(), )); } ``` The doctrine's way is the commented code, and it just inserts the last element of the loop. Strange thing is that all the images are uploaded…
Dan Costinel
Dan Costinel
Read Full Comment
This one is : [Doctrine\Common\Annotations\AnnotationException] You have to enable opcache.load_comments=1 or zend_optimizerplus.load_comments=1. Script Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache handling the post-install-cmd event terminated with an exception [RuntimeException] An error occurred when executing the "'cache:clear…
Tabla Mihai
Tabla Mihai
Read Full Comment
41 lines | app/config/services.yml
// ... lines 1 - 5
services:
// ... lines 7 - 21
app.doctrine.hash_password_listener:
class: AppBundle\Doctrine\HashPasswordListener
tags:
- { name: doctrine.event_subscriber }
app.form.help_form_extenion:
class: AppBundle\Form\TypeExtension\HelpFormExtension
tags:
- { name: form.type_extension, extended_type: Symfony\Component\Form\Extension\Core\Type\FormType }
// ... lines 31 - 41
See Code Block in Script
57 lines | app/config/services.yml
// ... lines 1 - 8
services:
// ... lines 10 - 37
AppBundle\Doctrine\HashPasswordListener:
tags:
- { name: doctrine.event_subscriber }
// ... lines 41 - 57
See Code Block in Script
70 lines | composer.json
// ... lines 1 - 15
"require": {
// ... lines 17 - 27
"stof/doctrine-extensions-bundle": "dev-master"
},
// ... lines 30 - 70
See Code Block in Script
81 lines | composer.json
{
// ... lines 2 - 42
"require-dev": {
// ... lines 44 - 45
"doctrine/doctrine-fixtures-bundle": "^3.0"
},
// ... lines 48 - 79
}
See Code Block in Script
43 lines | src/AppBundle/Form/GenusFormType.php
// ... lines 1 - 4
use Symfony\Bridge\Doctrine\Form\Type\EntityType;
// ... lines 6 - 10
class GenusFormType extends AbstractType
{
public function buildForm(FormBuilderInterface $builder, array $options)
{
$builder
// ... line 16
->add('subFamily', EntityType::class, [
// ... lines 18 - 22
])
// ... lines 24 - 32
;
}
// ... lines 35 - 41
}
See Code Block in Script
27 lines | app/config/services.yml
// ... lines 1 - 5
services:
// ... lines 7 - 21
app.doctrine.hash_password_listener:
class: AppBundle\Doctrine\HashPasswordListener
autowire: true
// ... lines 25 - 27
See Code Block in Script
27 lines | app/config/services.yml
// ... lines 1 - 5
services:
// ... lines 7 - 21
app.doctrine.hash_password_listener:
class: AppBundle\Doctrine\HashPasswordListener
autowire: true
tags:
- { name: doctrine.event_subscriber }
See Code Block in Script
118 lines | src/AppBundle/Entity/User.php
// ... lines 1 - 4
use Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntity;
// ... lines 6 - 10
/**
// ... lines 12 - 13
* @UniqueEntity(fields={"email"}, message="It looks like your already have an account!")
*/
class User implements UserInterface
// ... lines 17 - 118
See Code Block in Script
// ... lines 1 - 19
$cache = $this->get('doctrine_cache.providers.my_markdown_cache');
$key = md5($funFact);
// ... lines 22 - 55
See Code Block in Script
// ... lines 1 - 19
$cache = $this->get('doctrine_cache.providers.my_markdown_cache');
$key = md5($funFact);
if ($cache->contains($key)) {
$funFact = $cache->fetch($key);
// ... lines 24 - 28
}
// ... lines 30 - 55
See Code Block in Script
50 lines | src/AppBundle/Form/GenusFormType.php
// ... lines 1 - 6
use Symfony\Bridge\Doctrine\Form\Type\EntityType;
// ... lines 8 - 13
class GenusFormType extends AbstractType
{
public function buildForm(FormBuilderInterface $builder, array $options)
{
$builder
// ... line 19
->add('subFamily', EntityType::class, [
'placeholder' => 'Choose a Sub Family',
// ... lines 22 - 25
])
// ... lines 27 - 39
;
}
// ... lines 42 - 48
}
See Code Block in Script