first commit

This commit is contained in:
riccardo
2021-09-05 17:20:59 +02:00
commit 9b4e2b9963
53 changed files with 9015 additions and 0 deletions

38
app/Models/User.php Normal file
View File

@@ -0,0 +1,38 @@
<?php
namespace App\Models;
use Illuminate\Auth\Authenticatable;
use Illuminate\Contracts\Auth\Access\Authorizable as AuthorizableContract;
use Illuminate\Contracts\Auth\Authenticatable as AuthenticatableContract;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Laravel\Lumen\Auth\Authorizable;
class User extends Model implements AuthenticatableContract, AuthorizableContract
{
use Authenticatable, Authorizable, HasFactory;
/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = [
'id', 'profile',
];
/**
* The attributes excluded from the model's JSON form.
*
* @var array
*/
protected $hidden = [
//
];
public function coupons()
{
return $this->hasMany(Coupon::class, 'user_id');
}
}