. /** * CALLERS * This page is called from: * - print_menu() * - print_account_menu() * * EXPECTED BEHAVIOUR * - Display the user's current sponsorships * - Allow the user to edit the payment flag * * CALLS * This page calls the following pages: * - account_sponsor_update.php (to save changes) * * RESTRICTIONS & PERMISSIONS * - User must be authenticated, and not anonymous * - sponsorship must be enabled * * @package MantisBT * @copyright Copyright (C) 2000 - 2002 Kenzaburo Ito - kenito@300baud.org * @copyright Copyright (C) 2002 - 2014 MantisBT Team - mantisbt-dev@lists.sourceforge.net * @link http://www.mantisbt.org */ /** * MantisBT Core API's */ require_once( 'core.php' ); require_once( 'current_user_api.php' ); if ( config_get( 'enable_sponsorship' ) == OFF ) { trigger_error( ERROR_SPONSORSHIP_NOT_ENABLED, ERROR ); } # anonymous users are not allowed to sponsor issues if ( current_user_is_anonymous() ) { access_denied(); } $t_show_all = gpc_get_bool( 'show_all', false ); # start the page html_page_top( lang_get( 'my_sponsorship' ) ); $t_project = helper_get_current_project(); ?>
' . lang_get( 'no_own_sponsored' ) . '

'; } else { ?>
status, auth_get_current_user_id(), $t_bug->project_id ) ); $t_resolution = string_attribute( get_enum_element( 'resolution', $t_bug->resolution, auth_get_current_user_id(), $t_bug->project_id ) ); $t_version_id = version_get_id( $t_bug->fixed_in_version, $t_project ); if ( ( false !== $t_version_id ) && ( VERSION_RELEASED == version_get_field( $t_version_id, 'released' ) ) ) { $t_released_label = '' . $t_bug->fixed_in_version . ''; } else { $t_released_label = $t_bug->fixed_in_version; } echo ''; echo ''; echo ''; echo ''; echo ''; echo ''; # summary echo ''; # describe sponsorship amount echo ''; echo ''; if ( SPONSORSHIP_PAID == $t_sponsor->paid ) { $t_total_paid += $t_sponsor->amount; } else { $t_total_owing += $t_sponsor->amount; } echo ''; echo ''; } ?>
 
' . bug_format_id( $row['bug'] ) . '' . string_display_line( project_get_field( $t_bug->project_id, 'name' ) ) . ' ' . $t_released_label . ' ' . $t_status . ''; print_user( $t_bug->handler_id ); echo '' . string_display_line( $t_bug->summary ); if ( VS_PRIVATE == $t_bug->view_state ) { printf( ' (%s)', $t_icon_path . 'protected.gif', lang_get( 'private' ), lang_get( 'private' ) ); } echo '' . sponsorship_format_amount( $t_sponsor->amount ) . '' . get_enum_element( 'sponsorship', $t_sponsor->paid ) . ''; if ( $t_payment ) { echo '(paypal button)'; } else { echo ' '; } echo '
' . lang_get( 'no_sponsored' ) . '

'; } else { ?>
status, auth_get_current_user_id(), $t_bug->project_id ) ); $t_resolution = string_attribute( get_enum_element( 'resolution', $t_bug->resolution, auth_get_current_user_id(), $t_bug->project_id ) ); $t_version_id = version_get_id( $t_bug->fixed_in_version, $t_project ); if ( ( false !== $t_version_id ) && ( VERSION_RELEASED == version_get_field( $t_version_id, 'released' ) ) ) { $t_released_label = '' . $t_bug->fixed_in_version . ''; } else { $t_released_label = $t_bug->fixed_in_version; } echo ''; echo ''; echo ''; echo ''; echo ''; # summary echo ''; echo ''; echo ''; echo ''; if ( SPONSORSHIP_PAID == $t_sponsor->paid ) { $t_total_paid += $t_sponsor->amount; } else { $t_total_owing += $t_sponsor->amount; } } $t_hidden_bug_list = implode( ',', $t_buglist ); ?>
' . bug_format_id( $row['bug'] ) . '' . string_display_line( project_get_field( $t_bug->project_id, 'name' ) ) . ' ' . $t_released_label . ' ' . $t_status . ' ' . string_display_line( $t_bug->summary ); if ( VS_PRIVATE == $t_bug->view_state ) { printf( ' (%s)', $t_icon_path . 'protected.gif', lang_get( 'private' ), lang_get( 'private' ) ); } # describe sponsorship amount echo ''; print_user( $t_sponsor->user_id ); echo '' . sponsorship_format_amount( $t_sponsor->amount ) . '
 

( $t_show_all ? 0 : 1 ) ) ); ?>