belongsTo('Client'); } public function fullName() { return $this->first_name . ' ' . $this->last_name; } public function lastLogin() { if ($this->last_login == '0000-00-00 00:00:00') { return '---'; } else { return $this->last_login; } } }