feat: 拆分邮件通知选项,根据会员权益显示

- 翻译完成邮件通知(所有用户)
- 鮮件带附件发送(VIP专属,free用户显示需VIP)
- 会员到期提醒(仅VIP用户显示)
- 添加 notify_with_attachment 字段
- 更新各等级权益:email_notify/email_attachment
This commit is contained in:
2026-04-15 01:10:59 +08:00
parent 56709b1a65
commit 9a36b9245a
4 changed files with 53 additions and 8 deletions

View File

@@ -54,6 +54,7 @@ class User(db.Model):
# 邮件通知设置
email_notify = db.Column(db.Boolean, default=True) # 邮件通知开关
notify_on_complete = db.Column(db.Boolean, default=True) # 翻译完成通知
notify_with_attachment = db.Column(db.Boolean, default=False) # 邮件带附件VIP功能
notify_on_expire = db.Column(db.Boolean, default=True) # 会员到期提醒
# 关系
@@ -132,6 +133,7 @@ class User(db.Model):
'invite_rewards': self.invite_rewards,
'email_notify': self.email_notify,
'notify_on_complete': self.notify_on_complete,
'notify_with_attachment': self.notify_with_attachment,
'notify_on_expire': self.notify_on_expire,
'daily_count': self.daily_count,
'total_count': self.total_count,