作者 耿培杰

测试定时器

... ... @@ -109,4 +109,24 @@ class Timing extends Api
$teamGroupModel->pastDue($ids);
}
/**
* @ApiTitle (修改拼团过期状态)
* @ApiSummary (修改拼团过期状态 每分钟执行)
* @ApiMethod (POST)
* @ApiRoute (/api/Timing/teamGroup)
* @ApiReturn({
})
*/
public function test(){
$code = rand(100000,999999);
$content = array(
'content' => "【E-MP market】您的验证码是:" . $code . ",请于10分钟内使用,如非本人操作,可忽略此消息。",//短信内容
'mobile' => 17336406664,//手机号码
'tKey' => time(),
);
$result = json_decode(send_sms($content),true);
}
}
... ...
... ... @@ -32,6 +32,7 @@ class TeamGroup extends Model
//修改订单表拼团状态
$res2 = $orderModel->where(['team_group_id'=>['in',$ids]])->update(['team_group_status'=>3]);
$orderList = $orderModel->where(['team_group_id'=>['in',$ids]])->field('id,order_num,pay_total,pay_type,user_id')->select();
//退款
foreach ($orderList as $k => $orderInfo){
if ($orderInfo['pay_type'] == 1){
... ...