Merge pull request #460 from yansongda/v3.0

fix: #453
This commit is contained in:
yansongda 2021-07-25 14:58:28 +08:00 committed by GitHub
commit c3bd92ef75
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 36 additions and 0 deletions

View File

@ -0,0 +1,15 @@
<?php
declare(strict_types=1);
namespace Yansongda\Pay\Plugin\Alipay\Fund;
use Yansongda\Pay\Plugin\Alipay\GeneralPlugin;
class TransCommonQueryPlugin extends GeneralPlugin
{
protected function getMethod(): string
{
return 'alipay.fund.trans.common.query';
}
}

View File

@ -0,0 +1,15 @@
<?php
declare(strict_types=1);
namespace Yansongda\Pay\Plugin\Alipay\Fund;
use Yansongda\Pay\Plugin\Alipay\GeneralPlugin;
class TransTobankTransferPlugin extends GeneralPlugin
{
protected function getMethod(): string
{
return 'alipay.fund.trans.tobank.transfer';
}
}

View File

@ -20,10 +20,16 @@ abstract class GeneralPlugin implements PluginInterface
'biz_content' => $rocket->getParams(),
]);
$this->doSomething($rocket);
Logger::info('[alipay][GeneralPlugin] 通用插件装载完毕', ['rocket' => $rocket]);
return $next($rocket);
}
protected function doSomething(Rocket $rocket): void
{
}
abstract protected function getMethod(): string;
}