mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Fix an issue where type column in dependents/dependencies tab is not showing correct label. #7225
This commit is contained in:
@@ -34,3 +34,4 @@ Bug fixes
|
|||||||
| `Issue #6808 <https://github.com/pgadmin-org/pgadmin4/issues/6808>`_ - Fix the tabbed panel backward/forward shortcut for tabs.
|
| `Issue #6808 <https://github.com/pgadmin-org/pgadmin4/issues/6808>`_ - Fix the tabbed panel backward/forward shortcut for tabs.
|
||||||
| `Issue #7164 <https://github.com/pgadmin-org/pgadmin4/issues/7164>`_ - Fix an issue where constraint check control is enabled in the edit table dialog.
|
| `Issue #7164 <https://github.com/pgadmin-org/pgadmin4/issues/7164>`_ - Fix an issue where constraint check control is enabled in the edit table dialog.
|
||||||
| `Issue #7165 <https://github.com/pgadmin-org/pgadmin4/issues/7165>`_ - Fix an issue where the scripts created by generate script of Schema diff for Table with sequence was not working earlier.
|
| `Issue #7165 <https://github.com/pgadmin-org/pgadmin4/issues/7165>`_ - Fix an issue where the scripts created by generate script of Schema diff for Table with sequence was not working earlier.
|
||||||
|
| `Issue #7225 <https://github.com/pgadmin-org/pgadmin4/issues/7225>`_ - Fix an issue where type column in dependents/dependencies tab is not showing correct label.
|
||||||
|
|||||||
@@ -88,6 +88,9 @@ function Dependents({ nodeData, nodeItem, node, treeNodeInfo, isActive, isStale,
|
|||||||
sortable: true,
|
sortable: true,
|
||||||
resizable: true,
|
resizable: true,
|
||||||
disableGlobalFilter: false,
|
disableGlobalFilter: false,
|
||||||
|
Cell: ({row})=>{
|
||||||
|
return pgAdmin.Browser.Nodes?.[row.original.type]?.label??row.original.type;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
Header: 'Name',
|
Header: 'Name',
|
||||||
|
|||||||
@@ -193,7 +193,7 @@ export default function CollectionNodeProperties({
|
|||||||
};
|
};
|
||||||
|
|
||||||
React.useEffect(() => {
|
React.useEffect(() => {
|
||||||
if (node){
|
if (node) {
|
||||||
|
|
||||||
let nodeObj =
|
let nodeObj =
|
||||||
pgAdmin.Browser.Nodes[nodeData?._type.replace('coll-', '')];
|
pgAdmin.Browser.Nodes[nodeData?._type.replace('coll-', '')];
|
||||||
@@ -204,6 +204,10 @@ export default function CollectionNodeProperties({
|
|||||||
|
|
||||||
let tableColumns = [];
|
let tableColumns = [];
|
||||||
let column = {};
|
let column = {};
|
||||||
|
if(!isStale || !isActive) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
setLoaderText(gettext('Loading...'));
|
setLoaderText(gettext('Loading...'));
|
||||||
|
|
||||||
if (nodeData._type.indexOf('coll-') > -1 && !_.isUndefined(nodeObj.getSchema)) {
|
if (nodeData._type.indexOf('coll-') > -1 && !_.isUndefined(nodeObj.getSchema)) {
|
||||||
@@ -250,9 +254,6 @@ export default function CollectionNodeProperties({
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!isStale || !isActive) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
api({
|
api({
|
||||||
url: url,
|
url: url,
|
||||||
@@ -275,7 +276,7 @@ export default function CollectionNodeProperties({
|
|||||||
});
|
});
|
||||||
setIsStale(false);
|
setIsStale(false);
|
||||||
}
|
}
|
||||||
}, [nodeData, node, nodeItem, isStale]);
|
}, [nodeData, node, nodeItem, isStale, isActive]);
|
||||||
|
|
||||||
const CustomHeader = () => {
|
const CustomHeader = () => {
|
||||||
const canDrop = evalFunc(node, node.canDrop, nodeData, nodeItem, treeNodeInfo);
|
const canDrop = evalFunc(node, node.canDrop, nodeData, nodeItem, treeNodeInfo);
|
||||||
|
|||||||
Reference in New Issue
Block a user