|
|
@@ -39,18 +39,19 @@ class Platform extends Api
|
|
|
}
|
|
|
|
|
|
public function user_share(){
|
|
|
- if(input('uid',0)>0){
|
|
|
- $map['uid']=input('uid');
|
|
|
+ $map = []; // 初始化$map数组,避免未定义时的错误
|
|
|
+ if(input('uid', 0) > 0){
|
|
|
+ // 明确指定uid所属的表(假设主表为video_share)
|
|
|
+ $map['video_share.uid'] = input('uid');
|
|
|
}
|
|
|
- $config=$this->config();
|
|
|
- $configs=config('site');
|
|
|
+ $config = $this->config();
|
|
|
$list = model('VideoShare')
|
|
|
- ->with('videolist')
|
|
|
+ ->with('videolist,user')
|
|
|
->where($map)
|
|
|
->limit(10)
|
|
|
->select();
|
|
|
- $data=['config'=>$config,'doctor'=>$list];
|
|
|
- $this->success('请求成功',$data);
|
|
|
+ $data = ['config' => $config, 'doctor' => $list];
|
|
|
+ $this->success('请求成功', $data);
|
|
|
}
|
|
|
// 每个短剧更具贡献值分红
|
|
|
public function dividend(){
|