源战役
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

62 lines
1.9 KiB

  1. %% ---------------------------------------------------------------------------
  2. %% @doc 邮件推送记录
  3. %% @author xiaoxiang
  4. %% @since 2017-02-28
  5. %% @deprecated 邮件推送
  6. %% ---------------------------------------------------------------------------
  7. -define(PUSHMAIL_LV, 1). % 个人等级升到X级
  8. -define(PUSHMAIL_OPENSERVER, 2). % 开服天数
  9. -define(PUSHMAIL_DUNGEON, 3). % 通过副本ID
  10. -define(PUSHMAIL_ARRIVETIME, 4). % 到达某个具体时间
  11. -define(PUSHMAIL_MARGE, 5). % 合服
  12. -define(PUSH_LIST, [?PUSHMAIL_LV, ?PUSHMAIL_OPENSERVER, ?PUSHMAIL_DUNGEON, ?PUSHMAIL_ARRIVETIME, ?PUSHMAIL_MARGE]).
  13. -define(MAX_TIME, 4294967296 - 1).
  14. -define(PUSH_LIMIT_LV, 1).
  15. -define(PUSH_LIMIT_SEX, 2).
  16. -define(PUSH_LIMIT_CAREER, 3).
  17. -record(pushmail, {
  18. id = 0, %% 触发id 1个人等级升到X级, 2开服天数, 3通过副本id, 4到达某个具体时间
  19. value = 0,
  20. time = 0,
  21. limit = [],
  22. title = "",
  23. msg = "",
  24. accessory = [],
  25. about = ""
  26. }).
  27. -record(base_pushmail, {
  28. id = 0,
  29. time = [], %% 时间
  30. open_day = 0, %% 开服天数
  31. merge_day = 0, %% 合服天数
  32. create_day = 0, %% 角色创建天数
  33. lv = 0, %% 等级
  34. career = [], %% 职业
  35. sex = [], %% 性别
  36. dun = 0, %% 副本ID
  37. other = [], %% 其他 end_open_day 有效开服天数 end_time有效日期 end_marge_day有效合服天数
  38. title = "", %% 邮件标题
  39. msg = "", %% 邮件内容
  40. accessory = [], %% 附件
  41. about = ""
  42. }).
  43. -record(status_pushmail, {
  44. push_list = []
  45. }).
  46. -record(push_state, {
  47. time_ref = none,
  48. server_ref = none
  49. }).
  50. -define(sql_select_his, <<"select mail from pushmail where role_id = ~p">>).
  51. -define(sql_replace_his, <<"replace into pushmail (role_id, mail) values (~p, ~p)">>).