-
Notifications
You must be signed in to change notification settings - Fork 125
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin/master' into radjabov
- Loading branch information
Showing
34 changed files
with
233 additions
and
35 deletions.
There are no files selected for viewing
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
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
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
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
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
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
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
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20200520182548_update_chargeback_assignments_startpage.rb
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20200520210200_update_chargeback_reports_startpage.rb
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20200910163718_adjust_control_explorer_startpage_entries.rb
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20201227173629_update_startup_shortcut_after_policy_profile_deexplorization.rb
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20201230005555_update_startpage_shortcut_after_actions_de_explorization.rb
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20210105011714_update_policy_startpage_url_after_de_explorization.rb
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
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20210106200226_update_policy_export_startpage_url.rb
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
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20210112000610_update_alerts_startpage_url_after_de_explorization.rb
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20210112001749_update_alert_profiles_startpage_url_after_de_explorization.rb
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20210112003720_update_events_startpage_url_after_de_explorization.rb
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20210112004301_update_conditions_startpage_url_after_de_explorization.rb
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20210315161230_update_automation_provider_startpage.rb
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
2 changes: 1 addition & 1 deletion
2
db/migrate/20220629110748_update_startpage_shortcut_after_services_de_explorization.rb
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
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
35 changes: 35 additions & 0 deletions
35
db/migrate/20240516101409_update_resource_pool_identifiers_to_miq_product_features.rb
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
class UpdateResourcePoolIdentifiersToMiqProductFeatures < ActiveRecord::Migration[6.1] | ||
class MiqProductFeature < ActiveRecord::Base; end | ||
|
||
FEATURE_MAPPING_UPDATE = { | ||
'resource_pool' => 'resource_pool_infra', | ||
'resource_pool_view' => 'resource_pool_infra_view', | ||
'resource_pool_show_list' => 'resource_pool_infra_show_list', | ||
'resource_pool_show' => 'resource_pool_infra_show', | ||
'resource_pool_control' => 'resource_pool_infra_control', | ||
'resource_pool_tag' => 'resource_pool_infra_tag', | ||
'resource_pool_protect' => 'resource_pool_infra_protect', | ||
'resource_pool_admin' => 'resource_pool_infra_admin', | ||
'resource_pool_delete' => 'resource_pool_infra_delete' | ||
}.freeze | ||
|
||
def up | ||
return if MiqProductFeature.none? | ||
|
||
say_with_time('Updating resource_pool features to resource_pool_infra') do | ||
FEATURE_MAPPING_UPDATE.each do |from, to| | ||
MiqProductFeature.find_by(:identifier => from)&.update!(:identifier => to) | ||
end | ||
end | ||
end | ||
|
||
def down | ||
return if MiqProductFeature.none? | ||
|
||
say_with_time('Reverting resource_pool_infra features back to resource_pool') do | ||
FEATURE_MAPPING_UPDATE.each do |to, from| | ||
MiqProductFeature.find_by(:identifier => from)&.update!(:identifier => to) | ||
end | ||
end | ||
end | ||
end |
35 changes: 35 additions & 0 deletions
35
db/migrate/20240830172702_reset_resource_pool_identifiers.rb
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
class ResetResourcePoolIdentifiers < ActiveRecord::Migration[6.1] | ||
class MiqProductFeature < ActiveRecord::Base; end | ||
|
||
FEATURE_MAPPING_UPDATE = { | ||
'resource_pool_infra' => 'resource_pool', | ||
'resource_pool_infra_view' => 'resource_pool_view', | ||
'resource_pool_infra_show_list' => 'resource_pool_show_list', | ||
'resource_pool_infra_show' => 'resource_pool_show', | ||
'resource_pool_infra_control' => 'resource_pool_control', | ||
'resource_pool_infra_tag' => 'resource_pool_tag', | ||
'resource_pool_infra_protect' => 'resource_pool_protect', | ||
'resource_pool_infra_admin' => 'resource_pool_admin', | ||
'resource_pool_infra_delete' => 'resource_pool_delete' | ||
}.freeze | ||
|
||
def up | ||
return if MiqProductFeature.none? | ||
|
||
say_with_time('Resetting resource_pool_infra features back to resource_pool') do | ||
FEATURE_MAPPING_UPDATE.each do |from, to| | ||
MiqProductFeature.find_by(:identifier => from)&.update!(:identifier => to) | ||
end | ||
end | ||
end | ||
|
||
def down | ||
return if MiqProductFeature.none? | ||
|
||
say_with_time('Updating resource_pool features to resource_pool_infra') do | ||
FEATURE_MAPPING_UPDATE.each do |to, from| | ||
MiqProductFeature.find_by(:identifier => from)&.update!(:identifier => to) | ||
end | ||
end | ||
end | ||
end |
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
19 changes: 19 additions & 0 deletions
19
lib/manageiq/schema/serialize_positional_to_kwargs_bridge.rb
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
module ManageIQ | ||
module Schema | ||
module SerializePositionalToKwargsBridge | ||
def serialize(*args, **options) | ||
return super if Rails.version >= "7.1" | ||
|
||
# For rails 7.0.x, convert 7.1+ kwargs for coder/type into the positional argument | ||
# class_name_or_coder | ||
if options[:coder] | ||
args << options.delete(:coder) | ||
elsif options[:type] | ||
args << options.delete(:type) | ||
end | ||
|
||
super(*args, **options) | ||
end | ||
end | ||
end | ||
end |
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
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
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
Oops, something went wrong.