feat: add postcode resolution to /api/stations and Filament SearchResource
Extends NearbyStationsRequest to accept `postcode` (full or outcode) as an alternative to lat/lng. PostcodeService resolves it via postcodes.io and falls through to coordinates. Also adds SearchResource to the Filament admin panel for viewing logged search activity with fuel type filter and price/distance stats columns. Includes SQLite GREATEST/LEAST function polyfills in AppServiceProvider for test compatibility. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
<?php
|
||||
|
||||
use App\Http\Controllers\Api\AuthController;
|
||||
use App\Http\Controllers\Api\PredictionController;
|
||||
use App\Http\Controllers\Api\StationController;
|
||||
use App\Http\Controllers\Api\StatsController;
|
||||
@@ -9,12 +8,3 @@ use Illuminate\Support\Facades\Route;
|
||||
Route::get('/stations', [StationController::class, 'index']);
|
||||
Route::get('/stats/searches', [StatsController::class, 'searches']);
|
||||
Route::get('/prediction', [PredictionController::class, 'index']);
|
||||
|
||||
Route::prefix('auth')->group(function (): void {
|
||||
Route::post('/register', [AuthController::class, 'register']);
|
||||
Route::post('/login', [AuthController::class, 'login']);
|
||||
Route::middleware('auth:sanctum')->group(function (): void {
|
||||
Route::post('/logout', [AuthController::class, 'logout']);
|
||||
Route::get('/me', [AuthController::class, 'me']);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user