|
@@ -31,11 +31,11 @@ class Active extends Api{
|
|
|
// 接收参数
|
|
|
$id = request('id',0);
|
|
|
// 如果存在的话
|
|
|
- if( !$id ) return json_send(['code'=>'error','msg'=>'未知的活动ID','data'=>'']);
|
|
|
+ if( !$id ) return json_send(['code'=>'error','msg'=>'未知的活动ID','data'=>['error'=>'未知的活动ID']]);
|
|
|
// 获取客户城市的数据
|
|
|
$data = $Model->getOne($id);
|
|
|
// 如果存在的话
|
|
|
- if( !$data ) return json_send(['code'=>'error','msg'=>'暂无活动','data'=>$data]);
|
|
|
+ if( !$data ) return json_send(['code'=>'error','msg'=>'暂无活动','data'=>['error'=>'暂无活动']]);
|
|
|
// 默认可以参加活动
|
|
|
$data['allow_join'] = 1;
|
|
|
// 判断是不是可以参与
|