message.js 467 B

12345678910111213141516
  1. "use strict";
  2. const common_vendor = require("../common/vendor.js");
  3. const messageStore = common_vendor.reactive({
  4. unreadCount: 0,
  5. // 初始未读数为 0,由 App.vue onShow 触发刷新
  6. // 更新未读数的方法
  7. setUnreadCount(count) {
  8. this.unreadCount = count;
  9. },
  10. // 标记全部已读
  11. markAllAsRead() {
  12. this.unreadCount = 0;
  13. }
  14. });
  15. exports.messageStore = messageStore;
  16. //# sourceMappingURL=../../.sourcemap/mp-weixin/store/message.js.map