2023-09-14 20:16:27 +00:00
|
|
|
<?php namespace Romanah\Gokbakja\Models;
|
|
|
|
|
|
|
|
|
|
use Model;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Model
|
|
|
|
|
*/
|
|
|
|
|
class Production extends Model
|
|
|
|
|
{
|
|
|
|
|
use \October\Rain\Database\Traits\Validation;
|
2023-09-16 06:18:02 +00:00
|
|
|
|
2023-09-14 20:16:27 +00:00
|
|
|
use \October\Rain\Database\Traits\SoftDelete;
|
|
|
|
|
|
|
|
|
|
protected $dates = ['deleted_at'];
|
|
|
|
|
|
2023-09-16 13:00:30 +00:00
|
|
|
// public $belongsToMany = [
|
|
|
|
|
// 'pivot_production' => [
|
|
|
|
|
// 'Romanah\Gokbakja\Models\PivotProduction',
|
|
|
|
|
// 'table' => 'romanah_gokbakja_pivot_production',
|
|
|
|
|
// 'key' => 'production_id'
|
|
|
|
|
// // 'order' => 'name'
|
|
|
|
|
// ]
|
|
|
|
|
// ];
|
|
|
|
|
|
|
|
|
|
public $hasMany = [
|
2023-09-16 06:18:02 +00:00
|
|
|
'pivot_production' => [
|
|
|
|
|
'Romanah\Gokbakja\Models\PivotProduction',
|
2023-09-16 13:00:30 +00:00
|
|
|
'key' => 'production_id'
|
2023-09-16 06:18:02 +00:00
|
|
|
]
|
|
|
|
|
];
|
2023-09-14 20:16:27 +00:00
|
|
|
/**
|
|
|
|
|
* @var string The database table used by the model.
|
|
|
|
|
*/
|
|
|
|
|
public $table = 'romanah_gokbakja_production';
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @var array Validation rules
|
|
|
|
|
*/
|
|
|
|
|
public $rules = [
|
|
|
|
|
];
|
|
|
|
|
}
|