mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Fixed an issue where the Dashboard Server Activity was showing old queries as active. Fixes #7305
This commit is contained in:
committed by
Akshay Joshi
parent
6e2ee9a21f
commit
7c61017f57
@@ -353,18 +353,16 @@ export default function Dashboard({
|
||||
onClick={(e) => {
|
||||
e.preventDefault();
|
||||
row.toggleRowExpanded(!row.isExpanded);
|
||||
if(!(row.id in schemaDict)){
|
||||
let schema = new ActiveQuery({
|
||||
query: row.original.query,
|
||||
backend_type: row.original.backend_type,
|
||||
state_change: row.original.state_change,
|
||||
query_start: row.original.query_start,
|
||||
});
|
||||
setSchemaDict(prevState => ({
|
||||
...prevState,
|
||||
[row.id]: schema
|
||||
}));
|
||||
}
|
||||
let schema = new ActiveQuery({
|
||||
query: row.original.query,
|
||||
backend_type: row.original.backend_type,
|
||||
state_change: row.original.state_change,
|
||||
query_start: row.original.query_start,
|
||||
});
|
||||
setSchemaDict(prevState => ({
|
||||
...prevState,
|
||||
[row.id]: schema
|
||||
}));
|
||||
}}
|
||||
disabled={!canEditRow}
|
||||
aria-label="View the active session details"
|
||||
|
||||
Reference in New Issue
Block a user