Bug 1625382 - When a button is for 'single and list' or 'list' and has a visibility expression, the button does not display in the list view even when all VMs in the list meet the expression
Summary: When a button is for 'single and list' or 'list' and has a visibility express...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: UI - OPS
Version: 5.9.3
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: GA
: 5.10.0
Assignee: Harpreet Kataria
QA Contact: Nikhil Dhandre
URL:
Whiteboard:
Depends On:
Blocks: 1629121
TreeView+ depends on / blocked
 
Reported: 2018-09-04 19:20 UTC by David Luong
Modified: 2021-12-10 17:19 UTC (History)
7 users (show)

Fixed In Version: 5.10.0.15
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1629121 (view as bug list)
Environment:
Last Closed: 2019-02-12 16:49:30 UTC
Category: Bug
Cloudforms Team: CFME Core
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description David Luong 2018-09-04 19:20:59 UTC
Description of problem:
When a button is for 'single and list' or 'list' and has a visibility expression, the button does not display in the list view even when all VMs in the list meet the expression.


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

How reproducible:
Always

Steps to Reproduce:
1.  Make a button for 'single and list' or 'list'
2.  Make a visibility expression for button
3.  Filter by condition which makes visibility true

Actual results:
Button doesn't show in list when all filtered vms meet visibility condition

Expected results:
Button shows up when filtered vms meet visibility condition

Additional info:

Comment 3 CFME Bot 2018-09-13 15:27:35 UTC
New commit detected on ManageIQ/manageiq-ui-classic/master:

https://github.com/ManageIQ/manageiq-ui-classic/commit/8a1aac2dddd8649d23d1e920cf7ef141af777fe4
commit 8a1aac2dddd8649d23d1e920cf7ef141af777fe4
Author:     Harpreet Kataria <hkataria>
AuthorDate: Thu Sep  6 18:54:08 2018 -0400
Commit:     Harpreet Kataria <hkataria>
CommitDate: Thu Sep  6 18:54:08 2018 -0400

    Custom Buttons with expressions are only visible on summary screen

    - Added a note on both tabs to specify that Expression can only be set for single entity display buttons only.
    - Hide expression related fields when user selects "List" or "Single and List" option in "Display for" drop down. Clear out any expression related data if custom button is not displayed on Single item screen only.
    - Work as before when "Single Entity" is selected in "display for" drop down.
    - Fixed a failing spec test

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

 app/controllers/application_controller/buttons.rb | 8 +-
 app/views/shared/buttons/_ab_advanced_form.html.haml | 43 +-
 app/views/shared/buttons/_ab_options_form.html.haml | 3 +
 spec/controllers/miq_ae_customization_controller/custom_buttons_spec.rb | 1 +
 4 files changed, 36 insertions(+), 19 deletions(-)


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