Last change
on this file since 328 was
268,
checked in by gav, 15 years ago
|
Refactor classes for asset tree refinement.
Regenerate views and controllers to suite.
|
File size:
498 bytes
|
Rev | Line | |
---|
[162] | 1 | class Department { |
---|
| 2 | |
---|
| 3 | String name |
---|
| 4 | String description = "" |
---|
| 5 | boolean isActive = true |
---|
| 6 | |
---|
[268] | 7 | static hasMany = [sections: Section, |
---|
| 8 | departmentExtendedAttributes: DepartmentExtendedAttribute, |
---|
| 9 | persons: Person] |
---|
[162] | 10 | |
---|
| 11 | // static belongsTo = [] |
---|
| 12 | |
---|
[164] | 13 | static constraints = { |
---|
[268] | 14 | name(maxSize:50, unique:true, blank:false) |
---|
| 15 | description(maxSize:100) |
---|
[164] | 16 | isActive() |
---|
| 17 | } |
---|
[162] | 18 | |
---|
| 19 | String toString() { |
---|
| 20 | "${this.name}" |
---|
| 21 | } |
---|
| 22 | } |
---|
| 23 | |
---|
Note: See
TracBrowser
for help on using the repository browser.