}
     $totalmarks_array = $bus_report_stream->total_marks_stream($st['student_id'], $_POST['period_id'], $db);
     $LeftOvers = $pdf->addTextWrap($XPos2 - 10, $YPos + 10, 300, $FontSize, number_format($st['marks'], 0));
     $LeftOvers = $pdf->addTextWrap($XPos2 + 30, $YPos + 10, 300, $FontSize, $grade);
     $LeftOvers = $pdf->addTextWrap($XPos2 + 65, $YPos + 10, 300, $FontSize, $st['rank']);
     $grand_total = $grand_total + $st['marks'];
 }
 //end of scheduled students
 $XPos3 = 212;
 foreach ($subjects_array as $r => $s) {
     $bus_report2 = new bus_report2($_POST['class_id'], $_POST['period_id'], $s['id'], $db);
     $count = 0;
     $total_marks = 0;
     $total_marks2 = 0;
     foreach ($bus_report2->scheduled_students as $a => $b) {
         $bus_report = new bus_report($b['student_id'], $_POST['period_id'], $db);
         $totalmarks_array = $bus_report->total_marks($s['id'], $b['student_id'], $_POST['period_id'], $b['id'], $db);
         $total_marks2 = $total_marks2 + $totalmarks_array;
         $count = $count + 1;
     }
     if ($count > 0) {
         $subject_mean = $total_marks2 / $count;
     } else {
         $subject_mean = 0;
     }
     $LeftOvers = $pdf->addTextWrap($XPos3 - 1, $YPos + 1, 300, 9, $total_marks2);
     $LeftOvers = $pdf->addTextWrap($XPos3, $YPos - 10, 300, 9, number_format($subject_mean, 1));
     $XPos3 += 0.5 * $line_width;
 }
 //end of ssubjects array foreach
 if ($no_of_students > 0) {
Ejemplo n.º 2
0
 $_SESSION['period'] = $_POST['period_id'];
 $sql = "SELECT year FROM years\n\t\tWHERE id= '" . $_SESSION['period'] . "'";
 $result = DB_query($sql, $db);
 $myrow = DB_fetch_row($result);
 $academic_year = $myrow[0];
 $sql = "SELECT dtr.name,dtr.debtorno,dp.department_name,cs.course_name as course,gl.grade_level FROM debtorsmaster dtr\nINNER JOIN courses cs ON cs.id=dtr.course_id\nINNER JOIN departments dp ON dp.id=cs.department_id\nINNER JOIN gradelevels gl ON gl.id=dtr.grade_level_id \n\t\tWHERE debtorno =  '" . $_SESSION['UserID'] . "'";
 $result = DB_query($sql, $db);
 $myrow = DB_fetch_row($result);
 $course = $myrow['course'];
 $sql = "SELECT cp.id,terms.title,years.year FROM collegeperiods cp\n\t\tINNER JOIN terms ON terms.id=cp.term_id\n\t\tINNER JOIN years ON years.id=cp.year \n\t\tWHERE cp.id='" . $_SESSION['period'] . "'";
 $result = DB_query($sql, $db);
 $myrow = DB_fetch_array($result);
 $title = $myrow['title'];
 $count = 0;
 $i = 0;
 $bus_report = new bus_report($student_id, $_POST['period_id'], $db);
 echo "<form method='post' action=" . $_SERVER['PHP_SELF'] . "?" . SID . ">";
 echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />';
 echo "<table  width='50%' align='center' border=\"1\" >";
 echo "<tr><td colspan='8'  class=\"centered\"><font size='4'>" . _('Masinde Muliro University of Science & Technology') . "</td></tr>";
 echo "<tr><td colspan='8' class=\"centered\"><font size='4'>" . _('Academic Year') . ' ' . $academic_year . ' ' . _('Transcript') . "</td></tr>";
 echo "<tr><td colspan='5' align='center'><font size='4'>" . _('RegNO') . _(': ') . $_SESSION['UserID'] . "</td></tr>";
 echo "<tr><th>" . _('Subject') . "</th><th>" . _('Marks') . "</th><th>" . _('Points') . "</th><th>" . _('Grade') . "</th></tr>";
 $asterik = 0;
 $marks = 0;
 foreach ($bus_report->scheduled_subjects as $a => $b) {
     $count = $count + 1;
     $scheduled = new scheduled($b['subject_id'], $db);
     $scheduled->set_calendar_vars($student_id, $_POST['period_id'], $b['id'], $db);
     echo "<tr><td class=\"visible\">" . $scheduled->subject_name . "</td>";
     foreach ($scheduled->subject as $sub => $s) {
Ejemplo n.º 3
0
 $standard = $myrow[3];
 $YPos += 20;
 $YPos -= $line_height;
 $YPos -= 12 * $line_height;
 $YPos -= 85;
 $YPos3 = $YPos;
 $YPos -= $line_height;
 $pdf->line(60, $YPos + $line_height, $Page_Width - $Right_Margin - 25, $YPos + $line_height, $style);
 $line_width = 70;
 $XPos = 170;
 $XPos5 = 100;
 $XPos6 = 100;
 $YPos2 = $YPos;
 $count = 0;
 $i = 0;
 $bus_report = new bus_report($myrowclass['student_id'], $_POST['period_id'], $db);
 $status_array = tep_get_status($_POST['period_id'], $myrowclass['student_id'], $db);
 foreach ($status_array as $r => $s) {
     $pdf->starttransform();
     $pdf->xy($XPos, 332);
     $pdf->rotate(90);
     $LeftOvers = $pdf->addTextWrap($XPos - 25, $YPos - 70, 300, $FontSize, $s['title']);
     $pdf->stoptransform();
     $XPos += 40;
 }
 $YPos -= 5 * $line_height;
 foreach ($bus_report->scheduled_subjects as $a => $b) {
     //$count=$count+1;
     $sql = "select no_of_subjects from termly_class_ranks\n\t\t\tWHERE student_id='" . $myrowclass['student_id'] . "'\n\t\t\tAND period_id='" . $_POST['period_id'] . "'";
     $result = DB_query($sql, $db);
     $row = DB_fetch_row($result);
Ejemplo n.º 4
0
 $LeftOvers = $pdf->addTextWrap(40, $YPos - $line_height * 15, 500, $FontSize, _('Class') . _(': ') . $class_name);
 $YPos += 20;
 $YPos -= $line_height;
 //Note, this is ok for multilang as this is the value of a Select, text in option is different
 $YPos -= 12 * $line_height;
 $pdf->line(19, $YPos + $line_height, $Page_Width - $Right_Margin, $YPos + $line_height, $style);
 $YPos -= 50;
 $YPos -= $line_height;
 $pdf->line(19, $YPos + $line_height, $Page_Width - $Right_Margin, $YPos + $line_height, $style);
 $YPos -= 8 * $line_height;
 $line_width = 40;
 $XPos = 180;
 $YPos2 = $YPos;
 $count = 0;
 $i = 0;
 $bus_report = new bus_report($_POST['class_id'], $_POST['year'], $_POST['term'], $db);
 $subjects_array = tep_get_subjects($_POST['class_id'], $_POST['year'], $_POST['term'], $db);
 $current_student = '';
 $pdf->starttransform();
 $pdf->xy($XPos - 20, 332);
 $pdf->rotate(90);
 $pdf->stoptransform();
 $FontSize = 5;
 foreach ($subjects_array as $r => $s) {
     $pdf->starttransform();
     $pdf->xy($XPos, 332);
     $pdf->rotate(90);
     $LeftOvers = $pdf->addTextWrap($XPos - 45, $YPos, 300, $FontSize, $s['subject_name']);
     $pdf->stoptransform();
     $XPos += 0.5 * $line_width;
 }
Ejemplo n.º 5
0
    ?>
<html><body><br /><br /><br />
<?php 
    $_SESSION['student'] = $_POST['student_id'];
    $_SESSION['period'] = $_POST['period_id'];
    $sql = "SELECT dtr.name,dtr.debtorno,dp.department_name,cs.course_name as course,gl.grade_level FROM debtorsmaster dtr\nINNER JOIN courses cs ON cs.id=dtr.course_id\nINNER JOIN departments dp ON dp.id=cs.department_id\nINNER JOIN gradelevels gl ON gl.id=dtr.grade_level_id \n\t\tWHERE debtorno =  '" . $_SESSION['student'] . "'";
    $result = DB_query($sql, $db);
    $myrow = DB_fetch_row($result);
    $course = $myrow['course'];
    $sql = "SELECT cp.id,terms.title,years.year,cp.end_date FROM collegeperiods cp\n\t\tINNER JOIN terms ON terms.id=cp.term_id\n\t\tINNER JOIN years ON years.id=cp.year \n\t\tWHERE cp.id='" . $_SESSION['period'] . "'";
    $result = DB_query($sql, $db);
    $myrow = DB_fetch_array($result);
    $title = $myrow['title'];
    $count = 0;
    $i = 0;
    $bus_report = new bus_report($_POST['student_id'], $_POST['period_id'], $db);
    $status_array = tep_get_status($db);
    echo "<form method='post' action=" . $_SERVER['PHP_SELF'] . "?" . SID . ">";
    echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />';
    echo "<table class=enclosed>";
    echo "<tr><td colspan='8'><font size='16'>" . _('AFRICAN INSTITUTE') . "</td></tr>";
    echo "<tr><td colspan='8' align='center'><font size='4'>" . _('of Research & Development Studies') . "</td></tr>";
    echo "<tr><td colspan='8' align='center'><font size='2'>" . _('RegNO') . _(': ') . $_SESSION['student'] . _('  ') . _('Term') . _(': ') . $title . _(' ') . _('Course') . _(': ') . $course . "</td></tr>";
    echo "<tr><td>" . _('Subject') . "</td>";
    foreach ($status_array as $r => $s) {
        echo "<td>" . $s['title'] . "</td>";
    }
    echo "<td>" . _('Total(%)') . "</td>";
    echo "<td>" . _('Grade') . "</td>";
    echo "<td>" . _('Comment') . "</td>";
    echo "</tr>";
 $standard = $myrow[3];
 $YPos += 20;
 $YPos -= $line_height;
 $YPos -= 12 * $line_height;
 $YPos -= 83;
 $YPos3 = $YPos;
 $YPos -= $line_height;
 $pdf->line(60, $YPos + $line_height, $Page_Width - $Right_Margin - 25, $YPos + $line_height, $style);
 $line_width = 70;
 $XPos = 170;
 $XPos5 = 100;
 $XPos6 = 100;
 $YPos2 = $YPos;
 $count = 0;
 $i = 0;
 $bus_report = new bus_report($myrowstudent['student_id'], $_POST['period_id'], $db);
 $YPos -= 5 * $line_height;
 foreach ($bus_report->scheduled_subjects as $a => $b) {
     $count = $count + 1;
     $scheduled = new scheduled($b['subject_id'], $db);
     $scheduled->set_calendar_vars($b['id'], $b['subject_id'], $myrowstudent['student_id'], $_POST['period_id'], $_POST['exam_mode'], $db);
     $LeftOvers = $pdf->addTextWrap(70, $YPos + 1, 300, $FontSize, $scheduled->subject_name);
     $pdf->line(60, $YPos + $line_height, $Page_Width - $Right_Margin - 25, $YPos + $line_height, $style);
     $status_array = tep_get_status($_POST['period_id'], $myrowstudent['student_id'], $db);
     $XPos2 = 200;
     $YPos -= 1 * $line_height;
     $LeftOvers = $pdf->addTextWrap($XPos2 + 50, $YPos + 15, 300, $FontSize, $scheduled->exam_marks);
     $XPos2 += 40;
     $totalmarks_array = $bus_report->total_marks($b['subject_id'], $myrowstudent['student_id'], $_POST['period_id'], $b['id'], $db);
     if (!isset($scheduled->exam_marks)) {
         $subjectGrade = '';
Ejemplo n.º 7
0
    include 'includes/header.inc';
    ?>
<html><body><br /><br /><br />
<?php 
    $_SESSION['period'] = $_POST['period_id'];
    $sql = "SELECT dtr.name,dtr.debtorno,dp.department_name,cs.course_name as course,gl.grade_level FROM debtorsmaster dtr\nINNER JOIN courses cs ON cs.id=dtr.course_id\nINNER JOIN departments dp ON dp.id=cs.department_id\nINNER JOIN gradelevels gl ON gl.id=dtr.grade_level_id \n\t\tWHERE debtorno =  '" . $_SESSION['UserID'] . "'";
    $result = DB_query($sql, $db);
    $myrow = DB_fetch_row($result);
    $course = $myrow['course'];
    $sql = "SELECT cp.id,terms.title,years.year,cp.end_date FROM collegeperiods cp\n\t\tINNER JOIN terms ON terms.id=cp.term_id\n\t\tINNER JOIN years ON years.id=cp.year \n\t\tWHERE cp.id='" . $_SESSION['period'] . "'";
    $result = DB_query($sql, $db);
    $myrow = DB_fetch_array($result);
    $title = $myrow['title'];
    $count = 0;
    $i = 0;
    $bus_report = new bus_report($_SESSION['UserID'], $_POST['period_id'], $db);
    $status_array = tep_get_status($db);
    echo "<form method='post' action=" . $_SERVER['PHP_SELF'] . "?" . SID . ">";
    echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />';
    echo "<table  width='50%' align='center' border=\"1\" >";
    echo "<tr><td colspan='8'  class=\"centered\"><font size='4'>" . _('Masinde Muliro University of Science & Technology') . "</td></tr>";
    echo "<tr><td colspan='8' class=\"centered\"><font size='4'>" . _('End semester Marks Report') . "</td></tr>";
    echo "<tr><td colspan='2' align='center'><font size='4'>" . _('RegNO') . _(': ') . $_SESSION['UserID'] . "</td><td colspan='5'>" . _('  ') . _('Term') . _(': ') . $title . _(' ') . _('Course') . _(': ') . $course . "</td></tr>";
    echo "<tr><td class=\"visible\">" . _('Subject') . "</td>";
    foreach ($status_array as $r => $s) {
        echo "<td class=\"visible\">" . $s['title'] . "</td>";
    }
    echo "<td class=\"visible\">" . _('Total(%)') . "</td>";
    echo "<td class=\"visible\">" . _('Points') . "</td>";
    echo "<td class=\"visible\">" . _('Grade') . "</td>";
    echo "</tr>";
Ejemplo n.º 8
0
 $ReportCard = 1;
 $YPos -= 75;
 $YPos -= $line_height;
 //Note, this is ok for multilang as this is the value of a Select, text in option is different
 $YPos -= 5 * $line_height;
 /*Draw a rectangle to put the headings in     */
 $pdf->line($Left_Margin, $YPos + $line_height, $Page_Width - $Right_Margin, $YPos + $line_height);
 $FontSize = 13;
 $YPos -= 1.5 * $line_height;
 $PageNumber++;
 $line_width = 70;
 $XPos = 150;
 $YPos2 = $YPos;
 $count = 0;
 $i = 0;
 $bus_report = new bus_report($_POST['period_id'], $db);
 foreach ($bus_report->scheduled_subjects as $a => $b) {
     $scheduled = new scheduled($b['subject_id'], $db);
     $scheduled->set_calendar_vars($b['id'], $db);
     if ($ReportCard == 1) {
         $FontSize = 13;
         $YPos = $Page_Height - $Top_Margin;
         $XPos = 0;
         $status_array = tep_get_status($db);
         foreach ($status_array as $r => $s) {
             $LeftOvers = $pdf->addTextWrap($XPos + 45, $YPos, 300, $FontSize, $s['title']);
             $XPos += 1 * $line_width;
         }
         $YPos = 620;
         $count = $count + 1;
         $LeftOvers = $pdf->addTextWrap(50, $YPos, 300, $FontSize, $scheduled->subject_name);
Ejemplo n.º 9
0
 $pdf->line($Left_Margin, $YPos, $Page_Width - $Right_Margin, $YPos, $style);
 $YPos -= 1 * $line_height;
 $FontSize = 9;
 $LeftOvers = $pdf->addTextWrap(200, $YPos, 400, $FontSize, _('STUDENT ACADEMIC PROGRESS REPORT'));
 $YPos -= 0.5 * $line_height;
 $LeftOvers = $pdf->addTextWrap(200, $YPos, 100, $FontSize, '______________________________________________________________________________');
 $FontSize = 8;
 $YPos -= 55;
 $XPos = 170;
 $line_width = 50;
 $pdf->line($Left_Margin, $YPos, $Page_Width - $Right_Margin, $YPos, $style);
 $YPos -= 1 * $line_height;
 $YPos2 = $YPos + $line_height;
 $count = 0;
 $i = 0;
 $bus_report = new bus_report($myrowclass['student_id'], $_POST['term'], $_POST['year'], $db);
 $status_array = tep_get_status($db);
 $YPos = 430;
 foreach ($status_array as $r => $s) {
     $LeftOvers = $pdf->addTextWrap(45, $YPos + 20, 300, $FontSize, _('NO'));
     $LeftOvers = $pdf->addTextWrap(70, $YPos + 20, 300, $FontSize, _('COURSE DESCRIPTION'));
     $pdf->starttransform();
     $pdf->xy($XPos, 332);
     $pdf->rotate(90);
     $LeftOvers = $pdf->addTextWrap($XPos - 65, $YPos - 15, 300, $FontSize, $s['title']);
     $pdf->stoptransform();
     $XPos += 0.5 * $line_width;
 }
 foreach ($bus_report->scheduled_subjects as $a => $b) {
     $count = $count + 1;
     $scheduled = new scheduled($b['subject_id'], $db);