-
Notifications
You must be signed in to change notification settings - Fork 17
/
Wallet.php
124 lines (104 loc) · 2.37 KB
/
Wallet.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
<?php
namespace LemonWay\Models;
class Wallet
{
const MISTER = 'M';
const MADAM = 'F';
const JOINT = 'J';
const UNKNOWN = 'U';
const AUTO_COMMISSION = '1';
const NO_AUTO_COMMISSION = '0';
const ATOS_PRE_AUTH = '1';
const NO_ATOS_PRE_AUTH = '0';
const WALLET_BLOCKED = '1';
const WALLET_NOT_BLOCKED = '0';
const STATUS_KYC_1 = '5';
const STATUS_KYC_2 = '6';
const STATUS_CLOSED = '12';
/**
* ID as defined by merchant
* @var string
*/
public $ID;
/**
* LWID number ID as defined by Lemon Way
* @var string
*/
public $LWID;
/**
* STATUS {2,3,4,5,6,7,8,12}
* @var string
*/
public $STATUS;
/**
* BAL balance
* @var string
*/
public $BAL;
/**
* NAME full name
* @var string
*/
public $NAME;
/**
* EMAIL
* @var string
*/
public $EMAIL;
/**
* BLOCKED {0,1}
* @var string
*/
public $BLOCKED;
/**
* kycDocs
* @var array KycDoc
*/
public $kycDocs;
/**
* ibans
* @var array Iban
*/
public $ibans;
/**
* sddMandates
* @var array SddMandate
*/
public $sddMandates;
/**
* cards
* @var array Card
*/
public $cards;
function __construct($WALLET)
{
$this->ID = $WALLET->ID;
$this->LWID = $WALLET->LWID;
$this->STATUS = $WALLET->STATUS;
$this->BAL = $WALLET->BAL;
$this->NAME = $WALLET->NAME;
$this->EMAIL = $WALLET->EMAIL;
$this->BLOCKED = $WALLET->BLOCKED;
$this->kycDocs = array();
if (isset($WALLET->DOCS))
foreach ($WALLET->DOCS->DOC as $DOC) {
$this->kycDocs[] = new KycDoc($DOC);
}
$this->ibans = array();
if (isset($WALLET->IBANS))
foreach ($WALLET->IBANS->IBAN as $IBAN) {
$this->ibans[] = new Iban($IBAN);
}
$this->sddMandates = array();
if (isset($WALLET->SDDMANDATES))
foreach ($WALLET->SDDMANDATES->SDDMANDATE as $SDDMANDATE) {
$this->sddMandates[] = new SddMandate($SDDMANDATE);
}
$this->cards = array();
if (isset($WALLET->CARDS))
foreach ($WALLET->CARDS->CARD as $CARD) {
$this->cards[] = new Card($CARD);
}
}
}
?>