1. 1 : (function(root, factory) {
  2. 2 : if (typeof define === 'function' && define.amd) {
  3. 3 : // AMD. Register as an anonymous module.
  4. 4 : define(['ApiClient', 'models/AddressVo'], factory);
  5. 5 : } else if (typeof module === 'object' && module.exports) {
  6. 6 : // CommonJS-like environments that support module.exports, like Node.
  7. 7 : module.exports = factory(require('../ApiClient'), require('./AddressVo'));
  8. 8 : } else {
  9. 9 : // Browser globals (root is window)
  10. 10 : if (!root.OrbipayPaymentsapiClient) {
  11. 11 : root.OrbipayPaymentsapiClient = {};
  12. 12 : }
  13. 13 : root.OrbipayPaymentsapiClient.CreateCustomerAccountRequest = factory(root.OrbipayPaymentsapiClient.ApiClient, root.OrbipayPaymentsapiClient.AddressVo);
  14. 14 : }
  15. 15 : }(this, function(ApiClient, AddressVo) {
  16. 16 : 'use strict';
  17. 17 :
  18. 18 :
  19. 19 :
  20. 20 :
  21. 21 : /**
  22. 22 : * The CreateCustomerAccountRequest model module.
  23. 23 : * @module models/CreateCustomerAccountRequest
  24. 24 : */
  25. 25 :
  26. 26 : /**
  27. 27 : * <h3 style="color:red"> This class subject to change without prior notice, Please dont use this class directly. </h3>
  28. 28 :
  29. 29 : * Constructs a new <code>CreateCustomerAccountRequest</code>.
  30. 30 : * @alias module:models/CreateCustomerAccountRequest
  31. 31 : * @class
  32. 32 : * @param account_holder_name {String} The name as specified on the account.
  33. 33 : * @param account_number {String} The number or reference that a customer uses to identify the customer's account.
  34. 34 : */
  35. 35 : var exports = function(account_holder_name, account_number) {
  36. 36 : var _this = this;
  37. 37 :
  38. 38 : _this['account_holder_name'] = account_holder_name;
  39. 39 :
  40. 40 :
  41. 41 :
  42. 42 : _this['account_number'] = account_number;
  43. 43 :
  44. 44 :
  45. 45 :
  46. 46 :
  47. 47 :
  48. 48 :
  49. 49 :
  50. 50 :
  51. 51 : };
  52. 52 :
  53. 53 : /**
  54. 54 : * Constructs a <code>CreateCustomerAccountRequest</code> from a plain JavaScript object, optionally creating a new instance.
  55. 55 : * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
  56. 56 : * @param {Object} data The plain JavaScript object bearing properties of interest.
  57. 57 : * @param {module:models/CreateCustomerAccountRequest} obj Optional instance to populate.
  58. 58 : * @return {module:models/CreateCustomerAccountRequest} The populated <code>CreateCustomerAccountRequest</code> instance.
  59. 59 : */
  60. 60 : exports.constructFromObject = function(data, obj) {
  61. 61 : if (data) {
  62. 62 : obj = obj || new exports();
  63. 63 :
  64. 64 : if (data.hasOwnProperty('account_holder_name')) {
  65. 65 : obj['account_holder_name'] = ApiClient.convertToType(data['account_holder_name'], 'String');
  66. 66 : }
  67. 67 : if (data.hasOwnProperty('nickname')) {
  68. 68 : obj['nickname'] = ApiClient.convertToType(data['nickname'], 'String');
  69. 69 : }
  70. 70 : if (data.hasOwnProperty('address')) {
  71. 71 : obj['address'] = AddressVo.constructFromObject(data['address']);
  72. 72 : }
  73. 73 : if (data.hasOwnProperty('customer_account_reference')) {
  74. 74 : obj['customer_account_reference'] = ApiClient.convertToType(data['customer_account_reference'], 'String');
  75. 75 : }
  76. 76 : if (data.hasOwnProperty('account_number')) {
  77. 77 : obj['account_number'] = ApiClient.convertToType(data['account_number'], 'String');
  78. 78 : }
  79. 79 : if (data.hasOwnProperty('current_balance')) {
  80. 80 : obj['current_balance'] = ApiClient.convertToType(data['current_balance'], 'String');
  81. 81 : }
  82. 82 : if (data.hasOwnProperty('current_statement_balance')) {
  83. 83 : obj['current_statement_balance'] = ApiClient.convertToType(data['current_statement_balance'], 'String');
  84. 84 : }
  85. 85 : if (data.hasOwnProperty('minimum_payment_due')) {
  86. 86 : obj['minimum_payment_due'] = ApiClient.convertToType(data['minimum_payment_due'], 'String');
  87. 87 : }
  88. 88 : if (data.hasOwnProperty('past_amount_due')) {
  89. 89 : obj['past_amount_due'] = ApiClient.convertToType(data['past_amount_due'], 'String');
  90. 90 : }
  91. 91 : if (data.hasOwnProperty('payment_due_date')) {
  92. 92 : obj['payment_due_date'] = ApiClient.convertToType(data['payment_due_date'], 'String');
  93. 93 : }
  94. 94 : if (data.hasOwnProperty('statement_date')) {
  95. 95 : obj['statement_date'] = ApiClient.convertToType(data['statement_date'], 'String');
  96. 96 : }
  97. 97 : if (data.hasOwnProperty('status')) {
  98. 98 : obj['status'] = ApiClient.convertToType(data['status'], 'String');
  99. 99 : }
  100. 100 : if (data.hasOwnProperty('custom_fields')) {
  101. 101 : obj['custom_fields'] = ApiClient.convertToType(data['custom_fields'], {'String': 'String'});
  102. 102 : }
  103. 103 : }
  104. 104 : return obj;
  105. 105 : };
  106. 106 :
  107. 107 : /**
  108. 108 : * The name as specified on the account.
  109. 109 : * @member {String} account_holder_name
  110. 110 : */
  111. 111 : exports.prototype['account_holder_name'] = undefined;
  112. 112 : /**
  113. 113 : * The nickname by which a customer might want to identify the account.
  114. 114 : * @member {String} nickname
  115. 115 : */
  116. 116 : exports.prototype['nickname'] = undefined;
  117. 117 : /**
  118. 118 : * @member {module:models/AddressVo} address
  119. 119 : */
  120. 120 : exports.prototype['address'] = undefined;
  121. 121 : /**
  122. 122 : * The unique identifier in the client system for the customer account.
  123. 123 : * @member {String} customer_account_reference
  124. 124 : */
  125. 125 : exports.prototype['customer_account_reference'] = undefined;
  126. 126 : /**
  127. 127 : * The number or reference that a customer uses to identify the customer's account.
  128. 128 : * @member {String} account_number
  129. 129 : */
  130. 130 : exports.prototype['account_number'] = undefined;
  131. 131 : /**
  132. 132 : * The current balance on the customer's account with the biller.
  133. 133 : * @member {String} current_balance
  134. 134 : */
  135. 135 : exports.prototype['current_balance'] = undefined;
  136. 136 : /**
  137. 137 : * The balance on the customer’s account with the biller as reported on the last statement.
  138. 138 : * @member {String} current_statement_balance
  139. 139 : */
  140. 140 : exports.prototype['current_statement_balance'] = undefined;
  141. 141 : /**
  142. 142 : * The minimum payment amount, as specified by the biller, that needs to be made against the customer’s account.
  143. 143 : * @member {String} minimum_payment_due
  144. 144 : */
  145. 145 : exports.prototype['minimum_payment_due'] = undefined;
  146. 146 : /**
  147. 147 : * The amount that is due from the past bills/statements on the customer’s account with the biller.
  148. 148 : * @member {String} past_amount_due
  149. 149 : */
  150. 150 : exports.prototype['past_amount_due'] = undefined;
  151. 151 : /**
  152. 152 : * The date by which the customer needs to clear the dues against the customer's account with the biller. It must be in ISO8601 full-date format, namely, YYYY-MM-DD.
  153. 153 : * @member {String} payment_due_date
  154. 154 : */
  155. 155 : exports.prototype['payment_due_date'] = undefined;
  156. 156 : /**
  157. 157 : * The date on which the biller generates the statement for the customer's account. It must be in ISO8601 full-date format, namely, YYYY-MM-DD.
  158. 158 : * @member {String} statement_date
  159. 159 : */
  160. 160 : exports.prototype['statement_date'] = undefined;
  161. 161 : /**
  162. 162 : * The status of the customer's account in EBPP and it is defaults to active.
  163. 163 : * @member {module:models/CreateCustomerAccountRequest.StatusEnum} status
  164. 164 : */
  165. 165 : exports.prototype['status'] = undefined;
  166. 166 : /**
  167. 167 : * The additional information or meta-information that EBPP can accept, maintain and transmit back to the client.
  168. 168 : * @member {Object.<String, String>} custom_fields
  169. 169 : */
  170. 170 : exports.prototype['custom_fields'] = undefined;
  171. 171 :
  172. 172 :
  173. 173 : /**
  174. 174 : * Allowed values for the <code>status</code> property.
  175. 175 : * @enum {String}
  176. 176 : * @readonly
  177. 177 : */
  178. 178 : exports.StatusEnum = {
  179. 179 : /**
  180. 180 : * value: "active"
  181. 181 : * @const
  182. 182 : */
  183. 183 : "active": "active",
  184. 184 : /**
  185. 185 : * value: "inactive"
  186. 186 : * @const
  187. 187 : */
  188. 188 : "inactive": "inactive",
  189. 189 : /**
  190. 190 : * value: "incollections"
  191. 191 : * @const
  192. 192 : */
  193. 193 : "incollections": "incollections",
  194. 194 : /**
  195. 195 : * value: "inbankruptcy"
  196. 196 : * @const
  197. 197 : */
  198. 198 : "inbankruptcy": "inbankruptcy" };
  199. 199 :
  200. 200 :
  201. 201 : return exports;
  202. 202 : }));
  203. 203 :
  204. 204 :