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

Use table name when generating SQL to filter jobs on ... Container Analysis Tasks screens #551

Merged

Conversation

yrudman
Copy link
Contributor

@yrudman yrudman commented Mar 2, 2017

This PR is preparation for ManageIQ/manageiq#14030

There is Owner column on Jobs screens and right now it takes value from jobs.agent_name which get populated from miq_servers.name.
After linking Job and MiqServer (PR ManageIQ/manageiq#14030) not used jobs.agent_name column will be removed and "Owner" column would get data directly from miq_server.name.
SQL for filtering would join 2 tables. To avoid SQL error on the columns with the name, we need to add table name (the same what was done to miq_tasks SQL generation in #344 )

in this PR:

  • add jobs when generating filtering SQL for Job model
  • refactor rspec by adding table name jobs to

There are no changes on UI:

BEFORE:
before

AFTER:
after

@miq-bot add-label enhancement

\cc @gtanzillo @dclarizio

@miq-bot
Copy link
Member

miq-bot commented Mar 2, 2017

Checked commits yrudman/manageiq-ui-classic@1d7df73~...060784e with ruby 2.2.6, rubocop 0.47.1, and haml-lint 0.20.0
2 files checked, 0 offenses detected
Everything looks good. ⭐

@dclarizio dclarizio self-assigned this Mar 3, 2017
@dclarizio dclarizio merged commit 3af46a5 into ManageIQ:master Mar 3, 2017
@dclarizio dclarizio added this to the Sprint 56 Ending Mar 13, 2017 milestone Mar 3, 2017
@yrudman yrudman deleted the use-table-name-for-sql-on-jobs-screens branch March 3, 2017 18:24
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