[Ovirt-devel] [PATCH] fixed some 500 internal server errors
Hugh O. Brock
hbrock at redhat.com
Mon Jun 2 16:01:13 UTC 2008
On Fri, May 30, 2008 at 06:13:00PM -0400, Jason Guiditta wrote:
> Including all 4 pieces of this patch, for easier application, but the
> only new one is 0004. Some variables were not getting set, pretty
> simple fix.
>
> -j
[ snipped the first 3 already posted to the list ]
> >From 2128e2a6b5aa44387f1a5c2a5d366a25392ac377 Mon Sep 17 00:00:00 2001
> >From: Jason Guiditta <jguiditt at redhat.com>
> Date: Fri, 30 May 2008 18:08:15 -0400
> Subject: [PATCH] some of the show methods had variaable to be set, but were calling the parent show method first, so variables werenever set
>
>
> Signed-off-by: Jason Guiditta <jguiditt at redhat.com>
> ---
> wui/src/app/controllers/hardware_controller.rb | 8 ++++----
> wui/src/app/controllers/resources_controller.rb | 8 ++++----
> 2 files changed, 8 insertions(+), 8 deletions(-)
>
> diff --git a/wui/src/app/controllers/hardware_controller.rb b/wui/src/app/controllers/hardware_controller.rb
> index b86d929..97f5df2 100644
> --- a/wui/src/app/controllers/hardware_controller.rb
> +++ b/wui/src/app/controllers/hardware_controller.rb
> @@ -80,14 +80,14 @@ class HardwareController < ApplicationController
> show
> end
>
> - def show_users
> - show
> + def show_users
> @roles = Permission::ROLES.keys
> + show
> end
>
> - def show_hosts
> - show
> + def show_hosts
> @hardware_pools = HardwarePool.find :all
> + show
> end
>
> def show_graphs
> diff --git a/wui/src/app/controllers/resources_controller.rb b/wui/src/app/controllers/resources_controller.rb
> index e9a0cba..704abd1 100644
> --- a/wui/src/app/controllers/resources_controller.rb
> +++ b/wui/src/app/controllers/resources_controller.rb
> @@ -71,20 +71,20 @@ class ResourcesController < ApplicationController
> end
>
> # resource's vms list page
> - def show_vms
> - show
> + def show_vms
> @actions = [VmTask.label_and_action(VmTask::ACTION_START_VM),
> (VmTask.label_and_action(VmTask::ACTION_SHUTDOWN_VM) << "break"),
> VmTask.label_and_action(VmTask::ACTION_SUSPEND_VM),
> VmTask.label_and_action(VmTask::ACTION_RESUME_VM),
> VmTask.label_and_action(VmTask::ACTION_SAVE_VM),
> VmTask.label_and_action(VmTask::ACTION_RESTORE_VM)]
> + show
> end
>
> # resource's users list page
> - def show_users
> - show
> + def show_users
> @roles = Permission::ROLES.keys
> + show
> end
>
> def vms_json
> --
> 1.5.4.1
ACK, this appears to work fine. I have committed and pushed it along
with the other three that preceded it.
Is it easy, or worth doing, to include a check so that the content
pane does not reload if the user clicks its link in the tree again? Or
do we *want* it to reload?
Take care,
--Hugh
More information about the ovirt-devel
mailing list