diff --git a/WePay/Redpack.php b/WePay/Redpack.php index 8456810..e4c74b1 100644 --- a/WePay/Redpack.php +++ b/WePay/Redpack.php @@ -35,7 +35,7 @@ class Redpack extends BasicPay $this->params->offsetUnset('appid'); $this->params->set('wxappid', $this->config->get('appid')); $url = "https://api.mch.weixin.qq.com/mmpaymkttransfers/sendredpack"; - return $this->callPostApi($url, $options, true); + return $this->callPostApi($url, $options, true, 'MD5', false); } /** @@ -49,21 +49,21 @@ class Redpack extends BasicPay $this->params->offsetUnset('appid'); $this->params->set('wxappid', $this->config->get('appid')); $url = "https://api.mch.weixin.qq.com/mmpaymkttransfers/sendgroupredpack"; - return $this->callPostApi($url, $options, true); + return $this->callPostApi($url, $options, true, 'MD5', false); } /** * 查询红包记录 - * @param array $options + * @param array $mch_billno 商户发放红包的商户订单号 * @return array * @throws \WeChat\Exceptions\InvalidResponseException */ - public function query(array $options) + public function query($mch_billno) { $this->params->offsetUnset('wxappid'); $this->params->set('appid', $this->config->get('appid')); $url = "https://api.mch.weixin.qq.com/mmpaymkttransfers/gethbinfo"; - return $this->callPostApi($url, $options, true); + return $this->callPostApi($url, ['mch_billno' => $mch_billno, 'bill_type' => 'MCHT'], true, 'MD5', false); } } \ No newline at end of file