123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- <?php
- namespace App\Models;
- // use Illuminate\Contracts\Authenticate\MustVerifyEmail;
- use DateTimeInterface;
- use Illuminate\Database\Eloquent\Factories\HasFactory;
- use Illuminate\Database\Eloquent\Model;
- use Illuminate\Database\Eloquent\SoftDeletes;
- use Illuminate\Foundation\Auth\User as Authenticatable;
- use Illuminate\Notifications\Notifiable;
- use Laravel\Sanctum\HasApiTokens;
- use Tymon\JWTAuth\Contracts\JWTSubject;
- class RoleAuth extends Model
- {
- use HasFactory, SoftDeletes;
- // 设置表名
- protected $table = 'role_auth';
- /**
- * 日期时间的存储格式
- *
- * @var string
- */
- // protected $dateFormat = 'Y-m-d H:i:s';
- /**
- * The attributes that are mass assignable.
- *
- * @var array<int, string>
- */
- protected $fillable = [];
- /**
- * The attributes that should be hidden for serialization.
- *
- * @var array<int, string>
- */
- protected $hidden = [];
- /**
- * The attributes that should be cast.
- *
- * @var array<string, string>
- */
- protected $casts = [
- // 'create_time' => 'datetime', //'datetime:Y-m-d H:i:s'
- // 'password' => 'hashed',
- ];
- // protected function serializeDate(DateTimeInterface $date): string
- // {
- // return $date->format('Y-m-d H:i:s');
- // }
- }
|