Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Remove gon_ prefix from IfcModelsHelper methods

Alexander Brandon Colesbcd73bb9f0b6
diff --git a/modules/bim/app/helpers/ifc_models_helper.rb b/modules/bim/app/helpers/ifc_models_helper.rb
index 1d50932d073..c3b463d3326 100644
--- a/modules/bim/app/helpers/ifc_models_helper.rb
+++ b/modules/bim/app/helpers/ifc_models_helper.rb
@@ -3,10 +3,10 @@ module IfcModelsHelper
all_converted_models = converted_ifc_models(all_models)
{
- models: gon_ifc_model_models(all_converted_models),
- shown_models: gon_ifc_shown_models(all_converted_models, shown_models),
+ models: ifc_model_models(all_converted_models),
+ shown_models: ifc_shown_models(all_converted_models, shown_models),
projects: [{ id: @project.identifier, name: @project.name }],
- xkt_attachment_ids: gon_ifc_model_xkt_attachment_ids(all_converted_models),
+ xkt_attachment_ids: ifc_model_xkt_attachment_ids(all_converted_models),
permissions: {
manage_ifc_models: User.current.allowed_in_project?(:manage_ifc_models, @project),
manage_bcf: User.current.allowed_in_project?(:manage_bcf, @project)
@@ -18,7 +18,7 @@ module IfcModelsHelper
ifc_models.select(&:converted?)
end
- def gon_ifc_model_models(all_models)
+ def ifc_model_models(all_models)
all_converted_models = converted_ifc_models(all_models)
all_converted_models.map do |ifc_model|
@@ -30,7 +30,7 @@ module IfcModelsHelper
end
end
- def gon_ifc_shown_models(all_models, shown_models)
+ def ifc_shown_models(all_models, shown_models)
if shown_models.empty?
return all_models.select(&:is_default).map(&:id)
end
@@ -40,7 +40,7 @@ module IfcModelsHelper
.map(&:id)
end
- def gon_ifc_model_xkt_attachment_ids(models)
+ def ifc_model_xkt_attachment_ids(models)
models.map { |model| [model.id, model.xkt_attachment.id] }.to_h
end
end