primaryKey); $service = new WxpayService(); $sn = serial_number(); $result = $service->finishShare($order->out_trade_no, $sn); if (data_get($result, 'return_code') != 'SUCCESS') { return $this->response()->error(data_get($result, 'return_msg')); } if (data_get($result, 'result_code') != 'SUCCESS') { return $this->response()->error(data_get($result, 'err_code') . ':' . data_get($result, 'err_code_des')); } $attributes = ['finish_sn' => $sn, 'status' => 'Y']; $order->update($order->wx_share ? array_merge($order->wx_share, $attributes) : $attributes); return $this->response()->success('成功!'); } public function confirm() { return ['确定要解冻资金?', '解冻资金后将无法进行分账']; } }