- 1 :
(function(root, factory) {
- 2 :
if (typeof define === 'function' && define.amd) {
- 3 :
// AMD. Register as an anonymous module.
- 4 :
define(['ApiClient', 'models/FundingAccountAddress'], factory);
- 5 :
} else if (typeof module === 'object' && module.exports) {
- 6 :
// CommonJS-like environments that support module.exports, like Node.
- 7 :
module.exports = factory(require('../ApiClient'), require('./FundingAccountAddress'));
- 8 :
} else {
- 9 :
// Browser globals (root is window)
- 10 :
if (!root.OrbipayPaymentsapiClient) {
- 11 :
root.OrbipayPaymentsapiClient = {};
- 12 :
}
- 13 :
root.OrbipayPaymentsapiClient.AddFundingAccountRequest = factory(root.OrbipayPaymentsapiClient.ApiClient, root.OrbipayPaymentsapiClient.FundingAccountAddress);
- 14 :
}
- 15 :
}(this, function(ApiClient, FundingAccountAddress) {
- 16 :
'use strict';
- 17 :
- 18 :
- 19 :
- 20 :
- 21 :
/**
- 22 :
* The AddFundingAccountRequest model module.
- 23 :
* @module models/AddFundingAccountRequest
- 24 :
*/
- 25 :
- 26 :
/**
- 27 :
* <h3 style="color:red"> This class subject to change without prior notice, Please dont use this class directly. </h3>
- 28 :
- 29 :
* Constructs a new <code>AddFundingAccountRequest</code>.
- 30 :
* @alias module:models/AddFundingAccountRequest
- 31 :
* @class
- 32 :
* @param account_holder_name {String} The name as specified on the account.
- 33 :
* @param account_number {String} The number or reference that a customer uses to identify the funding account.
- 34 :
*/
- 35 :
var exports = function(account_holder_name, account_number) {
- 36 :
var _this = this;
- 37 :
- 38 :
_this['account_holder_name'] = account_holder_name;
- 39 :
- 40 :
- 41 :
_this['account_number'] = account_number;
- 42 :
- 43 :
- 44 :
- 45 :
- 46 :
- 47 :
- 48 :
- 49 :
};
- 50 :
- 51 :
/**
- 52 :
* Constructs a <code>AddFundingAccountRequest</code> from a plain JavaScript object, optionally creating a new instance.
- 53 :
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
- 54 :
* @param {Object} data The plain JavaScript object bearing properties of interest.
- 55 :
* @param {module:models/AddFundingAccountRequest} obj Optional instance to populate.
- 56 :
* @return {module:models/AddFundingAccountRequest} The populated <code>AddFundingAccountRequest</code> instance.
- 57 :
*/
- 58 :
exports.constructFromObject = function(data, obj) {
- 59 :
if (data) {
- 60 :
obj = obj || new exports();
- 61 :
- 62 :
if (data.hasOwnProperty('account_holder_name')) {
- 63 :
obj['account_holder_name'] = ApiClient.convertToType(data['account_holder_name'], 'String');
- 64 :
}
- 65 :
if (data.hasOwnProperty('nickname')) {
- 66 :
obj['nickname'] = ApiClient.convertToType(data['nickname'], 'String');
- 67 :
}
- 68 :
if (data.hasOwnProperty('address')) {
- 69 :
obj['address'] = FundingAccountAddress.constructFromObject(data['address']);
- 70 :
}
- 71 :
if (data.hasOwnProperty('account_number')) {
- 72 :
obj['account_number'] = ApiClient.convertToType(data['account_number'], 'String');
- 73 :
}
- 74 :
if (data.hasOwnProperty('aba_routing_number')) {
- 75 :
obj['aba_routing_number'] = ApiClient.convertToType(data['aba_routing_number'], 'String');
- 76 :
}
- 77 :
if (data.hasOwnProperty('expiry_date')) {
- 78 :
obj['expiry_date'] = ApiClient.convertToType(data['expiry_date'], 'String');
- 79 :
}
- 80 :
if (data.hasOwnProperty('account_holder_type')) {
- 81 :
obj['account_holder_type'] = ApiClient.convertToType(data['account_holder_type'], 'String');
- 82 :
}
- 83 :
if (data.hasOwnProperty('custom_fields')) {
- 84 :
obj['custom_fields'] = ApiClient.convertToType(data['custom_fields'], {'String': 'String'});
- 85 :
}
- 86 :
if (data.hasOwnProperty('account_subtype')) {
- 87 :
obj['account_subtype'] = ApiClient.convertToType(data['account_subtype'], 'String');
- 88 :
}
- 89 :
if (data.hasOwnProperty('card_cvv_number')) {
- 90 :
obj['card_cvv_number'] = ApiClient.convertToType(data['card_cvv_number'], 'String');
- 91 :
}
- 92 :
if (data.hasOwnProperty('comments')) {
- 93 :
obj['comments'] = ApiClient.convertToType(data['comments'], 'String');
- 94 :
}
- 95 :
}
- 96 :
return obj;
- 97 :
};
- 98 :
- 99 :
/**
- 100 :
* The name as specified on the account.
- 101 :
* @member {String} account_holder_name
- 102 :
*/
- 103 :
exports.prototype['account_holder_name'] = undefined;
- 104 :
/**
- 105 :
* The nickname by which a customer might want to identify the account.
- 106 :
* @member {String} nickname
- 107 :
*/
- 108 :
exports.prototype['nickname'] = undefined;
- 109 :
/**
- 110 :
* @member {module:models/FundingAccountAddress} address
- 111 :
*/
- 112 :
exports.prototype['address'] = undefined;
- 113 :
/**
- 114 :
* The number or reference that a customer uses to identify the funding account.
- 115 :
* @member {String} account_number
- 116 :
*/
- 117 :
exports.prototype['account_number'] = undefined;
- 118 :
/**
- 119 :
* The ABA/Routing number for the bank account.
- 120 :
* @member {String} aba_routing_number
- 121 :
*/
- 122 :
exports.prototype['aba_routing_number'] = undefined;
- 123 :
/**
- 124 :
* The expiry date for the card. This is to be in the format MM/YY.
- 125 :
* @member {String} expiry_date
- 126 :
*/
- 127 :
exports.prototype['expiry_date'] = undefined;
- 128 :
/**
- 129 :
* The type of ownership for the funding account.
- 130 :
* @member {module:models/AddFundingAccountRequest.AccountHolderTypeEnum} account_holder_type
- 131 :
*/
- 132 :
exports.prototype['account_holder_type'] = undefined;
- 133 :
/**
- 134 :
* The additional information or meta-information that EBPP can accept, maintain and transmit back to the client.
- 135 :
* @member {Object.<String, String>} custom_fields
- 136 :
*/
- 137 :
exports.prototype['custom_fields'] = undefined;
- 138 :
/**
- 139 :
* The sub type of the funding account.
- 140 :
* @member {module:models/AddFundingAccountRequest.AccountSubtypeEnum} account_subtype
- 141 :
*/
- 142 :
exports.prototype['account_subtype'] = undefined;
- 143 :
/**
- 144 :
* @member {String} card_cvv_number
- 145 :
*/
- 146 :
exports.prototype['card_cvv_number'] = undefined;
- 147 :
/**
- 148 :
* Comments that can be used to recollect the operation performed on the resource object.
- 149 :
* @member {String} comments
- 150 :
*/
- 151 :
exports.prototype['comments'] = undefined;
- 152 :
- 153 :
- 154 :
/**
- 155 :
* Allowed values for the <code>account_holder_type</code> property.
- 156 :
* @enum {String}
- 157 :
* @readonly
- 158 :
*/
- 159 :
exports.AccountHolderTypeEnum = {
- 160 :
/**
- 161 :
* value: "personal"
- 162 :
* @const
- 163 :
*/
- 164 :
"personal": "personal",
- 165 :
/**
- 166 :
* value: "business"
- 167 :
* @const
- 168 :
*/
- 169 :
"business": "business" };
- 170 :
- 171 :
/**
- 172 :
* Allowed values for the <code>account_subtype</code> property.
- 173 :
* @enum {String}
- 174 :
* @readonly
- 175 :
*/
- 176 :
exports.AccountSubtypeEnum = {
- 177 :
/**
- 178 :
* value: "savings"
- 179 :
* @const
- 180 :
*/
- 181 :
"savings": "savings",
- 182 :
/**
- 183 :
* value: "checking"
- 184 :
* @const
- 185 :
*/
- 186 :
"checking": "checking",
- 187 :
/**
- 188 :
* value: "money_market"
- 189 :
* @const
- 190 :
*/
- 191 :
"money_market": "money_market",
- 192 :
/**
- 193 :
* value: "visa_credit"
- 194 :
* @const
- 195 :
*/
- 196 :
"visa_credit": "visa_credit",
- 197 :
/**
- 198 :
* value: "mastercard_credit"
- 199 :
* @const
- 200 :
*/
- 201 :
"mastercard_credit": "mastercard_credit",
- 202 :
/**
- 203 :
* value: "american_express_credit"
- 204 :
* @const
- 205 :
*/
- 206 :
"american_express_credit": "american_express_credit",
- 207 :
/**
- 208 :
* value: "discover_credit"
- 209 :
* @const
- 210 :
*/
- 211 :
"discover_credit": "discover_credit",
- 212 :
/**
- 213 :
* value: "visa_debit"
- 214 :
* @const
- 215 :
*/
- 216 :
"visa_debit": "visa_debit",
- 217 :
/**
- 218 :
* value: "mastercard_debit"
- 219 :
* @const
- 220 :
*/
- 221 :
"mastercard_debit": "mastercard_debit",
- 222 :
/**
- 223 :
* value: "discover_debit"
- 224 :
* @const
- 225 :
*/
- 226 :
"discover_debit": "discover_debit",
- 227 :
/**
- 228 :
* value: "voyager_fleet"
- 229 :
* @const
- 230 :
*/
- 231 :
"voyager_fleet": "voyager_fleet" };
- 232 :
- 233 :
- 234 :
return exports;
- 235 :
}));
- 236 :
- 237 :