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/FeeRequest', 'models/UpdatePaymentFundingAccountMinimalRequest'], 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('./FeeRequest'), require('./UpdatePaymentFundingAccountMinimalRequest'));
  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.UpdatePaymentRequest = factory(root.OrbipayPaymentsapiClient.ApiClient, root.OrbipayPaymentsapiClient.FeeRequest, root.OrbipayPaymentsapiClient.UpdatePaymentFundingAccountMinimalRequest);
  14. 14 : }
  15. 15 : }(this, function(ApiClient, FeeRequest, UpdatePaymentFundingAccountMinimalRequest) {
  16. 16 : 'use strict';
  17. 17 :
  18. 18 :
  19. 19 :
  20. 20 :
  21. 21 : /**
  22. 22 : * The UpdatePaymentRequest model module.
  23. 23 : * @module models/UpdatePaymentRequest
  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>UpdatePaymentRequest</code>.
  30. 30 : * @alias module:models/UpdatePaymentRequest
  31. 31 : * @class
  32. 32 : */
  33. 33 : var exports = function() {
  34. 34 : var _this = this;
  35. 35 :
  36. 36 :
  37. 37 :
  38. 38 :
  39. 39 :
  40. 40 :
  41. 41 :
  42. 42 :
  43. 43 :
  44. 44 :
  45. 45 : };
  46. 46 :
  47. 47 : /**
  48. 48 : * Constructs a <code>UpdatePaymentRequest</code> from a plain JavaScript object, optionally creating a new instance.
  49. 49 : * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
  50. 50 : * @param {Object} data The plain JavaScript object bearing properties of interest.
  51. 51 : * @param {module:models/UpdatePaymentRequest} obj Optional instance to populate.
  52. 52 : * @return {module:models/UpdatePaymentRequest} The populated <code>UpdatePaymentRequest</code> instance.
  53. 53 : */
  54. 54 : exports.constructFromObject = function(data, obj) {
  55. 55 : if (data) {
  56. 56 : obj = obj || new exports();
  57. 57 :
  58. 58 : if (data.hasOwnProperty('comments')) {
  59. 59 : obj['comments'] = ApiClient.convertToType(data['comments'], 'String');
  60. 60 : }
  61. 61 : if (data.hasOwnProperty('custom_fields')) {
  62. 62 : obj['custom_fields'] = ApiClient.convertToType(data['custom_fields'], {'String': 'String'});
  63. 63 : }
  64. 64 : if (data.hasOwnProperty('fee')) {
  65. 65 : obj['fee'] = FeeRequest.constructFromObject(data['fee']);
  66. 66 : }
  67. 67 : if (data.hasOwnProperty('amount')) {
  68. 68 : obj['amount'] = ApiClient.convertToType(data['amount'], 'String');
  69. 69 : }
  70. 70 : if (data.hasOwnProperty('card_cvv_number')) {
  71. 71 : obj['card_cvv_number'] = ApiClient.convertToType(data['card_cvv_number'], 'String');
  72. 72 : }
  73. 73 : if (data.hasOwnProperty('payment_date')) {
  74. 74 : obj['payment_date'] = ApiClient.convertToType(data['payment_date'], 'String');
  75. 75 : }
  76. 76 : if (data.hasOwnProperty('payment_request_date')) {
  77. 77 : obj['payment_request_date'] = ApiClient.convertToType(data['payment_request_date'], 'String');
  78. 78 : }
  79. 79 : if (data.hasOwnProperty('payment_amount_type')) {
  80. 80 : obj['payment_amount_type'] = ApiClient.convertToType(data['payment_amount_type'], 'String');
  81. 81 : }
  82. 82 : if (data.hasOwnProperty('funding_account')) {
  83. 83 : obj['funding_account'] = UpdatePaymentFundingAccountMinimalRequest.constructFromObject(data['funding_account']);
  84. 84 : }
  85. 85 : }
  86. 86 : return obj;
  87. 87 : };
  88. 88 :
  89. 89 : /**
  90. 90 : * Comments that can be used to recollect the operation performed on the resource object. API clients need to ensure that no sensitive information is passed in the memo. Alacriti (EBPP) is not responsible for the security of any sensitive information that may be passed as part of the memo.
  91. 91 : * @member {String} comments
  92. 92 : */
  93. 93 : exports.prototype['comments'] = undefined;
  94. 94 : /**
  95. 95 : * The additional information or meta-information that EBPP can accept, maintain and transmit back to the client. The custom fields need to be configured with EBPP before they can be accepted. EBPP would reject custom fields that are not pre-configured. Please contact <a href = \"mailto: support@billerpayments.com\">support@billerpayments.com</a> for more information on configuring and using custom fields. Only the custom fields enabled for the client, in EBPP, would be accepted in the requests.
  96. 96 : * @member {Object.<String, String>} custom_fields
  97. 97 : */
  98. 98 : exports.prototype['custom_fields'] = undefined;
  99. 99 : /**
  100. 100 : * @member {module:models/FeeRequest} fee
  101. 101 : */
  102. 102 : exports.prototype['fee'] = undefined;
  103. 103 : /**
  104. 104 : * The amount being paid. In case the payment_amount_type is 'discounted_amount', 'penalty_amount' or 'other', the amount needs to be specified. In other cases, this is derived from the payment_amount_type.
  105. 105 : * @member {String} amount
  106. 106 : */
  107. 107 : exports.prototype['amount'] = undefined;
  108. 108 : /**
  109. 109 : * This is never returned by EBPP. This needs to be passed to EBPP when making or editing a payment with a card funding account.
  110. 110 : * @member {String} card_cvv_number
  111. 111 : */
  112. 112 : exports.prototype['card_cvv_number'] = undefined;
  113. 113 : /**
  114. 114 : * The date on which the payment is scheduled to be made. It must be in ISO8601 full-date format, namely, YYYY-MM-DD.
  115. 115 : * @member {String} payment_date
  116. 116 : */
  117. 117 : exports.prototype['payment_date'] = undefined;
  118. 118 : /**
  119. 119 : * The date on which the biller wants the payment to be settled. It must be in ISO8601 full-date format, namely, YYYY-MM-DD. This is applicable only if the client has opted for it.
  120. 120 : * @member {String} payment_request_date
  121. 121 : */
  122. 122 : exports.prototype['payment_request_date'] = undefined;
  123. 123 : /**
  124. 124 : * The type of amount, as per the bill/statement, that is being paid. The payment amount is derived from the amount type selected for the payment. This defaults to other.
  125. 125 : * @member {module:models/UpdatePaymentRequest.PaymentAmountTypeEnum} payment_amount_type
  126. 126 : */
  127. 127 : exports.prototype['payment_amount_type'] = undefined;
  128. 128 : /**
  129. 129 : * @member {module:models/UpdatePaymentFundingAccountMinimalRequest} funding_account
  130. 130 : */
  131. 131 : exports.prototype['funding_account'] = undefined;
  132. 132 :
  133. 133 :
  134. 134 : /**
  135. 135 : * Allowed values for the <code>payment_amount_type</code> property.
  136. 136 : * @enum {String}
  137. 137 : * @readonly
  138. 138 : */
  139. 139 : exports.PaymentAmountTypeEnum = {
  140. 140 : /**
  141. 141 : * value: "current_balance"
  142. 142 : * @const
  143. 143 : */
  144. 144 : "current_balance": "current_balance",
  145. 145 : /**
  146. 146 : * value: "minimum_payment_due"
  147. 147 : * @const
  148. 148 : */
  149. 149 : "minimum_payment_due": "minimum_payment_due",
  150. 150 : /**
  151. 151 : * value: "past_payment_due"
  152. 152 : * @const
  153. 153 : */
  154. 154 : "past_payment_due": "past_payment_due",
  155. 155 : /**
  156. 156 : * value: "statement_balance"
  157. 157 : * @const
  158. 158 : */
  159. 159 : "statement_balance": "statement_balance",
  160. 160 : /**
  161. 161 : * value: "discounted_amount"
  162. 162 : * @const
  163. 163 : */
  164. 164 : "discounted_amount": "discounted_amount",
  165. 165 : /**
  166. 166 : * value: "penalty_amount"
  167. 167 : * @const
  168. 168 : */
  169. 169 : "penalty_amount": "penalty_amount",
  170. 170 : /**
  171. 171 : * value: "other"
  172. 172 : * @const
  173. 173 : */
  174. 174 : "other": "other" };
  175. 175 :
  176. 176 :
  177. 177 : return exports;
  178. 178 : }));
  179. 179 :
  180. 180 :