UNPKG

square-connect

Version:

JavaScript client library for the Square Connect v2 API

75 lines (57 loc) 2.56 kB
/** * 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'); /** * The SearchTeamMembersFilter model module. * @module model/SearchTeamMembersFilter */ /** * Constructs a new <code>SearchTeamMembersFilter</code>. * Represents a filter used in a search for &#x60;TeamMember&#x60; objects. &#x60;AND&#x60; logic is applied between the individual fields, and &#x60;OR&#x60; logic is applied within list-based fields. For example, setting this filter value, &#x60;&#x60;&#x60; filter &#x3D; (locations_ids &#x3D; [\&quot;A\&quot;, \&quot;B\&quot;], status &#x3D; ACTIVE) &#x60;&#x60;&#x60; returns only active team members assigned to either location \&quot;A\&quot; or \&quot;B\&quot;. * @alias module:model/SearchTeamMembersFilter * @class */ var exports = function() { var _this = this; }; /** * Constructs a <code>SearchTeamMembersFilter</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/SearchTeamMembersFilter} obj Optional instance to populate. * @return {module:model/SearchTeamMembersFilter} The populated <code>SearchTeamMembersFilter</code> instance. */ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); if (data.hasOwnProperty('location_ids')) { obj['location_ids'] = ApiClient.convertToType(data['location_ids'], ['String']); } if (data.hasOwnProperty('status')) { obj['status'] = ApiClient.convertToType(data['status'], 'String'); } } return obj; } /** * When present, filter by team members assigned to the specified locations. When empty, include team members assigned to any location. * @member {Array.<String>} location_ids */ exports.prototype['location_ids'] = undefined; /** * When present, filter by team members who match the given status. When empty, include team members of all statuses. See [TeamMemberStatus](#type-teammemberstatus) for possible values * @member {String} status */ exports.prototype['status'] = undefined; module.exports = exports;