30 lines
509 B
PHP
30 lines
509 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class MigrationSource extends Model
|
|
{
|
|
use HasFactory;
|
|
|
|
protected $fillable = [
|
|
'name',
|
|
'type',
|
|
'path',
|
|
'enabled',
|
|
'meta'
|
|
];
|
|
|
|
protected $casts = [
|
|
'enabled' => 'boolean',
|
|
'meta' => 'array',
|
|
];
|
|
|
|
public function datasets()
|
|
{
|
|
return $this->hasMany(MigrationDataset::class, 'source_id');
|
|
}
|
|
}
|