<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class UserBrands extends Model
{
    protected $table = 'users_brands';
    
    protected $fillable = [
        'id',
        'user_id',
        'brand',
    ];
    public function detail()
    {
        return $this->hasOne('App\Models\BrandDb','Code','brand');
    }
    public function user()
    {
        
        return $this->belongsTo('App\User');
    }
}