import React,{ Component } from 'react';
import {Select} from "antd";
import { provinceList} from '@/NewDicProvinceList';
import './index.less';
import TabelContent from '../../../../common/tabelContent'
import DetailedList from './detailedList';
import moment from "moment";
class InterviewStatistics extends Component{
constructor(props) {
super(props);
this.state={
columns: [
{
title: "序号",
dataIndex: "key",
key: "key",
},
{
title: "省份",
dataIndex: "name",
key: "name",
},
{
title: "老客户面谈数",
dataIndex: "useInterview",
key: "useInterview",
className: 'projectTable',
onCellClick: (record, event) => {
event.stopPropagation();
record.type = 1;
this.setState({
visible: true,
recordInfor: record,
})
},
},
{
title: "老客户签单数/金额",
dataIndex: "useQuantity",
key: "useQuantity",
render:(text, record)=>(
text + '/' + record.useTotal
),
className: 'projectTable',
onCellClick: (record, event) => {
event.stopPropagation();
record.type = 1;
this.setState({
visible: true,
recordInfor: record,
})
},
},
{
title: "老客户面谈率",
dataIndex: "useRatio",
key: "useRatio",
render:(text)=>(
parseFloat((parseFloat(text) * 100).toFixed(2)) + '%'
),
className: 'projectTable',
onCellClick: (record, event) => {
event.stopPropagation();
record.type = 1;
this.setState({
visible: true,
recordInfor: record,
})
},
},
{
title: "新客户面谈数",
dataIndex: "newInterview",
key: "newInterview",
className: 'projectTable',
onCellClick: (record, event) => {
event.stopPropagation();
record.type = 2;
this.setState({
visible: true,
recordInfor: record,
})
},
},
{
title: "新客户签单数/金额",
dataIndex: "newQuantity",
key: "newQuantity",
render:(text, record)=>(
text + '/' + record.newTotal
),
className: 'projectTable',
onCellClick: (record, event) => {
event.stopPropagation();
record.type = 2;
this.setState({
visible: true,
recordInfor: record,
})
},
},
{
title: "新客户面谈率",
dataIndex: "newRatio",
key: "newRatio",
render:(text)=>(
parseFloat((parseFloat(text) * 100).toFixed(2)) + '%'
),
className: 'projectTable',
onCellClick: (record, event) => {
event.stopPropagation();
record.type = 2;
this.setState({
visible: true,
recordInfor: record,
})
},
},
{
title: "总面数",
dataIndex: "totalInterview",
key: "totalInterview",
className: 'projectTable',
onCellClick: (record, event) => {
event.stopPropagation();
record.type = 0;
this.setState({
visible: true,
recordInfor: record,
})
},
},
{
title: "总签单数/金额",
dataIndex: "totalQuantity",
key: "totalQuantity",
render:(text, record)=>(
text + '/' + record.total
),
className: 'projectTable',
onCellClick: (record, event) => {
event.stopPropagation();
record.type = 0;
this.setState({
visible: true,
recordInfor: record,
})
},
},
{
title: "总面谈率",
dataIndex: "totalRatio",
key: "totalRatio",
render:(text)=>(
parseFloat((parseFloat(text) * 100).toFixed(2)) + '%'
),
className: 'projectTable',
onCellClick: (record, event) => {
event.stopPropagation();
record.type = 0;
this.setState({
visible: true,
recordInfor: record,
})
},
},
],
searchConfig:{}
}
}
searchList(){
let arr = [
{
type:'departmentSelect',
dataKey:'depId',
placeholder:'请选择部门'
},
{
type:'select',
dataKey:'province',
placeholder:'请选择省份',
selectOptionList:()=>{
let Province = [];
provinceList.map(function(item) {
let id = String(item.id)
Province.push(