<?php

namespace App\Model;

use Illuminate\Database\Eloquent\Model;

class Suplier extends Model
{
    protected $fillable = ['name', 'company_name', 'tax_id', 'bank_id', 'branch', 'phone', 'mobile', 'email', 'address', 'description', 'map'];
    protected $casts = [
        'map' => 'array',
    ];
    public function setNameAttribute($value)
    {
        $this->attributes['name'] = $value;
        $this->attributes['slug'] = str_slug($value);
    }
}

{'avg_line_length': 24.157894736842106, 'max_line_length': 143, 'alphanum_fraction': 0.6056644880174292, 'licenses': ['MIT'], 'repository_name': 'nhathuycn13/meme.dev', 'path': 'app/Model/Suplier.php', 'size': 459, 'lang': 'PHP'}