Viewing file: v_addCourseOpenStudent.php (3.3 KB) -rwxr-xr-x Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php $row_co = isset($qu_co) ? $qu_co->row() : NULL; ?> <?php echo form_open($this->config->item("rg_folder")."popup/cos_insert", array("name" => "myform", "id" => "myform"));?> <table width="100%" cellpadding="0" cellspacing="0"> <tr> <td colspan="2"><br /></td> </tr> <tr> <td colspan="2"><table class="szone"> <tr> <td><font size="2"><b>รายวิชา</b> <?php echo getval('crsCode',$row_co).' '.getval('crsName',$row_co).' กลุ่ม '.getval('coSection',$row_co);?></font> <input type="hidden" id="cosCoId" name="cosCoId" value="<?php echo getval('coId',$row_co);?>"></td> </tr> </table></td> </tr> <tr> <td colspan="2"><table class="headCol"> <tr> <th class="seqCol"><span>เลือก</span></th> <th class="seqCol"><span>ลำดับที่</span></th> <th class="stdCodeCol"><span>รหัสนักศึกษา</span></th> <th><span>ชื่อ-นามสกุลนักศึกษา</span></th> <th class="editCol"><span>กลุ่ม</span></th> </tr> <?php $num_rows = count($rs); if ($num_rows) { foreach ($rs as $key => $val) { $row_std = isset($rs[$key]['qu_std']) ? $rs[$key]['qu_std']->row() : NULL;
echo "<tr onmouseover=\"bgColor='".$tr_color_even."'\" onmouseout=\"bgColor='".$this->config->item("rg_mouseout")."'\">"; ?> <td align="center"> <?php if ($rs[$key]['dsb'] == '') { ?> <input type="checkbox" id="order<?php echo $key;?>" name="order<?php echo $key;?>" value="Y" <?php echo $rs[$key]['dsb'].' '.$rs[$key]['chk'];?> /> <?php } ?> <input type="hidden" id="cosStdId<?php echo $key;?>" name="cosStdId<?php echo $key;?>" value="<?php echo getval('stdId', $row_std);?>" /></td> <td align="center"><span><?php echo $key + 1;?></span></td> <td align="center"><span><?php echo getval('stdCode', $row_std);?></span></td> <td class="indent"><span><?php echo getval('prefixName', $row_std).getval('stdName', $row_std).' '.getval('stdSurname', $row_std);?></span></td> <td align="center"><span><?php echo $rs[$key]['section'];?></span></td> </tr> <?php } } else { ?> <tr> <td colspan="5" height="22" align="center"><span class="error">** ไม่ปรากฏรายการในฐานข้อมูล **</span></td> </tr> <?php } ?> </table></td> </tr> <tr> <td><input type="button" name="chkAll" value="เลือกทั้งหมด" onClick="doCheckAll(this.form, true)" <?php echo ($num_rows == 0) ? 'disabled' : '';?>> <input type="button" name="cancelAll" value="ยกเลิกทั้งหมด" onClick="doCheckAll(this.form, false)" <?php echo ($num_rows == 0) ? 'disabled' : '';?>></td> <td align="right"><font size="2" >รวม <?php echo $num_rows;?> รายการ</font></td> </tr> <tr> <td colspan="2" align="center"> <input type="submit" name="add" value="บันทึก" <?php echo (($num_rows == 0) || $cntStd) ? 'disabled' : '';?> /> <input type="hidden" id="curId" name="curId" value="<?php echo $curId;?>" /> <input type="hidden" id="add" name="add" value="add" /> <input type="hidden" id="cnt" name="cnt" value="<?php echo $num_rows;?>" /></td> </tr> </table> <?php echo form_close();?>
<?php if(isset($add)) { ?> <script> self.window.opener.location.reload(); window.close(); </script> <?php } ?>
|