-
Notifications
You must be signed in to change notification settings - Fork 358
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
Introducing embedded_workflow to dynamic select box in service dialogs #8844
Conversation
@@ -0,0 +1,44 @@ | |||
module Mixins | |||
module AutomationMixin | |||
# Returns an object to be resued for passing down to service catalogs(rails) and dialog(angular) form. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# Returns an object to be resued for passing down to service catalogs(rails) and dialog(angular) form. | |
# Returns an object to be reused for passing down to service catalogs(rails) and dialog(angular) form. |
end | ||
|
||
# Returns an array of entry point options. | ||
# used in provision_entry_poins, retirement_entry_points, reconfigure_entry_points html files |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# used in provision_entry_poins, retirement_entry_points, reconfigure_entry_points html files | |
# used in provision_entry_points, retirement_entry_points, reconfigure_entry_points html files |
@jeffibm Sorry to make you refactor again, but can you separate the linting fixes from the actual changes? If not, that's ok. Reason I'm asking is because those make backport much harder, and we'd like to backport this to petrosian. (For future reference, try to avoid lint/cleanup changes mixed with feature changes - linting could be a separate PR beforehand) |
890a960
to
658aa70
Compare
that field is a hidden field - https://github.com/ManageIQ/ui-components/blob/e3024f51a0092794d5cc3ab779adec1cbbeb9621/src/dialog-editor/components/modal-field-template/drop-down-list.html#L133C27-L133C27 could you please try a git pull to see if you have any new changes.. |
Ah I see the issue, yours and Noopur's branch had the same name and I was tracking her remote. |
I created a new PR for ui-components recently (had linked it in the description above) - ManageIQ/ui-components#471. |
👍 looks good with the latest changes |
I think we can build now, however I don't think the dependent PR has been merged (and thus not released) |
Oh okay so ManageIQ/ui-components#471 (comment) has been resolved? |
f66d414
to
06d5212
Compare
Similar to the other side, we need to hide the workflows stuff behind the prototype flag. |
2fd4f26
to
5e4f4e5
Compare
da91a47
to
c8df589
Compare
@@ -30,6 +30,8 @@ | |||
|
|||
:javascript | |||
ManageIQ.angular.app.value('dialogIdAction', '#{ dialog_id_action.to_json }'); | |||
ManageIQ.angular.app.value('automationKeys', '#{ Mixins::AutomationMixin::AUTOMATION_TYPES.to_json }'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typically you don't reference Mixins
directly, they are included into the relevant classes and you would reference them from the class.
Don't know much about the layout here, but you do include that mixin into MiqAeCustomizationHelper
is that able to be accessed here or is there another class that you have access to?
options + AUTOMATION_TYPES.map do |item| | ||
[item[1][:label], item[1][:key]] | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks like a weird way to dereference a hash (the item[1] is actually just the value where item[0] is the hash key)
options + AUTOMATION_TYPES.map do |item| | |
[item[1][:label], item[1][:key]] | |
end | |
options + AUTOMATION_TYPES.values.map do |item| | |
[item[:label], item[:key]] | |
end |
The rubocop comments in #8844 (comment) also look valid |
872ed19
to
187bcc7
Compare
Code looks good, going to give it one more test then I will approve @jeffibm do we need to do a release of ui-components after merging ManageIQ/ui-components#471 ? Are you able to do that or do we need @Fryguy ? |
I only know till the merge part. I haven't really done an actual release yet. |
Dependent ui-components PR merged, we still need a release before this can be merged AFAIK |
@jeffibm I think you need to update the package.json to pull in ui-components 1.5.0 |
Tested locally after manually updating package.json and everything looks good. |
c754f0c
to
39c6042
Compare
Checked commit jeffbonson@39c6042 with ruby 2.6.10, rubocop 1.28.2, haml-lint 0.35.0, and yamllint app/views/miq_ae_customization/editor.html.haml
|
just putting it here so we can use this to debug in future..
|
Backported to
|
Introducing embedded_workflow to dynamic select box in service dialogs (cherry picked from commit fa1620f)
Related PR -
After
The automation Type Field introduced
Can select Embedded Workflow from the select-box
Opens up a dialog box when we click on the workflow load-balancer icon
Select an item from the list to see the selected item in the embedded_workflow's field