|
|
@@ -24,11 +24,16 @@ const LeaderBoard = ({ loading = false, dataList = [] }) => {
|
|
|
const oColumns = [
|
|
|
{
|
|
|
title: '排名',
|
|
|
- dataIndex: 'rank',
|
|
|
+ dataIndex: 'index',
|
|
|
+ valueType: 'indexBorder',
|
|
|
align: 'center',
|
|
|
width: '30%',
|
|
|
- render: (_, record) =>
|
|
|
- record.rank <= 3 ? <Iconfont type="icon-trophy" className={colorMap[record.rank]} /> : ''
|
|
|
+ render: (_, __, index) =>
|
|
|
+ index + 1 <= 3 ? (
|
|
|
+ <span className={colorMap[index + 1]}>
|
|
|
+ <Iconfont type="icon-trophy" />
|
|
|
+ </span>
|
|
|
+ ) : null
|
|
|
},
|
|
|
{
|
|
|
title: '姓名',
|