KSP-SpaceDock / SpaceDock

Current Codebase (Python /Flask)
https://spacedock.info
Other
72 stars 33 forks source link

new Upvote button, ignore auto-updated followed mods #333

Closed yalov closed 2 years ago

yalov commented 3 years ago

I use follow almost like "upvote", because there is no other spacedock-related free way to compliment mod author, and ofthen I don't really need the email messaging feature.

Also, the email messaging, then author just clicked yes, my mod compatible for a new version of ksp is not so helpful, so I propose :

HebaruSan commented 3 years ago

author just clicked yes, my mod compatible for a new version of ksp is not so helpful

  • ignore email messaging for mods, that is updated by the yes, update automatically button

I think I agree with this. Users who want notifications will be expecting new downloads, not that the author has had a good think and decided it's OK to keep using the current one. Don't need to make the data model and UI more complicated with extra buttons and features, though, we can just not notify for that case.

HebaruSan commented 3 years ago

Several users said they liked this notification, so we can't just remove it. Instead, I'm picturing a "Notification Settings" page linked from the user profile, that would contain a big table of all the emails the user might receive. Check the box to receive the email, uncheck it to suppress, with some kind of mass operation buttons so users who don't want any auto-update messages don't have to click every row:

Followed Mod Update Auto-update (All)
Kerbal Engineer Redux Check Uncheck
Module Manager Check Uncheck
Kopernicus Check Uncheck
Kerbal Konstructs Check Uncheck
(All) Check Uncheck Check Uncheck

Two new bool columns in this table could store this adequately:

https://github.com/KSP-SpaceDock/SpaceDock/blob/9d6dadd3dda66e2ece6298b4e4c8e2b76f782b8f/KerbalStuff/objects.py#L14-L16

Then we would check these rows when sending notifications, possibly by using a more complex SQL operation instead of mod.followers:

https://github.com/KSP-SpaceDock/SpaceDock/blob/9d6dadd3dda66e2ece6298b4e4c8e2b76f782b8f/KerbalStuff/email.py#L82-L128

I didn't realize there are only two mod-specific emails at this point. If there are any others that we might want to add, this would be a good time to do that.