]> Raphaƫl G. Git Repositories - airbundle/blobdiff - Resources/config/doctrine/Session.orm.yml
New header layout
[airbundle] / Resources / config / doctrine / Session.orm.yml
index 68c611682b0e422cc69ed7224c051a5f01f01cae..9631e932bcdb2d7dcb858d0d4b5b1814d87f589c 100644 (file)
@@ -18,10 +18,36 @@ Rapsys\AirBundle\Entity\Session:
         length:
             type: time
             nullable: true
-#The day score, 1 for sun-thu, 2 for fri-sat, +1 for high temperature, *-1 for bad weather
-#        score:
-#            type: smallint
-#            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:
@@ -43,3 +69,24 @@ Rapsys\AirBundle\Entity\Session:
     uniqueConstraints:
         date_location_slot:
             columns: [ date, location_id, slot_id ]
+    indexes:
+        #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']