-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
15 changed files
with
219 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,8 @@ | ||
## v3.5.3-TBD | ||
## v3.5.3 | ||
|
||
### feat | ||
|
||
- feat: 增加支付宝 分账关系维护/分账查询 插件(#874) | ||
|
||
### optimized | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Yansongda\Pay\Plugin\Alipay\Trade; | ||
|
||
use Yansongda\Pay\Plugin\Alipay\GeneralPlugin; | ||
|
||
/** | ||
* @see https://opendocs.alipay.com/open/02pj6l?ref=api | ||
*/ | ||
class OrderSettleQueryPlugin extends GeneralPlugin | ||
{ | ||
protected function getMethod(): string | ||
{ | ||
return 'alipay.trade.order.settle.query'; | ||
} | ||
} |
18 changes: 18 additions & 0 deletions
18
src/Plugin/Alipay/Trade/RoyaltyRelationBatchQueryPlugin.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Yansongda\Pay\Plugin\Alipay\Trade; | ||
|
||
use Yansongda\Pay\Plugin\Alipay\GeneralPlugin; | ||
|
||
/** | ||
* @see https://opendocs.alipay.com/open/02c7hs?ref=api | ||
*/ | ||
class RoyaltyRelationBatchQueryPlugin extends GeneralPlugin | ||
{ | ||
protected function getMethod(): string | ||
{ | ||
return 'alipay.trade.royalty.relation.batchquery'; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Yansongda\Pay\Plugin\Alipay\Trade; | ||
|
||
use Yansongda\Pay\Plugin\Alipay\GeneralPlugin; | ||
|
||
/** | ||
* @see https://opendocs.alipay.com/open/02c7hq?ref=api | ||
*/ | ||
class RoyaltyRelationBindPlugin extends GeneralPlugin | ||
{ | ||
public function getMethod(): string | ||
{ | ||
return 'alipay.trade.royalty.relation.bind'; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Yansongda\Pay\Plugin\Alipay\Trade; | ||
|
||
use Yansongda\Pay\Plugin\Alipay\GeneralPlugin; | ||
|
||
/** | ||
* @see https://opendocs.alipay.com/open/02c7hr?ref=api | ||
*/ | ||
class RoyaltyRelationUnbindPlugin extends GeneralPlugin | ||
{ | ||
public function getMethod(): string | ||
{ | ||
return 'alipay.trade.royalty.relation.unbind'; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
<?php | ||
|
||
namespace Yansongda\Pay\Tests\Plugin\Alipay\Trade; | ||
|
||
use Yansongda\Pay\Direction\ResponseDirection; | ||
use Yansongda\Pay\Plugin\Alipay\Trade\AppPayPlugin; | ||
use Yansongda\Pay\Plugin\Alipay\Trade\OrderSettleQueryPlugin; | ||
use Yansongda\Pay\Rocket; | ||
use Yansongda\Pay\Tests\TestCase; | ||
|
||
class OrderSettleQueryPluginTest extends TestCase | ||
{ | ||
protected OrderSettleQueryPlugin $plugin; | ||
|
||
protected function setUp(): void | ||
{ | ||
parent::setUp(); | ||
|
||
$this->plugin = new OrderSettleQueryPlugin(); | ||
} | ||
|
||
public function testNormal() | ||
{ | ||
$rocket = new Rocket(); | ||
$rocket->setParams([]); | ||
|
||
$result = $this->plugin->assembly($rocket, function ($rocket) { return $rocket; }); | ||
|
||
self::assertStringContainsString('alipay.trade.order.settle.query', $result->getPayload()->toJson()); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
tests/Plugin/Alipay/Trade/RoyaltyRelationBatchQueryPluginTest.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
|
||
namespace Yansongda\Pay\Tests\Plugin\Alipay\Trade; | ||
|
||
use Yansongda\Pay\Plugin\Alipay\Trade\RoyaltyRelationBatchQueryPlugin; | ||
use Yansongda\Pay\Rocket; | ||
use Yansongda\Pay\Tests\TestCase; | ||
|
||
class RoyaltyRelationBatchQueryPluginTest extends TestCase | ||
{ | ||
protected RoyaltyRelationBatchQueryPlugin $plugin; | ||
|
||
protected function setUp(): void | ||
{ | ||
parent::setUp(); | ||
|
||
$this->plugin = new RoyaltyRelationBatchQueryPlugin(); | ||
} | ||
|
||
public function testNormal() | ||
{ | ||
$rocket = new Rocket(); | ||
$rocket->setParams([]); | ||
|
||
$result = $this->plugin->assembly($rocket, function ($rocket) { return $rocket; }); | ||
|
||
self::assertStringContainsString('alipay.trade.royalty.relation.batchquery', $result->getPayload()->toJson()); | ||
} | ||
} |
29 changes: 29 additions & 0 deletions
29
tests/Plugin/Alipay/Trade/RoyaltyRelationBindPluginTest.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
|
||
namespace Yansongda\Pay\Tests\Plugin\Alipay\Trade; | ||
|
||
use Yansongda\Pay\Plugin\Alipay\Trade\RoyaltyRelationBindPlugin; | ||
use Yansongda\Pay\Rocket; | ||
use Yansongda\Pay\Tests\TestCase; | ||
|
||
class RoyaltyRelationBindPluginTest extends TestCase | ||
{ | ||
protected RoyaltyRelationBindPlugin $plugin; | ||
|
||
protected function setUp(): void | ||
{ | ||
parent::setUp(); | ||
|
||
$this->plugin = new RoyaltyRelationBindPlugin(); | ||
} | ||
|
||
public function testNormal() | ||
{ | ||
$rocket = new Rocket(); | ||
$rocket->setParams([]); | ||
|
||
$result = $this->plugin->assembly($rocket, function ($rocket) { return $rocket; }); | ||
|
||
self::assertStringContainsString('alipay.trade.royalty.relation.bind', $result->getPayload()->toJson()); | ||
} | ||
} |
30 changes: 30 additions & 0 deletions
30
tests/Plugin/Alipay/Trade/RoyaltyRelationUnbindPluginTest.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<?php | ||
|
||
namespace Yansongda\Pay\Tests\Plugin\Alipay\Trade; | ||
|
||
use Yansongda\Pay\Plugin\Alipay\Trade\RoyaltyRelationBatchQueryPlugin; | ||
use Yansongda\Pay\Plugin\Alipay\Trade\RoyaltyRelationUnbindPlugin; | ||
use Yansongda\Pay\Rocket; | ||
use Yansongda\Pay\Tests\TestCase; | ||
|
||
class RoyaltyRelationUnbindPluginTest extends TestCase | ||
{ | ||
protected RoyaltyRelationUnbindPlugin $plugin; | ||
|
||
protected function setUp(): void | ||
{ | ||
parent::setUp(); | ||
|
||
$this->plugin = new RoyaltyRelationUnbindPlugin(); | ||
} | ||
|
||
public function testNormal() | ||
{ | ||
$rocket = new Rocket(); | ||
$rocket->setParams([]); | ||
|
||
$result = $this->plugin->assembly($rocket, function ($rocket) { return $rocket; }); | ||
|
||
self::assertStringContainsString('alipay.trade.royalty.relation.unbind', $result->getPayload()->toJson()); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters