43 lines
905 B
PHP
43 lines
905 B
PHP
<?php namespace GermanAirlinesVa\Social\Models;
|
|
|
|
use Model;
|
|
|
|
/**
|
|
* Model
|
|
*/
|
|
class Member extends Model
|
|
{
|
|
use \October\Rain\Database\Traits\Validation;
|
|
|
|
/*
|
|
* Disable timestamps by default.
|
|
* Remove this line if timestamps are defined in the database table.
|
|
*/
|
|
public $timestamps = false;
|
|
|
|
/**
|
|
* @var string The database table used by the model.
|
|
*/
|
|
public $table = 'members';
|
|
public $connection = 'germanairlinesva_social';
|
|
|
|
/**
|
|
* @var array Validation rules
|
|
*/
|
|
public $rules = [];
|
|
|
|
public $belongsTo = [
|
|
'member_rank' => 'GermanAirlinesVa\Schooling\Models\MemberRank',
|
|
];
|
|
|
|
public $hasMany = [
|
|
'exam_member_ranks' => 'GermanAirlinesVa\Schooling\Models\ExamMemberRank',
|
|
'exam_typeratings' => 'GermanAirlinesVa\Schooling\Models\ExamTyperating',
|
|
];
|
|
|
|
public function logIn($password)
|
|
{
|
|
return password_verify($password, $this->password);
|
|
}
|
|
}
|