Refactor laravel architecture.

Move App folder to infrastructure folder.

1. moved laravel app folder content to /src/Common/Infrastructure/Laravel

2. moved Console/Kernel.php to /src/Common/Infrastructure/Laravel/Kernel/Console.php

3. moved Http/Kernel.php to /src/Common/Infrastructure/Laravel/Kernel/Http.php

4. moved Http/Controllers/Controller.php to /src/Common/Infrastructure/Laravel/Controller.php

5. fix file paths in boorstrap/app.php

6. fix file paths for application service providers in config/app.php

7. fix file paths for middleware in config/sanctum.php

8. change app to src in composer.json
This commit is contained in:
omair saleh
2022-09-24 20:53:57 +08:00
parent b6c87fd42b
commit e19d535edf
-44
View File
@@ -1,44 +0,0 @@
<?php
namespace App\Models;
// use Illuminate\Contracts\Auth\MustVerifyEmail;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Foundation\Auth\User as Authenticatable;
use Illuminate\Notifications\Notifiable;
use Laravel\Sanctum\HasApiTokens;
class User extends Authenticatable
{
use HasApiTokens, HasFactory, Notifiable;
/**
* The attributes that are mass assignable.
*
* @var array<int, string>
*/
protected $fillable = [
'name',
'email',
'password',
];
/**
* The attributes that should be hidden for serialization.
*
* @var array<int, string>
*/
protected $hidden = [
'password',
'remember_token',
];
/**
* The attributes that should be cast.
*
* @var array<string, string>
*/
protected $casts = [
'email_verified_at' => 'datetime',
];
}