logo       
Google Custom Search
    AddThis Social Bookmark Button
-->

mantisbt print_bugnote_inc.php,1.27,1.28: msg#00037

Subject: mantisbt print_bugnote_inc.php,1.27,1.28
Update of /cvsroot/mantisbt/mantisbt
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10075

Modified Files:
        print_bugnote_inc.php 
Log Message:
fix for issue #0004912: Reminders are not handled in print_bugnote_inc.php


Index: print_bugnote_inc.php
===================================================================
RCS file: /cvsroot/mantisbt/mantisbt/print_bugnote_inc.php,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -d -r1.27 -r1.28
--- print_bugnote_inc.php       8 Aug 2004 11:39:00 -0000       1.27
+++ print_bugnote_inc.php       29 Nov 2004 15:45:02 -0000      1.28
@@ -32,13 +32,15 @@
                $t_restriction = '';
        }
 
+       $t_bugnote_table                = config_get( 'mantis_bugnote_table' );
+       $t_bugnote_text_table   = config_get( 'mantis_bugnote_text_table' );
        # get the bugnote data
        $t_bugnote_order = current_user_get_pref( 'bugnote_order' );
        
        $query = "SELECT *,date_submitted
-                       FROM $g_mantis_bugnote_table
+                       FROM $t_bugnote_table
                        WHERE bug_id='$c_bug_id' $t_restriction
-                       ORDER BY date_submitted $g_bugnote_order";
+                       ORDER BY date_submitted $t_bugnote_order";
        $result = db_query($query);
        $num_notes = db_num_rows($result);
 ?>
@@ -70,7 +72,7 @@
 
                # grab the bugnote text and id and prefix with v3_
                $query = "SELECT note, id
-                               FROM $g_mantis_bugnote_text_table
+                               FROM $t_bugnote_text_table
                                WHERE id='$v3_bugnote_text_id'";
                $result2 = db_query( $query );
                $v3_note = db_result( $result2, 0, 0 );
@@ -88,7 +90,14 @@
                <table class="hide" cellspacing="1">
                <tr>
                        <td class="print">
-                               <?php print_user( $v3_reporter_id ) 
?>&nbsp;&nbsp;&nbsp;
+                               <?php  if ( FALSE == user_get_field( 
$v3_reporter_id, 'enabled' ) ) {
+                                       echo '<font STYLE="text-decoration: 
line-through">';
+                               } else {
+                                       echo '<font STYLE="text-decoration: 
none">';
+                               }
+                               echo print_user( $v3_reporter_id );
+                               echo '</font>'; 
+                               ?>&nbsp;&nbsp;&nbsp;
                        </td>
                </tr>
                <tr>
@@ -102,7 +111,20 @@
                <table class="hide" cellspacing="1">
                <tr>
                        <td class="print">
-                               <?php echo $v3_note ?>
+                               <?php 
+                                       switch ( $v3_note_type ) {
+                                               case REMINDER:
+                                                       echo '<div 
class="italic">' . lang_get( 'reminder_sent_to' ) . ': ';
+                                                       $v3_note_attr = substr( 
$v3_note_attr, 1, strlen( $v3_note_attr ) - 2 );
+                                                       $t_to = array();
+                                                       foreach ( explode( '|', 
$v3_note_attr ) as $t_recipient ) {
+                                                               $t_to[] = 
user_get_name( $t_recipient );
+                                                       }
+                                                       echo implode( ', ', 
$t_to ) . '</div><br />';
+                                               default:
+                                                       echo $v3_note;
+                                       }
+                               ?>
                        </td>
                </tr>
                </table>



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/


<Prev in Thread] Current Thread [Next in Thread>