lrf402788946 4 年之前
父节点
当前提交
615145d77e
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      app/service/users/person_room.js

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

@@ -17,11 +17,11 @@ class Person_roomService extends CrudService {
     const condition = { ...info }; // last_time: { $exists: true },
     const condition = { ...info }; // last_time: { $exists: true },
     if (p_id) {
     if (p_id) {
       condition.$or = [{ p1_id: p_id }, { p2_id: p_id }];
       condition.$or = [{ p1_id: p_id }, { p2_id: p_id }];
-      delete condition.p_id;
     }
     }
     console.log(condition);
     console.log(condition);
     const data = await this.model.find(condition).skip(parseInt(skip)).limit(parseInt(limit));
     const data = await this.model.find(condition).skip(parseInt(skip)).limit(parseInt(limit));
     const total = await this.model.count(condition);
     const total = await this.model.count(condition);
+    console.log(total);
     return { data, total };
     return { data, total };
   }
   }
   async create(payload) {
   async create(payload) {