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

Show Configuration Workflows in UI #4138

Merged
merged 5 commits into from Aug 2, 2018

Conversation

h-kataria
Copy link
Contributor

@h-kataria h-kataria commented Jun 13, 2018

Changes to show list of Job Templates and Configuration Workflows in existing UI under Automation/Ansible Tower/Explorer in Templates Accordion.

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

before:
screenshot from 2018-06-13 16-53-23

screenshot from 2018-06-13 16-53-47

after:
screenshot from 2018-06-18 17-08-29

screenshot from 2018-06-18 17-08-39

screenshot from 2018-06-22 12-30-12

Depends on ManageIQ/manageiq#17720

@martinpovolny
Copy link

Looks good. Restarting travis.

@h-kataria
Copy link
Contributor Author

@martinpovolny test failures are due to backend PR not being merged yet.

@h-kataria
Copy link
Contributor Author

@dclarizio @gmcculloug @tinaafitz mostly addressed all the items discussed that were needed in this PR, now we need to change all references to ConfigurationScriptBase class once model changes are made, related to sub-classing of Workflow Templates.
As discussed, In a follow up PR will add changes to show child Jobs off of Ansible Service Summary screen, once we have back-end work done to be able to create a Service with Workflow Template.

cc @lgalis

@h-kataria h-kataria changed the title Show Configuration Workflows in UI [WIP] - Show Configuration Workflows in UI Jun 22, 2018
@h-kataria h-kataria added the wip label Jun 22, 2018
@miq-bot
Copy link
Member

miq-bot commented Jun 26, 2018

This pull request is not mergeable. Please rebase and repush.

@lgalis lgalis force-pushed the configuration_workflows_ui branch 2 times, most recently from 26a29e5 to 73aaeed Compare June 26, 2018 19:40
@h-kataria h-kataria force-pushed the configuration_workflows_ui branch 5 times, most recently from d8a6e6e to b8a92e1 Compare July 9, 2018 15:07
@h-kataria h-kataria changed the title [WIP] - Show Configuration Workflows in UI Show Configuration Workflows in UI Jul 10, 2018
@h-kataria h-kataria removed the wip label Jul 10, 2018
@h-kataria
Copy link
Contributor Author

@martinpovolny please re-review, this is still waiting on core PR merge

@martinpovolny
Copy link

martinpovolny commented Jul 14, 2018

@h-kataria : the style issues in app/controllers/catalog_controller.rb seem to be easy to fix.
The is_template_record? complaint is also simple to fix.

Other than that I have no further comments. Thx!

@martinpovolny
Copy link

Oh, the core PR is still not merged :-(

h-kataria and others added 3 commits July 31, 2018 14:32
Changes to show list of Job Templates and Configuration Workflows in existing UI under Automation/Ansible Tower/Explorer in Templates Accordion.

https://bugzilla.redhat.com/show_bug.cgi?id=1590441
- Further changes to update titles on screen and show toolbar buttons when Workflow Template record is selected, and render correct textual summary when printing summary to PDF.
- Changes to Catalo Items editor to show grouping in the Template drop down.

https://bugzilla.redhat.com/show_bug.cgi?id=1590441
@miq-bot
Copy link
Member

miq-bot commented Jul 31, 2018

Checked commits h-kataria/manageiq-ui-classic@96b8283~...26ae0c9 with ruby 2.3.3, rubocop 0.52.1, haml-lint 0.20.0, and yamllint 1.10.0
18 files checked, 1 offense detected

**

  • 💣 💥 🔥 🚒 - Linter/Haml - Linter::Haml STDERR:
warning: parser/current is loading parser/ruby23, which recognizes
warning: 2.3.6-compliant syntax, but you are running 2.3.3.
warning: please see https://github.com/whitequark/parser#compatibility-with-ruby-mri.

@h-kataria
Copy link
Contributor Author

@martinpovolny core PR is merged, addressed all rubocop warnings as well. Ready for merge.

@martinpovolny martinpovolny merged commit 0a0df98 into ManageIQ:master Aug 2, 2018
@martinpovolny martinpovolny added this to the Sprint 92 Ending Aug 13, 2018 milestone Aug 2, 2018
def available_job_templates(manager_id)
@edit[:new][:available_templates] = []
all_job_templates = ExtManagementSystem.find_by(:id => manager_id).send('configuration_scripts').collect { |t| [t.name, t.id] }.sort
all_workflow_templates = ExtManagementSystem.find_by(:id => manager_id).send('configuration_workflows').collect { |t| [t.name, t.id] }.sort
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@h-kataria method configuration_workflows does not exist. You need to rework on this PR.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jameswnl please let me know what is the new method name that i should use. @bzwei i did test my PR as is yesterday and i was able to see correct values in the drop down.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can just filter what you've got from the previous query all_job_templates to get the workflows.

(If you are making another call to db to get just the workflows, that would defeat the purpose of the whole remodeling in configuration_workflow which is to allow ui to get back both types of objects in one db/api call)

h-kataria added a commit to h-kataria/manageiq-ui-classic that referenced this pull request Aug 3, 2018
h-kataria added a commit to h-kataria/manageiq-ui-classic that referenced this pull request Aug 3, 2018
h-kataria added a commit to h-kataria/manageiq-ui-classic that referenced this pull request Aug 3, 2018
h-kataria added a commit to h-kataria/manageiq-ui-classic that referenced this pull request Aug 3, 2018
Addressed codeclimate warning Method available_job_templates has a Cognitive Complexity of 6

Follow up fix for changes requested in ManageIQ#4138 (review)
h-kataria added a commit to h-kataria/manageiq-ui-classic that referenced this pull request Aug 3, 2018
Addressed codeclimate warning Method available_job_templates has a Cognitive Complexity of 6

Follow up fix for changes requested in ManageIQ#4138 (review)
h-kataria added a commit to h-kataria/manageiq-ui-classic that referenced this pull request Aug 3, 2018
Addressed codeclimate warning Method available_job_templates has a Cognitive Complexity of 6

Follow up fix for changes requested in ManageIQ#4138 (review)

https://bugzilla.redhat.com/show_bug.cgi?id=1590441
@h-kataria h-kataria deleted the configuration_workflows_ui branch October 24, 2018 22:08
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

7 participants