From 7c0a57f3a37a36f34191ec2b4dd6a92f4dc2c775 Mon Sep 17 00:00:00 2001 From: xq2005 Date: Fri, 23 Sep 2011 06:23:12 +0000 Subject: [PATCH] users can change the node name on rscan result dialog git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@10618 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-UI/xcat/plugins/web.pm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/xCAT-UI/xcat/plugins/web.pm b/xCAT-UI/xcat/plugins/web.pm index 68a3ad80a..e1d508d4f 100644 --- a/xCAT-UI/xcat/plugins/web.pm +++ b/xCAT-UI/xcat/plugins/web.pm @@ -1913,6 +1913,9 @@ sub web_addnode{ foreach(@tempArray) { $temphash{$_} = 1; } + for (my $i = 0; $i < scalar(@tempArray); $i = $i + 2){ + $temphash{$tempArray[$i]} = $tempArray[$i + 1]; + } `rscan $hcpname -z > /tmp/rscanall.tmp`; #if can not create the rscan result file, error unless(-e '/tmp/rscanall.tmp'){ @@ -1925,7 +1928,7 @@ sub web_addnode{ if ($line =~ /(\S+):$/){ if ($temphash{$1}){ $writeflag = 1; - print OUTPUTFILE $line; + print OUTPUTFILE $temphash{$1} . ":\n"; } else{ $writeflag = 0;