diff --git a/framework/core/js/src/common/models/Notification.js b/framework/core/js/src/common/models/Notification.js index ad6cff6db..b324addcd 100644 --- a/framework/core/js/src/common/models/Notification.js +++ b/framework/core/js/src/common/models/Notification.js @@ -1,17 +1,13 @@ import Model from '../Model'; -import computed from '../utils/computed'; export default class Notification extends Model {} Object.assign(Notification.prototype, { contentType: Model.attribute('contentType'), - subjectId: Model.attribute('subjectId'), content: Model.attribute('content'), - time: Model.attribute('time', Model.date), + createdAt: Model.attribute('createdAt', Model.transformDate), isRead: Model.attribute('isRead'), - unreadCount: Model.attribute('unreadCount'), - additionalUnreadCount: computed('unreadCount', unreadCount => Math.max(0, unreadCount - 1)), user: Model.hasOne('user'), fromUser: Model.hasOne('fromUser'),