Open dwasyl opened 8 months ago
Hi @dwasyl - thanks so much for the detailed menu :)
I have to focus on getting a new release out (which I'm doing now) and after that, I can try to list out which of these things are already changed or fixed - and which would be interesting in a PR.
Thanks!
Hey there,
I've been running an older fork of
django-nyt
with a few tweaks. I have to update my fork to the latest build anyway so I thought I'd check in and see if there's any interest in the specific changes made:Improved
notifymail
with a number of changes:notifymail.py
notifymail
checksSetting.interval
to be > -1 before sending notifications.-1
treated as disabling notifications (e-mails) for a usernotifymail
checks the new fieldSettings.last_sent
and compares it to the user'sinterval
setting before sending mail. This makes cron jobs work properly with set intervals.notifymail
tries for the HTML file and falls back to the text file.Added to the
Settings
object:Setting
had a new field addedlast_sent
to store a datetime when notifications were last sent to the userAdded a new setting and option to existing:
NYT_SEND_ONLY_LATEST
setting to enable e-mail notifications for most recent notification or all unset notifications for the subscription.-1
to represent disable e-mail notifications,Improved the content returned by
get_notifications
:target_obj
method toSubscription
to return the target object, if any.type_lbl
field to returned Json data in addition to theNotficationType.key
that was already included.target
field to returned Json data, as the string representation of the target object (if any).@benjaoming would there be any interest in some or all of these things as a PR?