@bisondesk/core-sdk 1.0.354 → 1.0.355
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/types/crm.d.ts +1 -0
- package/lib/types/crm.d.ts.map +1 -1
- package/lib/types/crm.js.map +1 -1
- package/lib/types/quotes.d.ts +1 -0
- package/lib/types/quotes.d.ts.map +1 -1
- package/lib/types/quotes.js.map +1 -1
- package/package.json +1 -1
- package/src/types/crm.ts +1 -0
- package/src/types/quotes.ts +1 -0
- package/tsconfig.tsbuildinfo +1 -1
package/lib/types/crm.d.ts
CHANGED
package/lib/types/crm.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"crm.d.ts","sourceRoot":"/","sources":["types/crm.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,aAAa,EACb,mBAAmB,EACnB,gBAAgB,EAChB,iBAAiB,EAClB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,sBAAsB,EAAE,MAAM,kBAAkB,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAE3C,MAAM,MAAM,QAAQ,GAAG,oBAAoB,GAAG,eAAe,CAAC;AAE9D,MAAM,MAAM,eAAe,GAAG;IAC5B,SAAS,EAAE,MAAM,CAAC;IAClB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,MAAM,EAAE,QAAQ,GAAG,QAAQ,CAAC;IAC5B,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,MAAM,MAAM,oBAAoB,GAAG;IACjC,cAAc,EAAE,MAAM,CAAC;IACvB,MAAM,EAAE,QAAQ,GAAG,QAAQ,CAAC;IAC5B,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,KAAK,g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,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,MAAM,MAAM,UAAU,GAAG,WAAW,GAAG;IACrC,EAAE,CAAC,EAAE,SAAS,CAAC;IACf,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,MAAM,EAAE,KAAK,CAAC,gBAAgB,GAAG,mBAAmB,CAAC,CAAC;CACvD,CAAC;AAEF,MAAM,MAAM,OAAO,GAAG,WAAW,GAAG;IAClC,EAAE,EAAE,MAAM,CAAC;IACX,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,gBAAgB,EAAE,CAAC;CAC5B,CAAC;AAEF,oBAAY,qBAAqB;IAC/B,gBAAgB,sBAAsB;IACtC,eAAe,qBAAqB;CACrC;AAED,oBAAY,iBAAiB;IAC3B,gBAAgB,sBAAsB;IACtC,eAAe,qBAAqB;CACrC;AAED,oBAAY,cAAc;IACxB,MAAM,WAAW;IACjB,YAAY,iBAAiB;CAC9B"}
|
package/lib/types/crm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"crm.js","sourceRoot":"/","sources":["types/crm.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"crm.js","sourceRoot":"/","sources":["types/crm.ts"],"names":[],"mappings":"AAsJA,MAAM,CAAN,IAAY,qBAGX;AAHD,WAAY,qBAAqB;IAC/B,+DAAsC,CAAA;IACtC,6DAAoC,CAAA;AACtC,CAAC,EAHW,qBAAqB,KAArB,qBAAqB,QAGhC;AAED,MAAM,CAAN,IAAY,iBAGX;AAHD,WAAY,iBAAiB;IAC3B,2DAAsC,CAAA;IACtC,yDAAoC,CAAA;AACtC,CAAC,EAHW,iBAAiB,KAAjB,iBAAiB,QAG5B;AAED,MAAM,CAAN,IAAY,cAGX;AAHD,WAAY,cAAc;IACxB,mCAAiB,CAAA;IACjB,+CAA6B,CAAA;AAC/B,CAAC,EAHW,cAAc,KAAd,cAAc,QAGzB","sourcesContent":["import {\n LocationValue,\n PhoneNumberRawValue,\n PhoneNumberValue,\n SearchPermissions,\n} from '@bisondesk/commons-sdk/types';\nimport { PublicSearchDefinition } from './definitions.js';\nimport { ReferenceData } from './utils.js';\n\nexport type CrmEvent = CrmOrganizationEvent | CrmContactEvent;\n\nexport type CrmContactEvent = {\n contactId: string;\n organizationId?: string;\n action: 'upsert' | 'delete';\n actionAt: string;\n userId: string;\n tenantId: string;\n};\n\nexport type CrmOrganizationEvent = {\n organizationId: string;\n action: 'upsert' | 'delete';\n actionAt: string;\n userId: string;\n tenantId: string;\n};\n\ntype BaseOrganization = {\n inUse: boolean;\n countryCode: string;\n syncedAt: string;\n name: string;\n segment?: string;\n type?: 'COMPANY' | 'INDIVIDUAL';\n vatNumber?: string;\n addresses?: {\n legal?: LocationValue;\n transport?: LocationValue;\n };\n accountManagers: string[];\n conglomerate?: boolean;\n riskTags?: string[];\n\n // billing\n billingEmails?: string[];\n skipPaymentReminders?: boolean;\n trustworthy?: boolean;\n};\n\nexport type NewOrganization = BaseOrganization & {\n id?: undefined;\n externalId?: undefined;\n createdAt?: undefined;\n createdBy?: undefined;\n billingPhone?: PhoneNumberValue | PhoneNumberRawValue;\n};\n\nexport type ValidatedNewOrganization = Omit<NewOrganization, 'billingPhone'> & {\n billingPhone?: PhoneNumberValue;\n};\n\nexport type Organization = BaseOrganization & {\n createdAt: string;\n externalId: number;\n createdBy: string;\n id: string;\n\n debt?: OrganizationDebtInfo;\n\n billingPhone?: PhoneNumberValue;\n\n disabled?: boolean;\n disabledAt?: string;\n disabledBy?: string;\n disabledReason?: string;\n};\n\nexport type OrganizationDebtInfo = {\n overdueSince?: string;\n overdueInvoices: number;\n overdueAmount: string;\n unpaidInvoices: number;\n unpaidAmount: string;\n syncedAt: string;\n};\n\nexport type OrgLeasingContract = {\n id: string;\n contractNumber?: string;\n vehicle: {\n id: string;\n stockNumber: string;\n administrativeNumber?: string;\n };\n};\n\nexport type SearchOrganization = {\n org: Organization;\n contract: OrgLeasingContract[]; // important for the logic regarding leasing overdue reminders\n};\n\nexport type PotentialDuplicatesReferenceData = ReferenceData & { blockIgnore?: boolean };\n\nexport type InputSearchOrganization = SearchOrganization & {\n permissions: SearchPermissions;\n};\n\nexport type SearchContact = {\n contact: Contact;\n org?: Organization;\n};\n\nexport type InputSearchContact = SearchContact & {\n permissions: SearchPermissions;\n};\n\nexport type CrmPublicSearchDefinitions = {\n searchOrg: PublicSearchDefinition;\n searchContact: PublicSearchDefinition;\n};\n\ntype BaseContact = {\n accountManager?: string;\n countryCode?: string;\n language?: string;\n emails: string[];\n job?: string;\n /** either firstName or lastName should be filled in */\n firstName?: string;\n lastName?: string;\n organizationId?: string;\n /** will not be filled if organizationId is present */\n orgName?: string;\n};\n\nexport type NewContact = BaseContact & {\n id?: undefined;\n createdAt?: undefined;\n createdBy?: undefined;\n phones: Array<PhoneNumberValue | PhoneNumberRawValue>;\n};\n\nexport type Contact = BaseContact & {\n id: string;\n createdAt: string;\n createdBy: string;\n phones: PhoneNumberValue[];\n};\n\nexport enum SaveContactResolution {\n IgnoreDuplicates = 'IGNORE_DUPLICATES',\n BlockDuplicates = 'BLOCK_DUPLICATES',\n}\n\nexport enum SaveOrgResolution {\n IgnoreDuplicates = 'IGNORE_DUPLICATES',\n BlockDuplicates = 'BLOCK_DUPLICATES',\n}\n\nexport enum CrmSearchScope {\n Tenant = 'tenant',\n Conglomerate = 'conglomerate',\n}\n"]}
|
package/lib/types/quotes.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|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AqB,CAAA;IACrB,sCAAuB,CAAA;IACvB,mDAAoC,CAAA;IACpC,mDAAoC,CAAA;AACtC,CAAC,EATW,WAAW,KAAX,WAAW,QAStB;AAED,MAAM,CAAN,IAAY,iBAIX;AAJD,WAAY,iBAAiB;IAC3B,sCAAiB,CAAA;IACjB,wCAAmB,CAAA;IACnB,kCAAa,CAAA;AACf,CAAC,EAJW,iBAAiB,KAAjB,iBAAiB,QAI5B;AACD,MAAM,CAAN,IAAY,aAIX;AAJD,WAAY,aAAa;IACvB,mCAAkB,CAAA;IAClB,oCAAmB,CAAA;IACnB,8BAAa,CAAA;AACf,CAAC,EAJW,aAAa,KAAb,aAAa,QAIxB;AAED,MAAM,CAAN,IAAY,WAIX;AAJD,WAAY,WAAW;IACrB,8BAAe,CAAA;IACf,kCAAmB,CAAA;IACnB,qCAAsB,CAAA;AACxB,CAAC,EAJW,WAAW,KAAX,WAAW,QAItB;AAED,MAAM,CAAN,IAAY,kBAGX;AAHD,WAAY,kBAAkB;IAC5B,wCAAkB,CAAA;IAClB,6CAAuB,CAAA;AACzB,CAAC,EAHW,kBAAkB,KAAlB,kBAAkB,QAG7B","sourcesContent":["import { AttachmentValue, LocationValue } from '@bisondesk/commons-sdk/types';\nimport { OpportunityType } from '../constants.js';\nimport {\n CustomLeasingQuoteExtraInput,\n CustomSalesQuoteExtraInput,\n LeasingDeliveryPackageInput,\n LeasingQuoteExtraInput,\n SalesQuoteExtraInput,\n} from './leasing-settings.js';\nimport { MatchingRuleValue } from './roi-ratings.js';\nimport { PricePercentageMode } from './utils.js';\n\nexport enum QuoteActions {\n ACCEPT = 'accept',\n VALIDATE = 'validate',\n DONWLOAD_PDFS = 'download-pdfs',\n CANCEL = 'cancel',\n}\n\nexport enum QuoteStatus {\n CREATED = 'created',\n VALIDATED = 'validated',\n INVALIDATED = 'invalidated',\n ACCEPTED = 'accepted',\n REJECTED = 'rejected',\n CANCELLED = 'cancelled',\n MANAGER_REJECTED = 'managerRejected',\n MANAGER_ACCEPTED = 'managerAccepted',\n}\n\nexport enum QuoteMetricsScore {\n DANGER = 'danger',\n NEUTRAL = 'neutral',\n GOOD = 'good',\n}\nexport enum DeliveryTypes {\n PICK_UP = 'pickUp',\n ADDRESS = 'address',\n PORT = 'port',\n}\n\nexport enum SpoilerInfo {\n MOUNT = 'mount',\n UNMOUNT = 'unmount',\n NO_ACTION = 'noAction',\n}\n\nexport enum TransportationMode {\n BY_ROAD = 'byRoad',\n ON_LOW_BED = 'onLowBed',\n}\n\ntype BaseQuoteCalculatorInput = {\n branchId: string;\n branchCountry: string;\n customerCountry: string;\n customerVatNumber?: string;\n currency: string;\n vehicle: {\n id: string;\n category: string;\n bodywork?: string;\n agreedPriceExclVat: string;\n };\n\n allRisksCost?: string;\n};\n\n// Sent by the Frontend to bootstrap the calculator\nexport type LeasingCalculatorDefaultInput = BaseQuoteCalculatorInput & {\n deliveryPackage?: LeasingQuoteExtraInput;\n};\n\nexport type LeasingCalculatorInput = BaseQuoteCalculatorInput & {\n localLicensePlate: boolean;\n vanCourier: boolean;\n vehicle: BaseQuoteCalculatorInput['vehicle'] & {\n purchasePriceExclVat: string;\n agreedPrice: string;\n purchasePrice: string;\n };\n leasing: {\n deposit: string;\n depositMode: PricePercentageMode;\n depositPercentage: string;\n residual: string;\n residualMode: PricePercentageMode;\n residualPercentage: string;\n startupFee: string;\n startupFeeMode: PricePercentageMode;\n startupFeePercentage: string;\n interestRate: string;\n duration: number;\n contractStartDate: string;\n };\n bank: {\n interestRate: string;\n deposit: string;\n depositMode: PricePercentageMode;\n depositPercentage: string;\n residual: string;\n residualMode: PricePercentageMode;\n residualPercentage: string;\n duration: number;\n salesPrice: string;\n };\n taxes: {\n yearlyRoadTax: boolean;\n oneTimeRoadTax: boolean;\n margin: string; //Non Editable, copies the value insurance > margin\n };\n insurance: {\n margin: string;\n civilLiabilities: boolean;\n allRisks: boolean;\n specialTechnicalInsurance: boolean;\n roadAssistance: boolean;\n initialFractionPercentage: string;\n };\n deliveryPackage?: LeasingDeliveryPackageInput;\n extras: LeasingQuoteExtraInput[];\n customRequests: CustomLeasingQuoteExtraInput[];\n};\n\ntype BaseDeliveryType = {\n agreedPrice: string;\n spoiler?: SpoilerInfo;\n stackingVehicleNeeded?: boolean;\n detailsStacking?: string;\n};\n\nexport type PickUpDeliveryType = BaseDeliveryType & {\n type: DeliveryTypes.PICK_UP;\n urgent: boolean;\n transportationMode?: TransportationMode;\n detailsBorderCrossing?: string;\n technicalControlNeeded: boolean;\n insuranceNeeded: boolean;\n transitPlateBelgiumNeeded: boolean;\n transitPlateAustriaNeeded: boolean;\n licensePlateNeeded: boolean;\n dateOfPickUpByCustomer?: string;\n};\n\nexport type AddressDeliveryType = BaseDeliveryType & {\n type: DeliveryTypes.ADDRESS;\n address: LocationValue;\n distanceKm: string;\n technicalControlNeeded: boolean;\n};\n\nexport type PortDeliverytype = BaseDeliveryType & {\n type: DeliveryTypes.PORT;\n portOriginId: string;\n portDestination?: string;\n shippingCompany?: string;\n portToPortCostPrice: string;\n portToPortMargin: string;\n};\n\n// Sent by the Frontend to bootstrap the calculator\nexport type SalesCalculatorDefaultInput = BaseQuoteCalculatorInput & {\n extras: SalesQuoteExtraInput[];\n customRequests: CustomSalesQuoteExtraInput[];\n};\n\nexport type SalesCalculatorInput = BaseQuoteCalculatorInput & {\n vehicle: BaseQuoteCalculatorInput['vehicle'] & {\n purchasePrice: string;\n purchasePriceExclVat: string;\n agreedPrice: string;\n premiumPrice?: string;\n vatRate: string;\n minimumPrice: string;\n internetPrice?: string;\n comissionCost: string;\n };\n delivery?: PickUpDeliveryType | AddressDeliveryType | PortDeliverytype;\n extras: SalesQuoteExtraInput[];\n customRequests: CustomSalesQuoteExtraInput[];\n};\n\nexport type SalesQuoteRuleInput = {\n minimumPrice: number;\n internetPrice: number;\n agreedPrice: number;\n premiumPrice: number;\n stockAge: number;\n};\n\nexport type LeasingCalculatorOutput = {\n vatApplicable: boolean;\n installment: string;\n installmentPrintable: string;\n totalMonthlyAmount: string;\n monthlyTaxesInsurance: string;\n beforeDeliveryExclVat: string;\n beforeDelivery: string;\n financingAmount: string;\n settingId: string;\n totalRetailAmount: string;\n finalSalesPrice: string;\n roi: {\n value: string;\n target: string;\n perYear: string;\n difference: string;\n score?: QuoteMetricsScore;\n };\n cashflow: {\n deficit: string;\n balanced: boolean;\n score: QuoteMetricsScore;\n };\n profitability: {\n leasing: string;\n vehicle: string;\n total: string;\n score: QuoteMetricsScore;\n };\n taxes: {\n yearlyRetailPrice: string;\n monthlyRetailPrice: string;\n yearlyRoadTax: string;\n oneTimeRoadTax: string;\n profit: string;\n };\n insurance: {\n beforeDelivery: string;\n yearlyRetailPrice: string;\n monthlyRetailPrice: string;\n civilLiabilities: string;\n allRisks: string;\n specialTechnicalInsurance: string;\n roadAssistance: string;\n profit: string;\n };\n trackAndTrace: {\n beforeDelivery: string;\n monthlyCost: string;\n installationCost: string; // currently this cost is being included as part of monthlyCost. In future, this will be a separate cost\n deviceCost: string; // same as above\n profit: string;\n };\n costs: {\n financingAmount: string;\n finalCostPrice: string;\n monhtly: string;\n };\n};\n\nexport type SalesCalculatorOutput = {\n totalRetailAmount: string;\n totalRetailAmountExclVat: string;\n retailAmounts: {\n vehicle: string;\n delivery: string;\n extras: string;\n };\n roi: { value: string; score?: QuoteMetricsScore };\n profit: {\n value: string;\n score: QuoteMetricsScore;\n };\n profitOverMin: {\n value: string;\n percentage: string;\n score: QuoteMetricsScore;\n };\n delivery: {\n retailPrice?: string;\n costPrice?: string;\n cleaningNeeded: boolean;\n cleaningNeededRetailPrice: string;\n transportationToPortRetailPrice?: string;\n };\n costs: {\n finalCostPrice: string;\n extras: string;\n delivery: string;\n };\n};\n\ntype BaseQuote = {\n opportunityId: string;\n preferredLanguage: string;\n clientNotes?: string;\n publicNotes?: string;\n} & (\n | {\n type: OpportunityType.LEASING;\n calculatorInput: LeasingCalculatorInput;\n calculatorOutput: LeasingCalculatorOutput;\n rating?: MatchingRuleValue;\n }\n | {\n type: OpportunityType.SALES;\n calculatorInput: SalesCalculatorInput;\n calculatorOutput: SalesCalculatorOutput;\n rating?: MatchingRuleValue;\n }\n);\n\nexport type NewQuote = BaseQuote & {\n id?: undefined;\n createdAt?: undefined;\n createdBy?: undefined;\n modifiedAt?: undefined;\n modifiedBy?: undefined;\n active: true;\n};\n\nexport type Quote = BaseQuote & {\n id: string;\n createdAt: string;\n createdBy: string;\n modifiedAt: string;\n modifiedBy: string;\n validationBy?: string;\n validationAt?: string;\n cancelledBy?: string;\n cancelledAt?: string;\n customerFeedbackAt?: string;\n customerFeedbackBy?: string;\n managerFeedbackAt?: string;\n managerFeedbackBy?: string;\n version: number;\n status: QuoteStatus;\n proformaPdf?: AttachmentValue;\n quotePdf?: AttachmentValue;\n salesAgreementPdf?: AttachmentValue;\n active: boolean;\n contactId: string;\n vehicleId: string;\n organizationId: string;\n};\n\nexport type QuoteUpdate = {\n status?: QuoteStatus;\n active?: boolean;\n};\n\nexport type CalculatorLeasingIO = {\n output: LeasingCalculatorOutput;\n input: LeasingCalculatorInput;\n rating?: MatchingRuleValue;\n};\nexport type CalculatorSalesIO = {\n output: SalesCalculatorOutput;\n input: SalesCalculatorInput;\n rating?: MatchingRuleValue;\n};\nexport type CalculatorQuoteIO = CalculatorLeasingIO | CalculatorSalesIO;\n\nexport type DeliveryLocationValue = Omit<LocationValue, 'addressLine1' | 'city'> & {\n addressLine1: string;\n city: string;\n};\n\nexport type DeliveryRoutesRequest = {\n origin: DeliveryLocationValue;\n destination: DeliveryLocationValue;\n};\n\ntype BaseCommission = {\n opportunityId: string;\n\n estimatedAmount: string;\n estimatedPaidAt: string;\n paidAmount?: string;\n paidAt?: string;\n\n notes?: string;\n};\n\nexport type NewCommission = BaseCommission & {};\n\nexport type Commission = BaseCommission & {\n stockNumber: string;\n vehicleId: string;\n\n branchId: string;\n currency: string;\n\n modifiedAt: string;\n modifiedBy: string;\n};\n\nexport type NewQuoteValidator = {\n userId: string;\n countryCode: string;\n type: OpportunityType;\n canValidateOwn?: boolean;\n};\n\nexport type QuoteValidator = NewQuoteValidator & {\n createdAt: string;\n};\n\nexport type QuoteValidatorUpdate = {\n canValidateOwn: boolean;\n};\n"]}
|
|
1
|
+
{"version":3,"file":"quotes.js","sourceRoot":"/","sources":["types/quotes.ts"],"names":[],"mappings":"AAYA,MAAM,CAAN,IAAY,YAKX;AALD,WAAY,YAAY;IACtB,iCAAiB,CAAA;IACjB,qCAAqB,CAAA;IACrB,+CAA+B,CAAA;IAC/B,iCAAiB,CAAA;AACnB,CAAC,EALW,YAAY,KAAZ,YAAY,QAKvB;AAED,MAAM,CAAN,IAAY,WASX;AATD,WAAY,WAAW;IACrB,kCAAmB,CAAA;IACnB,sCAAuB,CAAA;IACvB,0CAA2B,CAAA;IAC3B,oCAAqB,CAAA;IACrB,oCAAqB,CAAA;IACrB,sCAAuB,CAAA;IACvB,mDAAoC,CAAA;IACpC,mDAAoC,CAAA;AACtC,CAAC,EATW,WAAW,KAAX,WAAW,QAStB;AAED,MAAM,CAAN,IAAY,iBAIX;AAJD,WAAY,iBAAiB;IAC3B,sCAAiB,CAAA;IACjB,wCAAmB,CAAA;IACnB,kCAAa,CAAA;AACf,CAAC,EAJW,iBAAiB,KAAjB,iBAAiB,QAI5B;AACD,MAAM,CAAN,IAAY,aAIX;AAJD,WAAY,aAAa;IACvB,mCAAkB,CAAA;IAClB,oCAAmB,CAAA;IACnB,8BAAa,CAAA;AACf,CAAC,EAJW,aAAa,KAAb,aAAa,QAIxB;AAED,MAAM,CAAN,IAAY,WAIX;AAJD,WAAY,WAAW;IACrB,8BAAe,CAAA;IACf,kCAAmB,CAAA;IACnB,qCAAsB,CAAA;AACxB,CAAC,EAJW,WAAW,KAAX,WAAW,QAItB;AAED,MAAM,CAAN,IAAY,kBAGX;AAHD,WAAY,kBAAkB;IAC5B,wCAAkB,CAAA;IAClB,6CAAuB,CAAA;AACzB,CAAC,EAHW,kBAAkB,KAAlB,kBAAkB,QAG7B","sourcesContent":["import { AttachmentValue, LocationValue } from '@bisondesk/commons-sdk/types';\nimport { OpportunityType } from '../constants.js';\nimport {\n CustomLeasingQuoteExtraInput,\n CustomSalesQuoteExtraInput,\n LeasingDeliveryPackageInput,\n LeasingQuoteExtraInput,\n SalesQuoteExtraInput,\n} from './leasing-settings.js';\nimport { MatchingRuleValue } from './roi-ratings.js';\nimport { PricePercentageMode } from './utils.js';\n\nexport enum QuoteActions {\n ACCEPT = 'accept',\n VALIDATE = 'validate',\n DONWLOAD_PDFS = 'download-pdfs',\n CANCEL = 'cancel',\n}\n\nexport enum QuoteStatus {\n CREATED = 'created',\n VALIDATED = 'validated',\n INVALIDATED = 'invalidated',\n ACCEPTED = 'accepted',\n REJECTED = 'rejected',\n CANCELLED = 'cancelled',\n MANAGER_REJECTED = 'managerRejected',\n MANAGER_ACCEPTED = 'managerAccepted',\n}\n\nexport enum QuoteMetricsScore {\n DANGER = 'danger',\n NEUTRAL = 'neutral',\n GOOD = 'good',\n}\nexport enum DeliveryTypes {\n PICK_UP = 'pickUp',\n ADDRESS = 'address',\n PORT = 'port',\n}\n\nexport enum SpoilerInfo {\n MOUNT = 'mount',\n UNMOUNT = 'unmount',\n NO_ACTION = 'noAction',\n}\n\nexport enum TransportationMode {\n BY_ROAD = 'byRoad',\n ON_LOW_BED = 'onLowBed',\n}\n\ntype BaseQuoteCalculatorInput = {\n branchId: string;\n branchCountry: string;\n customerCountry: string;\n customerVatNumber?: string;\n currency: string;\n vehicle: {\n id: string;\n category: string;\n bodywork?: string;\n agreedPriceExclVat: string;\n technicalNotes?: string;\n };\n\n allRisksCost?: string;\n};\n\n// Sent by the Frontend to bootstrap the calculator\nexport type LeasingCalculatorDefaultInput = BaseQuoteCalculatorInput & {\n deliveryPackage?: LeasingQuoteExtraInput;\n};\n\nexport type LeasingCalculatorInput = BaseQuoteCalculatorInput & {\n localLicensePlate: boolean;\n vanCourier: boolean;\n vehicle: BaseQuoteCalculatorInput['vehicle'] & {\n purchasePriceExclVat: string;\n agreedPrice: string;\n purchasePrice: string;\n };\n leasing: {\n deposit: string;\n depositMode: PricePercentageMode;\n depositPercentage: string;\n residual: string;\n residualMode: PricePercentageMode;\n residualPercentage: string;\n startupFee: string;\n startupFeeMode: PricePercentageMode;\n startupFeePercentage: string;\n interestRate: string;\n duration: number;\n contractStartDate: string;\n };\n bank: {\n interestRate: string;\n deposit: string;\n depositMode: PricePercentageMode;\n depositPercentage: string;\n residual: string;\n residualMode: PricePercentageMode;\n residualPercentage: string;\n duration: number;\n salesPrice: string;\n };\n taxes: {\n yearlyRoadTax: boolean;\n oneTimeRoadTax: boolean;\n margin: string; //Non Editable, copies the value insurance > margin\n };\n insurance: {\n margin: string;\n civilLiabilities: boolean;\n allRisks: boolean;\n specialTechnicalInsurance: boolean;\n roadAssistance: boolean;\n initialFractionPercentage: string;\n };\n deliveryPackage?: LeasingDeliveryPackageInput;\n extras: LeasingQuoteExtraInput[];\n customRequests: CustomLeasingQuoteExtraInput[];\n};\n\ntype BaseDeliveryType = {\n agreedPrice: string;\n spoiler?: SpoilerInfo;\n stackingVehicleNeeded?: boolean;\n detailsStacking?: string;\n};\n\nexport type PickUpDeliveryType = BaseDeliveryType & {\n type: DeliveryTypes.PICK_UP;\n urgent: boolean;\n transportationMode?: TransportationMode;\n detailsBorderCrossing?: string;\n technicalControlNeeded: boolean;\n insuranceNeeded: boolean;\n transitPlateBelgiumNeeded: boolean;\n transitPlateAustriaNeeded: boolean;\n licensePlateNeeded: boolean;\n dateOfPickUpByCustomer?: string;\n};\n\nexport type AddressDeliveryType = BaseDeliveryType & {\n type: DeliveryTypes.ADDRESS;\n address: LocationValue;\n distanceKm: string;\n technicalControlNeeded: boolean;\n};\n\nexport type PortDeliverytype = BaseDeliveryType & {\n type: DeliveryTypes.PORT;\n portOriginId: string;\n portDestination?: string;\n shippingCompany?: string;\n portToPortCostPrice: string;\n portToPortMargin: string;\n};\n\n// Sent by the Frontend to bootstrap the calculator\nexport type SalesCalculatorDefaultInput = BaseQuoteCalculatorInput & {\n extras: SalesQuoteExtraInput[];\n customRequests: CustomSalesQuoteExtraInput[];\n};\n\nexport type SalesCalculatorInput = BaseQuoteCalculatorInput & {\n vehicle: BaseQuoteCalculatorInput['vehicle'] & {\n purchasePrice: string;\n purchasePriceExclVat: string;\n agreedPrice: string;\n premiumPrice?: string;\n vatRate: string;\n minimumPrice: string;\n internetPrice?: string;\n comissionCost: string;\n };\n delivery?: PickUpDeliveryType | AddressDeliveryType | PortDeliverytype;\n extras: SalesQuoteExtraInput[];\n customRequests: CustomSalesQuoteExtraInput[];\n};\n\nexport type SalesQuoteRuleInput = {\n minimumPrice: number;\n internetPrice: number;\n agreedPrice: number;\n premiumPrice: number;\n stockAge: number;\n};\n\nexport type LeasingCalculatorOutput = {\n vatApplicable: boolean;\n installment: string;\n installmentPrintable: string;\n totalMonthlyAmount: string;\n monthlyTaxesInsurance: string;\n beforeDeliveryExclVat: string;\n beforeDelivery: string;\n financingAmount: string;\n settingId: string;\n totalRetailAmount: string;\n finalSalesPrice: string;\n roi: {\n value: string;\n target: string;\n perYear: string;\n difference: string;\n score?: QuoteMetricsScore;\n };\n cashflow: {\n deficit: string;\n balanced: boolean;\n score: QuoteMetricsScore;\n };\n profitability: {\n leasing: string;\n vehicle: string;\n total: string;\n score: QuoteMetricsScore;\n };\n taxes: {\n yearlyRetailPrice: string;\n monthlyRetailPrice: string;\n yearlyRoadTax: string;\n oneTimeRoadTax: string;\n profit: string;\n };\n insurance: {\n beforeDelivery: string;\n yearlyRetailPrice: string;\n monthlyRetailPrice: string;\n civilLiabilities: string;\n allRisks: string;\n specialTechnicalInsurance: string;\n roadAssistance: string;\n profit: string;\n };\n trackAndTrace: {\n beforeDelivery: string;\n monthlyCost: string;\n installationCost: string; // currently this cost is being included as part of monthlyCost. In future, this will be a separate cost\n deviceCost: string; // same as above\n profit: string;\n };\n costs: {\n financingAmount: string;\n finalCostPrice: string;\n monhtly: string;\n };\n};\n\nexport type SalesCalculatorOutput = {\n totalRetailAmount: string;\n totalRetailAmountExclVat: string;\n retailAmounts: {\n vehicle: string;\n delivery: string;\n extras: string;\n };\n roi: { value: string; score?: QuoteMetricsScore };\n profit: {\n value: string;\n score: QuoteMetricsScore;\n };\n profitOverMin: {\n value: string;\n percentage: string;\n score: QuoteMetricsScore;\n };\n delivery: {\n retailPrice?: string;\n costPrice?: string;\n cleaningNeeded: boolean;\n cleaningNeededRetailPrice: string;\n transportationToPortRetailPrice?: string;\n };\n costs: {\n finalCostPrice: string;\n extras: string;\n delivery: string;\n };\n};\n\ntype BaseQuote = {\n opportunityId: string;\n preferredLanguage: string;\n clientNotes?: string;\n publicNotes?: string;\n} & (\n | {\n type: OpportunityType.LEASING;\n calculatorInput: LeasingCalculatorInput;\n calculatorOutput: LeasingCalculatorOutput;\n rating?: MatchingRuleValue;\n }\n | {\n type: OpportunityType.SALES;\n calculatorInput: SalesCalculatorInput;\n calculatorOutput: SalesCalculatorOutput;\n rating?: MatchingRuleValue;\n }\n);\n\nexport type NewQuote = BaseQuote & {\n id?: undefined;\n createdAt?: undefined;\n createdBy?: undefined;\n modifiedAt?: undefined;\n modifiedBy?: undefined;\n active: true;\n};\n\nexport type Quote = BaseQuote & {\n id: string;\n createdAt: string;\n createdBy: string;\n modifiedAt: string;\n modifiedBy: string;\n validationBy?: string;\n validationAt?: string;\n cancelledBy?: string;\n cancelledAt?: string;\n customerFeedbackAt?: string;\n customerFeedbackBy?: string;\n managerFeedbackAt?: string;\n managerFeedbackBy?: string;\n version: number;\n status: QuoteStatus;\n proformaPdf?: AttachmentValue;\n quotePdf?: AttachmentValue;\n salesAgreementPdf?: AttachmentValue;\n active: boolean;\n contactId: string;\n vehicleId: string;\n organizationId: string;\n};\n\nexport type QuoteUpdate = {\n status?: QuoteStatus;\n active?: boolean;\n};\n\nexport type CalculatorLeasingIO = {\n output: LeasingCalculatorOutput;\n input: LeasingCalculatorInput;\n rating?: MatchingRuleValue;\n};\nexport type CalculatorSalesIO = {\n output: SalesCalculatorOutput;\n input: SalesCalculatorInput;\n rating?: MatchingRuleValue;\n};\nexport type CalculatorQuoteIO = CalculatorLeasingIO | CalculatorSalesIO;\n\nexport type DeliveryLocationValue = Omit<LocationValue, 'addressLine1' | 'city'> & {\n addressLine1: string;\n city: string;\n};\n\nexport type DeliveryRoutesRequest = {\n origin: DeliveryLocationValue;\n destination: DeliveryLocationValue;\n};\n\ntype BaseCommission = {\n opportunityId: string;\n\n estimatedAmount: string;\n estimatedPaidAt: string;\n paidAmount?: string;\n paidAt?: string;\n\n notes?: string;\n};\n\nexport type NewCommission = BaseCommission & {};\n\nexport type Commission = BaseCommission & {\n stockNumber: string;\n vehicleId: string;\n\n branchId: string;\n currency: string;\n\n modifiedAt: string;\n modifiedBy: string;\n};\n\nexport type NewQuoteValidator = {\n userId: string;\n countryCode: string;\n type: OpportunityType;\n canValidateOwn?: boolean;\n};\n\nexport type QuoteValidator = NewQuoteValidator & {\n createdAt: string;\n};\n\nexport type QuoteValidatorUpdate = {\n canValidateOwn: boolean;\n};\n"]}
|
package/package.json
CHANGED
package/src/types/crm.ts
CHANGED