Bug 1602023 - Open URL Does Not Work When Using a DIalog with a Button
Summary: Open URL Does Not Work When Using a DIalog with a Button
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: UI - OPS
Version: 5.9.0
Hardware: Unspecified
OS: Unspecified
high
low
Target Milestone: GA
: 5.10.0
Assignee: Zita Nemeckova
QA Contact: Nikhil Dhandre
URL:
Whiteboard:
Depends On:
Blocks: 1618800
TreeView+ depends on / blocked
 
Reported: 2018-07-17 15:55 UTC by myoder
Modified: 2022-03-13 15:14 UTC (History)
13 users (show)

Fixed In Version: 5.10.0.12
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1618800 (view as bug list)
Environment:
Last Closed: 2019-02-11 14:18:32 UTC
Category: Bug
Cloudforms Team: CFME Core
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description myoder 2018-07-17 15:55:54 UTC
Description of problem:

When using a button that has "Open URL" marked as true, the url is never opened if a dialog is attached to the button.  When no dialog is attached to the button, the url opens as expected.


Basic automate code in custom method "test_open_url":

  vm = $evm.root['vm']
  $evm.log(:info, "VM to luanch SSH for is #{vm.hostnames[0]}")
  vm.remote_console_url = "ssh://10.13.153.96"

Button is invoking the "test_open_url" method from custom namespace:
 
  Yoder/System/Request/TestOpenUrl


Tested this on Chromium, as I was unable to get Chrome or Firefox to behave properly.  (For some reason Firefox doesn't even allow me to open the UI to my appliance, instead firefox just times out.  I suspect I have a setting configured incorrectly somewhere in firefox.  Chrome has an ssh app extension, however, I am unable to test "ssh://10.13.153.96" in the url of Chrome, as chrome tries to do a google search on this.  So when I try the open url in Chrome via my custom button, nothing happens).


Version-Release number of selected component (if applicable):
CFME 5.9.2.4

How reproducible:
always

Steps to Reproduce:
1. Create a VM button that has open url marked as true
2. Button points to a custom automate method that will invoke "vm.remote_console_url = "ssh://10.13.153.96"
3. Attach to the button a static dialog that in no way affects the automate code

Actual results:
When a dialog is attached to the button, the "remote_console_url" method does not work.

Expected results:
The "remote_console_url" should work with or without a dialog, as long as the dialog is not affecting the custom automate code.


Additional info:
Reproducer is 10.13.153.96 admin:smartvm
The button can be triggered from a VM summary screen under button group "Test" and button "TestOpenUrl".  I added the dialog "ImaanTest" to the button to make the "remote_console_url" not work.  "ImaanTest" is just a basic static drop down element.

Used this CloudForms now blog to configure this:
https://cloudformsblog.redhat.com/2017/08/24/rdp-ssh-cloudforms-custom-buttons/

Comment 3 Greg McCullough 2018-07-17 16:06:51 UTC
myoder - Please ask them to retest on the recently released 5.9.3 build.

Comment 10 CFME Bot 2018-08-01 20:41:43 UTC
New commit detected on ManageIQ/manageiq/master:

https://github.com/ManageIQ/manageiq/commit/25be3128d9da2de74612f4149f8c2177fb2511d6
commit 25be3128d9da2de74612f4149f8c2177fb2511d6
Author:     Dávid Halász <dhalasz>
AuthorDate: Wed Aug  1 09:04:16 2018 -0400
Commit:     Dávid Halász <dhalasz>
CommitDate: Wed Aug  1 09:04:16 2018 -0400

    Include task_id in result of ResourceActionWorkflow#process_request

    https://bugzilla.redhat.com/show_bug.cgi?id=1602023

 app/models/resource_action_workflow.rb | 2 +-
 spec/models/resource_action_workflow_spec.rb | 11 +-
 2 files changed, 8 insertions(+), 5 deletions(-)

Comment 11 CFME Bot 2018-08-17 07:27:09 UTC
New commit detected on ManageIQ/manageiq-ui-classic/master:

https://github.com/ManageIQ/manageiq-ui-classic/commit/fce083311cb33c13a90249fb6738d53a5678188e
commit fce083311cb33c13a90249fb6738d53a5678188e
Author:     Zita Nemeckova <znemecko>
AuthorDate: Tue Jul 24 06:59:08 2018 -0400
Commit:     Zita Nemeckova <znemecko>
CommitDate: Tue Jul 24 06:59:08 2018 -0400

    Allow Vm to open a url after a dialog is submitted

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1602023

 app/assets/javascripts/controllers/dialog_user/dialog_user_controller.js | 20 +-
 app/controllers/application_controller/buttons.rb | 8 +-
 app/views/shared/dialogs/_dialog_provision.html.haml | 3 +-
 app/views/shared/dialogs/_dialog_user.html.haml | 1 +
 config/routes.rb | 1 +
 5 files changed, 28 insertions(+), 5 deletions(-)

Comment 13 CFME Bot 2018-08-17 18:59:26 UTC
New commit detected on ManageIQ/manageiq-api/master:

https://github.com/ManageIQ/manageiq-api/commit/bce3c6f359b157c3a0459a4fe9eabd06f04f692f
commit bce3c6f359b157c3a0459a4fe9eabd06f04f692f
Author:     Dávid Halász <dhalasz>
AuthorDate: Wed Aug  1 09:08:34 2018 -0400
Commit:     Dávid Halász <dhalasz>
CommitDate: Wed Aug  1 09:08:34 2018 -0400

    Include task_id in the response when invoking a custom button

    https://bugzilla.redhat.com/show_bug.cgi?id=1602023

 app/controllers/api/base_controller/generic.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comment 15 Nikhil Dhandre 2018-09-26 12:33:57 UTC
It was my bad clearing both need info.
Working fine with dialog and without dialog on 5.10.0.16.20180919151347_a0c9e02

Comment 16 CFME Bot 2018-09-26 20:27:48 UTC
New commit detected on ManageIQ/manageiq-ui-classic/gaprindashvili:

https://github.com/ManageIQ/manageiq-ui-classic/commit/f547e7287963f1243958b9fc27ec3180ec9ad0fd
commit f547e7287963f1243958b9fc27ec3180ec9ad0fd
Author:     Zita Nemeckova <znemecko>
AuthorDate: Tue Jul 24 06:59:08 2018 -0400
Commit:     Zita Nemeckova <znemecko>
CommitDate: Tue Jul 24 06:59:08 2018 -0400

    Allow Vm to open a url after a dialog is submitted

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1602023

 app/assets/javascripts/controllers/dialog_user/dialog_user_controller.js | 20 +-
 app/controllers/application_controller/buttons.rb | 8 +-
 app/views/shared/dialogs/_dialog_provision.html.haml | 3 +-
 app/views/shared/dialogs/_dialog_user.html.haml | 1 +
 config/routes.rb | 1 +
 5 files changed, 28 insertions(+), 5 deletions(-)


Note You need to log in before you can comment on or make changes to this bug.