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

修改接口

... ... @@ -997,21 +997,18 @@ class User extends Api
$video['video_id'] = $this->request->param('video_id');
$video['attr'] = $this->request->param('attr');
$a = serialize($video);
//我已经购买过的视频
$video_buy = Db::name('iphone')
->where('user_id',$user_id)
->where('status',2)
->field('video_id')
->select();
foreach ($video_buy as &$v){
if(!empty($v['video_id'])){
$v['video_id'] = unserialize($v['video_id']);
if ($video == $v['video_id']){
$data['is_buy'] = 1;
}else{
$data['is_buy'] = 2;
}
}
->where('video_id',$a)
->find();
if(empty($video_buy)){
$data['is_buy'] = 2;
}else{
$data['is_buy'] = 1;
}
$this->success('SUCCESS',$data);
}
... ... @@ -1844,12 +1841,12 @@ class User extends Api
}else{
//发送短信,通知客户
$mobile = 13780608990;
$mobile1 = 18511199763;
$content = "【仁甲看见SHOP】提醒您,您有新苹果客户下了订单,客户电话为:$user[mobile] ,请您及时回复!";
//发送短信
$send = new Pay();
$send->sms($mobile,$content);
$send->sms($mobile1,$content);
$this->success('SUCCESS',['order_id'=>$data]);
}
... ...