lrf402788946 4 years ago
parent
commit
b08480e74e
1 changed files with 6 additions and 6 deletions
  1. 6 6
      app/service/users/person_room.js

+ 6 - 6
app/service/users/person_room.js

@@ -24,12 +24,12 @@ class Person_roomService extends CrudService {
     console.log(data.map(i => ObjectId(i.id || i._id)));
     const aggQuery = [
       { $match: { room_id: data.map(i => ObjectId(i.id || i._id)), is_read: false, receiver_id: ObjectId(p_id) } },
-      {
-        $group: {
-          _id: '$room_id',
-          sum: { $sum: 1 },
-        },
-      },
+      // {
+      //   $group: {
+      //     _id: '$room_id',
+      //     sum: { $sum: 1 },
+      //   },
+      // },
     ];
     console.log(aggQuery);
     const r = await this.pc.aggregate(aggQuery);