change: 所有的 Find*Plugin 调整为 Query*Plugin (#756)

This commit is contained in:
yansongda 2023-03-19 22:21:15 +08:00 committed by GitHub
parent 258ff12538
commit 04ea3fea5f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
15 changed files with 27 additions and 26 deletions

View File

@ -10,8 +10,9 @@
### changed
- change: 所有的 `Find*Plugin` 调整为 `Query*Plugin`(#756)
- change: 插件开始装载日志由 `info` 调整为 `debug`(#755)
- change: ParserInterface 签名由 `?ResponseInterface $response` 变更`PackerInterface $packer, ?ResponseInterface $response`(#754)
- change: ParserInterface 签名由 `?ResponseInterface $response` 调整`PackerInterface $packer, ?ResponseInterface $response`(#754)
## v3.2.14

View File

@ -15,7 +15,7 @@ use Yansongda\Pay\Rocket;
/**
* @see https://pay.weixin.qq.com/wiki/doc/apiv3_partner/apis/chapter7_6_2.shtml
*/
class FindPlugin extends GeneralPlugin
class QueryPlugin extends GeneralPlugin
{
/**
* @throws \Yansongda\Pay\Exception\InvalidParamsException

View File

@ -15,7 +15,7 @@ use Yansongda\Pay\Rocket;
/**
* @see https://pay.weixin.qq.com/wiki/doc/apiv3_partner/apis/chapter7_6_5.shtml
*/
class FindReturnAdvancePlugin extends GeneralPlugin
class QueryReturnAdvancePlugin extends GeneralPlugin
{
/**
* @throws \Yansongda\Pay\Exception\InvalidParamsException

View File

@ -7,6 +7,6 @@ namespace Yansongda\Pay\Plugin\Wechat\Pay\App;
/**
* @see https://pay.weixin.qq.com/wiki/doc/apiv3/apis/chapter3_2_10.shtml
*/
class FindRefundPlugin extends \Yansongda\Pay\Plugin\Wechat\Pay\Common\FindRefundPlugin
class QueryRefundPlugin extends \Yansongda\Pay\Plugin\Wechat\Pay\Common\QueryRefundPlugin
{
}

View File

@ -7,6 +7,6 @@ namespace Yansongda\Pay\Plugin\Wechat\Pay\Combine;
/**
* @see https://pay.weixin.qq.com/wiki/doc/apiv3/apis/chapter5_1_15.shtml
*/
class FindRefundPlugin extends \Yansongda\Pay\Plugin\Wechat\Pay\Common\FindRefundPlugin
class QueryRefundPlugin extends \Yansongda\Pay\Plugin\Wechat\Pay\Common\QueryRefundPlugin
{
}

View File

@ -12,7 +12,7 @@ use function Yansongda\Pay\get_wechat_config;
use Yansongda\Pay\Plugin\Wechat\GeneralPlugin;
use Yansongda\Pay\Rocket;
class FindRefundPlugin extends GeneralPlugin
class QueryRefundPlugin extends GeneralPlugin
{
/**
* @throws \Yansongda\Pay\Exception\InvalidParamsException

View File

@ -7,6 +7,6 @@ namespace Yansongda\Pay\Plugin\Wechat\Pay\H5;
/**
* @see https://pay.weixin.qq.com/wiki/doc/apiv3/apis/chapter3_3_10.shtml
*/
class FindRefundPlugin extends \Yansongda\Pay\Plugin\Wechat\Pay\Common\FindRefundPlugin
class QueryRefundPlugin extends \Yansongda\Pay\Plugin\Wechat\Pay\Common\QueryRefundPlugin
{
}

View File

@ -7,6 +7,6 @@ namespace Yansongda\Pay\Plugin\Wechat\Pay\Jsapi;
/**
* @see https://pay.weixin.qq.com/wiki/doc/apiv3/apis/chapter3_1_10.shtml
*/
class FindRefundPlugin extends \Yansongda\Pay\Plugin\Wechat\Pay\Common\FindRefundPlugin
class QueryRefundPlugin extends \Yansongda\Pay\Plugin\Wechat\Pay\Common\QueryRefundPlugin
{
}

View File

@ -7,6 +7,6 @@ namespace Yansongda\Pay\Plugin\Wechat\Pay\Mini;
/**
* @see https://pay.weixin.qq.com/wiki/doc/apiv3/apis/chapter3_5_10.shtml
*/
class FindRefundPlugin extends \Yansongda\Pay\Plugin\Wechat\Pay\Common\FindRefundPlugin
class QueryRefundPlugin extends \Yansongda\Pay\Plugin\Wechat\Pay\Common\QueryRefundPlugin
{
}

View File

@ -7,6 +7,6 @@ namespace Yansongda\Pay\Plugin\Wechat\Pay\Native;
/**
* @see https://pay.weixin.qq.com/wiki/doc/apiv3/apis/chapter3_4_10.shtml
*/
class FindRefundPlugin extends \Yansongda\Pay\Plugin\Wechat\Pay\Common\FindRefundPlugin
class QueryRefundPlugin extends \Yansongda\Pay\Plugin\Wechat\Pay\Common\QueryRefundPlugin
{
}

View File

@ -7,8 +7,8 @@ namespace Yansongda\Pay\Plugin\Wechat\Shortcut;
use Yansongda\Pay\Contract\ShortcutInterface;
use Yansongda\Pay\Exception\Exception;
use Yansongda\Pay\Exception\InvalidParamsException;
use Yansongda\Pay\Plugin\Wechat\Pay\Common\FindRefundPlugin;
use Yansongda\Pay\Plugin\Wechat\Pay\Common\QueryPlugin;
use Yansongda\Pay\Plugin\Wechat\Pay\Common\QueryRefundPlugin;
use Yansongda\Supports\Str;
class QueryShortcut implements ShortcutInterface
@ -41,7 +41,7 @@ class QueryShortcut implements ShortcutInterface
protected function refundPlugins(): array
{
return [
FindRefundPlugin::class,
QueryRefundPlugin::class,
];
}

View File

@ -6,16 +6,16 @@ use GuzzleHttp\Psr7\Uri;
use Yansongda\Pay\Exception\Exception;
use Yansongda\Pay\Exception\InvalidParamsException;
use Yansongda\Pay\Pay;
use Yansongda\Pay\Plugin\Wechat\Ecommerce\Refund\FindPlugin;
use Yansongda\Pay\Plugin\Wechat\Ecommerce\Refund\QueryPlugin;
use Yansongda\Pay\Provider\Wechat;
use Yansongda\Pay\Rocket;
use Yansongda\Pay\Tests\TestCase;
use Yansongda\Supports\Collection;
class FindPluginTest extends TestCase
class QueryPluginTest extends TestCase
{
/**
* @var \Yansongda\Pay\Plugin\Wechat\Ecommerce\Refund\FindPlugin
* @var \Yansongda\Pay\Plugin\Wechat\Ecommerce\Refund\QueryPlugin
*/
protected $plugin;
@ -23,7 +23,7 @@ class FindPluginTest extends TestCase
{
parent::setUp();
$this->plugin = new FindPlugin();
$this->plugin = new QueryPlugin();
}
public function testNotInServiceMode()

View File

@ -6,16 +6,16 @@ use GuzzleHttp\Psr7\Uri;
use Yansongda\Pay\Exception\Exception;
use Yansongda\Pay\Exception\InvalidParamsException;
use Yansongda\Pay\Pay;
use Yansongda\Pay\Plugin\Wechat\Ecommerce\Refund\FindReturnAdvancePlugin;
use Yansongda\Pay\Plugin\Wechat\Ecommerce\Refund\QueryReturnAdvancePlugin;
use Yansongda\Pay\Provider\Wechat;
use Yansongda\Pay\Rocket;
use Yansongda\Pay\Tests\TestCase;
use Yansongda\Supports\Collection;
class FindReturnAdvancePluginTest extends TestCase
class QueryReturnAdvancePluginTest extends TestCase
{
/**
* @var \Yansongda\Pay\Plugin\Wechat\Ecommerce\Refund\FindReturnAdvancePlugin
* @var \Yansongda\Pay\Plugin\Wechat\Ecommerce\Refund\QueryReturnAdvancePlugin
*/
protected $plugin;
@ -23,7 +23,7 @@ class FindReturnAdvancePluginTest extends TestCase
{
parent::setUp();
$this->plugin = new FindReturnAdvancePlugin();
$this->plugin = new QueryReturnAdvancePlugin();
}
public function testNotInServiceMode()

View File

@ -5,16 +5,16 @@ namespace Yansongda\Pay\Tests\Plugin\Wechat\Pay\Common;
use GuzzleHttp\Psr7\Uri;
use Psr\Http\Message\RequestInterface;
use Yansongda\Pay\Pay;
use Yansongda\Pay\Plugin\Wechat\Pay\Common\FindRefundPlugin;
use Yansongda\Pay\Plugin\Wechat\Pay\Common\QueryRefundPlugin;
use Yansongda\Pay\Provider\Wechat;
use Yansongda\Pay\Rocket;
use Yansongda\Pay\Tests\TestCase;
use Yansongda\Supports\Collection;
class FindRefundPluginTest extends TestCase
class QueryRefundPluginTest extends TestCase
{
/**
* @var \Yansongda\Pay\Plugin\Wechat\Pay\Common\FindRefundPlugin
* @var \Yansongda\Pay\Plugin\Wechat\Pay\Common\QueryRefundPlugin
*/
protected $plugin;
@ -22,7 +22,7 @@ class FindRefundPluginTest extends TestCase
{
parent::setUp();
$this->plugin = new FindRefundPlugin();
$this->plugin = new QueryRefundPlugin();
}
public function testNormal()

View File

@ -6,7 +6,7 @@ namespace Yansongda\Pay\Tests\Plugin\Wechat\Shortcut;
use Yansongda\Pay\Exception\Exception;
use Yansongda\Pay\Exception\InvalidParamsException;
use Yansongda\Pay\Plugin\Wechat\Pay\Common\FindRefundPlugin;
use Yansongda\Pay\Plugin\Wechat\Pay\Common\QueryRefundPlugin;
use Yansongda\Pay\Plugin\Wechat\Pay\Common\QueryPlugin;
use Yansongda\Pay\Plugin\Wechat\Shortcut\QueryShortcut;
use Yansongda\Pay\Tests\TestCase;
@ -32,7 +32,7 @@ class QueryShortcutTest extends TestCase
public function testRefund()
{
self::assertEquals([
FindRefundPlugin::class,
QueryRefundPlugin::class,
], $this->plugin->getPlugins(['_type' => 'refund']));
}