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/FeeRefundRequest'], 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('./FeeRefundRequest'));
  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.CreateRefundRequest = factory(root.OrbipayPaymentsapiClient.ApiClient, root.OrbipayPaymentsapiClient.FeeRefundRequest);
  14. 14 : }
  15. 15 : }(this, function(ApiClient, FeeRefundRequest) {
  16. 16 : 'use strict';
  17. 17 :
  18. 18 :
  19. 19 :
  20. 20 :
  21. 21 : /**
  22. 22 : * The CreateRefundRequest model module.
  23. 23 : * @module models/CreateRefundRequest
  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>CreateRefundRequest</code>.
  30. 30 : * @alias module:models/CreateRefundRequest
  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 : * Constructs a <code>CreateRefundRequest</code> from a plain JavaScript object, optionally creating a new instance.
  45. 45 : * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
  46. 46 : * @param {Object} data The plain JavaScript object bearing properties of interest.
  47. 47 : * @param {module:models/CreateRefundRequest} obj Optional instance to populate.
  48. 48 : * @return {module:models/CreateRefundRequest} The populated <code>CreateRefundRequest</code> instance.
  49. 49 : */
  50. 50 : exports.constructFromObject = function(data, obj) {
  51. 51 : if (data) {
  52. 52 : obj = obj || new exports();
  53. 53 :
  54. 54 : if (data.hasOwnProperty('refund_reference')) {
  55. 55 : obj['refund_reference'] = ApiClient.convertToType(data['refund_reference'], 'String');
  56. 56 : }
  57. 57 : if (data.hasOwnProperty('refund_amount')) {
  58. 58 : obj['refund_amount'] = ApiClient.convertToType(data['refund_amount'], 'String');
  59. 59 : }
  60. 60 : if (data.hasOwnProperty('fee_refund')) {
  61. 61 : obj['fee_refund'] = FeeRefundRequest.constructFromObject(data['fee_refund']);
  62. 62 : }
  63. 63 : if (data.hasOwnProperty('comments')) {
  64. 64 : obj['comments'] = ApiClient.convertToType(data['comments'], 'String');
  65. 65 : }
  66. 66 : if (data.hasOwnProperty('custom_fields')) {
  67. 67 : obj['custom_fields'] = ApiClient.convertToType(data['custom_fields'], {'String': 'String'});
  68. 68 : }
  69. 69 : }
  70. 70 : return obj;
  71. 71 : };
  72. 72 :
  73. 73 : /**
  74. 74 : * The unique identifier in the client system for the refund.
  75. 75 : * @member {String} refund_reference
  76. 76 : */
  77. 77 : exports.prototype['refund_reference'] = undefined;
  78. 78 : /**
  79. 79 : * The refund amount upto 2 decimal places.
  80. 80 : * @member {String} refund_amount
  81. 81 : */
  82. 82 : exports.prototype['refund_amount'] = undefined;
  83. 83 : /**
  84. 84 : * @member {module:models/FeeRefundRequest} fee_refund
  85. 85 : */
  86. 86 : exports.prototype['fee_refund'] = undefined;
  87. 87 : /**
  88. 88 : * Comments that can be used to recollect the operation performed on the resource object.
  89. 89 : * @member {String} comments
  90. 90 : */
  91. 91 : exports.prototype['comments'] = undefined;
  92. 92 : /**
  93. 93 : * The additional information or meta-information that EBPP can accept, maintain and transmit back to the client.
  94. 94 : * @member {Object.<String, String>} custom_fields
  95. 95 : */
  96. 96 : exports.prototype['custom_fields'] = undefined;
  97. 97 :
  98. 98 :
  99. 99 :
  100. 100 : return exports;
  101. 101 : }));
  102. 102 :
  103. 103 :