Mailinglist Archive: yast-commit (2114 mails)

< Previous Next >
[yast-commit] <web-client> network : Fixed failing tests.
  • From: Martin Vidner <mvidner@xxxxxxx>
  • Date: Wed, 16 Sep 2009 22:31:08 +0200
  • Message-id: <E1Mo1sM-0001iY-8V@xxxxxxxxxxxxxxxx>
ref: refs/heads/network
commit 193a61017d84fe8b31b2c7ed69263b5409b8d6bd
Author: Martin Vidner <mvidner@xxxxxxx>
Date: Wed Sep 16 22:31:08 2009 +0200

Fixed failing tests.
---
.../network/app/controllers/network_controller.rb | 7 +++++--
plugins/network/app/views/network/index.html.erb | 2 +-
2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/plugins/network/app/controllers/network_controller.rb
b/plugins/network/app/controllers/network_controller.rb
index 2e62adc..29c2f74 100644
--- a/plugins/network/app/controllers/network_controller.rb
+++ b/plugins/network/app/controllers/network_controller.rb
@@ -17,7 +17,11 @@ class NetworkController < ApplicationController
def index

@ifcs = load_proxy "org.opensuse.yast.modules.yapi.network.interfaces",
:all
- @iface = params[:interface] || @ifcs.find {|i| i.bootproto!=nil}.id ||
@ifcs[0].id
+ @iface = params[:interface]
+ unless @iface
+ ifc = @ifcs.find {|i| i.bootproto!=nil} || @ifcs[0]
+ @iface = ifc.id
+ end

ifc = load_proxy "org.opensuse.yast.modules.yapi.network.interfaces",
@iface
return false unless ifc
@@ -38,7 +42,6 @@ class NetworkController < ApplicationController
redirect_to root_path
return false
end
-

@conf_mode = ifc.bootproto
if @conf_mode == "static"
diff --git a/plugins/network/app/views/network/index.html.erb
b/plugins/network/app/views/network/index.html.erb
index 82b6c57..50a20b1 100644
--- a/plugins/network/app/views/network/index.html.erb
+++ b/plugins/network/app/views/network/index.html.erb
@@ -5,7 +5,7 @@
<% disabled = ! @permissions[:write] %>


-<% form_tag("/network", :method => "get") do |f| %>
+<% form_tag("/network", :method => "get") do %>
<!-- (collection, value, text, selected) -->
<div class="table">
<table class="list" cellpadding="0" cellspacing="0">
--
To unsubscribe, e-mail: yast-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages