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

Check button's inputs before looking for records #5241

Merged
merged 1 commit into from
Feb 13, 2019

Conversation

ZitaNemeckova
Copy link
Contributor

Solves #5238

Go to Automation -> Automate ->Customization -> Buttons -> try to save/add one that has type Ansible Playbook without Playbook Catalog Item

Before:
"Nothing" happens
image
with error in log

 : Error caught: [ActiveRecord::RecordNotFound] Couldn't find ServiceTemplate without an ID
/Users/zita/.rbenv/versions/2.4.4/lib/ruby/gems/2.4.0/gems/activerecord-5.0.7.1/lib/active_record/relation/finder_methods.rb:456:in `find_with_ids'
/Users/zita/.rbenv/versions/2.4.4/lib/ruby/gems/2.4.0/gems/activerecord-5.0.7.1/lib/active_record/relation/finder_methods.rb:66:in `find'
/Users/zita/.rbenv/versions/2.4.4/lib/ruby/gems/2.4.0/gems/activerecord-5.0.7.1/lib/active_record/querying.rb:3:in `find'
/Users/zita/.rbenv/versions/2.4.4/lib/ruby/gems/2.4.0/gems/activerecord-5.0.7.1/lib/active_record/core.rb:151:in `find'
/Users/zita/Desktop/ManageIQ/manageiq-ui-classic/app/controllers/application_controller/buttons.rb:946:in `button_set_playbook_record'
/Users/zita/Desktop/ManageIQ/manageiq-ui-classic/app/controllers/application_controller/buttons.rb:890:in `button_set_record_vars'
/Users/zita/Desktop/ManageIQ/manageiq-ui-classic/app/controllers/application_controller/buttons.rb:590:in `ab_button_save'
/Users/zita/Desktop/ManageIQ/manageiq-ui-classic/app/controllers/application_controller/buttons.rb:486:in `button_create_update'
/Users/zita/Desktop/ManageIQ/manageiq-ui-classic/app/controllers/application_controller/buttons.rb:190:in `button_update'

After:
image

@miq-bot add_label bug, hammer/yes, gaprindashvili/yes, automation/automate

@ZitaNemeckova ZitaNemeckova changed the title Check button's inputs before setting them to record Check button's inputs before looking for records Feb 13, 2019
@miq-bot
Copy link
Member

miq-bot commented Feb 13, 2019

Checked commit ZitaNemeckova@e1360cb 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. ⭐

@h-kataria h-kataria self-assigned this Feb 13, 2019
@h-kataria h-kataria added this to the Sprint 105 Ending Feb 18, 2019 milestone Feb 13, 2019
@h-kataria h-kataria merged commit 1148f9a into ManageIQ:master Feb 13, 2019
@ZitaNemeckova ZitaNemeckova deleted the fix_dialog branch February 13, 2019 22:07
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.

4 participants