class AssignedPerson {

    Person person
    Task task
    Integer estimatedHour = 0
    Integer estimatedMinute = 0

    static constraints = {
        task()
        person()
        estimatedHour(min:0)
        estimatedMinute(min:0,max:59)
    }

    String toString() {
        "${person.firstName} ${person.lastName} - ${estimatedHour}h : ${estimatedMinute}min"
    }
}
