<?php

namespace App;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Foundation\Auth\User as Authenticatable;
use Illuminate\Database\Eloquent\SoftDeletes;

class Member extends Authenticatable
{
    use SoftDeletes;
    protected $dates = ['deleted_at'];
    /**
     * The attributes that are mass assignable.
     *
     * @var array
    */
    protected $fillable = array('username','email','password', 'city','phone','gender','full_name','job','project_id','img');
    /**
     * The attributes that should be hidden for arrays.
     *
     * @var array
     */
    protected $hidden = [
        'password', 'remember_token',
    ];
    /**
     * Get the questions of this answer
     * @return BelongsTo
     */
    public function idea()
    {
        return $this->belongsTo('App\Idea','idea_id')->withTrashed();
    }
    public function field()
    {
        return $this->belongsTo('App\Field','field_id')->withTrashed();
    }

}	