Viewing file: v_showTimeQn.php (4 KB) -rwxr-xr-x Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
$row_tq = (isset($qu_tq) && $qu_tq!=NULL) ? $qu_tq->row() : NULL;
?>
<table width="60%" align="center">
<tr>
<td align="center"><span class="h error">กำหนดเงื่อนไขการตอบแบบสอบถามของผู้สำเร็จการศึกษา</span></td>
</tr>
<tr>
<td><br /></td>
</tr>
<tr>
<td><table class="szone"><?php echo form_open($this->config->item("ea_folder")."timeqn/processTimeQn", array("name" => "myform", "id" => "myform"));?>
<tr bgcolor="<?php echo $this->config->item('tr_c_even');?>">
<td class="coltd_szone">ปีการศึกษาที่จบ</td>
<td colspan="3">
<?php
if($row_tq==NULL) {
?>
<input type="text" name="graduateY" id="graduateY" value="<?php echo setValue('graduateY',$row_tq);?>" size="5" maxlength="4" class="required-int" />
<span class="error"> *<?php echo form_error('graduateY');?></span>
<?php
} else {
echo setValue('graduateY',$row_tq);
?>
<input type="hidden" name="graduateY" id="graduateY" value="<?php echo setValue('graduateY',$row_tq);?>" />
<?php
}
?>
</td>
</tr>
<tr bgcolor="<?php echo $this->config->item('tr_c_even');?>">
<td class="coltd_szone">วันที่เริ่มต้น</td>
<td><script>DateInput('startDate', true, 'DD/MM/YYYY', "<?php echo (set_value('startDate')!="") ? set_value('startDate') : (setValue('startDate',$row_tq)!="" ? splitDateDb2(setValue('startDate',$row_tq),'/') : getNowDateFw2());?>")</script></td>
<td class="coltd_szone">วันที่สิ้นสุด</td>
<td><script>DateInput('endDate', true, 'DD/MM/YYYY', "<?php echo (set_value('endDate')!="") ? set_value('endDate') : (setValue('endDate',$row_tq)!="" ? splitDateDb2(setValue('endDate',$row_tq),'/') : getNowDateFw2());?>")</script>
<span class="error"><?php echo form_error('endDate');?></span></td>
</tr>
<tr bgcolor="<?php echo $this->config->item('tr_c_even');?>">
<td colspan="4" align="center">
<input type="submit" name="add" id="add" value="บันทึก" />
<input type="hidden" name="seqId" id="seqId" value="<?php echo setValue('seqId',$row_tq);?>" />
</td>
</tr>
<?php echo form_close();?></table></td>
</tr>
<tr>
<td><br /></td>
</tr>
<tr>
<td><table class="headCol">
<tr bgcolor="<?php echo $this->config->item('table_c_even');?>">
<th class="hourCol">ปีการศึกษาที่จบ</th>
<th>ระยะเวลาตอบแบบสอบถาม</th>
<th class="editCol">แก้ไข</th>
<th class="deleteCol">ลบ</th>
</tr>
<?php
$i = 0;
if(isset($rs_tq) && $rs_tq->num_rows()) {
foreach($rs_tq->result() as $row_tq) {
echo "<tr onmouseover=\"bgColor='".$this->config->item('tr_c_even')."'\" onmouseout=\"bgColor='".$this->config->item("rg_mouseout")."'\">";
?>
<td align="center"><?php echo $row_tq->graduateY;?></td>
<td class="indent"><?php echo abbreDate2($row_tq->startDate).' - '.abbreDate2($row_tq->endDate);?></td>
<td align="center">
<img class="hand" src="<?php echo base_url().$this->config->item('rg_edit');?>" align="absmiddle" border="0"
onClick="sendPost('hidform',
{'seqId':<?php echo $row_tq->seqId;?>},
'<?php echo site_url($this->config->item('ea_folder').'timeqn/showTimeQn');?>')" /></td>
<td align="center">
<img class="hand" src="<?php echo base_url().$this->config->item('rg_delete');?>" align="absmiddle" border="0" onClick="confirmDel2({seqId:<?php echo $row_tq->seqId;?>}, 'm_form1','<?php echo site_url($this->config->item('ea_folder').'timeqn/deleteTimeQn');?>')" /></td>
</tr>
<?php
$i++;
}
} else {
?>
<tr>
<td colspan="4" align="center"><span class="error">** ไม่ปรากฏรายการในฐานข้อมูล **</span></td>
</tr>
<?php
}
?>
</table></td>
</tr>
<tr>
<td align="right">รวม <?php echo $i;?> รายการ</td>
</tr>
</table>
|