Der-Henning / tgtg

Scanner for Too Good To Go Notifications
https://github.com/Der-Henning/tgtg/wiki
GNU General Public License v3.0
395 stars 62 forks source link

Scanner ignoring ItemIDs config setting #480

Open lucastwg opened 6 months ago

lucastwg commented 6 months ago

When setting specific store IDs to scan via config, scanner always notifies of all favorites instead of the stores listed in the ItemIDs config.

Der-Henning commented 6 months ago

Hi @lucastwg. The scanner won't scan for stores. You can only set item ids in the ItemIDs property. The option is a legacy option though. The recommended way is to setup the items you want to scan as favorites.

lucastwg commented 6 months ago

I see, would it be possible to implement a setting in the config file to only alert specific stores? I along with many people have a lot of favorites but would only like to get alerts for a few stores

lars-devs commented 6 months ago

Are You using the SMTP notifier? You could easily get this working by using the RecipientsPerItem setting. Besides the regular recipient, You can set up different recipients addresses (per item). I have my own mailserver with a special mailbox that I don't monitor. Some items that I don't want to be notified about are listed in the RecipientsPerItem and go right to the trash whereas other items go to my main mailbox.

Depending on how many items You want to either include oder exclude, it's easier to:

See below

; Only notify desired items
Recipients = non-existing-or-not-in-use@example.org
RecipientsPerItem = {"123" : ["mail@example.org"], "456" : ["mail@example.org"]}

; Exclude non-desired items
Recipients = mail@example.org
RecipientsPerItem = {"123" : ["non-existing-or-not-in-use@example.org"], "456" : ["non-existing-or-not-in-use@example.org"]}