-
Notifications
You must be signed in to change notification settings - Fork 0
/
schema.xml
64 lines (64 loc) · 3.47 KB
/
schema.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
<?xml version="1.0" encoding="utf-8"?>
<!--Autogenerated by PropelSchemaReverseTask class.-->
<database name="librairie" defaultIdMethod="native">
<table name="client" phpName="Client" idMethod="native">
<column name="id" phpName="Id" type="INTEGER" primaryKey="true" autoIncrement="true" required="true"/>
<column name="nom" phpName="Nom" type="VARCHAR" size="255" required="true"/>
<column name="prenom" phpName="Prenom" type="VARCHAR" size="255" required="true"/>
<column name="adresse" phpName="Adresse" type="VARCHAR" size="1024" required="false"/>
<column name="tel" phpName="Tel" type="DECIMAL" size="10" scale="0" required="false"/>
<column name="codePostal" phpName="Codepostal" type="VARCHAR" size="5" required="false"/>
<column name="sexe" phpName="Sexe" type="VARCHAR" size="1" required="false"/>
<column name="login" phpName="Login" type="VARCHAR" size="25" required="true"/>
<column name="email" phpName="Email" type="VARCHAR" size="1024" required="false"/>
<column name="pass" phpName="Pass" type="VARCHAR" size="25" required="true"/>
<vendor type="mysql">
<parameter name="Engine" value="InnoDB"/>
</vendor>
</table>
<table name="commande" phpName="Commande" idMethod="native">
<column name="id" phpName="Id" type="INTEGER" primaryKey="true" autoIncrement="true" required="true"/>
<column name="client_id" phpName="ClientId" type="INTEGER" required="true"/>
<column name="payer" phpName="Payer" type="BOOLEAN" size="1" required="true"/>
<foreign-key foreignTable="client" name="commande_FK_1" onDelete="CASCADE" onUpdate="RESTRICT">
<reference local="client_id" foreign="id"/>
</foreign-key>
<index name="commande_FI_1">
<index-column name="client_id"/>
</index>
<vendor type="mysql">
<parameter name="Engine" value="InnoDB"/>
</vendor>
</table>
<table name="lignecommande" phpName="Lignecommande" idMethod="native">
<column name="id" phpName="Id" type="INTEGER" primaryKey="true" autoIncrement="true" required="true"/>
<column name="livre_id" phpName="LivreId" type="INTEGER" required="true"/>
<column name="commande_id" phpName="CommandeId" type="INTEGER" required="false"/>
<foreign-key foreignTable="livre" name="lignecommande_FK_1" onDelete="CASCADE" onUpdate="RESTRICT">
<reference local="livre_id" foreign="id"/>
</foreign-key>
<foreign-key foreignTable="commande" name="lignecommande_FK_2" onDelete="CASCADE" onUpdate="RESTRICT">
<reference local="commande_id" foreign="id"/>
</foreign-key>
<index name="lignecommande_FI_1">
<index-column name="livre_id"/>
</index>
<index name="lignecommande_FI_2">
<index-column name="commande_id"/>
</index>
<vendor type="mysql">
<parameter name="Engine" value="InnoDB"/>
</vendor>
</table>
<table name="livre" phpName="Livre" idMethod="native">
<column name="id" phpName="Id" type="INTEGER" primaryKey="true" autoIncrement="true" required="true"/>
<column name="titre" phpName="Titre" type="VARCHAR" size="255" required="true"/>
<column name="isbn" phpName="Isbn" type="VARCHAR" size="24" required="true"/>
<column name="prix" phpName="Prix" type="FLOAT" required="false"/>
<column name="description" phpName="Description" type="VARCHAR" size="2048" required="false"/>
<column name="photo" phpName="Photo" type="VARCHAR" size="2048" required="false"/>
<vendor type="mysql">
<parameter name="Engine" value="InnoDB"/>
</vendor>
</table>
</database>