feat: implement discount and transport features in the quote system
- Added maximum discount settings configurable by the administrator. - Implemented discount calculations in the quote confirmation process. - Introduced transport options with associated costs, including handling for exceeding maximum piece limits. - Updated frontend to display discounts and transport information in the quote summary. - Created new database migrations for storing discount and transport settings. - Developed a new Filament page for managing global discount settings. - Enhanced email templates to include discount and transport details. - Added tests to ensure proper functionality of discounts and transport calculations.
This commit is contained in:
@@ -10,6 +10,13 @@ use Illuminate\Support\Facades\Route;
|
||||
// frontend non deve indovinare la porta su cui gira Vite (può cambiare se 5174 è occupata).
|
||||
Route::get('config', fn () => response()->json([
|
||||
'frontend_cliente_url' => config('preventivi.frontend_cliente_url'),
|
||||
// Opzioni del contributo trasporto al checkout (importo per pezzo, null = da quantificare).
|
||||
'trasporto' => collect(config('preventivi.trasporto.zone'))
|
||||
->map(fn (array $zona, string $valore) => ['valore' => $valore] + $zona)
|
||||
->values(),
|
||||
'trasporto_nota' => config('preventivi.trasporto.nota_da_quantificare'),
|
||||
'trasporto_max_pezzi' => config('preventivi.trasporto.max_pezzi'),
|
||||
'trasporto_etichetta_oltre_max' => config('preventivi.trasporto.etichetta_oltre_max'),
|
||||
]));
|
||||
|
||||
// Catalogo prodotti (sistemi e modelli con icone) per il configuratore.
|
||||
|
||||
Reference in New Issue
Block a user