@hipay/hipay-enterprise-sdk-nodejs
Version:
The HiPay Enterprise SDK for NodeJS is a library for developers who want to integrate HiPay Enterprise payment methods to any NodeJS platform.
36 lines (29 loc) • 1.03 kB
JavaScript
;
const AbstractRequestPart = require('../AbstractRequestPart');
class DeliveryShippingInfoRequest extends AbstractRequestPart {
/**
* Creates a Delivery Info Object
*
* @param {Object} [values = {}]
* @param {String} [values.delivery_date] Delivery estimated date, format YYYY-MM-DD
* @param {'STORE'|'STORE24H'|'CARRIER'|'CARRIER24H'|'RELAYPOINT'|'RELAYPOINT24H'|'EXPRESS24H'|'EXPRESS48H'} [values.delivery_method] Delivery method
*/
constructor(values) {
super();
if (typeof values !== 'object') {
values = {};
}
if (Object.hasOwn(values, 'delivery_date')) {
this.delivery_date = values.delivery_date;
}
if (Object.hasOwn(values, 'delivery_method')) {
this.delivery_method = values.delivery_method;
}
}
initValues() {
super.initValues();
this.delivery_date = null;
this.delivery_method = null;
}
}
module.exports = DeliveryShippingInfoRequest;