mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange-2.0.git
synced 2026-08-19 20:43:56 +00:00
50 lines
883 B
PHP
50 lines
883 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class WorkflowTimestamp extends Model
|
|
{
|
|
use HasFactory;
|
|
|
|
/**
|
|
* The table associated with the model.
|
|
*
|
|
* @var string
|
|
*/
|
|
protected $table = 'workflow_timestamps';
|
|
|
|
/**
|
|
* The attributes that are mass assignable.
|
|
*
|
|
* @var array
|
|
*/
|
|
protected $fillable = [
|
|
'current_node',
|
|
'next_node',
|
|
'node',
|
|
'seconds',
|
|
'userId',
|
|
'session_id'
|
|
];
|
|
|
|
/**
|
|
* The attributes that should be cast.
|
|
*
|
|
* @var array
|
|
*/
|
|
protected $casts = [
|
|
'timestamp' => 'datetime',
|
|
];
|
|
|
|
/**
|
|
* Get the user that owns the workflow timestamp.
|
|
*/
|
|
public function user()
|
|
{
|
|
return $this->belongsTo(User::class, 'userId');
|
|
}
|
|
}
|