| | |
| | | import { maskPhoneNumber } from '@/utils/utils'; |
| | | import { PageContainer, ProTable } from '@ant-design/pro-components'; |
| | | import { DatePicker, Input, message, Select, Tag, Typography } from 'antd'; |
| | | import { DatePicker, message, Select, Tag, Typography } from 'antd'; |
| | | import moment from 'moment'; |
| | | import { useRef } from 'react'; |
| | | import { getCallRecords } from './service'; |
| | |
| | | ANSWER: '已接通', |
| | | NO_ANSWER: '未接通', |
| | | }; |
| | | |
| | | const callStatusOptions = Object.entries(callStatusLabels).map(([value, label]) => ({ value, label })); |
| | | |
| | | const hangupPartyLabels = { |
| | | CUSTOMER: '客户', |
| | |
| | | title: '通话状态', |
| | | dataIndex: 'status', |
| | | width: 140, |
| | | renderFormItem: () => <Input placeholder="如 ANSWER" />, |
| | | renderFormItem: () => <Select allowClear options={callStatusOptions} placeholder="请选择通话状态" />, |
| | | hideInTable: true, |
| | | }, |
| | | { |
| | |
| | | hideInSearch: true, |
| | | ellipsis: true, |
| | | render: renderText, |
| | | }, |
| | | { |
| | | title: '通话路径', |
| | | dataIndex: 'recordUrl', |
| | | width: 120, |
| | | hideInSearch: true, |
| | | render: (url) => |
| | | url ? ( |
| | | <Typography.Link href={url} download> |
| | | 下载录音 |
| | | </Typography.Link> |
| | | ) : ( |
| | | '-' |
| | | ), |
| | | }, |
| | | { |
| | | title: '通话录音', |