Files
Verde-Web/app/Http/Requests/DropOff/StoreCapacityLogRequest.php
admin 1150a518e8 feat(backend): complete Module 5 (drop-off points + auto-assign)
drop_off_points (with SPATIAL INDEX on coordinates) +
drop_off_capacity_logs. Public nearby query via ST_Distance_Sphere
returns DOPs sorted by distance with distance_meters in payload.
Admin CRUD plus capacity-log endpoint. Household creation auto-assigns
to the nearest active DOP within 25km; resident can re-run the lookup
via POST /households/{uuid}/reassign-drop-off.

97 feature tests passing.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-30 00:11:22 +08:00

23 lines
475 B
PHP

<?php
namespace App\Http\Requests\DropOff;
use Illuminate\Foundation\Http\FormRequest;
class StoreCapacityLogRequest extends FormRequest
{
public function authorize(): bool
{
return true;
}
public function rules(): array
{
return [
'fill_percent' => ['required', 'integer', 'min:0', 'max:100'],
'recorded_at' => ['nullable', 'date'],
'notes' => ['nullable', 'string', 'max:500'],
];
}
}