blue-twilight/app/Storage.php

48 lines
875 B
PHP
Raw Permalink Normal View History

<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Notifications\Notifiable;
class Storage extends Model
{
use Notifiable;
/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = [
'name',
'source',
'is_default',
'location',
'is_internal',
'is_active',
'auth_url',
'tenant_name',
'username',
'password',
'service_name',
'service_region',
'container_name',
'cdn_url',
'access_key',
'secret_key',
'b2_bucket_type',
'external_service_id'
];
public function albums()
{
return $this->hasMany(Album::class);
}
public function externalService()
{
return $this->belongsTo(ExternalService::class);
}
}