环境变量值增加复制功能

This commit is contained in:
whyour 2022-11-03 17:34:36 +08:00
parent 73c6fd18ed
commit 19a58a3510
3 changed files with 8 additions and 5 deletions

View File

@ -1037,6 +1037,7 @@ const Crontab = () => {
const tabClick = (key: string) => {
const view = enabledCronViews.find((x) => x.id == key);
setSelectedRowIds([]);
setPageConf({ ...pageConf, page: 1 });
setViewConf(view ? view : null);
};

View File

@ -286,7 +286,7 @@ const Dependence = () => {
setTimeout(() => {
if (selectedRowIds.length === 0 || selectedIds.length === 0) {
setTableScrollHeight(getTableScroll({ extraHeight: 87 }));
setTableScrollHeight(getTableScroll({ extraHeight: 59 }));
}
});
};
@ -370,7 +370,7 @@ const Dependence = () => {
useEffect(() => {
if (tableRef.current) {
setTableScrollHeight(getTableScroll({ extraHeight: 87 }));
setTableScrollHeight(getTableScroll({ extraHeight: 59 }));
}
}, []);
@ -470,6 +470,7 @@ const Dependence = () => {
);
const onTabChange = (activeKey: string) => {
setSelectedRowIds([]);
setType(activeKey);
};

View File

@ -134,6 +134,7 @@ const Env = () => {
textAlign: 'left',
}}
ellipsis={{ tooltip: text, rows: 2 }}
copyable
>
{text}
</Paragraph>
@ -410,7 +411,7 @@ const Env = () => {
setTimeout(() => {
if (selectedRowIds.length === 0 || selectedIds.length === 0) {
setTableScrollHeight(getTableScroll({ extraHeight: 87 }));
setTableScrollHeight(getTableScroll({ extraHeight: 59 }));
}
});
};
@ -510,7 +511,7 @@ const Env = () => {
useEffect(() => {
if (tableRef.current) {
setTableScrollHeight(getTableScroll({ extraHeight: 87 }));
setTableScrollHeight(getTableScroll({ extraHeight: 59 }));
}
}, []);
@ -598,7 +599,7 @@ const Env = () => {
scroll={{ x: 1000, y: tableScrollHeight }}
components={components}
loading={loading}
onRow={(record: any, index: number) => {
onRow={(record: any, index: number | undefined) => {
return {
index,
moveRow,