CourseClass
Implements the concept of school classes. It has many students associated through enrollments and it belongs to one Course, which can have many classes.
A Course can only have one CourseClass with the flag main set to true.
One of the reasons for this is the students when registering on the course being directed to a class automatically.
Propriedades do Objeto
| Nome | Tipo | Descrição |
|---|---|---|
| course | Course | Course that this class belongs to - Required |
| start_at | Datetime | Date when the class will start - Required |
| code | String | Custom code to use as identifier - Allow nil, but should be unique if set |
| end_at | Datetime | Date when the class will close |
| main | Boolean | Flag that defines the Course's main class |
| enrollments | Array<Enrollment> | Enrollments registered in this class |
| created_at | Datetime | Timestamp of when it was created |
| updated_at | Datetime | Timestamp of the last time it was modified |
Examples
{
"id": 8,
"start_at": "2014-09-08 14:21:38 UTC",
"end_at": "2014-09-08 14:21:38 UTC",
"code": "abc123",
"main": true,
"course": {
"id": 3,
"name": "Rails for Zombies"
}
}