File: /var/www/quadcode.com/node_modules/pipedrive/dist/model/DealCountAndActivityInfo.js
"use strict";
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
value: true
});
exports["default"] = void 0;
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
var _ApiClient = _interopRequireDefault(require("../ApiClient"));
var _ActivityInfo = _interopRequireDefault(require("./ActivityInfo"));
var _DealsCountInfo = _interopRequireDefault(require("./DealsCountInfo"));
/**
* Pipedrive API v1
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*
*/
/**
* The DealCountAndActivityInfo model module.
* @module model/DealCountAndActivityInfo
* @version 1.0.0
*/
var DealCountAndActivityInfo = /*#__PURE__*/function () {
/**
* Constructs a new <code>DealCountAndActivityInfo</code>.
* @alias module:model/DealCountAndActivityInfo
* @implements module:model/DealsCountInfo
* @implements module:model/ActivityInfo
*/
function DealCountAndActivityInfo() {
(0, _classCallCheck2["default"])(this, DealCountAndActivityInfo);
_DealsCountInfo["default"].initialize(this);
_ActivityInfo["default"].initialize(this);
DealCountAndActivityInfo.initialize(this);
}
/**
* Initializes the fields of this object.
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
* Only for internal use.
*/
(0, _createClass2["default"])(DealCountAndActivityInfo, null, [{
key: "initialize",
value: function initialize(obj) {}
/**
* Constructs a <code>DealCountAndActivityInfo</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/DealCountAndActivityInfo} obj Optional instance to populate.
* @return {module:model/DealCountAndActivityInfo} The populated <code>DealCountAndActivityInfo</code> instance.
*/
}, {
key: "constructFromObject",
value: function constructFromObject(data, obj) {
if (data) {
obj = obj || new DealCountAndActivityInfo();
_DealsCountInfo["default"].constructFromObject(data, obj);
_ActivityInfo["default"].constructFromObject(data, obj);
if (data.hasOwnProperty('open_deals_count')) {
obj['open_deals_count'] = _ApiClient["default"].convertToType(data['open_deals_count'], 'Number');
delete data['open_deals_count'];
}
if (data.hasOwnProperty('related_open_deals_count')) {
obj['related_open_deals_count'] = _ApiClient["default"].convertToType(data['related_open_deals_count'], 'Number');
delete data['related_open_deals_count'];
}
if (data.hasOwnProperty('closed_deals_count')) {
obj['closed_deals_count'] = _ApiClient["default"].convertToType(data['closed_deals_count'], 'Number');
delete data['closed_deals_count'];
}
if (data.hasOwnProperty('related_closed_deals_count')) {
obj['related_closed_deals_count'] = _ApiClient["default"].convertToType(data['related_closed_deals_count'], 'Number');
delete data['related_closed_deals_count'];
}
if (data.hasOwnProperty('won_deals_count')) {
obj['won_deals_count'] = _ApiClient["default"].convertToType(data['won_deals_count'], 'Number');
delete data['won_deals_count'];
}
if (data.hasOwnProperty('related_won_deals_count')) {
obj['related_won_deals_count'] = _ApiClient["default"].convertToType(data['related_won_deals_count'], 'Number');
delete data['related_won_deals_count'];
}
if (data.hasOwnProperty('lost_deals_count')) {
obj['lost_deals_count'] = _ApiClient["default"].convertToType(data['lost_deals_count'], 'Number');
delete data['lost_deals_count'];
}
if (data.hasOwnProperty('related_lost_deals_count')) {
obj['related_lost_deals_count'] = _ApiClient["default"].convertToType(data['related_lost_deals_count'], 'Number');
delete data['related_lost_deals_count'];
}
if (data.hasOwnProperty('next_activity_date')) {
obj['next_activity_date'] = _ApiClient["default"].convertToType(data['next_activity_date'], 'String');
delete data['next_activity_date'];
}
if (data.hasOwnProperty('next_activity_time')) {
obj['next_activity_time'] = _ApiClient["default"].convertToType(data['next_activity_time'], 'String');
delete data['next_activity_time'];
}
if (data.hasOwnProperty('next_activity_id')) {
obj['next_activity_id'] = _ApiClient["default"].convertToType(data['next_activity_id'], 'Number');
delete data['next_activity_id'];
}
if (data.hasOwnProperty('last_activity_id')) {
obj['last_activity_id'] = _ApiClient["default"].convertToType(data['last_activity_id'], 'Number');
delete data['last_activity_id'];
}
if (data.hasOwnProperty('last_activity_date')) {
obj['last_activity_date'] = _ApiClient["default"].convertToType(data['last_activity_date'], 'String');
delete data['last_activity_date'];
}
if (Object.keys(data).length > 0) {
Object.assign(obj, data);
}
}
return obj;
}
}]);
return DealCountAndActivityInfo;
}();
/**
* The count of open deals related with the item
* @member {Number} open_deals_count
*/
DealCountAndActivityInfo.prototype['open_deals_count'] = undefined;
/**
* The count of related open deals related with the item
* @member {Number} related_open_deals_count
*/
DealCountAndActivityInfo.prototype['related_open_deals_count'] = undefined;
/**
* The count of closed deals related with the item
* @member {Number} closed_deals_count
*/
DealCountAndActivityInfo.prototype['closed_deals_count'] = undefined;
/**
* The count of related closed deals related with the item
* @member {Number} related_closed_deals_count
*/
DealCountAndActivityInfo.prototype['related_closed_deals_count'] = undefined;
/**
* The count of won deals related with the item
* @member {Number} won_deals_count
*/
DealCountAndActivityInfo.prototype['won_deals_count'] = undefined;
/**
* The count of related won deals related with the item
* @member {Number} related_won_deals_count
*/
DealCountAndActivityInfo.prototype['related_won_deals_count'] = undefined;
/**
* The count of lost deals related with the item
* @member {Number} lost_deals_count
*/
DealCountAndActivityInfo.prototype['lost_deals_count'] = undefined;
/**
* The count of related lost deals related with the item
* @member {Number} related_lost_deals_count
*/
DealCountAndActivityInfo.prototype['related_lost_deals_count'] = undefined;
/**
* The date of the next activity associated with the deal
* @member {String} next_activity_date
*/
DealCountAndActivityInfo.prototype['next_activity_date'] = undefined;
/**
* The time of the next activity associated with the deal
* @member {String} next_activity_time
*/
DealCountAndActivityInfo.prototype['next_activity_time'] = undefined;
/**
* The ID of the next activity associated with the deal
* @member {Number} next_activity_id
*/
DealCountAndActivityInfo.prototype['next_activity_id'] = undefined;
/**
* The ID of the last activity associated with the deal
* @member {Number} last_activity_id
*/
DealCountAndActivityInfo.prototype['last_activity_id'] = undefined;
/**
* The date of the last activity associated with the deal
* @member {String} last_activity_date
*/
DealCountAndActivityInfo.prototype['last_activity_date'] = undefined;
// Implement DealsCountInfo interface:
/**
* The count of open deals related with the item
* @member {Number} open_deals_count
*/
_DealsCountInfo["default"].prototype['open_deals_count'] = undefined;
/**
* The count of related open deals related with the item
* @member {Number} related_open_deals_count
*/
_DealsCountInfo["default"].prototype['related_open_deals_count'] = undefined;
/**
* The count of closed deals related with the item
* @member {Number} closed_deals_count
*/
_DealsCountInfo["default"].prototype['closed_deals_count'] = undefined;
/**
* The count of related closed deals related with the item
* @member {Number} related_closed_deals_count
*/
_DealsCountInfo["default"].prototype['related_closed_deals_count'] = undefined;
/**
* The count of won deals related with the item
* @member {Number} won_deals_count
*/
_DealsCountInfo["default"].prototype['won_deals_count'] = undefined;
/**
* The count of related won deals related with the item
* @member {Number} related_won_deals_count
*/
_DealsCountInfo["default"].prototype['related_won_deals_count'] = undefined;
/**
* The count of lost deals related with the item
* @member {Number} lost_deals_count
*/
_DealsCountInfo["default"].prototype['lost_deals_count'] = undefined;
/**
* The count of related lost deals related with the item
* @member {Number} related_lost_deals_count
*/
_DealsCountInfo["default"].prototype['related_lost_deals_count'] = undefined;
// Implement ActivityInfo interface:
/**
* The date of the next activity associated with the deal
* @member {String} next_activity_date
*/
_ActivityInfo["default"].prototype['next_activity_date'] = undefined;
/**
* The time of the next activity associated with the deal
* @member {String} next_activity_time
*/
_ActivityInfo["default"].prototype['next_activity_time'] = undefined;
/**
* The ID of the next activity associated with the deal
* @member {Number} next_activity_id
*/
_ActivityInfo["default"].prototype['next_activity_id'] = undefined;
/**
* The ID of the last activity associated with the deal
* @member {Number} last_activity_id
*/
_ActivityInfo["default"].prototype['last_activity_id'] = undefined;
/**
* The date of the last activity associated with the deal
* @member {String} last_activity_date
*/
_ActivityInfo["default"].prototype['last_activity_date'] = undefined;
var _default = DealCountAndActivityInfo;
exports["default"] = _default;