feat: add product selection step before meal planning

Inserts a new PlanProductsSheet as step 1 of the planning flow.
Users see their current products as a multi-select checklist (all
selected by default) before choosing the planning mode and dates.

- Empty state explains the benefit and offers "Add products" CTA
  while always allowing "Plan without products" to skip
- Selected product IDs flow through PlanMenuSheet →
  PlanDatePickerSheet → MenuService.generateForDates → backend
- Backend: added ProductIDs field to generate-menu request body;
  uses ListForPromptByIDs when set, ListForPrompt otherwise
- Backend: added Repository.ListForPromptByIDs (filtered SQL query)
- All 12 ARB locale files updated with planProducts* keys

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
dbastrikin
2026-03-23 16:07:28 +02:00
parent b6c75a3488
commit b38190ff5b
33 changed files with 1007 additions and 77 deletions

View File

@@ -118,7 +118,9 @@
"noResultsForQuery": "Nessun risultato per \"{query}\"",
"@noResultsForQuery": {
"placeholders": {
"query": { "type": "String" }
"query": {
"type": "String"
}
}
},
"servingsLabel": "Porzioni",
@@ -127,7 +129,9 @@
"planningForDate": "",
"@planningForDate": {
"placeholders": {
"date": { "type": "String" }
"date": {
"type": "String"
}
}
},
"markAsEaten": "Segna come mangiato",
@@ -136,7 +140,6 @@
"generateWeekSubtitle": "L'AI creerà un menu con colazione, pranzo e cena per tutta la settimana",
"generatingMenu": "Generazione menu...",
"dayPlannedLabel": "Giorno pianificato",
"planMenuButton": "Pianifica i pasti",
"planMenuTitle": "Cosa pianificare?",
"planOptionSingleMeal": "Un pasto",
@@ -151,6 +154,16 @@
"planSelectMealType": "Tipo di pasto",
"planSelectRange": "Seleziona periodo",
"planGenerateButton": "Pianifica",
"planGenerating": "Generazione piano\u2026",
"planSuccess": "Menu pianificato!"
"planGenerating": "Generazione piano",
"planSuccess": "Menu pianificato!",
"planProductsTitle": "Prodotti per il menu",
"planProductsSubtitle": "L'AI terrà conto dei prodotti selezionati nella generazione delle ricette",
"planProductsEmpty": "Nessun prodotto aggiunto",
"planProductsEmptyMessage": "Aggiungi prodotti che hai in casa — l'AI suggerirà ricette con quello che hai già",
"planProductsAddProducts": "Aggiungi prodotti",
"planProductsContinue": "Continua",
"planProductsSkip": "Salta la selezione dei prodotti",
"planProductsSkipNoProducts": "Pianifica senza prodotti",
"planProductsSelectAll": "Seleziona tutto",
"planProductsDeselectAll": "Deseleziona tutto"
}