Initial commit
This commit is contained in:
23
app/Models/EdiBand.php
Normal file
23
app/Models/EdiBand.php
Normal file
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Relations\BelongsToMany;
|
||||
|
||||
class EdiBand extends Model
|
||||
{
|
||||
protected $table = 'edi_bands';
|
||||
|
||||
use HasFactory;
|
||||
|
||||
protected $fillable = [
|
||||
'value'
|
||||
];
|
||||
|
||||
public function bands(): BelongsToMany
|
||||
{
|
||||
return $this->belongsToMany(Band::class, 'bands_edi_bands', 'edi_band_id', 'band_id');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user