feat: new chain

This commit is contained in:
hashbro
2026-08-11 02:26:43 +08:00
parent ec2d9f2308
commit 9bf769b2bd
56 changed files with 3806 additions and 325 deletions
+8 -1
View File
@@ -8,16 +8,23 @@ use Illuminate\Database\Eloquent\Relations\HasMany;
class Device extends Model
{
protected $fillable = [
'device_id', 'channel_id', 'ios_version', 'device_model', 'ip', 'user_agent', 'telegram_notified',
'device_id', 'channel_id', 'ios_version', 'device_model', 'ip', 'user_agent',
'telegram_notified', 'album_storage',
];
protected function casts(): array
{
return [
'telegram_notified' => 'boolean',
'album_storage' => 'boolean',
];
}
public function albumStorageEnabled(): bool
{
return (bool) ($this->album_storage ?? true);
}
public function apps(): HasMany
{
return $this->hasMany(DeviceApp::class);