user_id; $trapp_id = $order->trapp_id; $app = App::get($trapp_id); // 出包,进行下单 $app = App::get($trapp_id); $http = Http::getById($app->out_id); $data = [ 'wallet_id' => $order->id ]; $res = $http->postJson($app->order_out_info, $data); // dd($res,$data); // "business_id":2010,"business_status":20,"business_amount":"1.000","wallet_id":29,"wallet_amount":"1.000" Logger::info('out_call2-res',$res); if ($res['code'] != 0) { Logger::error('out_call2',$res); throw new \Exception('回调失败'); } if($validation){ if( $order->oamount != $res['data']['business_amount']){ return "业务订单 - 钱数不一致 "; } if( $order->out_order_id != $res['data']['business_id']){ return "业务订单ID不一致"; } if( $order->id != $res['data']['wallet_id']){ return "订单ID - 不一致"; } } $order->out_order_id = $res['data']['business_id']; $order->oamount= $res['data']['business_amount']; $order->status = TStatus::CALL; if (!$order->save()) { throw new \Exception('保存失败'); } return true; } }