Skip to content

Commit 2ea5541

Browse files
add updates
1 parent 6c1111b commit 2ea5541

4 files changed

Lines changed: 1938 additions & 0 deletions

File tree

src/Invoice/ChangeLog.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
2019-09-10 version: 0.4.0
2+
2019-09-18 change type name
3+
2019-12-03 add getCompanyCreditInfo interface
4+
2023-01-30 0.4.3 poc 增加使用人、支付人信息
5+
2023-12-18 0.4.7 支持月账单开票
6+
2024-07-24 0.4.10 对外sdk发布

src/Invoice/InvoiceClient.php

Lines changed: 120 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,120 @@
1+
<?php
2+
/**
3+
* Invoice
4+
*
5+
* @category Jdcloud
6+
* @package Jdcloud\Invoice
7+
* @author Jdcloud <jdcloud-api@jd.com>
8+
* @license Apache-2.0 http://www.apache.org/licenses/LICENSE-2.0
9+
* @link https://www.jdcloud.com/help/faq
10+
*/
11+
12+
namespace Jdcloud\Invoice;
13+
14+
use Jdcloud\JdCloudClient;
15+
use Jdcloud\Api\Service;
16+
use Jdcloud\Api\DocModel;
17+
use Jdcloud\Api\ApiProvider;
18+
use Jdcloud\PresignUrlMiddleware;
19+
20+
/**
21+
* Client used to interact with invoice.
22+
*
23+
* @method \Jdcloud\Result describeAddresses(array $args = [])
24+
* @method \GuzzleHttp\Promise\Promise describeAddressesAsync(array $args = [])
25+
* @method \Jdcloud\Result describeChildrenArea(array $args = [])
26+
* @method \GuzzleHttp\Promise\Promise describeChildrenAreaAsync(array $args = [])
27+
* @method \Jdcloud\Result describeAddress(array $args = [])
28+
* @method \GuzzleHttp\Promise\Promise describeAddressAsync(array $args = [])
29+
* @method \Jdcloud\Result modifyAddress(array $args = [])
30+
* @method \GuzzleHttp\Promise\Promise modifyAddressAsync(array $args = [])
31+
* @method \Jdcloud\Result deleteAddress(array $args = [])
32+
* @method \GuzzleHttp\Promise\Promise deleteAddressAsync(array $args = [])
33+
* @method \Jdcloud\Result createAddress(array $args = [])
34+
* @method \GuzzleHttp\Promise\Promise createAddressAsync(array $args = [])
35+
* @method \Jdcloud\Result describeInvoiceOrderList(array $args = [])
36+
* @method \GuzzleHttp\Promise\Promise describeInvoiceOrderListAsync(array $args = [])
37+
* @method \Jdcloud\Result createInvoiceAgent(array $args = [])
38+
* @method \GuzzleHttp\Promise\Promise createInvoiceAgentAsync(array $args = [])
39+
* @method \Jdcloud\Result editInvoiceTemplate(array $args = [])
40+
* @method \GuzzleHttp\Promise\Promise editInvoiceTemplateAsync(array $args = [])
41+
* @method \Jdcloud\Result decribeInvoicedChildOrders(array $args = [])
42+
* @method \GuzzleHttp\Promise\Promise decribeInvoicedChildOrdersAsync(array $args = [])
43+
* @method \Jdcloud\Result describeInvoices(array $args = [])
44+
* @method \GuzzleHttp\Promise\Promise describeInvoicesAsync(array $args = [])
45+
* @method \Jdcloud\Result describeInvoice(array $args = [])
46+
* @method \GuzzleHttp\Promise\Promise describeInvoiceAsync(array $args = [])
47+
* @method \Jdcloud\Result billDetail(array $args = [])
48+
* @method \GuzzleHttp\Promise\Promise billDetailAsync(array $args = [])
49+
* @method \Jdcloud\Result getCompanyCreditInfo(array $args = [])
50+
* @method \GuzzleHttp\Promise\Promise getCompanyCreditInfoAsync(array $args = [])
51+
* @method \Jdcloud\Result getOrderRelateInvoice(array $args = [])
52+
* @method \GuzzleHttp\Promise\Promise getOrderRelateInvoiceAsync(array $args = [])
53+
* @method \Jdcloud\Result getOrderRelateInfo(array $args = [])
54+
* @method \GuzzleHttp\Promise\Promise getOrderRelateInfoAsync(array $args = [])
55+
* @method \Jdcloud\Result createInvoice(array $args = [])
56+
* @method \GuzzleHttp\Promise\Promise createInvoiceAsync(array $args = [])
57+
* @method \Jdcloud\Result refundInvoice(array $args = [])
58+
* @method \GuzzleHttp\Promise\Promise refundInvoiceAsync(array $args = [])
59+
* @method \Jdcloud\Result artificialRefund(array $args = [])
60+
* @method \GuzzleHttp\Promise\Promise artificialRefundAsync(array $args = [])
61+
* @method \Jdcloud\Result cancelInvoice(array $args = [])
62+
* @method \GuzzleHttp\Promise\Promise cancelInvoiceAsync(array $args = [])
63+
* @method \Jdcloud\Result describeInvoiceUrl(array $args = [])
64+
* @method \GuzzleHttp\Promise\Promise describeInvoiceUrlAsync(array $args = [])
65+
* @method \Jdcloud\Result describeInvoiceOrders(array $args = [])
66+
* @method \GuzzleHttp\Promise\Promise describeInvoiceOrdersAsync(array $args = [])
67+
* @method \Jdcloud\Result invoiceOweList(array $args = [])
68+
* @method \GuzzleHttp\Promise\Promise invoiceOweListAsync(array $args = [])
69+
* @method \Jdcloud\Result deductOweFee(array $args = [])
70+
* @method \GuzzleHttp\Promise\Promise deductOweFeeAsync(array $args = [])
71+
* @method \Jdcloud\Result getTaxInfo(array $args = [])
72+
* @method \GuzzleHttp\Promise\Promise getTaxInfoAsync(array $args = [])
73+
* @method \Jdcloud\Result getInvoicePreview(array $args = [])
74+
* @method \GuzzleHttp\Promise\Promise getInvoicePreviewAsync(array $args = [])
75+
* @method \Jdcloud\Result calculateInvoicePrice(array $args = [])
76+
* @method \GuzzleHttp\Promise\Promise calculateInvoicePriceAsync(array $args = [])
77+
* @method \Jdcloud\Result describeMonthDetail(array $args = [])
78+
* @method \GuzzleHttp\Promise\Promise describeMonthDetailAsync(array $args = [])
79+
* @method \Jdcloud\Result describeInvoiceTemplate(array $args = [])
80+
* @method \GuzzleHttp\Promise\Promise describeInvoiceTemplateAsync(array $args = [])
81+
* @method \Jdcloud\Result createInvoiceTemplate(array $args = [])
82+
* @method \GuzzleHttp\Promise\Promise createInvoiceTemplateAsync(array $args = [])
83+
* @method \Jdcloud\Result modifyInvoiceTemplate(array $args = [])
84+
* @method \GuzzleHttp\Promise\Promise modifyInvoiceTemplateAsync(array $args = [])
85+
* @method \Jdcloud\Result deleteInvoiceTemplate(array $args = [])
86+
* @method \GuzzleHttp\Promise\Promise deleteInvoiceTemplateAsync(array $args = [])
87+
* @method \Jdcloud\Result checkInvoiceOwedInfo(array $args = [])
88+
* @method \GuzzleHttp\Promise\Promise checkInvoiceOwedInfoAsync(array $args = [])
89+
* @method \Jdcloud\Result batchUpdateInvoiceRefundOrder(array $args = [])
90+
* @method \GuzzleHttp\Promise\Promise batchUpdateInvoiceRefundOrderAsync(array $args = [])
91+
* @method \Jdcloud\Result refundOwedInvoice(array $args = [])
92+
* @method \GuzzleHttp\Promise\Promise refundOwedInvoiceAsync(array $args = [])
93+
* @method \Jdcloud\Result describeOrderInvoice(array $args = [])
94+
* @method \GuzzleHttp\Promise\Promise describeOrderInvoiceAsync(array $args = [])
95+
* @method \Jdcloud\Result updateInvoiceRefundAmount(array $args = [])
96+
* @method \GuzzleHttp\Promise\Promise updateInvoiceRefundAmountAsync(array $args = [])
97+
*/
98+
class InvoiceClient extends JdCloudClient
99+
{
100+
public function __construct(array $args)
101+
{
102+
$args['with_resolved'] = function (array $args) {
103+
$this->getHandlerList()->appendInit(
104+
PresignUrlMiddleware::wrap(
105+
$this,
106+
$args['endpoint_provider'],
107+
[
108+
'operations' => [
109+
],
110+
'service' => 'invoice',
111+
'presign_param' => 'PresignedUrl',
112+
]
113+
),
114+
'invoice'
115+
);
116+
};
117+
118+
parent::__construct($args);
119+
}
120+
}

0 commit comments

Comments
 (0)