...
|
...
|
@@ -65,6 +65,7 @@ func (dao *EmployeeDao) CalculatePersonUnReadNotification(uid int64) (map[string |
|
|
if count, err := tx.Model(sentNotificationModel).Relation("Notification").
|
|
|
Where(`sent_notification.receiver @> '{"uid":?}'`, uid).
|
|
|
Where("notification.notification_type = ?", domain.NOTIFICATION_TYPE_SYSTEM).
|
|
|
Where("sent_notification.is_read = ?", false).
|
|
|
Count(); err != nil {
|
|
|
return nil, err
|
|
|
} else {
|
...
|
...
|
@@ -73,6 +74,7 @@ func (dao *EmployeeDao) CalculatePersonUnReadNotification(uid int64) (map[string |
|
|
if count, err := tx.Model(sentNotificationModel).Relation("Notification").
|
|
|
Where(`sent_notification.receiver @> '{"uid":?}'`, uid).
|
|
|
Where("notification.notification_type = ?", domain.NOTIFICATION_TYPE_INTERACTION).
|
|
|
Where("sent_notification.is_read = ?", false).
|
|
|
Count(); err != nil {
|
|
|
return nil, err
|
|
|
} else {
|
...
|
...
|
|