import { ILeadContactProjection, ILeadProperty, ISalesAuditedEntity, ISalesMoney, LeadOrigin, LeadPriority, LeadStage } from './Common'; export declare enum LeadProbabilitySource { STATUS_DEFAULT = "STATUS_DEFAULT", MANUAL = "MANUAL" } export interface ILeadLineItem { id: string; productId?: string; sku?: string; description: string; quantity: string; unitPrice: ISalesMoney; discount?: ISalesMoney; tax?: ISalesMoney; total: ISalesMoney; } export interface ILead { id: string; spaceId: string; number: number; title: string; description?: string; contactId: string; contact?: ILeadContactProjection; statusId: string; stage: LeadStage; priority: LeadPriority; origin: LeadOrigin; assigneeId?: string; assignedGroupId?: string; properties: ILeadProperty[]; version: number; value?: ISalesMoney; probability: number; probabilitySource: LeadProbabilitySource; expectedCloseAt?: Date; wonAt?: Date; lostAt?: Date; lossReasonId?: string; lossReasonDetail?: string; campaignId?: string; items?: ILeadLineItem[]; createdAt: Date; createdBy: string; updatedAt?: Date; updatedBy?: string; deletedAt?: Date; deletedBy?: string; } export interface ILeadLossReason extends ISalesAuditedEntity { name: string; description?: string; order: number; enabled: boolean; detailRequired?: boolean; } export interface ICreateLeadDto { title: string; description?: string; contactId: string; statusId?: string; priority: LeadPriority; origin: LeadOrigin; assigneeId?: string; assignedGroupId?: string; properties?: ILeadProperty[]; source?: string; idempotencyKey?: string; value?: ISalesMoney; probability?: number; expectedCloseAt?: Date; campaignId?: string; items?: ILeadLineItem[]; } export interface IUpdateLeadDto { expectedVersion: number; title?: string; description?: string; priority?: LeadPriority; assigneeId?: string; assignedGroupId?: string; properties?: ILeadProperty[]; value?: ISalesMoney; probability?: number; expectedCloseAt?: Date; campaignId?: string; items?: ILeadLineItem[]; } export interface IMarkLeadLostDto { expectedVersion: number; toStatusId: string; lossReasonId: string; lossReasonDetail?: string; } export interface IMarkLeadWonDto { expectedVersion: number; toStatusId: string; finalValue?: ISalesMoney; }