export type CustomerStatus = '正常' | '黑名单';

export type CoopStatus = '已合作' | '终止合作' | '洽谈中' | '合同到期';

export interface CustomerRecord {
  id: string;
  code: string;
  name: string;
  labels: string[];
  region: string;
  status: CustomerStatus;
  department: string;
  manager: string;
  customerType: string;
  industry: string;
  creditCode: string;
  legalPerson: string;
  regCapital: string;
  operateStatus: string;
  address: string;
  createTime: string;
}

export interface CustomerFilters {
  code: string;
  name: string;
  labels: string[];
  region: string;
  statuses: CustomerStatus[];
  departments: string[];
  managers: string[];
  createFrom: string;
  createTo: string;
}

export const EMPTY_FILTERS: CustomerFilters = {
  code: '',
  name: '',
  labels: [],
  region: '',
  statuses: [],
  departments: [],
  managers: [],
  createFrom: '',
  createTo: '',
};

export interface CustomerCreateForm {
  customerType: string;
  customerLevel: string;
  coopStatus: string;
  customerName: string;
  customerShortName: string;
  cityProvince: string;
  cityName: string;
  address: string;
  department: string;
  manager: string;
  remark: string;
  contactName: string;
  contactPhone: string;
  contactPosition: string;
  invoiceTitle: string;
  taxId: string;
  regAddress: string;
  regPhone: string;
  bankName: string;
  bankAccount: string;
}

export const EMPTY_CREATE_FORM: CustomerCreateForm = {
  customerType: '企业',
  customerLevel: 'B',
  coopStatus: '',
  customerName: '',
  customerShortName: '',
  cityProvince: '',
  cityName: '',
  address: '',
  department: '',
  manager: '',
  remark: '',
  contactName: '',
  contactPhone: '',
  contactPosition: '',
  invoiceTitle: '',
  taxId: '',
  regAddress: '',
  regPhone: '',
  bankName: '',
  bankAccount: '',
};

export type CustomerPageId = 'list' | 'create';
