feat/task1-c-wallet
devil_gong 2018-09-28 14:48:36 +08:00
parent 41909b1566
commit 5f8e35ef24
1 changed files with 2 additions and 3 deletions

View File

@ -223,8 +223,7 @@ class OrderService
// 开启事务
$m->startTrans();
// 更新支付状态
$where = array('id' => $out_trade_no);
// 更新订单状态
$upd_data = array(
'status' => 2,
'pay_status'=> 1,
@ -232,7 +231,7 @@ class OrderService
'pay_time' => time(),
'upd_time' => time(),
);
if($m->where($where)->save($upd_data))
if($m->where(['id'=>$data['id']])->save($upd_data))
{
// 提交事务
$m->commit();