-
Notifications
You must be signed in to change notification settings - Fork 897
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
Preserve group and user when importing reports #18270
Merged
gtanzillo
merged 7 commits into
ManageIQ:master
from
yrudman:keep-group-and-user-when-importing-report
Jan 15, 2019
Merged
Preserve group and user when importing reports #18270
gtanzillo
merged 7 commits into
ManageIQ:master
from
yrudman:keep-group-and-user-when-importing-report
Jan 15, 2019
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
yrudman
added a commit
to yrudman/manageiq-ui-classic
that referenced
this pull request
Dec 6, 2018
…ser_id and miq_group_id field of imported report with value for user who is doing import. After: owrk old way (ovverride) f Preserver Owner checkbox unchecked and do not override (keep original values) if this checkbox checked. After: owrk old way (ovverride) f Preserver Owner checkbox unchecked and do not override (keep original values) if this checkbox checked. Depends on ManageIQ/manageiq#18270 Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1638533
yrudman
force-pushed
the
keep-group-and-user-when-importing-report
branch
3 times, most recently
from
December 7, 2018 15:14
75b8947
to
4acbee4
Compare
miq-bot
changed the title
[WIP] Preserve group and user when importing reports
Preserve group and user when importing reports
Dec 7, 2018
This comment has been minimized.
This comment has been minimized.
yrudman
added a commit
to yrudman/manageiq-ui-classic
that referenced
this pull request
Dec 17, 2018
…ser_id and miq_group_id field of imported report with value for user who is doing import. After: owrk old way (ovverride) f Preserver Owner checkbox unchecked and do not override (keep original values) if this checkbox checked. After: owrk old way (ovverride) f Preserver Owner checkbox unchecked and do not override (keep original values) if this checkbox checked. Depends on ManageIQ/manageiq#18270 Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1638533
yrudman
force-pushed
the
keep-group-and-user-when-importing-report
branch
5 times, most recently
from
December 21, 2018 22:05
65c47e7
to
38db427
Compare
yrudman
force-pushed
the
keep-group-and-user-when-importing-report
branch
3 times, most recently
from
January 9, 2019 18:25
23d5df3
to
337fa66
Compare
gtanzillo
reviewed
Jan 10, 2019
There is 'Preserve owner' checkbox added on Import report page, UI PR: ManageIQ/manageiq-ui-classic#5060 This checkbox controls if report will be imported in the old way: unconditionally override user_id and miq_group_id fields of imported report, OR in the new way: keep those fields untouched. In order to support report import in mutilregion environment: added 'userid' and 'group_description' attributes to exported report Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1638533
… attributes which are not present in the MqReport model: 'userid' and 'group_description'. We need those attributes to import saved report in mutiregion environment, BZ: https://bugzilla.redhat.com/show_bug.cgi?id=1638533. To make sure that MiqReport#update_attributes(saved_report_atributes) will not raise error, we need to implement stub for assignment method for those added attributes
yrudman
force-pushed
the
keep-group-and-user-when-importing-report
branch
from
January 11, 2019 13:45
337fa66
to
b2615d6
Compare
Checked commits yrudman/manageiq@dd5afbe~...b2615d6 with ruby 2.3.3, rubocop 0.52.1, haml-lint 0.20.0, and yamllint 1.10.0 app/models/miq_report/import_export.rb
|
gtanzillo
suggested changes
Jan 15, 2019
gtanzillo
approved these changes
Jan 15, 2019
simaishi
pushed a commit
that referenced
this pull request
Mar 29, 2019
…ting-report Preserve group and user when importing reports (cherry picked from commit 620d833) https://bugzilla.redhat.com/show_bug.cgi?id=1693719
Hammer backport details:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Issue:
When importing report (usually by
admin
user), report's access (defined inuser_id
andmiq_group_id
fields of report) got overwritten by ids of user who executed import and this is preventing from clean backup/restore operations.Solution:
Preserver owner?
checkbox which would control how import will work: old way (override) or new way (preserve user_id and miq_group_id from imported report)userid
andgroup_description
) for report export. Those attributes needed for importing saved report in multi-region environmentCorresponding PR on UI: ManageIQ/manageiq-ui-classic#5060
Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1638533
@miq-bot add-label bug