dever 6 years ago
parent
commit
5ac08a32ba
4 changed files with 16 additions and 2 deletions
  1. 11 0
      act/database/comment.php
  2. 1 0
      act/database/like.php
  3. 2 0
      config/base.php
  4. 2 2
      doc/apidoc.php

+ 11 - 0
act/database/comment.php

@@ -65,6 +65,17 @@ return array
 			'match' 	=> 'option',
 			'list'		=> 'Dever::load("act/lib/manage.load", "{type}", {data_id})',
 		),
+
+		'num_up'		=> array
+		(
+			'type' 		=> 'int-11',
+			'name' 		=> '点赞数',
+			'default' 	=> '0',
+			'desc' 		=> '点赞数',
+			'match' 	=> 'option',
+			//'search'	=> 'order',
+			'list'		=> true,
+		),
 		
 		'content'		=> array
 		(

+ 1 - 0
act/database/like.php

@@ -1,6 +1,7 @@
 <?php
 
 $table = Dever::config('base')->type;
+$table[11] = '评论';
 return array
 (
 	# 表名

+ 2 - 0
config/base.php

@@ -30,6 +30,8 @@ $config['base'] = array
 		2 => 'video/vod',
 		3 => 'video/live',
 		4 => 'journal/info',
+		11 => 'act/comment',
+		12 => 'act/live_comment',
 	),
 
 	'audit' => array

+ 2 - 2
doc/apidoc.php

@@ -33,7 +33,7 @@
  * @apiDescription 类型设置说明
  *
  * @apiParam {String} source_type 请在header中定义,ios:ios | android:android | 移动h5:h5  | 小程序:applet | 公众号:service | pc网站:pc
- * @apiParam {Number} type 图文:1 | 视频:2 | 直播:3 | 小刊:4 | 链接:10
+ * @apiParam {Number} type 图文:1 | 视频:2 | 直播:3 | 小刊:4 | 链接:10 | 评论: 11
  * @apiParam {Number} push_ 所有带push_开头的返回参数,返回字典都是一样的,参考获取首页数据中的push_focus
  */
 
@@ -499,7 +499,7 @@
  * @apiDescription 喜欢
  *
  * @apiParam {String} signature signature
- * @apiParam {Number} type type类型
+ * @apiParam {Number} type type类型 这里增加了一个评论点赞(喜欢),type的值为11就是 给评论点赞
  * @apiParam {Number} id 当前的数据id
  *
  * @apiSuccess {Number}  id 当前的数据id