|
| 1 | +Table "edition" { |
| 2 | + "id" int [pk, not null, increment] |
| 3 | + "creation_date" datetime [not null] |
| 4 | + "name" varchar(40) [not null] |
| 5 | + "event_id" int [not null] |
| 6 | + "edition_date" datetime [not null] |
| 7 | + "first_inscription" datetimeme [not null] |
| 8 | + "last_inscription" datetime [not null] |
| 9 | + "rdv_lat" float [not null] |
| 10 | + "rdv_lng" float [not null] |
| 11 | + "description" text [not null] |
| 12 | + |
| 13 | + Indexes { |
| 14 | + event_id [name: "event_id"] |
| 15 | + } |
| 16 | +} |
| 17 | + |
| 18 | +Table "editions_parcours" { |
| 19 | + "edition_id" int [default: NULL] |
| 20 | + "parcours_id" int [default: NULL] |
| 21 | + |
| 22 | + Indexes { |
| 23 | + edition_id [name: "edition_id"] |
| 24 | + parcours_id [name: "parcours_id"] |
| 25 | + } |
| 26 | +} |
| 27 | + |
| 28 | +Table "event" { |
| 29 | + "id" int [pk, not null, increment] |
| 30 | + "creation_date" datetime [not null] |
| 31 | + "name" varchar(40) [not null] |
| 32 | + "createur_id" int [not null] |
| 33 | + "description" text [not null] |
| 34 | + |
| 35 | + Indexes { |
| 36 | + name [unique, name: "name"] |
| 37 | + createur_id [name: "createur_id_user_id"] |
| 38 | + } |
| 39 | +} |
| 40 | + |
| 41 | +Table "inscription" { |
| 42 | + "id" int [pk, not null, increment] |
| 43 | + "creation_date" datetime [not null] |
| 44 | + "user_id" int [not null] |
| 45 | + "event_id" int [not null] |
| 46 | + "edition_id" int [not null] |
| 47 | + "parcours_id" int [not null] |
| 48 | + "dossard" int [default: NULL] |
| 49 | + "present" tinyint(1) [not null] |
| 50 | + "end" varchar(10) [default: NULL] |
| 51 | + |
| 52 | + Indexes { |
| 53 | + event_id [name: "event_id"] |
| 54 | + parcours_id [name: "parcours_id_parcours_id"] |
| 55 | + edition_id [name: "edition_id_edition_id"] |
| 56 | + user_id [name: "user_id_user_id"] |
| 57 | + } |
| 58 | +} |
| 59 | + |
| 60 | +Table "parcours" { |
| 61 | + "id" int [pk, not null, increment] |
| 62 | + "creation_date" datetime [not null] |
| 63 | + "name" varchar(40) [not null] |
| 64 | + "event_id" int [not null] |
| 65 | + "description" text [not null] |
| 66 | + "archived" tinyint(1) [not null] |
| 67 | + "chronos_list" text [not null] |
| 68 | + |
| 69 | + Indexes { |
| 70 | + event_id [name: "event_id_event_id"] |
| 71 | + } |
| 72 | +} |
| 73 | + |
| 74 | +Table "passage" { |
| 75 | + "id" int [pk, not null, increment] |
| 76 | + "time_stamp" datetime [not null] |
| 77 | + "key_id" int [default: NULL] |
| 78 | + "inscription_id" int [not null] |
| 79 | + |
| 80 | + Indexes { |
| 81 | + key_id [name: "key_id_passage_key_id"] |
| 82 | + inscription_id [name: "inscription_id_inscription_id"] |
| 83 | + } |
| 84 | +} |
| 85 | + |
| 86 | +Table "passage_key" { |
| 87 | + "id" int [pk, not null, increment] |
| 88 | + "creation_date" datetime [not null] |
| 89 | + "event_id" int [not null] |
| 90 | + "edition_id" int [not null] |
| 91 | + "key" varchar(20) [not null] |
| 92 | + "name" varchar(40) [not null] |
| 93 | + |
| 94 | + Indexes { |
| 95 | + key [unique, name: "key"] |
| 96 | + event_id [name: "event_id"] |
| 97 | + edition_id [name: "edition_id"] |
| 98 | + } |
| 99 | +} |
| 100 | + |
| 101 | +Table "passagekey_stand" { |
| 102 | + "passage_key_id" int [default: NULL] |
| 103 | + "stand_id" int [default: NULL] |
| 104 | + |
| 105 | + Indexes { |
| 106 | + stand_id [name: "stand_id_stand_id"] |
| 107 | + passage_key_id [name: "passage_key_id_passage_key_id"] |
| 108 | + } |
| 109 | +} |
| 110 | + |
| 111 | +Table "stand" { |
| 112 | + "id" int [pk, not null, increment] |
| 113 | + "name" varchar(40) [not null] |
| 114 | + "lat" float [not null] |
| 115 | + "lng" float [not null] |
| 116 | + "elevation" float [default: NULL] |
| 117 | + "parcours_id" int [default: NULL] |
| 118 | + "start_stand" int [default: NULL] |
| 119 | + "end_stand" int [default: NULL] |
| 120 | + "color" varchar(20) [not null] |
| 121 | + "chrono" tinyint(1) [not null] |
| 122 | + |
| 123 | + Indexes { |
| 124 | + parcours_id [name: "parcours_id"] |
| 125 | + end_stand [name: "end_stand_parcours_id"] |
| 126 | + start_stand [name: "start_stand_parcours_id"] |
| 127 | + } |
| 128 | +} |
| 129 | + |
| 130 | +Table "trace" { |
| 131 | + "id" int [pk, not null, increment] |
| 132 | + "name" varchar(40) [not null] |
| 133 | + "parcours_id" int [default: NULL] |
| 134 | + "start_id" int [not null] |
| 135 | + "end_id" int [not null] |
| 136 | + "trace" text [not null] |
| 137 | + "turn_nb" int [not null] |
| 138 | + |
| 139 | + Indexes { |
| 140 | + parcours_id [name: "parcours_id"] |
| 141 | + end_id [name: "end_id_stand_id"] |
| 142 | + start_id [name: "start_id_stand_id"] |
| 143 | + } |
| 144 | +} |
| 145 | + |
| 146 | +Table "user" { |
| 147 | + "id" int [pk, not null, increment] |
| 148 | + "creation_date" datetime [not null] |
| 149 | + "avatar" varchar(80) [not null] |
| 150 | + "name" varchar(40) [not null] |
| 151 | + "lastname" varchar(20) [not null] |
| 152 | + "password" varchar(80) [not null] |
| 153 | + "username" varchar(20) [not null] |
| 154 | + "email" varchar(80) [default: NULL] |
| 155 | + "phone" varchar(15) [default: NULL] |
| 156 | + "datenaiss" datetime [not null] |
| 157 | + "admin" tinyint(1) [not null] |
| 158 | + |
| 159 | + Indexes { |
| 160 | + username [unique, name: "username"] |
| 161 | + } |
| 162 | +} |
| 163 | + |
| 164 | +Ref "edition_ibfk_1":"event"."id" < "edition"."event_id" |
| 165 | + |
| 166 | +Ref "editions_parcours_ibfk_1":"edition"."id" < "editions_parcours"."edition_id" |
| 167 | + |
| 168 | +Ref "editions_parcours_ibfk_2":"parcours"."id" < "editions_parcours"."parcours_id" |
| 169 | + |
| 170 | +Ref "event_ibfk_1":"user"."id" < "event"."createur_id" |
| 171 | + |
| 172 | +Ref "inscription_ibfk_1":"user"."id" < "inscription"."user_id" |
| 173 | + |
| 174 | +Ref "inscription_ibfk_2":"event"."id" < "inscription"."event_id" |
| 175 | + |
| 176 | +Ref "inscription_ibfk_3":"edition"."id" < "inscription"."edition_id" |
| 177 | + |
| 178 | +Ref "inscription_ibfk_4":"parcours"."id" < "inscription"."parcours_id" |
| 179 | + |
| 180 | +Ref "parcours_ibfk_1":"event"."id" < "parcours"."event_id" |
| 181 | + |
| 182 | +Ref "passage_ibfk_1":"passage_key"."id" < "passage"."key_id" |
| 183 | + |
| 184 | +Ref "passage_ibfk_2":"inscription"."id" < "passage"."inscription_id" |
| 185 | + |
| 186 | +Ref "passage_key_ibfk_1":"event"."id" < "passage_key"."event_id" |
| 187 | + |
| 188 | +Ref "passage_key_ibfk_2":"edition"."id" < "passage_key"."edition_id" |
| 189 | + |
| 190 | +Ref "passagekey_stand_ibfk_1":"passage_key"."id" < "passagekey_stand"."passage_key_id" |
| 191 | + |
| 192 | +Ref "passagekey_stand_ibfk_2":"stand"."id" < "passagekey_stand"."stand_id" |
| 193 | + |
| 194 | +Ref "stand_ibfk_1":"parcours"."id" < "stand"."parcours_id" |
| 195 | + |
| 196 | +Ref "stand_ibfk_2":"parcours"."id" < "stand"."start_stand" |
| 197 | + |
| 198 | +Ref "stand_ibfk_3":"parcours"."id" < "stand"."end_stand" |
| 199 | + |
| 200 | +Ref "trace_ibfk_1":"parcours"."id" < "trace"."parcours_id" |
| 201 | + |
| 202 | +Ref "trace_ibfk_2":"stand"."id" < "trace"."start_id" |
| 203 | + |
| 204 | +Ref "trace_ibfk_3":"stand"."id" < "trace"."end_id" |
0 commit comments