Installer updates

Added probe.php
Added new installer views and controllers
Updated AuthController
Updated Middlewares
Updated Commands for installation process
This commit is contained in:
Manish Verma
2018-08-07 13:45:46 +05:30
parent 1ac0f42a58
commit 22d3bb4036
28 changed files with 1197 additions and 405 deletions

View File

@@ -0,0 +1,32 @@
<?php
namespace App\Http\Middleware;
use Closure;
class IsInstalled
{
/**
* Handle an incoming request.
*
* @param \Illuminate\Http\Request $request
* @param \Closure $next
*
* @return mixed
*/
public function handle($request, Closure $next)
{
if (!isInstall()) {
return $next($request);
} else {
if ($request->isJson()) {
$url = url('/');
$result = ['fails' => 'already installed', 'api' => $url];
return response()->json(compact('result'));
} else {
return redirect('/');
}
}
}
}