File tree 3 files changed +39
-0
lines changed
3 files changed +39
-0
lines changed Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ require_once ('config/sample_config.php ' );
4
+
5
+ use Craftgate \Model \ApmType ;
6
+ use Craftgate \Model \Currency ;
7
+ use Craftgate \Model \PaymentGroup ;
8
+ use Craftgate \Util \Guid ;
9
+
10
+ $ request = array (
11
+ 'apmType ' => ApmType::PAYLANDS_MB_WAY ,
12
+ 'price ' => 1 ,
13
+ 'paidPrice ' => 1 ,
14
+ 'currency ' => Currency::EUR ,
15
+ 'paymentGroup ' => PaymentGroup::LISTING_OR_SUBSCRIPTION ,
16
+ 'conversationId ' => 'conversationId ' ,
17
+ 'externalId ' => 'externalId ' ,
18
+ 'items ' => array (
19
+ array (
20
+ 'externalId ' => Guid::generate (),
21
+ 'name ' => 'Item 1 ' ,
22
+ 'price ' => 0.40
23
+ ),
24
+ array (
25
+ 'externalId ' => Guid::generate (),
26
+ 'name ' => 'Item 2 ' ,
27
+ 'price ' => 0.60
28
+ )
29
+ ),
30
+ 'additionalParams ' => array (
31
+ 'buyerPhoneNumber ' => "34700000000 " ,
32
+ )
33
+ );
34
+
35
+ $ response = SampleConfig::craftgate ()->payment ()->initApmPayment ($ request );
36
+
37
+ print_r ($ response );
Original file line number Diff line number Diff line change @@ -35,6 +35,7 @@ class ApmType
35
35
const VODAFONE_DCB = "VODAFONE_DCB " ;
36
36
const PAYMOB = "PAYMOB " ;
37
37
const BIZUM = "BIZUM " ;
38
+ const PAYLANDS_MB_WAY = "PAYLANDS_MB_WAY " ;
38
39
const PAYCELL_DCB = "PAYCELL_DCB " ;
39
40
const IWALLET = "IWALLET " ;
40
41
const FUND_TRANSFER = 'FUND_TRANSFER ' ;
Original file line number Diff line number Diff line change @@ -38,6 +38,7 @@ class PaymentProvider
38
38
const VODAFONE = "VODAFONE " ;
39
39
const PAYMOB = "PAYMOB " ;
40
40
const BIZUM = "BIZUM " ;
41
+ const PAYLANDS_MB_WAY = "PAYLANDS_MB_WAY " ;
41
42
const PAYCELL_DCB = "PAYCELL_DCB " ;
42
43
const IWALLET = "IWALLET " ;
43
44
const OFFLINE = "OFFLINE " ;
You can’t perform that action at this time.
0 commit comments