Viewing file: v_editStdMBHis4.php (6.13 KB) -rwxr-xr-x Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
$row_cfg = (isset($qu_cfg) && $qu_cfg->num_rows()) ? $qu_cfg->row() : NULL;
$row_std = (isset($qu_std) && $qu_std->num_rows()) ? $qu_std->row() : NULL;
?>
<table width="100%" border="0">
<tr>
<td><table class="szone">
<?php echo form_open($this->config->item("rg_folder")."studenthis/std_insertStdMBHis4", array("name" => "myform", "id" => "myform"));?>
<tr bgcolor="<?php echo setValue('cfgBgClSwapTr',$row_cfg);?>">
<td colspan="2" height="25" align="center"><span class="h error">เพิ่มประวัติความประพฤติ</span></td>
</tr>
<tr bgcolor="<?php echo setValue('cfgBgClSwapTr',$row_cfg);?>">
<td class="coltd_szone">ปีการศึกษา (พ.ศ.)</td>
<td><input type="text" name="sbeAcY" id="sbeAcY" value="<?php echo set_value('sbeAcY',$acY);?>" size="5" maxlength="4" class="required-int" />
<span class="error">*<?php echo form_error('sbeAcY');?></span></td>
</tr>
<tr bgcolor="<?php echo setValue('cfgBgClSwapTr',$row_cfg);?>">
<td class="coltd_szone">ภาคการศึกษา</td>
<td>
<?php
echo form_dropdown('sbeTmId', $rs_tm, set_value('sbeTmId'));
?>
</td>
</tr>
<tr bgcolor="<?php echo setValue('cfgBgClSwapTr',$row_cfg);?>">
<td class="coltd_szone">รายละเอียด</td>
<td><input type="text" name="sbeDescription" id="sbeDescription" value="<?php echo set_value('sbeDescription');?>" size="50" maxlength="50" />
<span class="error">*<?php echo form_error('sbeDescription');?></span></td>
</tr>
<tr bgcolor="<?php echo setValue('cfgBgClSwapTr',$row_cfg);?>">
<td class="coltd_szone">ระดับคะแนน</td>
<td><input type="text" name="dcpName" id="dcpName" value="<?php echo set_value('dcpName');?>" size="70" readonly class="input2" />
<input type="hidden" name="sbeDcpId" id="sbeDcpId" value="<?php echo set_value('sbeDcpId');?>" readonly /></td>
</tr>
<tr bgcolor="<?php echo setValue('cfgBgClSwapTr',$row_cfg);?>">
<td class="coltd_szone">คะแนนที่ตัด</td>
<td><input type="text" name="sbeCutPoint" id="sbeCutPoint" value="<?php echo set_value('sbeCutPoint');?>" size="4" readonly class="input2" />
<?php
echo anchor_popup($this->config->item("rg_folder")."popup/dcp_popup", "<img src=\"".base_url().$this->config->item('rg_search')."\" width=\"15\" height=\"19\" align=\"absmiddle\" border=\"0\" />", array("width" => "500", "height" => "300"));
?>
<span class="error">*<?php echo form_error('sbeDcpId');?></span></td>
</tr>
<tr bgcolor="<?php echo setValue('cfgBgClSwapTr',$row_cfg);?>">
<td class="coltd_szone">วันที่เกิดเหตุ</td>
<td><script>DateInput('sbeRecordDate', true, 'DD/MM/YYYY', '<?php echo (set_value("sbeRecordDate")=="") ? getNowDateFw2() : set_value("sbeRecordDate");?>');</script>
<?php echo form_error('sbeRecordDate');?></td>
</tr>
<tr bgcolor="<?php echo setValue('cfgBgClSwapTr',$row_cfg);?>">
<td class="coltd_szone">วันที่อนุมัติ</td>
<td><script>DateInput('sbeApproveDate', true, 'DD/MM/YYYY', '<?php echo (set_value("sbeApproveDate")=="") ? getNowDateFw2() : set_value("sbeApproveDate");?>');</script>
<?php echo form_error('sbeApproveDate');?></td>
</tr>
<tr bgcolor="<?php echo setValue('cfgBgClSwapTr',$row_cfg);?>">
<td colspan="2" align="center">
<input type="submit" name="add" id="add" value="บันทึก" />
<input type="reset" name="clear" id="clear" value="เคลียร์ข้อมูล" />
<input type="hidden" name="tab" id="tab" value="<?php echo $tab;?>" />
<input type="hidden" name="stdId" id="stdId" value="<?php echo $stdId;?>" />
<input type="hidden" name="stdAdY" id="stdAdY" value="<?php echo setValue('stdAdY',$row_std);?>" /></td>
</tr>
<?php echo form_close();?></table></td>
</tr>
<tr>
<td><br /></td>
</tr>
<tr>
<td><table class="headCol">
<tr>
<th colspan="7">แสดงประวัติความประพฤติ</th>
</tr>
<tr>
<th class="domAmtCol">ภาค/ปีการศึกษา</th>
<th class="domAmtCol">วันที่เกิดเหตุ</th>
<th>รายละเอียด</th>
<th>ระดับคะแนน</th>
<th class="stdCodeCol">คะแนนที่ตัด</th>
<th class="domAmtCol">วันที่อนุมัติ</th>
<th class="deleteCol">ลบ</th>
</tr>
<?php
$i = 0;
if(isset($rs_sbe) && $rs_sbe->num_rows()) {
foreach($rs_sbe->result() as $row) {
echo "<tr onmouseover=\"bgColor='".setValue('cfgBgClSwapTr',$row_cfg)."'\" onmouseout=\"bgColor='".$this->config->item("rg_mouseout")."'\">";
?>
<td align="center"><?php echo $row->tmCode.'/'.$row->sbeAcY;?></td>
<td align="center"><?php echo abbreDate2($row->sbeRecordDate);?></td>
<td class="indent"><?php echo $row->sbeDescription;?></td>
<td class="indent"><?php echo $row->dcpName;?></td>
<td align="center"><?php echo $row->sbeCutPoint;?></td>
<td align="center"><?php echo abbreDate2($row->sbeApproveDate);?></td>
<td align="center">
<span onClick="confirmDel2({sbeStdId:<?php echo $row->sbeStdId;?>, sbeSeq:<?php echo $row->sbeSeq;?>, tab:<?php echo $tab;?>}, 'm_form1','<?php echo site_url($this->config->item('rg_folder').'studenthis/std_deleteStdMBHis4');?>')" /><img src="<?php echo base_url().$this->config->item('rg_delete');?>" align="absmiddle" border="0" width="16" height="19" class="hand"/></span></td>
<?php
$i++;
}
} else {
?>
<tr>
<td colspan="7" align="center"><span class="error">** ไม่ปรากฎรายการประวัติด้านการศึกษาในฐานข้อมูล **</span></td>
</tr>
<?php
}
?>
</table></td>
</tr>
<tr>
<td align="right">รวม <?php echo $i;?> รายการ</td>
</tr>
<tr>
<td><br /></td>
</tr>
<tr>
<td class="error"><b>หมายเหตุ</b> : * หมายถึง ต้องกรอกข้อมูลให้สมบูรณ์</td>
</tr>
</table>
|