[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [Ovirt-devel] [PATCH] Fix broken js cause by svg widget.



Jason Guiditta wrote:
> This just disables the calls to svg widget within any flexigrids, which is the cause of checkboxes not appearing, details not showing, and other such unpleasantness.  Next step would be to replace these bits with css bar graphs, which will hopefully make it in shortly, but as this breakage is annoying, thought I would do a quick fix.
> Also, slightly changed mmorsi's check to bypass apache for dev so it is still ised with production settings, but not in test or development.

ACK
w/ comments:

> --- a/wui/src/app/controllers/application.rb
> +++ b/wui/src/app/controllers/application.rb

>    def get_login_user
> -    if ENV["RAILS_ENV"] != 'test'
> +    if ENV["RAILS_ENV"] == 'production'

after session auth patch, this check is now in login_controller.rb:

--- a/wui/src/app/controllers/login_controller.rb
+++ b/wui/src/app/controllers/login_controller.rb
@@ -25,7 +25,7 @@ class LoginController < ActionController::Base
   before_filter :is_logged_in, :except => :login
   def login
     myUser = "ovirtadmin"
-    if ENV["RAILS_ENV"] != "test"
+    if ENV["RAILS_ENV"] == "production"
       myUser = user_from_principal(request.env["HTTP_X_FORWARDED_USER"])
     end
     session[:user] = myUser

> diff --git a/wui/src/app/views/graph/_load_graph.rhtml b/wui/src/app/views/graph/_load_graph.rhtml
> -  $(div).svg();
> -  var svg = svgManager.getSVGFor(div);
> +  //$(div).svg();
> +  //var svg = svgManager.getSVGFor(div);

just delete lines, don't comment out, we have git to keep history
same for the rest of the file


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]