修复表格滚动高度

This commit is contained in:
whyour
2021-10-31 19:45:51 +08:00
parent 021d89379a
commit b92daedea2
3 changed files with 6 additions and 12 deletions
+2 -4
View File
@@ -677,8 +677,7 @@ const Crontab = ({ headerStyle, isPhone }: any) => {
setTimeout(() => {
if (selectedRowIds.length === 0 || selectedIds.length === 0) {
const offset = isPhone ? 40 : 0;
setTableScrollHeight(getTableScroll() - offset);
setTableScrollHeight(getTableScroll());
}
});
};
@@ -762,9 +761,8 @@ const Crontab = ({ headerStyle, isPhone }: any) => {
useEffect(() => {
setPageSize(parseInt(localStorage.getItem('pageSize') || '20'));
const offset = isPhone ? 40 : 0;
setTimeout(() => {
setTableScrollHeight(getTableScroll() - offset);
setTableScrollHeight(getTableScroll());
});
}, []);