square-connect
Version:
JavaScript client library for the Square Connect v2 API
69 lines (53 loc) • 1.9 kB
JavaScript
/**
* Square Connect API
* Client library for accessing the Square Connect APIs
*
* OpenAPI spec version: 2.0
* Contact: developers@squareup.com
*
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
*
* Swagger Codegen version: 2.3.0-SNAPSHOT
*
*/
var ApiClient = require('../ApiClient');
var TimeRange = require('./TimeRange');
/**
* The LoyaltyEventDateTimeFilter model module.
* Note: This model is in beta.
* @module model/LoyaltyEventDateTimeFilter
*/
/**
* Constructs a new <code>LoyaltyEventDateTimeFilter</code>.
* Filter events by date time range.
* @alias module:model/LoyaltyEventDateTimeFilter
* @class
* @param createdAt {module:model/TimeRange} The `created_at` date time range used to filter the result.
*/
var exports = function(createdAt) {
var _this = this;
_this['created_at'] = createdAt;
};
/**
* Constructs a <code>LoyaltyEventDateTimeFilter</code> from a plain JavaScript object, optionally creating a new instance.
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
* @param {Object} data The plain JavaScript object bearing properties of interest.
* @param {module:model/LoyaltyEventDateTimeFilter} obj Optional instance to populate.
* @return {module:model/LoyaltyEventDateTimeFilter} The populated <code>LoyaltyEventDateTimeFilter</code> instance.
*/
exports.constructFromObject = function(data, obj) {
if (data) {
obj = obj || new exports();
if (data.hasOwnProperty('created_at')) {
obj['created_at'] = TimeRange.constructFromObject(data['created_at']);
}
}
return obj;
}
/**
* The `created_at` date time range used to filter the result.
* @member {module:model/TimeRange} created_at
*/
exports.prototype['created_at'] = undefined;
module.exports = exports;