diff --git a/core/print_api.php b/core/print_api.php index 6a36002..5eb6562 100644 --- a/core/print_api.php +++ b/core/print_api.php @@ -493,10 +493,11 @@ function print_note_option_list( $p_user_id = '', $p_project_id = null, $p_thres * @param bool $p_include_all_projects true: include "All Projects", otherwise false. * @param mixed $p_filter_project_id The id of a project to exclude or null. * @param string $p_trace The current project trace, identifies the sub-project via a path from top to bottom. + * @param bool $p_show_disabled Defaults to false; set to true to include disabled projects in the list. * @return void */ -function print_project_option_list( $p_project_id = null, $p_include_all_projects = true, $p_filter_project_id = null, $p_trace = false ) { - $t_project_ids = current_user_get_accessible_projects(); +function print_project_option_list( $p_project_id = null, $p_include_all_projects = true, $p_filter_project_id = null, $p_trace = false, $p_show_disabled = false ) { + $t_project_ids = current_user_get_accessible_projects($p_show_disabled); project_cache_array_rows( $t_project_ids ); if( $p_include_all_projects ) { @@ -512,16 +513,16 @@ function print_project_option_list( $p_project_id = null, $p_include_all_project echo '' . "\n"; - print_subproject_option_list( $t_id, $p_project_id, $p_filter_project_id, $p_trace, Array() ); + print_subproject_option_list( $t_id, $p_project_id, $p_filter_project_id, $p_trace, Array(), $p_show_disabled ); } } } # -------------------- # List projects that the current user has access to -function print_subproject_option_list( $p_parent_id, $p_project_id = null, $p_filter_project_id = null, $p_trace = false, $p_parents = Array() ) { +function print_subproject_option_list( $p_parent_id, $p_project_id = null, $p_filter_project_id = null, $p_trace = false, $p_parents = Array(), $p_show_disabled = false ) { array_push( $p_parents, $p_parent_id ); - $t_project_ids = current_user_get_accessible_subprojects( $p_parent_id ); + $t_project_ids = current_user_get_accessible_subprojects( $p_parent_id, $p_show_disabled ); $t_project_count = count( $t_project_ids ); for( $i = 0;$i < $t_project_count;$i++ ) { $t_full_id = $t_id = $t_project_ids[$i]; diff --git a/manage_custom_field_edit_page.php b/manage_custom_field_edit_page.php index dea1168..f3cc1a4 100644 --- a/manage_custom_field_edit_page.php +++ b/manage_custom_field_edit_page.php @@ -260,7 +260,7 @@