From 42a15d8eb0ff6e280e7f3a2acd123c4c7539ec2a Mon Sep 17 00:00:00 2001 From: wuliangbo Date: Wed, 3 Aug 2022 11:38:33 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E8=87=AA=E5=AE=9A=E4=B9=89?= =?UTF-8?q?=E4=BA=A4=E6=98=93=E7=BB=84=E4=BB=B6=E5=94=AE=E5=90=8E=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/MiniProgram/Shop/Aftersale/Client.php | 106 +++++++++++++++++++++- 1 file changed, 105 insertions(+), 1 deletion(-) diff --git a/src/MiniProgram/Shop/Aftersale/Client.php b/src/MiniProgram/Shop/Aftersale/Client.php index ebb83d1..5d29d3c 100644 --- a/src/MiniProgram/Shop/Aftersale/Client.php +++ b/src/MiniProgram/Shop/Aftersale/Client.php @@ -51,4 +51,108 @@ class Client extends BaseClient { return $this->httpPostJson('shop/ecaftersale/update', array_merge($order, $aftersale)); } -} + + /** + * 商家更新售后单 + * + * @param array $salesOrder + * @return array|\EasyWeChat\Kernel\Support\Collection|object|\Psr\Http\Message\ResponseInterface|string + * @throws \EasyWeChat\Kernel\Exceptions\InvalidConfigException + * @throws \GuzzleHttp\Exception\GuzzleException + */ + public function merchantUpdate(array $salesOrder) + { + return $this->httpPostJson('shop/ecaftersale/merchantupdate', $salesOrder); + } + + /** + * 用户取消售后申请 + * + * @param array $aftersale + * @return array|\EasyWeChat\Kernel\Support\Collection|object|\Psr\Http\Message\ResponseInterface|string + * @throws \EasyWeChat\Kernel\Exceptions\InvalidConfigException + * @throws \GuzzleHttp\Exception\GuzzleException + */ + public function cancel(array $aftersale) + { + return $this->httpPostJson('shop/ecaftersale/cancel', $aftersale); + } + + /** + * 用户上传退货物流 + * + * @param array $aftersale + * @return array|\EasyWeChat\Kernel\Support\Collection|object|\Psr\Http\Message\ResponseInterface|string + * @throws \EasyWeChat\Kernel\Exceptions\InvalidConfigException + * @throws \GuzzleHttp\Exception\GuzzleException + */ + public function uploadReturnInfo(array $aftersale) + { + return $this->httpPostJson('shop/ecaftersale/uploadreturninfo', $aftersale); + } + + /** + * 商家同意退款|商家同意退货 + * + * @param array $data + * @return array|\EasyWeChat\Kernel\Support\Collection|object|\Psr\Http\Message\ResponseInterface|string + * @throws \EasyWeChat\Kernel\Exceptions\InvalidConfigException + * @throws \GuzzleHttp\Exception\GuzzleException + */ + public function acceptRefund(array $data) + { + return $this->httpPostJson('shop/ecaftersale/acceptrefund', $data); + } + + /** + * 商家拒绝售后 + * + * @param $aftersale_id + * @return array|\EasyWeChat\Kernel\Support\Collection|object|\Psr\Http\Message\ResponseInterface|string + * @throws \EasyWeChat\Kernel\Exceptions\InvalidConfigException + * @throws \GuzzleHttp\Exception\GuzzleException + */ + public function reject($aftersale_id) + { + return $this->httpPostJson('shop/ecaftersale/reject', ['aftersale_id' => $aftersale_id]); + } + + /** + * 商家上传退款凭证 + * + * @param array $data + * @return array|\EasyWeChat\Kernel\Support\Collection|object|\Psr\Http\Message\ResponseInterface|string + * @throws \EasyWeChat\Kernel\Exceptions\InvalidConfigException + * @throws \GuzzleHttp\Exception\GuzzleException + */ + public function uploadCertificates(array $data) + { + return $this->httpPostJson('shop/ecaftersale/upload_certificates', $data); + } + + /** + * 商家更新订单售后期 + * + * @param array $data + * @return array|\EasyWeChat\Kernel\Support\Collection|object|\Psr\Http\Message\ResponseInterface|string + * @throws \EasyWeChat\Kernel\Exceptions\InvalidConfigException + * @throws \GuzzleHttp\Exception\GuzzleException + */ + public function updateDeadline(array $data) + { + return $this->httpPostJson('shop/ecaftersale/upload_certificates', $data); + } + + /** + * 获取售后单列表 + * + * @param array $data + * @return array|\EasyWeChat\Kernel\Support\Collection|object|\Psr\Http\Message\ResponseInterface|string + * @throws \EasyWeChat\Kernel\Exceptions\InvalidConfigException + * @throws \GuzzleHttp\Exception\GuzzleException + */ + public function getList(array $data) + { + return $this->httpPostJson('shop/ecaftersale/get_list', $data); + } +}