source: trunk/grails-app/domain/Task.groovy @ 241

Last change on this file since 241 was 241, checked in by gav, 14 years ago

Undo the AssignedGroup implementation by reverse merge r240:r239.

File size: 1.3 KB
Line 
1class Task {
2
3    TaskGroup taskGroup
4    TaskStatus taskStatus
5    TaskPriority taskPriority
6    TaskType taskType
7    Task parentTask
8    Person leadPerson
9    Asset primaryAsset
10    TaskRecurringSchedule taskRecurringSchedule
11    TaskProcedure taskProcedure
12
13    String description
14    String comment = ""
15    Date targetStartDate = new Date()
16    Date targetCompletionDate = new Date()
17    boolean scheduled = false
18    boolean approved = false
19    boolean trash = false
20
21    static hasMany = [entries: Entry, 
22                        taskModifications: TaskModification,
23                        assignedPersons: AssignedPerson,
24                        subTasks: Task,
25                        associatedAssets: Asset,
26                        inventoryMovements: InventoryMovement]
27
28    static mappedBy = [taskRecurringSchedule:"task"]
29
30    static belongsTo = [TaskGroup, TaskStatus, Task, Person]
31
32    static constraints = {
33        description(blank:false,maxSize:75)
34        comment()
35        targetStartDate()
36        targetCompletionDate()
37        leadPerson()
38        taskPriority()
39        taskStatus()
40        parentTask(nullable:true)
41        primaryAsset(nullable:true)
42        taskRecurringSchedule(nullable:true)
43        taskProcedure(nullable:true)
44
45    }
46
47    String toString() {"${this.id} - ${this.description}"}
48}
Note: See TracBrowser for help on using the repository browser.