2020-11-17 13:41:31 +01:00
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
namespace App\Models;
|
|
|
|
|
|
|
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
|
|
|
|
|
|
class OrdersStatus extends Model
|
|
|
|
|
{
|
|
|
|
|
use HasFactory;
|
|
|
|
|
|
2022-09-03 16:56:16 +02:00
|
|
|
/**
|
|
|
|
|
* The table associated with the model
|
|
|
|
|
*
|
|
|
|
|
* @var string
|
|
|
|
|
*/
|
2020-11-17 13:41:31 +01:00
|
|
|
protected $table = "orders_status";
|
2022-08-25 12:26:43 +02:00
|
|
|
|
2022-09-03 16:56:16 +02:00
|
|
|
/**
|
|
|
|
|
* Indicates if the model should be timestamped.
|
|
|
|
|
*
|
|
|
|
|
* @var boolean
|
|
|
|
|
*/
|
2020-11-17 13:41:31 +01:00
|
|
|
public $timestamps = false;
|
|
|
|
|
|
2022-09-03 16:56:16 +02:00
|
|
|
/**
|
|
|
|
|
* hasMany orders relation
|
|
|
|
|
*
|
|
|
|
|
* @return \Illuminate\Database\Eloquent\Relations\HasMany
|
|
|
|
|
*/
|
2022-08-25 12:26:43 +02:00
|
|
|
public function orders()
|
|
|
|
|
{
|
2021-03-17 09:28:02 +01:00
|
|
|
return $this->hasMany('App\Models\Order', 'status_id');
|
2020-11-17 13:41:31 +01:00
|
|
|
}
|
|
|
|
|
}
|