crm4
This commit is contained in:
@@ -3,6 +3,8 @@ export const crmContactEntryTypes = ["NOTE", "CALL", "EMAIL", "MEETING"] as cons
|
||||
|
||||
export type CrmRecordStatus = (typeof crmRecordStatuses)[number];
|
||||
export type CrmContactEntryType = (typeof crmContactEntryTypes)[number];
|
||||
export const crmContactRoles = ["PRIMARY", "PURCHASING", "AP", "SHIPPING", "ENGINEERING", "SALES", "OTHER"] as const;
|
||||
export type CrmContactRole = (typeof crmContactRoles)[number];
|
||||
|
||||
export interface CrmContactEntryDto {
|
||||
id: string;
|
||||
@@ -25,6 +27,37 @@ export interface CrmContactEntryInput {
|
||||
contactAt: string;
|
||||
}
|
||||
|
||||
export interface CrmContactDto {
|
||||
id: string;
|
||||
fullName: string;
|
||||
role: CrmContactRole;
|
||||
email: string;
|
||||
phone: string;
|
||||
isPrimary: boolean;
|
||||
createdAt: string;
|
||||
}
|
||||
|
||||
export interface CrmContactInput {
|
||||
fullName: string;
|
||||
role: CrmContactRole;
|
||||
email: string;
|
||||
phone: string;
|
||||
isPrimary: boolean;
|
||||
}
|
||||
|
||||
export interface CrmCustomerChildDto {
|
||||
id: string;
|
||||
name: string;
|
||||
status: CrmRecordStatus;
|
||||
}
|
||||
|
||||
export interface CrmCustomerHierarchyOptionDto {
|
||||
id: string;
|
||||
name: string;
|
||||
status: CrmRecordStatus;
|
||||
isReseller: boolean;
|
||||
}
|
||||
|
||||
export interface CrmRecordSummaryDto {
|
||||
id: string;
|
||||
name: string;
|
||||
@@ -34,6 +67,9 @@ export interface CrmRecordSummaryDto {
|
||||
state: string;
|
||||
country: string;
|
||||
status: CrmRecordStatus;
|
||||
isReseller?: boolean;
|
||||
parentCustomerId?: string | null;
|
||||
parentCustomerName?: string | null;
|
||||
updatedAt: string;
|
||||
}
|
||||
|
||||
@@ -44,6 +80,16 @@ export interface CrmRecordDetailDto extends CrmRecordSummaryDto {
|
||||
notes: string;
|
||||
createdAt: string;
|
||||
contactHistory: CrmContactEntryDto[];
|
||||
isReseller?: boolean;
|
||||
resellerDiscountPercent?: number | null;
|
||||
parentCustomerId?: string | null;
|
||||
parentCustomerName?: string | null;
|
||||
childCustomers?: CrmCustomerChildDto[];
|
||||
paymentTerms?: string | null;
|
||||
currencyCode?: string | null;
|
||||
taxExempt?: boolean;
|
||||
creditHold?: boolean;
|
||||
contacts?: CrmContactDto[];
|
||||
}
|
||||
|
||||
export interface CrmRecordInput {
|
||||
@@ -58,6 +104,13 @@ export interface CrmRecordInput {
|
||||
country: string;
|
||||
status: CrmRecordStatus;
|
||||
notes: string;
|
||||
isReseller?: boolean;
|
||||
resellerDiscountPercent?: number | null;
|
||||
parentCustomerId?: string | null;
|
||||
paymentTerms?: string | null;
|
||||
currencyCode?: string | null;
|
||||
taxExempt?: boolean;
|
||||
creditHold?: boolean;
|
||||
}
|
||||
|
||||
export type CustomerSummaryDto = CrmRecordSummaryDto;
|
||||
|
||||
Reference in New Issue
Block a user