|
@@ -161,6 +161,12 @@ class LiveService extends BaseService
|
|
|
];
|
|
];
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
|
+ * 详情
|
|
|
|
|
+ * @param $id
|
|
|
|
|
+ * @param $userId
|
|
|
|
|
+ * @return \Illuminate\Database\Eloquent\Builder|\Illuminate\Database\Eloquent\Model|object|null
|
|
|
|
|
+ */
|
|
|
public function getInfo($id, $userId)
|
|
public function getInfo($id, $userId)
|
|
|
{
|
|
{
|
|
|
$info = $this->model->with(['member'])->where(['id'=> $id,'mark'=>1])->first();
|
|
$info = $this->model->with(['member'])->where(['id'=> $id,'mark'=>1])->first();
|
|
@@ -224,7 +230,7 @@ class LiveService extends BaseService
|
|
|
if(!VideoCollectService::make()->getCollectCacheInfo($userId, $id, 1,2)){
|
|
if(!VideoCollectService::make()->getCollectCacheInfo($userId, $id, 1,2)){
|
|
|
$info = $this->model->from('live as a')
|
|
$info = $this->model->from('live as a')
|
|
|
->where(['a.id'=> $id,'a.mark'=>1])
|
|
->where(['a.id'=> $id,'a.mark'=>1])
|
|
|
- ->select(['a.id','a.category_id','a.user_id'])
|
|
|
|
|
|
|
+ ->select(['a.id','a.category','a.user_id'])
|
|
|
->first();
|
|
->first();
|
|
|
|
|
|
|
|
if(empty($info)){
|
|
if(empty($info)){
|
|
@@ -236,7 +242,7 @@ class LiveService extends BaseService
|
|
|
'type'=> 1,
|
|
'type'=> 1,
|
|
|
'source_type'=> 2,
|
|
'source_type'=> 2,
|
|
|
'collect_id'=> $id,
|
|
'collect_id'=> $id,
|
|
|
- 'category_id'=> isset($info['category_id'])? $info['category_id'] : 0,
|
|
|
|
|
|
|
+ 'category_id'=> isset($info['category'])? $info['category'] : 0,
|
|
|
'collect_uid'=> isset($info['user_id'])? $info['user_id'] : 0,
|
|
'collect_uid'=> isset($info['user_id'])? $info['user_id'] : 0,
|
|
|
'create_time'=> time(),
|
|
'create_time'=> time(),
|
|
|
'status'=> 1,
|
|
'status'=> 1,
|