Commit 4ba91182 by zhaochengxiang

服务搜索高亮

parent d1eac385
......@@ -13,7 +13,7 @@ import ExchangeOwnerModal from './ExchangeOwner';
import Table from '../../ResizeableTable';
import { dispatch } from '../../../../model';
import { showMessage, getQueryParam, paginate, isSzseEnv, formatDate, getDataModelerRole } from '../../../../util';
import { showMessage, getQueryParam, paginate, isSzseEnv, formatDate, getDataModelerRole, highlightSearchContentByTerms } from '../../../../util';
import { AnchorId, AnchorTimestamp, Action, CatalogId, ModelerId, DataModelerRoleReader } from '../../../../util/constant';
import { AppContext } from "../../../../App";
import SelectUser from "./SelectUsers";
......@@ -544,7 +544,7 @@ const ModelTable = (props) => {
width: 200,
render: (_, record) => {
return <Tooltip title={record.basicInfo ? record.basicInfo[item.key] : ''}>
<Text ellipsis={true}>{record.basicInfo ? record.basicInfo[item.key] : ''}</Text>
<Text ellipsis={true}>{highlightSearchContentByTerms(record.basicInfo?record.basicInfo[item.key]:'', [keyword??''], true) }</Text>
</Tooltip>
}
};
......@@ -581,7 +581,7 @@ const ModelTable = (props) => {
}
return newCols;
}, [visibleColNames, attrs, indexCol, actionCol, modelId, detailItem, users, pagination])
}, [visibleColNames, attrs, indexCol, actionCol, modelId, detailItem, users, pagination, keyword])
const modelEventChange = (e) => {
if (e.key === 'modelChange') {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment