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

修改接口

... ... @@ -1818,7 +1818,7 @@ class User extends Api
$send->sms($mobile1,$content);
$this->error('error',$data);
$this->error('error',['code'=>1,'info'=>$data]);
}else{
$data['is_enough'] = 1;
... ... @@ -1833,7 +1833,7 @@ class User extends Api
->where('video_id',$video_s)
->find();
if(!empty($res)){
$this->error('该属性的视频已经购买过了');
$this->error('error',['code'=>2]);
}
$param['video_id'] = serialize($video);
}else{
... ... @@ -1845,7 +1845,7 @@ class User extends Api
foreach ($arr as &$v){
if(!empty($v['pic_id'])){
if($v['pic_id'] == $pic_id){
$this->error('该图片已经购买过了');
$this->error('error',['code'=>2]);
}
}
}
... ... @@ -1856,7 +1856,7 @@ class User extends Api
$data_order = Db::name('iphone')
->insertGetId($param);
if(empty($data_order)){
$this->error(['code'=>2,'msg'=>'sql执行失败']);
$this->error('sql执行失败');
}else{
$send = new Pay();
Db::startTrans();
... ...