import { type ListFrontEndInterface } from '../../CommonType'

export interface ProspectClientDetailsListDataTypeInterface
    extends ProspectClientFormDataInterface {
    key: React.Key
}

export interface ProspectClientDetailsListCommunicationHistory
    extends CommunicationHistory {
    key: React.Key
}

export interface ProspectClientListInterface {
    prospectClientDetailsList: ProspectClientDetailsListDataTypeInterface[]
    prospectClientDetailsListCount: number
    siderClientID: number
}

export interface ProspectClientFormDataInterface {
    prospectClientId: number
    title: string
    firstName: string
    middleName: string
    surName: string
    companyName: string
    referredBy: string
    mobileNumber: string
    emailAddress: string
    address1: string
    address2: string
    town: string
    postCode: string
    country: string
    description: string
    isActive: string
    lastCommunicationStatus: string
    lastCommunicationStatusUrl: string
    isNewChatExist: number
    clientDynCategory: number
}

export interface ProspectClientFormInterface {
    onSave: (
        data: ProspectClientFormDataInterface,
        callBack: CallableFunction
    ) => void
    editData: ProspectClientFormDataInterface
    countryList: ListFrontEndInterface[]
}

export interface ProspectClientExpandViewInterface {
    prospectClientDetailsData: ProspectClientDetailsListDataTypeInterface
}

export interface ProspectClientDetailsPayloadInterface {
    data: ProspectClientFormDataInterface[]
    noOfRecords: number
}

export interface ProspectClientHistoryPayloadInterface {
    data: CommunicationHistory[]
    noOfRecords: number
}

export interface ProspectFormStateInterface {
    countryList: ListFrontEndInterface[]
}

export interface ProspectSmsProps {
    prospectClientId: number
    changeSMSModalStatus: () => void
}

export interface CommunicationHistory {
    otherCommunicationHistoryId: number
    communicationModeId: number
    communicationTypeId: number
    businessTypeId: number
    referenceId: number
    contactNumber: string
    description: string
    historyDate: string
}

export interface ProspectPhoneCallProps {
    prospectClientId: number
    changePhoneCallModalStatus: () => void
}

export interface ProspectHistoryProps {
    prospectClientId: number
    changePhoneCallModalStatus: () => void
    prospectClientHistory: ProspectClientDetailsListCommunicationHistory[]
    prospectClientHistoryCount: number
    setButtonID: React.Dispatch<React.SetStateAction<number | null>>
    seletedButton: number | null
}

export interface ProspectHistorystateProps {
    prospectClientHistory: ProspectClientDetailsListCommunicationHistory[]
    prospectClientHistoryCount: number
}

export interface Email {
    clientEmailId: number
    templateId: number
    serviceProcessId: number
    companyTypeId: number
    referenceId: number
    serviceActionId: number
    serviceActionStepId: number
    fromAddress: string
    toAddress: string
    ccAddress: string
    bccAddress: string
    subject: string
    description: string
    emailStatus: string
    serviceId: number
    contactName: string
    invoiceId: number
}

export interface ProspectChatStateInterface {
    userList: ListFrontEndInterface[]
}
export interface ProspectChatInterface extends ProspectChatStateInterface {
    prospectClientId: number
}

export interface ProcessDetailChat {
    chatId: number
    createdBy: string
    description: string
    dateInfo: string
    imageUrl: string
    createdUser: number
    userList: string
}

export interface DataCHAT {
    clientName: string
    clientNumber: string
    periodStartDate: string
    periodEndDate: string
    serviceId: number
    processDetailChatList: ProcessDetailChat[]
}

export interface ChatMessage {
    chatId: number
    msgType: number
    msgReferenceId: number
    isPinned: number
    description: string
    userIds: number[]
    businessTypeId: number
}
