1
0
mirror of synced 2025-02-03 05:49:25 +03:00

856 Commits

Author SHA1 Message Date
Maximilian Bosch
49bb345533
#5934 - #5938 - fix accidentally introduced regression with wrong target of ::class expression 2017-05-31 15:01:25 +02:00
Maximilian Bosch
fcfaa13df9
#5934 - #5938 - use ClassMetadata::class expression rather than FQCN in config drivers as of @Ocramius's review 2017-05-31 14:52:55 +02:00
Maximilian Bosch
92476b5953
#5934 - add fetch option to AssociationOverride in order to override fetch strategy for subclasses of entities 2017-05-30 18:19:48 +02:00
Luís Cobucci
f9062d9931
Force YAML parser to convert keys to string
Since Symfony 3.3 implicit conversion is not enabled by default so we
need to pass that flag manually.

Related to: https://github.com/symfony/symfony/pull/21774
2017-05-30 13:53:45 +02:00
Simone Gentili
fac7e8facb align equals signs 2017-05-13 23:05:37 +02:00
Luís Cobucci
4ebf27de35
Use "quoted" from existing data if exists
In order to keep that information for inheritance mapping.
2017-04-30 19:36:40 +02:00
Jarek Jakubowski
38bfcc6a7a
Fix notice in ClassMetadata when there is no ID Column defined
When you forget about defining the ID/PK Column, then this ugly Notice appear.
Now it will throw nice Exception.
2017-04-30 11:38:47 +02:00
Luís Cobucci
512aa8a3c7
Use "::class" syntax on "lib" directory 2016-12-08 17:09:35 +01:00
Luís Cobucci
234989d069
Use short-array syntax on "lib" directory 2016-12-08 00:31:12 +01:00
Marco Pivetta
5d477cdbbc #5914 ClassMetadataInfo#$lifecycleCallbacks is a multi-dimensional array 2016-11-26 06:42:46 +01:00
Javier Spagnoletti
e2b198112e [minor] Add missing type hints, add strictness for some checks, remove some useless calls 2016-11-26 05:18:46 +01:00
Marco Pivetta
8c38f5775d Merge pull request #6121 from kalessil/sca
Static Code Analysis with Php Inspections (EA Extended)
2016-11-26 04:57:48 +01:00
Alexander Guz
8d433cdb39 #6129 Fixed code style and @depends in test. 2016-11-17 21:05:58 +01:00
Alexander Guz
7bf206adb4 #6129 Moved test to AbstractMappingDriverTest. 2016-11-16 20:01:11 +01:00
Vladimir Reznichenko
db375a22cc Static Code Analysis with Php Inspections (EA Extended): revert unsets 2016-11-06 17:58:45 +01:00
Vladimir Reznichenko
0bf3d7f84c Static Code Analysis with Php Inspections (EA Extended) 2016-11-06 14:22:47 +01:00
Jefersson Nathan
b8a18cd0a1
fix license header inconsistencies 2016-10-25 23:58:42 -03:00
ReenExe
f7c16ab364 remove else 2016-07-03 00:21:00 +03:00
ReenExe
99b1eaaabb clear code - double condition after isset 2016-07-03 00:17:51 +03:00
ReenExe
1dba0b8545 clear code 2016-07-03 00:14:33 +03:00
ReenExe
0e8491a474 clear code 2016-07-03 00:11:44 +03:00
ReenExe
511b27517a refactoring: extract method 2016-07-03 00:10:43 +03:00
ReenExe
a81458a0aa 1. merge conditions
2. convert `if` to `condition`
2016-07-03 00:05:31 +03:00
ReenExe
b108a2af52 merge conditions 2016-07-03 00:01:07 +03:00
ReenExe
f7317d700c logical remove double condition 2016-07-02 23:58:29 +03:00
ReenExe
2301fb3ff2 move common cascades 2016-07-02 23:53:23 +03:00
ReenExe
eccec87796 clear code 2016-07-02 23:47:21 +03:00
Luís Cobucci
27f3bc1e2c Allow the usage of embedded objects on parent classes.
The `ClassMetadataInfo` was always using the "current class" to
fetch the reflection of a property even when a field is declared
on the parent class (which causes `ReflectionProperty` to throw
an exception).
2016-06-19 12:35:57 +02:00
Bill Schaller
8bde0c8a90 Fix AnnotationDriver, XmlDriver, YamlDriver to properly set DiscriminatorColumn defaults for type and length.
Note: Even though the column definition generated for a discriminator column
would eventually default the type to string and length to 255, the docs specify
defaults that should be reflected explicitly in the discriminatorColumn mapping.
2016-01-05 12:32:25 -05:00
Marco Pivetta
044b202379 Simplifying getColumnNames logic (can be an array_map call) 2015-12-11 20:50:18 +01:00
Jeroen Thora
6dcb97a20e Fixed many small phpcs issues 2015-12-11 20:30:41 +01:00
Steve Müller
e0cb90d426 fix empty expression on PHP 5.4 2015-11-19 16:43:33 +01:00
Steve Müller
86c81da7ce inherit ID generator strategy mapping from embeddables 2015-11-19 16:10:48 +01:00
Guilherme Blanco
49bb687aaf Merge pull request #1540 from pantelm/master
[DDC-3711] Correct Error on manyToMany with composite primary key + add Tests
2015-11-08 22:43:36 -05:00
Guilherme Blanco
843966ac50 General fixes across CS, type resolving, test fixes, etc 2015-11-07 03:55:05 +00:00
z38
ff28507b88 Allow override of inversedBy 2015-11-05 12:11:29 +01:00
Pantel
96687e04a6 [DDC-3711] Correct Error on manyToMany with composite primary key 2015-10-31 16:02:14 +01:00
Guido Contreras Woda
3a7d2da2e5 Added custom ID generator definition to the FieldBuilder 2015-10-02 13:51:07 -03:00
Tobias Schultze
c03996d3b3 Fix variable reference in phpdoc of ClassMetadataInfo 2015-09-11 00:19:18 +02:00
Marco Pivetta
506df640b5 Merge pull request #1433 from goetas/slc-check-to-classmetadatainfo
Check for non-cacheable entities on metadata level, not at runtime
2015-07-16 20:41:30 +01:00
Asmir Mustafic
3a7b2991e8 PSR-2 CS improvements 2015-07-16 16:20:36 +02:00
Nico Vogelaar
b3af5590f9 Fixes ClassMetadata wakeupReflection with embeddable and StaticReflectionService 2015-07-15 20:49:16 +01:00
Asmir Mustafic
acbda4bc0e YAML driver uses getAssociationCacheDefaults for SLC mapping 2015-06-20 14:32:14 +02:00
Asmir Mustafic
7d64be915c XML driver uses getAssociationCacheDefaults for SLC mapping 2015-06-20 14:32:14 +02:00
Asmir Mustafic
f4f32a5213 Annotation driver uses getAssociationCacheDefaults for SLC mapping 2015-06-20 14:32:14 +02:00
Asmir Mustafic
c685255fe3 Check for non-cacheable associations directly on the class metada info 2015-06-20 14:32:14 +02:00
Asmir Mustafic
6a428c6064 Allow to retreive association cache defaults 2015-06-20 14:32:14 +02:00
Bill Schaller
4b10db3a43 Fix crashes in ConvertMappingCommand and GenerateEntitiesCommand when using entities with joined table inheritance
ConvertMappingCommand and GenerateEntitiesCommand both use the DisconnectedClassMetadataFactory, which allows metadata manipulation without loading the associated classes. Commit a36bea broke these two commands by adding a bailout condition in ClassMetadataFactory::populateDiscriminatorValue which checks $metadata->reflClass->isAbstract(). If the DisconnectedClassMetadataFactory is being used, $metadata->reflClass will always be null, causing a fatal error, "Fatal error: Call to a member function isAbstract() on null".

This commit adds a check to see if $metadata->reflClass is set before checking isAbstract.
2015-03-20 13:59:27 -04:00
Benjamin Eberlei
b3a6fb7fde [DDC-3461] Renamed AssocationBuilder::isPrimaryKey() to makePrimaryKey(). Same for FieldBuilder and depreceating isPrimaryKey(). Adjust tests. Revert change in ClassMetadataInfo and fix bug. 2015-03-18 17:06:30 +01:00
Marco Pivetta
648fde8914 #1316 - removing useless null check (redundant with isset()), cs cleanups 2015-03-17 23:16:16 +00:00