for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace DavideCasiraghi\LaravelEventsCalendar\Models;
use Astrotomic\Translatable\Translatable;
use Illuminate\Database\Eloquent\Model;
class EventCategory extends Model
{
/***************************************************************************/
/**
* The table associated with the model.
*
* @var string
*/
protected $table = 'event_categories';
use Translatable;
Astrotomic\Translatable\Translatable
$each
DavideCasiraghi\LaravelE...ar\Models\EventCategory
public $translatedAttributes = ['name', 'slug'];
protected $fillable = [];
public $useTranslationFallback = true;
/*
* Return the category name.
* @param int $categoryId
* @return string
public static function getCategoryName($categoryId): string
$ret = self::find($categoryId)->name;
name
Checks if undeclared accessed properties appear in database migrations and if the creating migration is correct.
return $ret;
}