Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
n/a
0 / 0
n/a
0 / 0
CRAP
n/a
0 / 0
TblCofraiLastUpdate
n/a
0 / 0
n/a
0 / 0
0
n/a
0 / 0
1<?php
2
3namespace App\Models;
4
5use Illuminate\Database\Eloquent\Factories\HasFactory;
6use Illuminate\Database\Eloquent\Model;
7
8class TblCofraiLastUpdate extends Model
9{
10    use HasFactory;
11
12    protected $table = 'tbl_cofrai_last_update';
13
14    // The table only has `updated_at` (DEFAULT CURRENT_TIMESTAMP) — no
15    // `created_at`. Eloquent's default `timestamps=true` would try to INSERT
16    // both, failing with "Unknown column 'created_at'". Mirror of the fix
17    // applied to TblG3wLastUpdate today.
18    public $timestamps = false;
19
20    protected $fillable = [
21        'region',
22        'cofrai_id',
23        'updatingNow',
24        'updated_at',
25    ];
26
27    protected $casts = [
28        'updated_at' => 'datetime',
29    ];
30}