mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Few more changes to core schema framework required by other nodes.
This commit is contained in:
committed by
Akshay Joshi
parent
351928a1e0
commit
9d33b03be9
@@ -105,7 +105,7 @@ export function getNodeAjaxOptions(url, nodeObj, treeNodeInfo, itemNodeData, par
|
||||
}
|
||||
|
||||
/* Get the nodes list based on current selected node id */
|
||||
export function getNodeListById(nodeObj, treeNodeInfo, itemNodeData, filter=()=>true) {
|
||||
export function getNodeListById(nodeObj, treeNodeInfo, itemNodeData, params={}, filter=()=>true) {
|
||||
/* Transform the result to add image details */
|
||||
const transform = (rows) => {
|
||||
var res = [];
|
||||
@@ -130,11 +130,11 @@ export function getNodeListById(nodeObj, treeNodeInfo, itemNodeData, filter=()=>
|
||||
return res;
|
||||
};
|
||||
|
||||
return getNodeAjaxOptions('nodes', nodeObj, treeNodeInfo, itemNodeData, null, transform);
|
||||
return getNodeAjaxOptions('nodes', nodeObj, treeNodeInfo, itemNodeData, params, transform);
|
||||
}
|
||||
|
||||
/* Get the nodes list based on node name passed */
|
||||
export function getNodeListByName(node, treeNodeInfo, itemNodeData, filter=()=>true, postTransform=(res)=>res) {
|
||||
export function getNodeListByName(node, treeNodeInfo, itemNodeData, params={}, filter=()=>true, postTransform=(res)=>res) {
|
||||
let nodeObj = pgAdmin.Browser.Nodes[node];
|
||||
/* Transform the result to add image details */
|
||||
const transform = (rows) => {
|
||||
@@ -160,5 +160,5 @@ export function getNodeListByName(node, treeNodeInfo, itemNodeData, filter=()=>t
|
||||
return postTransform(res);
|
||||
};
|
||||
|
||||
return getNodeAjaxOptions('nodes', nodeObj, treeNodeInfo, itemNodeData, null, transform);
|
||||
return getNodeAjaxOptions('nodes', nodeObj, treeNodeInfo, itemNodeData, params, transform);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user