-
-
Save woutsanders/2f43a08fcd10061dbda0 to your computer and use it in GitHub Desktop.
Revisions
-
woutsanders renamed this gist
May 11, 2015 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
mnapoli revised this gist
Feb 12, 2014 . 1 changed file with 3 additions and 3 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,11 +1,11 @@ # Inspired from http://blog.hio.fr/2011/09/17/doctrine2-yaml-mapping-example.html MyEntity: type: entity repositoryClass: MyRepositoryClass table: my_entity namedQueries: all: "SELECT u FROM __CLASS__ u" # Class-Table-Inheritance inheritanceType: joined -
mnapoli revised this gist
Feb 15, 2013 . 1 changed file with 9 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -7,6 +7,15 @@ myEntity: namedQueries: all: SELECT u FROM __CLASS__ u # Class-Table-Inheritance inheritanceType: joined discriminatorColumn: name: type type: string discriminatorMap: class1: MyClass1 class2: MyClass2 id: id: type: integer -
mnapoli revised this gist
Dec 21, 2012 . 1 changed file with 1 addition and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -65,6 +65,7 @@ myEntity: manyToMany: groups: targetEntity: Group inversedBy: users joinTable: name: users_groups joinColumns: -
mnapoli revised this gist
Nov 28, 2012 . 1 changed file with 1 addition and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -95,6 +95,7 @@ myEntity: referencedColumnName: id nullable: false # Referencing an entity with a multiple columns primary key manyToOne: location: targetEntity: Location -
mnapoli revised this gist
Nov 28, 2012 . 1 changed file with 11 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -95,6 +95,17 @@ myEntity: referencedColumnName: id nullable: false manyToOne: location: targetEntity: Location joinColumns: - name: location_latitude referencedColumnName: latitude nullable: false - name: location_longitude referencedColumnName: longitude nullable: false lifecycleCallbacks: prePersist: [ doStuffOnPrePersist, doOtherStuffOnPrePersistToo ] postPersist: [ doStuffOnPostPersist ] -
mnapoli revised this gist
Oct 26, 2012 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -104,7 +104,7 @@ myEntity: uniqueConstraints: search_idx: columns: [name, user_email] indexes: name_idx: -
mnapoli revised this gist
Oct 11, 2012 . 1 changed file with 13 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -48,6 +48,19 @@ myEntity: number: ASC cascade: [ persist ] # ManyToMany unidirectionnal manyToMany: groups: targetEntity: Group joinTable: name: users_groups joinColumns: user_id: referencedColumnName: id inverseJoinColumns: group_id: referencedColumnName: id # ManyToMany bidirectionnal manyToMany: groups: -
mnapoli revised this gist
Oct 11, 2012 . 1 changed file with 8 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -48,6 +48,7 @@ myEntity: number: ASC cascade: [ persist ] # ManyToMany bidirectionnal manyToMany: groups: targetEntity: Group @@ -64,6 +65,13 @@ myEntity: columnDefinition: INT NULL cascade: - all # Inverse side Group: type: entity manyToMany: users: targetEntity: User mappedBy: groups manyToOne: securityLevel: -
mnapoli revised this gist
Oct 5, 2012 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -77,6 +77,9 @@ myEntity: lifecycleCallbacks: prePersist: [ doStuffOnPrePersist, doOtherStuffOnPrePersistToo ] postPersist: [ doStuffOnPostPersist ] preUpdate: [ preUpdate ] preRemove: [ preDelete ] postLoad: [ postLoad ] uniqueConstraints: search_idx: -
mnapoli renamed this gist
Oct 5, 2012 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
mnapoli renamed this gist
Oct 5, 2012 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
mnapoli renamed this gist
Oct 5, 2012 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
mnapoli revised this gist
Oct 5, 2012 . 2 changed files with 89 additions and 39 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,39 +0,0 @@ This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,89 @@ # Inspired from http://blog.hio.fr/2011/09/17/doctrine2-yaml-mapping-example.html myEntity: type: entity repositoryClass: myRepositoryClass table: my_entity namedQueries: all: SELECT u FROM __CLASS__ u id: id: type: integer generator: strategy: AUTO sequenceGenerator: sequenceName: tablename_seq allocationSize: 100 initialValue: 1 fields: name: type: string length: 50 nullable: true unique: true email: type: string column: user_email columnDefinition: CHAR(32) NOT NULL oneToOne: address: targetEntity: Address inversedBy: user joinColumn: name: address_id referencedColumnName: id onDelete: CASCADE onUpdate: CASCADE cascade: [ remove ] oneToMany: phonenumbers: targetEntity: PhoneNumber orphanRemoval: true mappedBy: user orderBy: number: ASC cascade: [ persist ] manyToMany: groups: targetEntity: Group joinTable: name: users_groups joinColumns: user_id: referencedColumnName: id nullable: false unique: false inverseJoinColumns: group_id: referencedColumnName: id columnDefinition: INT NULL cascade: - all manyToOne: securityLevel: targetEntity: SecurityLevel inversedBy: users joinColumn: name: securitylevel_id referencedColumnName: id nullable: false lifecycleCallbacks: prePersist: [ doStuffOnPrePersist, doOtherStuffOnPrePersistToo ] postPersist: [ doStuffOnPostPersist ] uniqueConstraints: search_idx: columns: name,user_email indexes: name_idx: columns: name 0: columns: user_email -
mnapoli created this gist
Oct 5, 2012 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,39 @@ Techno_Model_Family_Dimension: type: entity repositoryClass: Core_Model_Repository table: techno_family_dimension id: _id: column: id type: integer generator: strategy: AUTO fields: _orientation: column: orientation type: integer _query: column: query type: string nullable: true manyToOne: _family: targetEntity: Techno_Model_Family inversedBy: _dimensions joinColumn: name: idFamily referencedColumnName: id nullable: false _meaning: targetEntity: Techno_Model_Meaning joinColumn: name: idMeaning referencedColumnName: id nullable: false uniqueConstraints: family_meaning: columns: [idFamily, idMeaning]