lrf %!s(int64=2) %!d(string=hai) anos
pai
achega
d991be0c62
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      app/service/view/goods.js

+ 2 - 1
app/service/view/goods.js

@@ -107,7 +107,7 @@ class GoodsService extends CrudService {
         as: 'act',
       },
     });
-    // // 整理数据
+    // 整理数据
     pipeline.push({
       $project: {
         _id: 0,
@@ -144,6 +144,7 @@ class GoodsService extends CrudService {
       d.text = text;
       d.tag = tag;
     }
+    data.act = _.uniqBy(data.act, '_id');
     return data;
   }