Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix highlighting the condition in accordion after creating it #5302

Merged

Conversation

hstastna
Copy link
Contributor

@hstastna hstastna commented Mar 4, 2019

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

What:
Fix highlighting condition in accordion right after creating it: the newly created condition was not highlighted in accordion as expected, instead of that, All Conditions node was highlighted. Everything else regarding adding new conditions seems to work.

Steps to reproduce:

  1. Navigate to Control > Explorer, then Conditions > Replicator Conditions ,or any other conditions
  2. Create a new condition: choose Configuration > Add a New Container Replicator Condition or any other type of condition (depends on step 1)
  3. Fill in required fields (description and expression), values are not important
  4. Click on Add button
    => All Conditions node highlighted instead of newly created condition

TODO: (done)

  • specs
  • test all other types/classes of conditions if it works
  • check this also in :policy_tree, :policy_profile_tree - there is similar code for setting a new node

Details:
@new_condition_node was set incorrectly (see https://github.com/ManageIQ/manageiq-ui-classic/pull/5302/files#diff-4b771fc8b6101d357855d3d10d79ba8aL69), while adding a new condition, it was set for example to
"xx-containerreplicator..." instead of
"xx-containerReplicator..."


Before:
replic_before

After:
replic_after

@hstastna hstastna changed the title Fix highlighting the condition in accordion after creating it [WIP] Fix highlighting the condition in accordion after creating it Mar 4, 2019
@hstastna
Copy link
Contributor Author

hstastna commented Mar 4, 2019

@miq-bot add_label bug, hammer/yes

@hstastna hstastna force-pushed the Accordion_after_creating_condition branch 3 times, most recently from b88a167 to cb64d7f Compare March 6, 2019 10:53
Move the spec to the right place and refactor it
@hstastna hstastna force-pushed the Accordion_after_creating_condition branch 2 times, most recently from 7a0b606 to ef7bb86 Compare March 6, 2019 14:45
@hstastna hstastna force-pushed the Accordion_after_creating_condition branch from ef7bb86 to 34ee4f1 Compare March 6, 2019 15:15
@hstastna hstastna changed the title [WIP] Fix highlighting the condition in accordion after creating it Fix highlighting the condition in accordion after creating it Mar 6, 2019
@hstastna
Copy link
Contributor Author

hstastna commented Mar 6, 2019

@skateman What do you think about the specs? :-)

@miq-bot
Copy link
Member

miq-bot commented Mar 6, 2019

Checked commits hstastna/manageiq-ui-classic@e8f4580~...34ee4f1 with ruby 2.3.3, rubocop 0.52.1, haml-lint 0.20.0, and yamllint 1.10.0
3 files checked, 0 offenses detected
Everything looks fine. 🍪

@miq-bot miq-bot removed the wip label Mar 6, 2019
@skateman
Copy link
Member

skateman commented Mar 7, 2019

I think they're good enough, but this has to be tested in the UI as well.

@h-kataria h-kataria self-assigned this Mar 7, 2019
@h-kataria h-kataria added this to the Sprint 107 Ending Mar 18, 2019 milestone Mar 7, 2019
@h-kataria
Copy link
Contributor

verified in UI

@h-kataria h-kataria merged commit 40da987 into ManageIQ:master Mar 7, 2019
@hstastna
Copy link
Contributor Author

@miq-bot add_label test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants