dever 4 年之前
父节点
当前提交
13bfa7d5f2
共有 2 个文件被更改,包括 3 次插入1 次删除
  1. 1 1
      app/collection/lib/Content.php
  2. 2 0
      app/collection/src/Api.php

+ 1 - 1
app/collection/lib/Content.php

@@ -49,7 +49,7 @@ class Content
                 }
                 
                 $result[$i] = $page;
-                //$result[$i]['id'] = 
+                $result[$i]['id'] = $info_id . '_' . $page['id'];
                 $result[$i]['data'] = -1;
                 $result[$i]['type'] = -1;
                 $result[$i]['times'] = $result[$i]['times_parent'] = '';

+ 2 - 0
app/collection/src/Api.php

@@ -94,6 +94,8 @@ class Api extends Core
         # 佣金
         $data['info']['reward'] = 0;
         if ($type == -1) {
+            $temp = explode('_', $content_id);
+            $content_id = $temp[1];
             $page = Dever::db('collection/page')->one($content_id);
             $data['info']['name'] = $page['name'];
             $data['pic'] = explode(',', $page['pic']);