public inbox for [email protected]
help / color / mirror / Atom feedFrom: Pradip Parkale <[email protected]>
To: Akshay Joshi <[email protected]>
Cc: pgadmin-hackers <[email protected]>
Subject: Re: [pgAdmin][RM7296]: Browser tree is not getting refresh after deleting the multiple node from collection properties
Date: Mon, 11 Apr 2022 17:22:28 +0530
Message-ID: <CAJ9T6SvHYja_nku0bBpa85HvFEMkwLyDXzyZ51s_NPy2KBF-HA@mail.gmail.com> (raw)
In-Reply-To: <CANxoLDdT2uMOqZgipH1KMse3r=R6BmT+8Bkp1_VYHTBhX+OPhQ@mail.gmail.com>
References: <CAJ9T6SvSy4jwPGgPJq=a+xC=-ujNaMuMdVEx8MONO+eYLhfmFg@mail.gmail.com>
<CANxoLDdT2uMOqZgipH1KMse3r=R6BmT+8Bkp1_VYHTBhX+OPhQ@mail.gmail.com>
Hi Akshay,
Please find the attached patch for the issue below.
1. When deleting the constraint from the collection properties nodes, an
error occurred
2. The code to refresh the Dashboard after deleted session activities
has been improved.
On Sat, Apr 9, 2022 at 12:06 PM Akshay Joshi <[email protected]>
wrote:
> Thanks, the patch applied.
>
> On Fri, Apr 8, 2022 at 12:29 PM Pradip Parkale <
> [email protected]> wrote:
>
>> Hi Hackers,
>>
>> Please find the attached patch for #7296.I have fixed the issue where the
>> browser tree did not refresh after multiple nodes were deleted.
>>
>> --
>> Thanks & Regards,
>> Pradip Parkale
>> Software Engineer | EnterpriseDB Corporation
>>
>
>
> --
> *Thanks & Regards*
> *Akshay Joshi*
> *pgAdmin Hacker | Principal Software Architect*
> *EDB Postgres <http://edbpostgres.com>*
>
> *Mobile: +91 976-788-8246*
>
--
Thanks & Regards,
Pradip Parkale
Software Engineer | EnterpriseDB Corporation
Attachments:
[application/octet-stream] refresh.patch (2.3K, 3-refresh.patch)
download | inline diff:
diff --git a/web/pgadmin/dashboard/static/js/Dashboard.jsx b/web/pgadmin/dashboard/static/js/Dashboard.jsx
index 4c0d91874..4b7d779cc 100644
--- a/web/pgadmin/dashboard/static/js/Dashboard.jsx
+++ b/web/pgadmin/dashboard/static/js/Dashboard.jsx
@@ -128,7 +128,7 @@ export default function Dashboard({
const [msg, setMsg] = useState('');
const[infoMsg, setInfo] = useState('');
const [val, setVal] = useState(0);
- const [refresh, setRefresh] = useState();
+ const [refresh, setRefresh] = useState(false);
const [schemaDict, setSchemaDict] = React.useState({});
if (!did) {
@@ -235,6 +235,7 @@ export default function Dashboard({
if (res.data == gettext('Success')) {
setInfo(txtSuccess);
Notify.success(txtSuccess);
+ setRefresh(!refresh);
} else {
setInfo(txtError);
Notify.error(txtError);
@@ -769,9 +770,6 @@ export default function Dashboard({
if (message != '') {
setMsg(message);
}
- return () => {
- setRefresh();
- };
}, [nodeData, val, did, preferences, infoMsg, refresh, props.dbConnected]);
const RefreshButton = () =>{
@@ -783,7 +781,7 @@ export default function Dashboard({
icon={<CachedIcon />}
onClick={(e) => {
e.preventDefault();
- setRefresh(true);
+ setRefresh(!refresh);
}}
color="default"
aria-label="Refresh"
diff --git a/web/pgadmin/misc/properties/CollectionNodeProperties.jsx b/web/pgadmin/misc/properties/CollectionNodeProperties.jsx
index 9d340914d..5823fed4b 100644
--- a/web/pgadmin/misc/properties/CollectionNodeProperties.jsx
+++ b/web/pgadmin/misc/properties/CollectionNodeProperties.jsx
@@ -122,8 +122,8 @@ export function CollectionNodeView({
if (selNode && selNode.type && selNode.type == 'coll-constraints') {
// In order to identify the constraint type, the type should be passed to the server
selRows = selRowModels.map((row) => ({
- id: row.get('oid'),
- _type: row.get('_type'),
+ id: row.original.oid,
+ _type: row.original._type,
}));
} else {
selRows = selRowModels.map((row) => row.original.oid);
view thread (4+ messages) latest in thread
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected]
Subject: Re: [pgAdmin][RM7296]: Browser tree is not getting refresh after deleting the multiple node from collection properties
In-Reply-To: <CAJ9T6SvHYja_nku0bBpa85HvFEMkwLyDXzyZ51s_NPy2KBF-HA@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox