Viewing file:      v_rptRis110.php (4.69 KB)      -rwxr-xr-x Select action/file-type:    (+) |   (+) |   (+) | Code (+) | Session (+) |   (+) | SDB (+) |   (+) |   (+) |   (+) |   (+) |   (+) |
 
<table width="100%" align="center">
     <tr>
         <td>
             <table width="100%">
                 <tr>
                     <td align="center" colspan="4"><font class="h error">รายวิชาที่สอน</font></td>
                 </tr>
                 <tr>
                     <td><br /></td>
                 </tr>
                 <tr>
                     <td colspan="4">
                     <table class="szone">
                     <tr bgcolor="<?php echo $tr_color_even;?>">
                         <td class="coltd_szone">ปีการศึกษา</td>
                         <td>:<?php echo $acY;?></td>
                         <td class="coltd_szone">ภาคการศึกษา</td>
                         <td>:<?php echo $tmId;?></td>
                     </tr>
                     <tr bgcolor="<?php echo $tr_color_even;?>">
                         <td class="coltd_szone">รหัสรายวิชา</td>
                         <td>: *<?php echo $courseCode;?>*</td>
                         <td class="coltd_szone">กลุ่มเรียน</td>
                         <td>:<?php echo $section;?></td>
                     </tr>    
                     <tr>
                         <td height="22" colspan="4"></td>
                     </tr>
                     </table>
                 </td></tr>
                 <tr>
                     <td colspan="4">
                     <table class="headCol">
                         <tr bgcolor="<?=$this->config->item("rg_table_color")?>">
                             <th width="12%" height="22" align="center"><font size="2" color="<?=$font_color_table;?>"><strong>รหัสรายวิชา</strong></font></th>
                             <th width="40%" align="center"><font size="2" color="<?=$font_color_table;?>"><strong>ชื่อรายวิชา</strong></font></th>
                             <th width="38%" align="center"><font size="2" color="<?=$font_color_table;?>"><strong>ชื่ออาจารย์ผู้สอน</strong></font></th>
                             <th width="10%" align="center"><font size="2" color="<?=$font_color_table;?>"><strong>พิมพ์</strong></font></th>
                         </tr>
 <?php 
                         $i = 0;
                         if($rs_co->num_rows()) {
                             foreach($rs_co->result() as $row) {
 
                             $pgNames = '';
                             if(is_null($row->coCurId)) {
                             
                                 $k = 0;
                                 $cofCon = array('cofCoId' => $row->coId);
                                 $rs_cof = $cof->qryCofJoinCur($cofCon);
                                 if($rs_cof->num_rows()) {
                                     foreach($rs_cof->result() as $row_cof) {
                                         if($k == 0)
                                             $pgNames = $row_cof->curName;
                                         else
                                             $pgNames .= '<br> '.$row_cof->curName;
                                         
                                         $k++;
                                     
                                     }
                                 }
                             }
                             else {
                             
                                 $cur->curId = $row->coCurId;
                                 $qu_cur = $cur->get_by_key();    
                                 if($qu_cur->num_rows()) { 
                                     $row_cur = $qu_cur->row();
                                 
                                     $pgNames = $row_cur->curName;
                                 }
                             }
 
                             echo "<tr onmouseover=\"bgColor='".$tr_color_even."'\" onmouseout=\"bgColor='".$this->config->item("rg_mouseout")."'\">";
 ?>
                             <td height="22"><font size="2" ><?php echo (isset($row->crsCode)) ? $row->crsCode : '' ;?></font></td>
                             <td><font size="2" ><?php echo (isset($row->crsName)) ? explodeSquare($row->crsName) : '';?></font><br>
                             <font size="2" color="<?=$font_color_err;?>"><?php echo '['.$pgNames.']';?></font></td>
                             <td><font size="2" >
 <?php  
                             $j = 0;
                             $ttbCon = array('ttCoId' => ((isset($row->coId)) ? $row->coId : ''));
                             $ttbGroup = array('ttPrsId' => 'ttPrsId');
                             $rs_tt = $tt->qryTtJoinPeopleCenter($ttbCon,'',$ttbGroup);
                             if($rs_tt->num_rows() > 0) {
                                 foreach($rs_tt->result() as $rowtt) {
                                     if($j != 0) echo '<br>';
                                     echo $rowtt->prefixName.$rowtt->fName.' '.$rowtt->lName;
                                     $j++;
                                 }
                             }
                             
 ?>
                             </font></td>
                             <td align="center">
 <?php
                             echo anchor_popup($this->config->item("rg_folder")."rpt_regis/RptRis110/".((isset($row->coId)) ? $row->coId : '0')."/".$acY."/".$tmId."/".((isset($row->coCurId)) ? $row->coCurId : 'NULL'), "<img src=\"".base_url().$this->config->item("rg_print")."\" align=\"abmiddle\" title=\"ส่งออกเป็น Excel\" />");
 ?>
                             </td>
                         </tr>
 <?php
                             $i++;
                         }
                     }
                         
                         if($i == 0) {
 ?>
                         <tr>
                             <td colspan="4" align="center"><font size="2" >** ไม่ปรากฏรายวิชาที่สอนในฐานข้อมูล **</font></td>
                         </tr>
 <?php
                         }
 ?>
                     </table>
                     </td>
                 </tr>
                 <tr>
                 <!--     <td colspan="3"><input type="button" name="cancel" value="ย้อนกลับ" onClick="window.location = '<?php echo site_url($this->config->item("rg_folder")."rpt_regis/searchRptRis109");?>'" />
                     <input type="button" name="back" value="กลับเมนูหลัก" onClick="location.href = 'adminIndex.php?mm=1'"></td> -->    
                     <td align="right" colspan="4"><font size="2">รวม <?php echo $i;?> รายการ</font></td>
                 </tr>
             </table>
             
         <?php echo form_close();?>
       </div><br></td>
     </tr>
 </table>
  |