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 Save button which wasn't responding while editing Chargeback Rate #3974

Conversation

hstastna
Copy link

@hstastna hstastna commented May 22, 2018

Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1583175
Issue with more info: #3961


Fix Save button which was not responding for Currencies' changes while editing Chargeback
Rate, under Cloud Intel > Chargeback > Rates accordion > Compute/Storage Chargeback Rates.

Original Chargeback Rate (just started editing; see the Currencies):
rate_original
The currency was changed and Save button was enabled:
rate_change

Before:
Currency changed back to the original value and Save button still enabled which is wrong:
rate_bad

After:
Currency changed back to the original value and Save button was disabled which is right:
compute_rate_ok

Steps to reproduce:

  1. Go to Cloud Intel > Chargeback > Rates accordion > Compute/Storage Chargeback Rates
  2. Click on some rate or select it by checking the checkbox
  3. Choose Edit the selected Chargeback Rate or Edit this Chargeback Rate
  4. Change Currencies to something different
  5. Change Currencies back to what it was before (don't use Reset button here!)
    => Save button remains enabled (blue) even if we did not make any change comparing to the original currencies' values

Notes:
The problem was happening only while changing Currencies. Changing other values with enabling/disabling Save button seemed to work ok. Clicking on Reset button could fix the problem with Save button (after resetting the changes, Save button remained disabled which is right).

Details:
The core of the problem were:

Comparing the old vs. new values is happening here: https://github.com/ManageIQ/manageiq-ui-classic/pull/3974/files#diff-1b26f16afe1a647952df7cc1637f4394R183

issue: ManageIQ#3961

Fix Save button which was not responding for currencies changes while editing Chargeback
Rate, under Cloud Intel > Chargeback > Rates accordion > Compute/Storage Chargeback Rates.
@miq-bot
Copy link
Member

miq-bot commented May 22, 2018

Checked commit hstastna@70820ae with ruby 2.3.3, rubocop 0.52.1, haml-lint 0.20.0, and yamllint 1.10.0
1 file checked, 0 offenses detected
Everything looks fine. 🏆

@mzazrivec mzazrivec self-assigned this May 28, 2018
@mzazrivec mzazrivec added this to the Sprint 87 Ending Jun 4, 2018 milestone May 28, 2018
@mzazrivec mzazrivec merged commit ad206d6 into ManageIQ:master May 28, 2018
@mzazrivec
Copy link
Contributor

@hstastna is this gaprindashvili/yes ?

@hstastna
Copy link
Author

@mzazrivec Not sure. But if yes, we will need to create a BZ to backport it.

@hstastna
Copy link
Author

@hstastna
Copy link
Author

@miq-bot add_label gaprindashvili/yes

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.

3 participants