|
6 | 6 |
|
7 | 7 | class BkashPayment |
8 | 8 | { |
9 | | - private PaymentService $checkoutUrl; |
| 9 | + private PaymentService $paymentService; |
10 | 10 |
|
11 | 11 | public function __construct() |
12 | 12 | { |
13 | | - $this->checkoutUrl = new PaymentService(); |
| 13 | + $this->paymentService = new PaymentService(); |
14 | 14 | } |
15 | 15 |
|
16 | 16 | public function create($request = []) |
17 | 17 | { |
18 | | - return $this->checkoutUrl->createPayment($request); |
| 18 | + return $this->paymentService->createPayment($request); |
19 | 19 | } |
20 | 20 |
|
21 | 21 | public function execute($paymentID) |
22 | 22 | { |
23 | | - return $this->checkoutUrl->executePayment($paymentID); |
| 23 | + return $this->paymentService->executePayment($paymentID); |
24 | 24 | } |
25 | 25 |
|
26 | 26 | public function verify($paymentID) |
27 | 27 | { |
28 | | - return $this->checkoutUrl->verifyPayment($paymentID); |
| 28 | + return $this->paymentService->verifyPayment($paymentID); |
29 | 29 | } |
30 | 30 |
|
31 | 31 | public function query($paymentID) |
32 | 32 | { |
33 | | - return $this->checkoutUrl->queryPayment($paymentID); |
| 33 | + return $this->paymentService->queryPayment($paymentID); |
34 | 34 | } |
35 | 35 |
|
36 | 36 | public function search($trxID) |
37 | 37 | { |
38 | | - return $this->checkoutUrl->searchTransaction($trxID); |
| 38 | + return $this->paymentService->searchTransaction($trxID); |
39 | 39 | } |
40 | 40 |
|
41 | 41 | public function refund($paymentID, $trxID, $amount) |
42 | 42 | { |
43 | | - return $this->checkoutUrl->refundTransaction($paymentID, $trxID, $amount); |
| 43 | + return $this->paymentService->refundTransaction($paymentID, $trxID, $amount); |
44 | 44 | } |
45 | 45 |
|
46 | 46 | public function capture($paymentID) |
47 | 47 | { |
48 | | - return $this->checkoutUrl->capturePayment($paymentID); |
| 48 | + return $this->paymentService->capturePayment($paymentID); |
49 | 49 | } |
50 | 50 |
|
51 | 51 | public function void($paymentID) |
52 | 52 | { |
53 | | - return $this->checkoutUrl->voidPayment($paymentID); |
| 53 | + return $this->paymentService->voidPayment($paymentID); |
54 | 54 | } |
55 | 55 |
|
56 | 56 | public function failed($message) |
57 | 57 | { |
58 | | - return $this->checkoutUrl->failed($message); |
| 58 | + return $this->paymentService->failed($message); |
59 | 59 | } |
60 | 60 |
|
61 | 61 | public function success($txrID) |
62 | 62 | { |
63 | | - return $this->checkoutUrl->success($txrID); |
| 63 | + return $this->paymentService->success($txrID); |
64 | 64 | } |
65 | 65 |
|
66 | 66 | } |
0 commit comments