author | Sylvain Thénault <sylvain.thenault@logilab.fr> |
Tue, 16 Feb 2010 09:23:35 +0100 | |
changeset 4591 | 47acae3cb778 |
parent 4467 | 0e73d299730a |
child 5421 | 8167de96c523 |
permissions | -rw-r--r-- |
1977
606923dff11b
big bunch of copyright / docstring update
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
0
diff
changeset
|
1 |
""" |
606923dff11b
big bunch of copyright / docstring update
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
0
diff
changeset
|
2 |
|
606923dff11b
big bunch of copyright / docstring update
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
0
diff
changeset
|
3 |
:organization: Logilab |
4212
ab6573088b4a
update copyright: welcome 2010
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
2508
diff
changeset
|
4 |
:copyright: 2001-2010 LOGILAB S.A. (Paris, FRANCE), license is LGPL v2. |
1977
606923dff11b
big bunch of copyright / docstring update
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
0
diff
changeset
|
5 |
:contact: http://www.logilab.fr/ -- mailto:contact@logilab.fr |
606923dff11b
big bunch of copyright / docstring update
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
0
diff
changeset
|
6 |
:license: GNU Lesser General Public License, v2.1 - http://www.gnu.org/licenses |
606923dff11b
big bunch of copyright / docstring update
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
0
diff
changeset
|
7 |
""" |
2508
b1958ebed570
rewrite .sql / .rel files, drop unnecessary entity types, explicit imports
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
1977
diff
changeset
|
8 |
from yams.buildobjs import EntityType, SubjectRelation, String, Int, Date |
b1958ebed570
rewrite .sql / .rel files, drop unnecessary entity types, explicit imports
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
1977
diff
changeset
|
9 |
|
b1958ebed570
rewrite .sql / .rel files, drop unnecessary entity types, explicit imports
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
1977
diff
changeset
|
10 |
from cubes.person.schema import Person |
b1958ebed570
rewrite .sql / .rel files, drop unnecessary entity types, explicit imports
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
1977
diff
changeset
|
11 |
|
0 | 12 |
Person.add_relation(Date(), 'birthday') |
2508
b1958ebed570
rewrite .sql / .rel files, drop unnecessary entity types, explicit imports
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
1977
diff
changeset
|
13 |
|
b1958ebed570
rewrite .sql / .rel files, drop unnecessary entity types, explicit imports
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
1977
diff
changeset
|
14 |
class Bug(EntityType): |
b1958ebed570
rewrite .sql / .rel files, drop unnecessary entity types, explicit imports
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
1977
diff
changeset
|
15 |
title = String(maxsize=64, required=True, fulltextindexed=True) |
b1958ebed570
rewrite .sql / .rel files, drop unnecessary entity types, explicit imports
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
1977
diff
changeset
|
16 |
severity = String(vocabulary=('important', 'normal', 'minor'), default='normal') |
b1958ebed570
rewrite .sql / .rel files, drop unnecessary entity types, explicit imports
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
1977
diff
changeset
|
17 |
cost = Int() |
b1958ebed570
rewrite .sql / .rel files, drop unnecessary entity types, explicit imports
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
1977
diff
changeset
|
18 |
description = String(maxsize=4096, fulltextindexed=True) |
4467
0e73d299730a
fix long-waiting symetric typo: should be spelled symmetric. Add auto database migration on schema deserialization
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
4212
diff
changeset
|
19 |
identical_to = SubjectRelation('Bug', symmetric=True) |
2508
b1958ebed570
rewrite .sql / .rel files, drop unnecessary entity types, explicit imports
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
1977
diff
changeset
|
20 |