31 lines
636 B
PHP
31 lines
636 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class OldSlug extends Model
|
|
{
|
|
use HasFactory;
|
|
|
|
/**
|
|
* BelongsTo product relation
|
|
*
|
|
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
|
|
*/
|
|
public function product()
|
|
{
|
|
return $this->belongsTo('App\Model\Product', 'product_id');
|
|
}
|
|
|
|
/**
|
|
* BelongsTo range relation
|
|
*
|
|
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
|
|
*/
|
|
public function range()
|
|
{
|
|
return $this->belongsTo('App\Model\Range', 'range_id');
|
|
}
|
|
}
|