|
@@ -10,6 +10,19 @@ import ReminderList from './components/ReminderList'
|
|
|
|
|
|
|
|
const Dashboard = () => {
|
|
const Dashboard = () => {
|
|
|
const { Option } = Select
|
|
const { Option } = Select
|
|
|
|
|
+ const dataTypeNum = {
|
|
|
|
|
+ 0: '联系人',
|
|
|
|
|
+ 1: '客户',
|
|
|
|
|
+ 2: '商机'
|
|
|
|
|
+ }
|
|
|
|
|
+ const reminderDayNum = {
|
|
|
|
|
+ 3: '7day',
|
|
|
|
|
+ 4: '15day',
|
|
|
|
|
+ 5: '30day',
|
|
|
|
|
+ 6: '3month',
|
|
|
|
|
+ 7: '6month',
|
|
|
|
|
+ 8: 'reminder'
|
|
|
|
|
+ }
|
|
|
const [state, setState] = useState({
|
|
const [state, setState] = useState({
|
|
|
visible: false,
|
|
visible: false,
|
|
|
reminderData: [],
|
|
reminderData: [],
|
|
@@ -27,7 +40,14 @@ const Dashboard = () => {
|
|
|
const handleReminderList = id => {
|
|
const handleReminderList = id => {
|
|
|
setModalProps({
|
|
setModalProps({
|
|
|
width: '90vw',
|
|
width: '90vw',
|
|
|
- modalRender: node => <ReminderList dataId={id} node={node} />,
|
|
|
|
|
|
|
+ modalRender: node => (
|
|
|
|
|
+ <ReminderList
|
|
|
|
|
+ dataId={id}
|
|
|
|
|
+ node={node}
|
|
|
|
|
+ dataType={dataTypeNum[dataTypeNum]}
|
|
|
|
|
+ reminderCyclical={reminderDayNum[reminderDayNum]}
|
|
|
|
|
+ />
|
|
|
|
|
+ ),
|
|
|
onCancel: () => toggleModal()
|
|
onCancel: () => toggleModal()
|
|
|
})
|
|
})
|
|
|
toggleModal()
|
|
toggleModal()
|
|
@@ -84,23 +104,58 @@ const Dashboard = () => {
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
title: '15天',
|
|
title: '15天',
|
|
|
- dataIndex: 'day15'
|
|
|
|
|
|
|
+ dataIndex: 'day15',
|
|
|
|
|
+ render: (name, record) => (
|
|
|
|
|
+ <span
|
|
|
|
|
+ onClick={() => handleReminderList(record.day15)}
|
|
|
|
|
+ className="text-primary cursor-pointer hover:text-[#967bbd]">
|
|
|
|
|
+ {name}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ )
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
title: '30天',
|
|
title: '30天',
|
|
|
- dataIndex: 'day15'
|
|
|
|
|
|
|
+ dataIndex: 'day15',
|
|
|
|
|
+ render: (name, record) => (
|
|
|
|
|
+ <span
|
|
|
|
|
+ onClick={() => handleReminderList(record.day15)}
|
|
|
|
|
+ className="text-primary cursor-pointer hover:text-[#967bbd]">
|
|
|
|
|
+ {name}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ )
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
title: '3个月',
|
|
title: '3个月',
|
|
|
- dataIndex: 'month3'
|
|
|
|
|
|
|
+ dataIndex: 'month3',
|
|
|
|
|
+ render: (name, record) => (
|
|
|
|
|
+ <span
|
|
|
|
|
+ onClick={() => handleReminderList(record.day15)}
|
|
|
|
|
+ className="text-primary cursor-pointer hover:text-[#967bbd]">
|
|
|
|
|
+ {name}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ )
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
title: '6个月',
|
|
title: '6个月',
|
|
|
- dataIndex: 'month6'
|
|
|
|
|
|
|
+ dataIndex: 'month6',
|
|
|
|
|
+ render: (name, record) => (
|
|
|
|
|
+ <span
|
|
|
|
|
+ onClick={() => handleReminderList(record.day15)}
|
|
|
|
|
+ className="text-primary cursor-pointer hover:text-[#967bbd]">
|
|
|
|
|
+ {name}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ )
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
title: '提醒逾期',
|
|
title: '提醒逾期',
|
|
|
- dataIndex: 'remind'
|
|
|
|
|
|
|
+ dataIndex: 'remind',
|
|
|
|
|
+ render: (name, record) => (
|
|
|
|
|
+ <span
|
|
|
|
|
+ onClick={() => handleReminderList(record.day15)}
|
|
|
|
|
+ className="text-primary cursor-pointer hover:text-[#967bbd]">
|
|
|
|
|
+ {name}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ )
|
|
|
}
|
|
}
|
|
|
]
|
|
]
|
|
|
const columnsCustomer = [
|
|
const columnsCustomer = [
|