-
Notifications
You must be signed in to change notification settings - Fork 898
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
Add edit functionality for generic object UI #11815
Conversation
@@ -14,6 +14,22 @@ | |||
*/ | |||
function subscribeToSubject() { | |||
ManageIQ.angular.rxSubject.subscribe(function(event) { | |||
if (event.eventType === 'sendCountSelectedAndUpdateToolbar') { | |||
this.MiQToolbarSettingsService.countSelected = event.countSelected; |
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.
Once ManageIQ/ui-components#33 is in, this should be
if (event.eventType === 'sendCountSelectedAndUpdateToolbar') {
this.MiQToolbarSettingsService.setCount(event.countSelected);
}
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.
..and I wonder if the name could be a bit simpler .. like updateToolbarCount
or something.. WDYT?
_this.MiQToolbarSettingsService.enableToolbarItemByCountSelected(item); | ||
}) | ||
.value(); | ||
} |
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.
also.. an elseif
here, to keep this consistent..
@eclarizio upgrading |
1f5cdb7
to
27bf79e
Compare
Couple of screenshots to show the new "edit" drop down that is totally angularized!: Thanks to @himdel's suggestions for utilizing the @miq-bot assign @gmcculloug @gmcculloug Please review or tag someone for review. I should be able to get another PR in for the delete before vacation, but it may be WIP and can either wait until I get back or someone else can pick it up. Reminder that this is all still "locked" behind a feature setting so if you can't see the "generic object" main tab, then you'll have to enable it. |
🙇♂️ .. but note that you should update the |
@miq-bot remove_label wip |
Looks good. @syncrou Please review. |
<pr_mergeability_checker />This pull request is not mergeable. Please rebase and repush. |
e811737
to
9fd4056
Compare
@@ -44,6 +55,11 @@ def tree_data | |||
|
|||
private | |||
|
|||
def update_model_fields(generic_object_definition) | |||
generic_object_definition.update_attribute(:name, params[:name]) |
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.
Is update_attributes
not workable here? - e.g. is there validation that we're trying to get around? - Not sure on the history here - but the 2 separate calls to update_attribute
stick out as not common.
9fd4056
to
7f351c9
Compare
After rebasing, the ability to get to the generic objects UI was broken because of #12025. The removal of building a toolbar by class has been restored and the existing method has been refactored. @romanblanco Since you were the one who removed the ability to build a toolbar by class and changed the other method names, we can talk more about the naming of the methods I re-added if you want. For now, though, I would prefer if we can build toolbars by passing the class directly, instead of some kind of standardized name that then gets magically figured out. |
<pr_mergeability_checker />This pull request is not mergeable. Please rebase and repush. |
30b2773
to
9c6730d
Compare
Now that all of the UI stuff has moved to the classic UI repo, this only has one change within the |
Checked commit eclarizio@9c6730d with ruby 2.2.5, rubocop 0.37.2, and haml-lint 0.16.1 |
https://www.pivotaltracker.com/story/show/128427247
More details to follow when I un-wip, just wanted this out there for visibility while I'm away on jury duty. 😢