diff options
Diffstat (limited to 'app/helpers/projects_helper.rb')
-rw-r--r-- | app/helpers/projects_helper.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/app/helpers/projects_helper.rb b/app/helpers/projects_helper.rb index 9eec9f75e..3e839e683 100644 --- a/app/helpers/projects_helper.rb +++ b/app/helpers/projects_helper.rb @@ -87,6 +87,14 @@ module ProjectsHelper end end + def project_default_version_options(project) + versions = project.shared_versions.open.to_a + if project.default_version && !versions.include?(project.default_version) + versions << project.default_version + end + version_options_for_select(versions, project.default_version) + end + def format_version_sharing(sharing) sharing = 'none' unless Version::VERSION_SHARINGS.include?(sharing) l("label_version_sharing_#{sharing}") |