From: Raphaƫl Gertz Date: Wed, 2 Dec 2026 23:50:36 +0000 (+0100) Subject: Migrate yml orm to xml format X-Git-Tag: 0.6.0~11 X-Git-Url: https://git.rapsys.eu/.gitweb.cgi/airbundle/commitdiff_plain/9813f7eea401d8c5f74527d8364d245146a48046 Migrate yml orm to xml format --- diff --git a/config/doctrine/Application.orm.xml b/config/doctrine/Application.orm.xml new file mode 100644 index 0000000..fd29c59 --- /dev/null +++ b/config/doctrine/Application.orm.xml @@ -0,0 +1,33 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config/doctrine/Application.orm.yml b/config/doctrine/Application.orm.yml deleted file mode 100644 index 38de0fe..0000000 --- a/config/doctrine/Application.orm.yml +++ /dev/null @@ -1,44 +0,0 @@ -Rapsys\AirBundle\Entity\Application: - type: entity - repositoryClass: Rapsys\AirBundle\Repository\ApplicationRepository - table: applications - id: - id: - type: integer - generator: - strategy: AUTO - options: - unsigned: true - fields: - score: - type: float - nullable: true - canceled: - type: datetime - nullable: true - created: - type: datetime - updated: - type: datetime - manyToOne: - dance: - targetEntity: Rapsys\AirBundle\Entity\Dance - inversedBy: applications - session: - targetEntity: Rapsys\AirBundle\Entity\Session - inversedBy: applications - user: - targetEntity: Rapsys\AirBundle\Entity\User - inversedBy: applications - lifecycleCallbacks: - preUpdate: ['preUpdate'] -# oneToMany: -# votes: -# targetEntity: Rapsys\AirBundle\Entity\Vote -# mappedBy: application -# indexes: -# #XXX: used in SessionRepository::XXX -# id_user: -# columns: [ id, user_id ] -# id_user_canceled: -# columns: [ id, user_id, canceled ] diff --git a/config/doctrine/Civility.orm.xml b/config/doctrine/Civility.orm.xml new file mode 100644 index 0000000..65dda1f --- /dev/null +++ b/config/doctrine/Civility.orm.xml @@ -0,0 +1,4 @@ + + + + diff --git a/config/doctrine/Civility.orm.yml b/config/doctrine/Civility.orm.yml deleted file mode 100644 index ca77014..0000000 --- a/config/doctrine/Civility.orm.yml +++ /dev/null @@ -1,8 +0,0 @@ -Rapsys\AirBundle\Entity\Civility: - type: entity - #repositoryClass: Rapsys\AirBundle\Repository\CivilityRepository - table: civilities - oneToMany: - users: - targetEntity: User - mappedBy: civility diff --git a/config/doctrine/Country.orm.xml b/config/doctrine/Country.orm.xml new file mode 100644 index 0000000..054f38a --- /dev/null +++ b/config/doctrine/Country.orm.xml @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config/doctrine/Country.orm.yml b/config/doctrine/Country.orm.yml deleted file mode 100644 index e0a5527..0000000 --- a/config/doctrine/Country.orm.yml +++ /dev/null @@ -1,39 +0,0 @@ -Rapsys\AirBundle\Entity\Country: - type: entity - #repositoryClass: Rapsys\AirBundle\Repository\CountryRepository - table: countries - id: - id: - type: integer - generator: - strategy: AUTO - options: - unsigned: true - fields: - code: - type: string - length: 2 - nullable: false - alpha: - type: string - length: 3 - nullable: false - title: - type: string - length: 64 - nullable: false - created: - type: datetime - updated: - type: datetime - oneToMany: - users: - targetEntity: Rapsys\AirBundle\Entity\User - mappedBy: country - uniqueConstraints: - code: - columns: [ code ] - alpha: - columns: [ alpha ] - lifecycleCallbacks: - preUpdate: ['preUpdate'] diff --git a/config/doctrine/Dance.orm.xml b/config/doctrine/Dance.orm.xml new file mode 100644 index 0000000..5515af0 --- /dev/null +++ b/config/doctrine/Dance.orm.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config/doctrine/Dance.orm.yml b/config/doctrine/Dance.orm.yml deleted file mode 100644 index 0d241cc..0000000 --- a/config/doctrine/Dance.orm.yml +++ /dev/null @@ -1,35 +0,0 @@ -Rapsys\AirBundle\Entity\Dance: - type: entity - repositoryClass: Rapsys\AirBundle\Repository\DanceRepository - table: dances - id: - id: - type: integer - generator: - strategy: AUTO - options: - unsigned: true - fields: - name: - type: string - length: 32 - type: - type: string - length: 32 - created: - type: datetime - updated: - type: datetime - oneToMany: - applications: - targetEntity: Rapsys\AirBundle\Entity\Application - mappedBy: dance - manyToMany: - users: - targetEntity: Rapsys\AirBundle\Entity\User - mappedBy: dances - uniqueConstraints: - name_type: - columns: [ name, type ] - lifecycleCallbacks: - preUpdate: ['preUpdate'] diff --git a/config/doctrine/GoogleCalendar.orm.xml b/config/doctrine/GoogleCalendar.orm.xml new file mode 100644 index 0000000..5365619 --- /dev/null +++ b/config/doctrine/GoogleCalendar.orm.xml @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config/doctrine/GoogleCalendar.orm.yml b/config/doctrine/GoogleCalendar.orm.yml deleted file mode 100644 index d8d0fbc..0000000 --- a/config/doctrine/GoogleCalendar.orm.yml +++ /dev/null @@ -1,44 +0,0 @@ -Rapsys\AirBundle\Entity\GoogleCalendar: - type: entity - #repositoryClass: Rapsys\AirBundle\Repository\GoogleCalendarRepository - table: google_calendars - id: - id: - type: integer - generator: - strategy: AUTO - options: - unsigned: true - fields: - mail: - type: string - length: 1024 - summary: - type: string - length: 255 -# description: -# type: string -# length: 200 -# location: -# type: string -# length: 1024 -# timezone: -# type: string -# length: 32 - synchronized: - type: datetime - created: - type: datetime - updated: - type: datetime - manyToOne: - googleToken: - targetEntity: Rapsys\AirBundle\Entity\GoogleToken - inversedBy: googleCalendars - joinColumn: - nullable: false -# uniqueConstraints: -# user_mail: -# columns: [ user_id, mail ] - lifecycleCallbacks: - preUpdate: ['preUpdate'] diff --git a/config/doctrine/GoogleToken.orm.xml b/config/doctrine/GoogleToken.orm.xml new file mode 100644 index 0000000..42efdd7 --- /dev/null +++ b/config/doctrine/GoogleToken.orm.xml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config/doctrine/GoogleToken.orm.yml b/config/doctrine/GoogleToken.orm.yml deleted file mode 100644 index a32c963..0000000 --- a/config/doctrine/GoogleToken.orm.yml +++ /dev/null @@ -1,43 +0,0 @@ -Rapsys\AirBundle\Entity\GoogleToken: - type: entity - repositoryClass: Rapsys\AirBundle\Repository\GoogleTokenRepository - table: google_tokens - id: - id: - type: integer - generator: - strategy: AUTO - options: - unsigned: true - fields: - mail: - type: string - length: 254 - access: - type: string - length: 2048 - refresh: - type: string - length: 512 - nullable: true - expired: - type: datetime - created: - type: datetime - updated: - type: datetime - manyToOne: - user: - targetEntity: Rapsys\AirBundle\Entity\User - inversedBy: googleTokens - joinColumn: - nullable: false - oneToMany: - googleCalendars: - targetEntity: Rapsys\AirBundle\Entity\GoogleCalendar - mappedBy: googleToken - uniqueConstraints: - user_mail: - columns: [ user_id, mail ] - lifecycleCallbacks: - preUpdate: ['preUpdate'] diff --git a/config/doctrine/Group.orm.xml b/config/doctrine/Group.orm.xml new file mode 100644 index 0000000..7cfae29 --- /dev/null +++ b/config/doctrine/Group.orm.xml @@ -0,0 +1,4 @@ + + + + diff --git a/config/doctrine/Group.orm.yml b/config/doctrine/Group.orm.yml deleted file mode 100644 index 57f70a9..0000000 --- a/config/doctrine/Group.orm.yml +++ /dev/null @@ -1,8 +0,0 @@ -Rapsys\AirBundle\Entity\Group: - type: entity - #repositoryClass: Rapsys\AirBundle\Repository\GroupRepository - table: groups - manyToMany: - users: - targetEntity: Rapsys\AirBundle\Entity\User - mappedBy: groups diff --git a/config/doctrine/Location.orm.xml b/config/doctrine/Location.orm.xml new file mode 100644 index 0000000..f31a3e5 --- /dev/null +++ b/config/doctrine/Location.orm.xml @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config/doctrine/Location.orm.yml b/config/doctrine/Location.orm.yml deleted file mode 100644 index 2393106..0000000 --- a/config/doctrine/Location.orm.yml +++ /dev/null @@ -1,65 +0,0 @@ -Rapsys\AirBundle\Entity\Location: - type: entity - repositoryClass: Rapsys\AirBundle\Repository\LocationRepository - table: locations - id: - id: - type: integer - generator: - strategy: AUTO - options: - unsigned: true - fields: - title: - type: string - length: 32 - description: - type: text - nullable: true - address: - type: string - length: 32 - zipcode: - type: string - length: 5 - city: - type: string - length: 64 - latitude: - type: decimal - precision: 8 - scale: 6 - longitude: - type: decimal - precision: 9 - scale: 6 - indoor: - type: boolean - hotspot: - type: boolean - created: - type: datetime - updated: - type: datetime - oneToMany: - sessions: - targetEntity: Rapsys\AirBundle\Entity\Session - mappedBy: location - snippets: - targetEntity: Rapsys\AirBundle\Entity\Snippet - mappedBy: location - manyToMany: - users: - targetEntity: Rapsys\AirBundle\Entity\User - mappedBy: locations - indexes: - #XXX: used in SessionRepository::(findAllPendingDailyWeather|findAllPendingHourlyWeather) - zipcode: - columns: [ zipcode ] - city_zipcode2: - columns: [ city, zipcode ] - #XXX: see https://github.com/doctrine/dbal/pull/2412 and https://stackoverflow.com/questions/32539973/configuring-index-text-length-mysql-in-doctrine - options: - lengths: [ ~, 2 ] - lifecycleCallbacks: - preUpdate: ['preUpdate'] diff --git a/config/doctrine/Session.orm.xml b/config/doctrine/Session.orm.xml new file mode 100644 index 0000000..2988037 --- /dev/null +++ b/config/doctrine/Session.orm.xml @@ -0,0 +1,62 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config/doctrine/Session.orm.yml b/config/doctrine/Session.orm.yml deleted file mode 100644 index fb1e962..0000000 --- a/config/doctrine/Session.orm.yml +++ /dev/null @@ -1,95 +0,0 @@ -Rapsys\AirBundle\Entity\Session: - type: entity - repositoryClass: Rapsys\AirBundle\Repository\SessionRepository - table: sessions - id: - id: - type: integer - generator: - strategy: AUTO - options: - unsigned: true - fields: - date: - type: date - begin: - type: time - nullable: true - length: - type: time - nullable: true - premium: - type: boolean - nullable: true - rainfall: - type: float - nullable: true - rainrisk: - type: float - nullable: true - realfeel: - type: float - nullable: true - realfeelmin: - type: float - nullable: true - realfeelmax: - type: float - nullable: true - temperature: - type: float - nullable: true - temperaturemin: - type: float - nullable: true - temperaturemax: - type: float - nullable: true - locked: - type: datetime - nullable: true - created: - type: datetime - updated: - type: datetime - oneToOne: - application: - targetEntity: Rapsys\AirBundle\Entity\Application - manyToOne: - location: - targetEntity: Rapsys\AirBundle\Entity\Location - inversedBy: sessions - slot: - targetEntity: Rapsys\AirBundle\Entity\Slot - inversedBy: sessions - oneToMany: - applications: - targetEntity: Rapsys\AirBundle\Entity\Application - mappedBy: session - uniqueConstraints: - date_location_slot: - columns: [ date, location_id, slot_id ] - indexes: - #XXX: used in SessionRepository::findAllByPeriodAsCalendarArray - date_location: - columns: [ date, location_id ] - #XXX: used in SessionRepository::findAllPendingApplication - locked_date_begin_created: - columns: [ locked, date, begin, created ] - #XXX: used in SessionRepository::findBestApplicationById(s3) - application_locked_date_begin_slot_created: - columns: [ application_id, locked, date, begin, slot_id, created ] - #XXX: candidated in findAllPendingDailyWeather and findAllPendingHourlyWeather - location_date_begin_length_slot: - columns: [ location_id, date, begin, length, slot_id ] -# #XXX: tried for SessionRepository::findBestApplicationById(s2) -# location_slot_application_locked_date_begin: -# columns: [ location_id, slot_id, application_id, locked, date ] -# #XXX: tried for SessionRepository::findBestApplicationById(s3) -# application_locked_date: -# columns: [ application_id, locked, date ] -# #XXX: tried for SessionRepository::findBestApplicationById(s4) -# location_application_locked_date: -# columns: [ location_id, application_id, locked, date ] - lifecycleCallbacks: - preUpdate: ['preUpdate'] diff --git a/config/doctrine/Slot.orm.xml b/config/doctrine/Slot.orm.xml new file mode 100644 index 0000000..b52a813 --- /dev/null +++ b/config/doctrine/Slot.orm.xml @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + diff --git a/config/doctrine/Slot.orm.yml b/config/doctrine/Slot.orm.yml deleted file mode 100644 index d09120d..0000000 --- a/config/doctrine/Slot.orm.yml +++ /dev/null @@ -1,25 +0,0 @@ -Rapsys\AirBundle\Entity\Slot: - type: entity - #repositoryClass: Rapsys\AirBundle\Repository\SlotRepository - table: slots - id: - id: - type: integer - generator: - strategy: AUTO - options: - unsigned: true - fields: - title: - type: string - length: 16 - created: - type: datetime - updated: - type: datetime - oneToMany: - sessions: - targetEntity: Rapsys\AirBundle\Entity\Session - mappedBy: slot - lifecycleCallbacks: - preUpdate: ['preUpdate'] diff --git a/config/doctrine/Snippet.orm.xml b/config/doctrine/Snippet.orm.xml new file mode 100644 index 0000000..11ecc16 --- /dev/null +++ b/config/doctrine/Snippet.orm.xml @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config/doctrine/Snippet.orm.yml b/config/doctrine/Snippet.orm.yml deleted file mode 100644 index 2333e9a..0000000 --- a/config/doctrine/Snippet.orm.yml +++ /dev/null @@ -1,68 +0,0 @@ -Rapsys\AirBundle\Entity\Snippet: - type: entity - repositoryClass: Rapsys\AirBundle\Repository\SnippetRepository - table: snippets - id: - id: - type: integer - generator: - strategy: AUTO - options: - unsigned: true - fields: - locale: - type: string - length: 5 - description: - type: text - nullable: true - class: - type: text - nullable: true - short: - type: text - nullable: true - rate: - type: integer - nullable: true - options: - unsigned: true - hat: - type: boolean - nullable: true - contact: - type: string - length: 254 - nullable: true - donate: - type: string - length: 254 - nullable: true - link: - type: string - length: 254 - nullable: true - profile: - type: string - length: 254 - nullable: true - created: - type: datetime - updated: - type: datetime - manyToOne: - location: - targetEntity: Rapsys\AirBundle\Entity\Location - inversedBy: snippets - user: - targetEntity: Rapsys\AirBundle\Entity\User - inversedBy: snippets - indexes: - #XXX: may be used in SnippetRepository::findByLocaleUserId - locale_user: - columns: [ locale, user_id ] - uniqueConstraints: - locale_location_user: - columns: [ locale, location_id, user_id ] - lifecycleCallbacks: - preUpdate: ['preUpdate'] diff --git a/config/doctrine/User.orm.xml b/config/doctrine/User.orm.xml new file mode 100644 index 0000000..91cf2b5 --- /dev/null +++ b/config/doctrine/User.orm.xml @@ -0,0 +1,62 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config/doctrine/User.orm.yml b/config/doctrine/User.orm.yml deleted file mode 100644 index ceffdfd..0000000 --- a/config/doctrine/User.orm.yml +++ /dev/null @@ -1,96 +0,0 @@ -Rapsys\AirBundle\Entity\User: - type: entity - repositoryClass: Rapsys\AirBundle\Repository\UserRepository - table: users - fields: - city: - type: string - length: 64 - nullable: true - phone: - type: string - length: 16 - nullable: true - pseudonym: - type: string - length: 32 - nullable: true - zipcode: - type: string - length: 5 - nullable: true - mid: - type: string - length: 254 - nullable: true - mip: - type: string - length: 39 - nullable: true - oneToMany: - applications: - targetEntity: Rapsys\AirBundle\Entity\Application - mappedBy: user - snippets: - targetEntity: Rapsys\AirBundle\Entity\Snippet - mappedBy: user - googleTokens: - targetEntity: Rapsys\AirBundle\Entity\GoogleToken - mappedBy: user - manyToMany: - dances: - targetEntity: Rapsys\AirBundle\Entity\Dance - inversedBy: users - joinTable: - name: users_dances - joinColumns: - id: - name: user_id - inverseJoinColumns: - id: - name: dance_id - subscribers: - targetEntity: Rapsys\AirBundle\Entity\User - mappedBy: subscriptions - subscriptions: - targetEntity: Rapsys\AirBundle\Entity\User - inversedBy: subscribers - joinTable: - name: users_subscriptions - joinColumns: - id: - name: user_id - inverseJoinColumns: - id: - name: subscribed_id - locations: - targetEntity: Rapsys\AirBundle\Entity\Location - inversedBy: users - joinTable: - name: users_locations - joinColumns: - id: - name: user_id - inverseJoinColumns: - id: - name: location_id - manyToOne: - country: - targetEntity: Rapsys\AirBundle\Entity\Country - inversedBy: users -# manyToMany: -# groups: -# targetEntity: Group -# inversedBy: users -# joinTable: -# name: groups_users - associationOverride: - groups: - joinTable: - name: users_groups - joinColumns: - id: - name: user_id - inverseJoinColumns: - id: - name: group_id