<?php
namespace App\Models;

class Article extends Model {
    protected static function getTable(): string {
        return 'articles';
    }

    public function getCategory() {
        return Category::findBy(['slug' => $this->category_slug]);
    }

    public function getBrand() {
        return Brand::findBy(['slug' => $this->brand_slug]);
    }
}
