/** * Сделка (сущность) */ import ResourceEntity from "../ResourceEntity"; import { JSONObject, TConstructor } from "../../types"; import { ILeadFactory } from "../factories/LeadFactory"; import { IEntityAttributes, IResourceEntity } from "../../interfaces/api"; import { hasSave, IHasSave } from "./mixins/hasSave"; import { hasFetch, IHasFetch } from "./mixins/hasFetch"; import { IHasEmbeddedTags } from "./Tag"; import { IHasEmbeddedContacts } from "./Contact"; import { IHasEmbeddedCompanies } from "./Company"; import { IHasEmbeddedCatalogElements } from "./CatalogElement"; import { IHasEmbeddedTagsEntity } from "./mixins/embedded/hasEmbeddedTags"; import { IHasEmbeddedContactsEntity } from "./mixins/embedded/hasEmbeddedContacts"; import { IHasEmbeddedCompaniesEntity } from "./mixins/embedded/hasEmbeddedCompanies"; import { IHasEmbeddedCatalogElementsEntity } from "./mixins/embedded/hasEmbeddedCatalogElements"; import { IHasEmbeddedLossReasons } from "./LossReason"; import { IHasEmbeddedSource } from "./Source"; import { IHasEmbedded } from "./mixins/hasEmbedded"; import { hasTasks, IHasTasks } from "./mixins/hasTasks"; export interface LeadAttributes extends IEntityAttributes { id?: number; name?: string; price?: number; responsible_user_id?: number; group_id?: number; status_id?: number; pipeline_id?: number; loss_reason_id?: number; source_id?: number; created_by?: number; updated_by?: number; closed_at?: number; created_at?: number; updated_at?: number; closed_task_at?: number; is_deleted?: boolean; custom_fields_values?: JSONObject[] | null; score?: number | null; account_id?: number; labor_cost?: number; is_price_modified_by_robot?: boolean; _embedded?: ILeadEmbedded; } export declare type ILeadHasEmbedded = IHasEmbeddedTagsEntity & IHasEmbeddedContactsEntity & IHasEmbeddedCompaniesEntity & IHasEmbeddedCatalogElementsEntity; export declare type ILead = IResourceEntity & LeadAttributes & IHasEmbedded & IHasSave & IHasFetch & ILeadHasEmbedded & IHasTasks; export declare type ILeadEmbedded = IHasEmbeddedTags & IHasEmbeddedContacts & IHasEmbeddedCompanies & IHasEmbeddedCatalogElements & IHasEmbeddedLossReasons & IHasEmbeddedSource; /** * Сделка */ export declare class BaseLead extends ResourceEntity { name?: string; price?: number; responsible_user_id?: number; group_id?: number; status_id?: number; pipeline_id?: number; loss_reason_id?: number; source_id?: number; created_by?: number; updated_by?: number; closed_at?: number; created_at?: number; closed_task_at?: number; is_deleted?: boolean; custom_fields_values?: JSONObject[] | null; score?: number | null; account_id?: number; labor_cost?: number; is_price_modified_by_robot?: boolean; _embedded?: ILeadEmbedded; getAttributes(): LeadAttributes; setAttributes(attributes: LeadAttributes): void; } export declare const mixins: (typeof hasSave | typeof hasFetch | typeof hasTasks)[]; export declare const embeddedMixins: ((>>(Base: TConstructor>) => TConstructor>) | (>>(Base: TConstructor>) => TConstructor>) | (>>(Base: TConstructor>) => TConstructor>))[]; export declare const Lead: TConstructor;