Line | |
---|
1 | package dbnp.studycapturing |
---|
2 | |
---|
3 | /** |
---|
4 | * Domain class describing the basic entity in the study capture part: the Study class. |
---|
5 | * |
---|
6 | * Revision information: |
---|
7 | * $Rev$ |
---|
8 | * $Author$ |
---|
9 | * $Date$ |
---|
10 | */ |
---|
11 | class Study { |
---|
12 | nimble.User owner |
---|
13 | String title |
---|
14 | String code |
---|
15 | String researchQuestion |
---|
16 | String description |
---|
17 | String ecCode |
---|
18 | Date dateCreated |
---|
19 | Date lastUpdated |
---|
20 | Date startDate |
---|
21 | Template template |
---|
22 | |
---|
23 | static hasMany = [ editors: nimble.User, |
---|
24 | readers: nimble.User, |
---|
25 | subjects: Subject, |
---|
26 | groups: SubjectGroup, |
---|
27 | events: Event, |
---|
28 | samplingEvents: SamplingEvent |
---|
29 | ] |
---|
30 | |
---|
31 | static constraints = { |
---|
32 | owner(nullable: true, blank: true) |
---|
33 | title(nullable: false, blank: false) |
---|
34 | template(nullable: true, blank: true) |
---|
35 | } |
---|
36 | |
---|
37 | static mapping = { |
---|
38 | researchQuestion type: 'text' |
---|
39 | description type: 'text' |
---|
40 | autoTimestamp true |
---|
41 | } |
---|
42 | |
---|
43 | def String toString() { |
---|
44 | return title; |
---|
45 | } |
---|
46 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.