Version sharing (#465) + optional inclusion of subprojects in the roadmap view (#2666).

Each version of a project can be shared with:
* subprojects
* projects in the project hierarchy: ancestors + descendants (needs versions management permission on the root project)
* projects in the project tree: root project + all its descendants (same as above)
* all projects (can be set by admin users only)

Notes:
* when sharing a version of a private project with others projects, its name will be visible within the other projects
* a project with versions used by non descendant projects can not be archived

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3123 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2009-12-06 10:28:20 +00:00
parent e178123569
commit 5f8e9d7118
40 changed files with 659 additions and 75 deletions
+8
View File
@@ -31,6 +31,14 @@ class QueryTest < ActiveSupport::TestCase
:include => [ :assigned_to, :status, :tracker, :project, :priority ],
:conditions => query.statement
end
def test_query_should_allow_shared_versions_for_a_project_query
subproject_version = Version.find(4)
query = Query.new(:project => Project.find(1), :name => '_')
query.add_filter('fixed_version_id', '=', [subproject_version.id.to_s])
assert query.statement.include?("#{Issue.table_name}.fixed_version_id IN ('4')")
end
def test_query_with_multiple_custom_fields
query = Query.find(1)