Skip to content

Commit

Permalink
Fix cross-project display of custom resolution codes
Browse files Browse the repository at this point in the history
When a custom resolution is defined in a different project, its code
was displayed as @x@ instead of the corresponding string in the
resolution column, as well as when hovering over the status in the view
issues page.

Fixes #13707
  • Loading branch information
dregad committed Feb 28, 2012
1 parent a5aaf06 commit a20f399
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions core/columns_api.php
Expand Up @@ -1172,7 +1172,9 @@ function print_column_reproducibility( $p_bug, $p_columns_target = COLUMNS_TARGE
* @access public
*/
function print_column_resolution( $p_bug, $p_columns_target = COLUMNS_TARGET_VIEW_PAGE ) {
echo '<td class="center column-resolution">', get_enum_element( 'resolution', $p_bug->resolution ), '</td>';
echo '<td class="center column-resolution">',
get_enum_element( 'resolution', $p_bug->resolution, auth_get_current_user_id(), $p_bug->project_id ),
'</td>';
}

/**
Expand All @@ -1184,7 +1186,10 @@ function print_column_resolution( $p_bug, $p_columns_target = COLUMNS_TARGET_VIE
*/
function print_column_status( $p_bug, $p_columns_target = COLUMNS_TARGET_VIEW_PAGE ) {
echo '<td class="center column-status">';
printf( '<span class="issue-status" title="%s">%s</span>', get_enum_element( 'resolution', $p_bug->resolution ), get_enum_element( 'status', $p_bug->status, auth_get_current_user_id(), $p_bug->project_id ) );
printf( '<span class="issue-status" title="%s">%s</span>',
get_enum_element( 'resolution', $p_bug->resolution, auth_get_current_user_id(), $p_bug->project_id ),
get_enum_element( 'status', $p_bug->status, auth_get_current_user_id(), $p_bug->project_id )
);

# print username instead of status
if(( ON == config_get( 'show_assigned_names' ) ) && ( $p_bug->handler_id > 0 ) && ( access_has_project_level( config_get( 'view_handler_threshold' ), $p_bug->project_id ) ) ) {
Expand Down

0 comments on commit a20f399

Please sign in to comment.