Files
Jobhero_back/app/Providers/AppServiceProvider.php
CarlosTorres 5e3b203f84 Fix: Correcciones panel admin y API frontend
## Panel de Administración

### FormBuilder personalizado (Laravel 11)
- Creado app/Support/FormBuilder.php como reemplazo de laravelcollective/html
- Creado app/Support/Facades/Form.php para el facade
- Registrado en AppServiceProvider y config/app.php
- Soporta: text, email, password, file, textarea, select, checkbox, radio, etc.
- Manejo de valores null en todos los parámetros

### Configuración de sesión
- Cambiado same_site de "none" a "lax" para compatibilidad HTTP
- Corrige error 419 Page Expired en login

### Status CRUD
- Agregado campo en_name al formulario (español/inglés)
- Actualizado StatusController create/update para manejar en_name

### Dependencias
- Instalado spatie/laravel-google-cloud-storage para driver GCS

## API Frontend

### Validaciones de perfil de proveedor
Agregadas validaciones en endpoints que requieren perfil de proveedor:

- SupplierController::getpostulation - Retorna error 400 si no hay perfil
- SupplierController::getcontractedpostulation - Retorna error 400 si no hay perfil
- PostulationController::postulate - Retorna error 400 si no hay perfil
- PostulationController::getfinishedpostulations - Retorna error 400 si no hay perfil
- ContractController::startcontract - Retorna error 400 si no hay perfil

### Null safety en contratos
- ContractController::getcurrentcontracts - Manejo seguro de supplier/category null
- ContractController::getfinishedcontracts - Manejo seguro de supplier/category/status null

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-18 23:16:34 +00:00

45 lines
921 B
PHP
Executable File

<?php
namespace App\Providers;
use App\Services\SocialUserResolver;
use App\Support\FormBuilder;
use Coderello\SocialGrant\Resolvers\SocialUserResolverInterface;
use Illuminate\Support\ServiceProvider;
use Illuminate\Support\Facades\Schema;
class AppServiceProvider extends ServiceProvider
{
/**
* All of the container bindings that should be registered.
*
* @var array
*/
public $bindings = [
SocialUserResolverInterface::class => SocialUserResolver::class,
];
/**
* Register any application services.
*
* @return void
*/
public function register()
{
$this->app->singleton('form', function ($app) {
return new FormBuilder();
});
}
/**
* Bootstrap any application services.
*
* @return void
*/
public function boot()
{
Schema::defaultStringLength(191);
//
}
}