The trait Backpack\CRUD\app\Models\Traits\CrudTrait requires some properties which are not provided by App\Models\Skills\Skill: $fakeColumns, $identifiableAttribute, $Type
Loading history...
13
protected $guarded = ['id'];
14
protected $with = ['level', 'skill_type'];
15
16
/** The category the skill belongs to */
17
public function skill_type()
18
{
19
return $this->belongsTo(SkillType::class);
20
}
21
22
/** A skill belongs to a level, this allows to filter available skills when attaching them to courses */
23
public function level()
24
{
25
return $this->belongsTo(Level::class);
26
}
27
28
/** a skill has many courses, and a course has many skills
29
* Skills are like "criteria" that will need to be evaluated during the course
30
*/
31
public function courses()
32
{
33
return $this->belongsToMany(Course::class);
34
}
35
36
/** A skill is linked to skill evaluations (themselves linked to enrollments) */