feat: redesign meal ordering system

This commit is contained in:
2025-12-02 12:57:42 +01:00
parent 0aada37286
commit 0cf6b405f1
24 changed files with 4823 additions and 639 deletions

View File

@@ -7,7 +7,7 @@ import './styles.scss'
interface KitchenReportResponse {
date: string
mealType: string
totalOrders: number
totalMeals: number
ingredients: Record<string, number>
labels: Record<string, string>
portionSizes?: Record<string, number>
@@ -31,7 +31,7 @@ export const KitchenDashboard: React.FC = () => {
try {
const response = await fetch(
`/api/meal-orders/kitchen-report?date=${date}&mealType=${mealType}`,
`/api/meals/kitchen-report?date=${date}&mealType=${mealType}`,
{
credentials: 'include',
},
@@ -138,14 +138,14 @@ export const KitchenDashboard: React.FC = () => {
<strong>Meal:</strong> {getMealTypeLabel(report.mealType)}
</span>
<span className="kitchen-dashboard__meta-item kitchen-dashboard__meta-item--highlight">
<strong>Total Orders:</strong> {report.totalOrders}
<strong>Total Meals:</strong> {report.totalMeals}
</span>
</div>
</div>
{report.totalOrders === 0 ? (
{report.totalMeals === 0 ? (
<div className="kitchen-dashboard__empty">
<p>No orders found for this date and meal type.</p>
<p>No meals found for this date and meal type.</p>
</div>
) : (
<>