forked from MarseyWorld/MarseyWorld
fddf
parent
8aee250116
commit
4d13606613
|
@ -140,8 +140,16 @@ def monthly(v):
|
|||
kind=name
|
||||
))
|
||||
|
||||
text = "You were given the following awards:\n\n"
|
||||
|
||||
for key, value in grant_awards.items():
|
||||
text += f" - **{value}** {AWARDS[key]['title']} {'Awards' if value != 1 else 'Award'}\n"
|
||||
|
||||
send_notification(NOTIFICATIONS_ACCOUNT, user, text)
|
||||
|
||||
g.db.bulk_save_objects(_awards)
|
||||
|
||||
|
||||
return {"message": "Monthly awards granted"}
|
||||
|
||||
|
||||
|
@ -255,6 +263,14 @@ def badge_grant_post(v):
|
|||
|
||||
g.db.bulk_save_objects(_awards)
|
||||
|
||||
text = "You were given the following awards:\n\n"
|
||||
|
||||
for key, value in grant_awards.items():
|
||||
text += f" - **{value}** {AWARDS[key]['title']} {'Awards' if value != 1 else 'Award'}\n"
|
||||
|
||||
send_notification(NOTIFICATIONS_ACCOUNT, user, text)
|
||||
|
||||
|
||||
g.db.add(user)
|
||||
|
||||
return redirect(user.url)
|
||||
|
|
Loading…
Reference in New Issue