<?php

namespace Modules\DailyLog\Models;

use Illuminate\Database\Eloquent\Relations\BelongsTo;
use Illuminate\Database\Eloquent\Relations\HasMany;
use Modules\Banner\Models\Banner;
use Modules\Category\Models\CategoryDescription;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\HasOne;
use Illuminate\Database\Eloquent\SoftDeletes;
use Modules\ContactList\Models\ContactList;
use Modules\Product\Models\Product;
use Modules\Type\Models\Type;
use Modules\User\Models\User;

class DailyLog extends Model
{
    //use soft delete
    use SoftDeletes;

    protected $fillable = [
        'type'	,'objective','objective_other',	'next_action',	'estimated_sale',	'date'	,'next_contact'	,'employee_id',	'contact_list_id','lock'
    ];

    /**
     * Get current description of the the Room
     * @return BelongsTo
     */
    public function employee() :BelongsTo
    {
        return $this->belongsTo(User::class,'employee_id')->withTrashed();
    }
    public function contactList() :BelongsTo
    {
        return $this->belongsTo(ContactList::class,'contact_list_id')->withTrashed();
    }
}
