<?php

namespace Modules\Cms\Models;

use App\Models\Model;
use App\Traits\HasCovers;

class Storage extends Model
{

    use HasCovers;

    protected $table = 'cms_storages';

    public function getCoverTextAttribute()
    {
        if ($this->url) {
            return $this->url . '/' . $this->cover;
        } else {
            return $this->cover_url;
        }
    }

}
