Commit c3494cf9 by zhaochengxiang

资产定位调整

parent be64a216
......@@ -46,7 +46,6 @@ const AssetTable = (props) => {
const timestamp = getQueryParam(AnchorTimestamp, props.location.search);
const shouldScrollRef = useRef(false);
const urlChangeRef = useRef(false);
const cellCache = new CellMeasurerCache({
fixedWidth: true,
......@@ -58,13 +57,9 @@ const AssetTable = (props) => {
if (shouldScrollRef.current === true) {
urlChangeRef.current = false;
shouldScrollRef.current = false;
getDataAssetLocation();
} else if (urlChangeRef.current) {
urlChangeRef.current = false;
} else {
setPagination({ ...pagination, pageNum: 1 });
......@@ -82,7 +77,6 @@ const AssetTable = (props) => {
if ((anchorId||'') !== '') {
shouldScrollRef.current = true;
urlChangeRef.current = true;
}
//eslint-disable-next-line react-hooks/exhaustive-deps
......@@ -99,16 +93,6 @@ const AssetTable = (props) => {
//eslint-disable-next-line react-hooks/exhaustive-deps
}, [ keyword, pagination ])
useEffect(() => {
if (shouldScrollRef.current) {
var anchor = document.querySelector(`#data-asset-${anchorId}`);
if (anchor) {
shouldScrollRef.current = false;
}
}
})
const getDataAssetLocation = () => {
setLoading(true);
dispatch({
......
......@@ -130,16 +130,6 @@ class MapContent extends React.Component {
})
}
setSquareGraphState = (item) => {
const { breadcrumbContents } = this.state;
this.loadedRowsMap = {};
this.setState({
breadcrumbContents: [...breadcrumbContents, { name: item.dirName || '', data: item }],
curTableModelData: item.children || [],
});
}
handleInfiniteOnLoad = ({ startIndex, stopIndex }) => {
const { haveMoreData, curTableModelData } = this.state;
......
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