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

Use the Project::PhaseComponent on the Overview page

Dombi Attila9c57c83ea006
diff --git a/modules/overviews/app/components/project_life_cycles/sections/project_life_cycles/show_component.html.erb b/modules/overviews/app/components/project_life_cycles/sections/project_life_cycles/show_component.html.erb
index a34e2bc5150..14c08c4f9a6 100644
--- a/modules/overviews/app/components/project_life_cycles/sections/project_life_cycles/show_component.html.erb
+++ b/modules/overviews/app/components/project_life_cycles/sections/project_life_cycles/show_component.html.erb
@@ -23,7 +23,7 @@
if not_set?
render(Primer::Beta::Text.new) { t("placeholders.default") }
else
- render_value
+ render Projects::PhaseComponent.new(phase: model)
end
end
end
diff --git a/modules/overviews/app/components/project_life_cycles/sections/project_life_cycles/show_component.rb b/modules/overviews/app/components/project_life_cycles/sections/project_life_cycles/show_component.rb
index e1820fc1404..d1e6f09be73 100644
--- a/modules/overviews/app/components/project_life_cycles/sections/project_life_cycles/show_component.rb
+++ b/modules/overviews/app/components/project_life_cycles/sections/project_life_cycles/show_component.rb
@@ -39,18 +39,6 @@ module ProjectLifeCycles
model.not_set?
end
- def render_value
- render(Primer::Beta::Text.new) do
- concat [
- model.start_date,
- model.end_date
- ]
- .compact
- .map { |d| helpers.format_date(d) }
- .join(" - ")
- end
- end
-
def icon
:"op-phase"
end