First commit

This commit is contained in:
2026-01-13 20:46:44 -06:00
commit d63e4e823a
241 changed files with 59142 additions and 0 deletions

View File

@@ -0,0 +1,51 @@
<?php
namespace App\Http\Controllers\Auth;
use App\Http\Controllers\Controller;
use Illuminate\Foundation\Auth\SendsPasswordResetEmails;
class ForgotPasswordController extends Controller
{
/*
|--------------------------------------------------------------------------
| Password Reset Controller
|--------------------------------------------------------------------------
|
| This controller is responsible for handling password reset emails and
| includes a trait which assists in sending these notifications from
| your application to your users. Feel free to explore this trait.
|
*/
use SendsPasswordResetEmails;
/**
* Create a new controller instance.
*
* @return void
*/
public function __construct()
{
$this->middleware('guest');
}
protected function sendResetLinkResponse($response)
{
if (request()->header('Content-Type') == 'application/json') {
return response()->json(['success' => 'Email enviado con éxito.']);
}
return back()->with('status', 'Email enviado con éxito.');
}
protected function sendResetLinkFailedResponse($response)
{
if (request()->header('Content-Type') == 'application/json') {
return response()->json(['error' => 'Por favor contacte a soporte técnico.']);
}
return back()->withErrors(
['email' => 'Ha ocurrido un error']
);
}
}