|
@@ -197,7 +197,8 @@ class VideoService extends BaseService
|
|
|
// 推荐的数据
|
|
|
$uids = [];
|
|
|
$countModel = clone $model;
|
|
|
- $total = $countModel->where(function($query) use($params, $userId, &$uids){
|
|
|
+ $countModel = $countModel->whereNotIn('user_id',[$userId])
|
|
|
+ ->where(function($query) use($params, $userId, &$uids){
|
|
|
// 推荐视频数据
|
|
|
$isRecommend = isset($params['is_recommend']) ? $params['is_recommend'] : 0;
|
|
|
if ($isRecommend > 0) {
|
|
@@ -220,7 +221,9 @@ class VideoService extends BaseService
|
|
|
});
|
|
|
}
|
|
|
}
|
|
|
- })->count('a.id');
|
|
|
+ });
|
|
|
+
|
|
|
+ $total = $countModel->count('a.id');
|
|
|
|
|
|
// 随机优先匹配推送
|
|
|
$match = false;
|