HEX
Server: nginx/1.18.0
System: Linux test-ipsremont 5.4.0-214-generic #234-Ubuntu SMP Fri Mar 14 23:50:27 UTC 2025 x86_64
User: ips (1000)
PHP: 8.0.30
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: /var/www/fintechfuel/node_modules/pipedrive/dist/model/NewDealParameters.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"));
/**
 * 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 NewDealParameters model module.
 * @module model/NewDealParameters
 * @version 1.0.0
 */
var NewDealParameters = /*#__PURE__*/function () {
  /**
   * Constructs a new <code>NewDealParameters</code>.
   * @alias module:model/NewDealParameters
   */
  function NewDealParameters() {
    (0, _classCallCheck2["default"])(this, NewDealParameters);
    NewDealParameters.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"])(NewDealParameters, null, [{
    key: "initialize",
    value: function initialize(obj) {}

    /**
     * Constructs a <code>NewDealParameters</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/NewDealParameters} obj Optional instance to populate.
     * @return {module:model/NewDealParameters} The populated <code>NewDealParameters</code> instance.
     */
  }, {
    key: "constructFromObject",
    value: function constructFromObject(data, obj) {
      if (data) {
        obj = obj || new NewDealParameters();
        if (data.hasOwnProperty('value')) {
          obj['value'] = _ApiClient["default"].convertToType(data['value'], 'String');
          delete data['value'];
        }
        if (data.hasOwnProperty('currency')) {
          obj['currency'] = _ApiClient["default"].convertToType(data['currency'], 'String');
          delete data['currency'];
        }
        if (data.hasOwnProperty('user_id')) {
          obj['user_id'] = _ApiClient["default"].convertToType(data['user_id'], 'Number');
          delete data['user_id'];
        }
        if (data.hasOwnProperty('person_id')) {
          obj['person_id'] = _ApiClient["default"].convertToType(data['person_id'], 'Number');
          delete data['person_id'];
        }
        if (data.hasOwnProperty('org_id')) {
          obj['org_id'] = _ApiClient["default"].convertToType(data['org_id'], 'Number');
          delete data['org_id'];
        }
        if (data.hasOwnProperty('pipeline_id')) {
          obj['pipeline_id'] = _ApiClient["default"].convertToType(data['pipeline_id'], 'Number');
          delete data['pipeline_id'];
        }
        if (data.hasOwnProperty('stage_id')) {
          obj['stage_id'] = _ApiClient["default"].convertToType(data['stage_id'], 'Number');
          delete data['stage_id'];
        }
        if (data.hasOwnProperty('status')) {
          obj['status'] = _ApiClient["default"].convertToType(data['status'], 'String');
          delete data['status'];
        }
        if (data.hasOwnProperty('add_time')) {
          obj['add_time'] = _ApiClient["default"].convertToType(data['add_time'], 'String');
          delete data['add_time'];
        }
        if (Object.keys(data).length > 0) {
          Object.assign(obj, data);
        }
      }
      return obj;
    }
  }]);
  return NewDealParameters;
}();
/**
 * The value of the deal. If omitted, value will be set to 0.
 * @member {String} value
 */
NewDealParameters.prototype['value'] = undefined;

/**
 * The currency of the deal. Accepts a 3-character currency code. If omitted, currency will be set to the default currency of the authorized user.
 * @member {String} currency
 */
NewDealParameters.prototype['currency'] = undefined;

/**
 * The ID of the user which will be the owner of the created deal. If not provided, the user making the request will be used.
 * @member {Number} user_id
 */
NewDealParameters.prototype['user_id'] = undefined;

/**
 * The ID of a person which this deal will be linked to. If the person does not exist yet, it needs to be created first. This property is required unless `org_id` is specified.
 * @member {Number} person_id
 */
NewDealParameters.prototype['person_id'] = undefined;

/**
 * The ID of an organization which this deal will be linked to. If the organization does not exist yet, it needs to be created first. This property is required unless `person_id` is specified.
 * @member {Number} org_id
 */
NewDealParameters.prototype['org_id'] = undefined;

/**
 * The ID of the pipeline this deal will be added to. By default, the deal will be added to the first stage of the specified pipeline. Please note that `pipeline_id` and `stage_id` should not be used together as `pipeline_id` will be ignored.
 * @member {Number} pipeline_id
 */
NewDealParameters.prototype['pipeline_id'] = undefined;

/**
 * The ID of the stage this deal will be added to. Please note that a pipeline will be assigned automatically based on the `stage_id`. If omitted, the deal will be placed in the first stage of the default pipeline.
 * @member {Number} stage_id
 */
NewDealParameters.prototype['stage_id'] = undefined;

/**
 * open = Open, won = Won, lost = Lost, deleted = Deleted. If omitted, status will be set to open.
 * @member {module:model/NewDealParameters.StatusEnum} status
 */
NewDealParameters.prototype['status'] = undefined;

/**
 * The optional creation date & time of the deal in UTC. Requires admin user API token. Format: YYYY-MM-DD HH:MM:SS
 * @member {String} add_time
 */
NewDealParameters.prototype['add_time'] = undefined;

/**
 * Allowed values for the <code>status</code> property.
 * @enum {String}
 * @readonly
 */
NewDealParameters['StatusEnum'] = {
  /**
   * value: "open"
   * @const
   */
  "open": "open",
  /**
   * value: "won"
   * @const
   */
  "won": "won",
  /**
   * value: "lost"
   * @const
   */
  "lost": "lost",
  /**
   * value: "deleted"
   * @const
   */
  "deleted": "deleted"
};
var _default = NewDealParameters;
exports["default"] = _default;