fedi-feed-router/app/Models/Keyword.php
myrmidex 6784af2ff6
Some checks failed
CI / ci (push) Failing after 4m31s
25 - Fix all PHPStan errors and add mockery extension
2026-03-08 14:18:28 +01:00

53 lines
1.1 KiB
PHP

<?php
namespace App\Models;
use Database\Factories\KeywordFactory;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
use Illuminate\Support\Carbon;
/**
* @property int $id
* @property int $feed_id
* @property Feed $feed
* @property int $platform_channel_id
* @property PlatformChannel $platformChannel
* @property string $keyword
* @property bool $is_active
* @property Carbon $created_at
* @property Carbon $updated_at
*/
class Keyword extends Model
{
/** @use HasFactory<KeywordFactory> */
use HasFactory;
protected $fillable = [
'feed_id',
'platform_channel_id',
'keyword',
'is_active',
];
protected $casts = [
'is_active' => 'boolean',
];
/**
* @return BelongsTo<Feed, $this>
*/
public function feed(): BelongsTo
{
return $this->belongsTo(Feed::class);
}
/**
* @return BelongsTo<PlatformChannel, $this>
*/
public function platformChannel(): BelongsTo
{
return $this->belongsTo(PlatformChannel::class);
}
}