Skip to content

Commit

Permalink
Add doctrine\orm 3
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasbeaujean committed May 27, 2024
1 parent e39bfc5 commit 144d28f
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
matrix:
operating-system: [ ubuntu-latest ]
php: [ '8.1','8.2']
symfony: ['5.4.*', '6.0.*', '6.1.*', '6.2.*', '6.3.*', '7.0.*']
symfony: ['5.4.*', '6.3.*', '7.0.*']
exclude:
- php: '8.1'
symfony: '7.0.*'
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
"php": "^8.1",
"symfony/maker-bundle": "^1.7",
"symfony/framework-bundle": "^5.4|^6.0|^7.0",
"doctrine/doctrine-bundle": "^2.10",
"doctrine/doctrine-bundle": "^2.12",
"symfony/twig-bundle": "^5.4|^6.0|^7.0",
"doctrine/orm": "^2.10"
"doctrine/orm": "^3.0"
}
}
1 change: 1 addition & 0 deletions src/Generator/RepositoryGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ private function generateRepository(array $allMetadata, string $bundleName, Clas
);
}

/** @var \Doctrine\ORM\Mapping\OneToManyAssociationMapping */
foreach ($associationMappings as $associationMapping) {
$targetEntityMetadata = $allMetadata[$associationMapping['targetEntity']];

Expand Down
3 changes: 2 additions & 1 deletion src/Generator/TemplateService.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
namespace Tbn\QueryBuilderRepositoryGeneratorBundle\Generator;

use Doctrine\ORM\Mapping\ClassMetadata;
use Doctrine\ORM\Mapping\OneToManyAssociationMapping;
use Tbn\QueryBuilderRepositoryGeneratorBundle\Configuration\Configurator;
use Twig\Environment;

Expand Down Expand Up @@ -33,7 +34,7 @@ public function renderTopClass(string $extendClass, string $namespace, string $e
}

public function renderAssociation(
array $associationMapping,
OneToManyAssociationMapping $associationMapping,
string $entityDql,
ClassMetadata $targetEntityMetadata,
string $entityDqlTargeted,
Expand Down

0 comments on commit 144d28f

Please sign in to comment.