mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Change icons for table inheritance (icons by Chethana Kumar) Fixes #3174
Along with this, I have also fixed few other issues/icons found on the way: 1) Dependencies tab for inherited tables/foreign keys shows partial text (Fixes ##3994). 2) Dependencies tab for child partition table shows parent partition table as Function. 3) Dependencies tab for triggers shows trigger functions as plain functions. 4) Dependents tab for partitioned table shows the child partition tables as normal table instead for partitioned tables.
This commit is contained in:
committed by
Dave Page
parent
bf548dda3f
commit
402dfd07db
@@ -46,10 +46,12 @@ define('misc.dependents', [
|
||||
// This function is used to fetch/set the icon for the type(Function, Role, Database, ....)
|
||||
parse: function(res) {
|
||||
var node = pgBrowser.Nodes[res.type];
|
||||
res.icon = node ? (_.isFunction(node['node_image']) ?
|
||||
(node['node_image']).apply(node, [null, null]) :
|
||||
(node['node_image'] || ('icon-' + res.type))) :
|
||||
('icon-' + res.type);
|
||||
if(res.icon == null || res.icon == '') {
|
||||
res.icon = node ? (_.isFunction(node['node_image']) ?
|
||||
(node['node_image']).apply(node, [null, null]) :
|
||||
(node['node_image'] || ('icon-' + res.type))) :
|
||||
('icon-' + res.type);
|
||||
}
|
||||
res.type = S.titleize(res.type.replace(/_/g, ' '), true);
|
||||
return res;
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user