From d5da920dfe9951109d7553fd1bb2ceb2e5980a20 Mon Sep 17 00:00:00 2001 From: bp-sawyers Date: Fri, 5 Mar 2010 21:01:24 +0000 Subject: [PATCH] Moved hosts and presecripts attrs to the common node and group def section so they show up for group listings git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@5392 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- perl-xCAT/xCAT/Schema.pm | 64 ++++++++++++++++++---------------------- 1 file changed, 28 insertions(+), 36 deletions(-) diff --git a/perl-xCAT/xCAT/Schema.pm b/perl-xCAT/xCAT/Schema.pm index 29668d74e..10b4f9241 100644 --- a/perl-xCAT/xCAT/Schema.pm +++ b/perl-xCAT/xCAT/Schema.pm @@ -1512,7 +1512,33 @@ my @nodeattrs = ( tabentry => 'switch.interface', access_tabentry => 'switch.node=attr:node', }, - ); +#################### +# hosts table # +#################### + {attr_name => 'ip', + tabentry => 'hosts.ip', + access_tabentry => 'hosts.node=attr:node', + }, + {attr_name => 'hostnames', + tabentry => 'hosts.hostnames', + access_tabentry => 'hosts.node=attr:node', + }, + {attr_name => 'otherinterfaces', + tabentry => 'hosts.otherinterfaces', + access_tabentry => 'hosts.node=attr:node', + }, +#################### +# prescripts table# +#################### + {attr_name => 'prescripts-begin', + tabentry => 'prescripts.begin', + access_tabentry => 'prescripts.node=attr:node', + }, + {attr_name => 'prescripts-end', + tabentry => 'prescripts.end', + access_tabentry => 'prescripts.node=attr:node', + }, + ); # end of @nodeattrs that applies to both nodes and groups #################### @@ -1542,36 +1568,10 @@ my @nodeattrs = ( tabentry => 'nodelist.primarysn', access_tabentry => 'nodelist.node=attr:node', }, -#################### -# hosts table # -#################### - {attr_name => 'ip', - tabentry => 'hosts.ip', - access_tabentry => 'hosts.node=attr:node', - }, - {attr_name => 'hostnames', - tabentry => 'hosts.hostnames', - access_tabentry => 'hosts.node=attr:node', - }, - {attr_name => 'otherinterfaces', - tabentry => 'hosts.otherinterfaces', - access_tabentry => 'hosts.node=attr:node', - }, - {attr_name => 'usercomment', + {attr_name => 'usercomment', tabentry => 'nodelist.comments', access_tabentry => 'nodelist.node=attr:node', }, -#################### -# prescripts table# -#################### - {attr_name => 'prescripts-begin', - tabentry => 'prescripts.begin', - access_tabentry => 'prescripts.node=attr:node', - }, - {attr_name => 'prescripts-end', - tabentry => 'prescripts.end', - access_tabentry => 'prescripts.node=attr:node', - }, ); # add on the node attrs from other tables @@ -1864,14 +1864,6 @@ push(@{$defspec{node}->{'attrs'}}, @nodeattrs); tabentry => 'nodegroup.wherevals', access_tabentry => 'nodegroup.groupname=attr:groupname', }, - {attr_name => 'ip', - tabentry => 'hosts.ip', - access_tabentry => 'hosts.node=attr:node', - }, - {attr_name => 'hostnames', - tabentry => 'hosts.hostnames', - access_tabentry => 'hosts.node=attr:node', - }, {attr_name => 'usercomment', tabentry => 'nodegroup.comments', access_tabentry => 'nodegroup.groupname=attr:groupname',