From 135ca0d7b5e9595352efe9fd858a8b9a373bdd20 Mon Sep 17 00:00:00 2001 From: zhangwenshuai Date: Mon, 29 Jun 2020 17:19:03 +0800 Subject: [PATCH] update icon --- components/CustomIcon/IconFont.js | 2 +- components/IconFont/IconFont.ts | 2 +- components/apolloTable/component/Cell.tsx | 11 ++++++++--- .../component/base/detail/text-link/index.tsx | 4 ++-- 4 files changed, 12 insertions(+), 7 deletions(-) diff --git a/components/CustomIcon/IconFont.js b/components/CustomIcon/IconFont.js index 3786e9d..4b9f9ec 100755 --- a/components/CustomIcon/IconFont.js +++ b/components/CustomIcon/IconFont.js @@ -1,7 +1,7 @@ import { createFromIconfontCN } from '@ant-design/icons'; const IconFont = createFromIconfontCN({ - scriptUrl: 'https://influencer-attachment.mttop.cn/influencer/v2/website/20200524/iconFont.js', + scriptUrl: 'https://influencer-attachment.mttop.cn/influencer/v2/website/20200629/iconFont.js', }); export default IconFont; diff --git a/components/IconFont/IconFont.ts b/components/IconFont/IconFont.ts index cb9fe8b..4b9f9ec 100755 --- a/components/IconFont/IconFont.ts +++ b/components/IconFont/IconFont.ts @@ -1,7 +1,7 @@ import { createFromIconfontCN } from '@ant-design/icons'; const IconFont = createFromIconfontCN({ - scriptUrl: 'https://influencer-attachment.mttop.cn//influencer/v2/website/20200613/iconFont.js', + scriptUrl: 'https://influencer-attachment.mttop.cn/influencer/v2/website/20200629/iconFont.js', }); export default IconFont; diff --git a/components/apolloTable/component/Cell.tsx b/components/apolloTable/component/Cell.tsx index 0e9188b..c485a7e 100644 --- a/components/apolloTable/component/Cell.tsx +++ b/components/apolloTable/component/Cell.tsx @@ -160,10 +160,15 @@ const Cell = (props: CellProps) => { return (current - 1) * pageSize + rowIndex + 1; }; const getCheckedIndex = () => { + if (!rowSelection) { + return -1; + } const { selectedRows } = rowSelection; - const index = selectedRows.findIndex((item: any) => { - return item.id === record.id; - }); + const index = + selectedRows && + selectedRows.findIndex((item: any) => { + return item.id === record.id; + }); return index; }; const getCheckbox = () => { diff --git a/components/apolloTable/component/base/detail/text-link/index.tsx b/components/apolloTable/component/base/detail/text-link/index.tsx index fa04a74..eff6e9b 100644 --- a/components/apolloTable/component/base/detail/text-link/index.tsx +++ b/components/apolloTable/component/base/detail/text-link/index.tsx @@ -2,7 +2,7 @@ import React, { useState, useRef, useEffect } from 'react'; import { Popover } from 'antd'; import classNames from 'classnames'; import s from './index.less'; -import extendIcon from '../../../../assets/extend.png'; +import IconFont from '@/submodule/components/IconFont'; export const ApolloTextLinkDetail = (props: any) => { const { value, origin, formatter } = props; @@ -86,7 +86,7 @@ export const ApolloTextLinkDetail = (props: any) => { } >
- +
)} -- 2.21.0