![](https://seccdn.libravatar.org/avatar/f9a9cf77af20d925b328ee8c95c0068c.jpg?s=120&d=mm&r=g)
On 09/03/2009 12:14 PM, Michal Zugec wrote:
ref: refs/heads/network commit b72baab724ea256472be56efe577c9231df97881 Author: Michal Zugec <mzugec@suse.cz> Date: Thu Sep 3 12:14:49 2009 +0200
dns model shows xml list --- plugins/network/app/models/dns.rb | 14 +++++++++++--- 1 files changed, 11 insertions(+), 3 deletions(-)
diff --git a/plugins/network/app/models/dns.rb b/plugins/network/app/models/dns.rb index 6a03736..f153a75 100644 --- a/plugins/network/app/models/dns.rb +++ b/plugins/network/app/models/dns.rb @@ -42,9 +42,17 @@ class DNS xml = options[:builder] ||= Builder::XmlMarkup.new(options) xml.instruct! unless options[:skip_instruct]
- xml.hostname do - xml.domains @domains - xml.servers @servers + xml.dns do + xml.domains({:type => "array"}) do + domains.each do |@domains, val| + xml.tag!(:domain, domains) + end + end + xml.servers({:type => "array"}) do + servers.each do |@servers, val| + xml.tag!(:nameserver, servers) + end + end end end
Hi, I see it quite often in code and Karel on session say, that instead xml.tag!(:domain, domains) we should use simple xml.domain domains -- Josef Reidinger YaST team maintainer of perl-Bootloader, YaST2-Repair, webyast modules language and time -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org