예제 #1
0
파일: API.php 프로젝트: yuyebin/wechat-sdk
 /**
  * Prepare order to pay.
  *
  * @param Order $order
  *
  * @return \EasyWeChat\Support\Collection
  */
 public function prepare(Order $order)
 {
     $order->notify_url = $order->get('notify_url', $this->merchant->notify_url);
     $order->spbill_create_ip = $order->trade_type === Order::NATIVE ? get_server_ip() : get_client_ip();
     return $this->request(self::API_PREPARE_ORDER, $order->all());
 }
예제 #2
0
파일: API.php 프로젝트: sunmingyang/wechat
 /**
  * Prepare order to pay.
  *
  * @param Order $order
  *
  * @return \EasyWeChat\Support\Collection
  */
 public function prepare(Order $order)
 {
     $order->notify_url = $order->get('notify_url', $this->merchant->notify_url);
     return $this->request(self::API_PREPARE_ORDER, $order->all());
 }