grocy / grocy

ERP beyond your fridge - Grocy is a web-based self-hosted groceries & household management solution for your home
https://grocy.info
MIT License
6.86k stars 568 forks source link

Itens in shopping list not deleted after purchase #2374

Closed albarreto closed 1 year ago

albarreto commented 1 year ago

Item "Carne Moida" on shopping list: Captura de Tela 2023-11-09 às 16 11 35

Adding products via Purchase option Captura de Tela 2023-11-09 às 16 12 07

Back to Shopping list and Carne Moida remains there Captura de Tela 2023-11-09 às 16 12 38

Stock contains new purchases Captura de Tela 2023-11-09 às 16 12 47

berrnd commented 1 year ago

A random purchase transaction does not remove a random item from a random shopping list - it's also nowhere stated that that's the case, so I really don't get how you came to to the conclusion to report that as a Bug.

But the the "Shopping list to stock workflow" was invented for that. Simply use one of those buttons and exactly what you expect happens:

grafik

  Only when triggering such a workflow from a shopping list item there is a relation to it, otherwise not - remember that Grocy has multiple shopping lists and even the same product can occur multiple times on the same shopping list. So assuming you have Carne Moida on 3 shopping lists with 3 different amounts and you do a purchase transaction (at the purchase page, so without a relation to a shopping list item), which shopping list item, out of those 3, do you expect to be removed and what's the rule behind which one to pick?

Has also been asked in #2359 lately and I know we did not hear each other for a month or so, but searching beforehand is still a thing.