作者 郭盛
1 个管道 的构建 通过 耗费 0 秒

修改评论

... ... @@ -1090,13 +1090,13 @@ class Project extends Api
$where['a.farm_id'] = $param['farm_id'];
$where['a.project_id'] = $param['project_id'];
$where['a.status'] = 2;
$data = Db::name('comment')
$data['list'] = Db::name('comment')
->alias('a')
->join('user b','a.user_id = b.id')
->field('a.*,b.avatar,b.nickname,a.createtime')
->where($where)
->select();
foreach ($data as &$v){
foreach ($data['list'] as &$v){
$v['is_zan'] = 1;
$v['createtime'] = date('Y-m-d H:i:s',$v['createtime']);
}
... ...